[alsa-devel] [PATCH v3 4/6] core: add API header and driver header files

Takashi Iwai tiwai at suse.de
Tue Dec 13 08:03:17 CET 2011


At Tue, 13 Dec 2011 12:01:30 +0530,
Vinod Koul wrote:
> 
> On Tue, 2011-12-13 at 14:11 +0800, Mark Brown wrote:
> > On Mon, Dec 05, 2011 at 01:09:49PM +0530, Vinod Koul wrote:
> > 
> > > +static inline void snd_compr_fragment_elapsed(struct snd_compr_stream *stream)
> > > +{
> > > +	wake_up(&stream->runtime->sleep);
> > > +}
> > 
> > You need to include sched.h for this.
> Hmmm, I have a different POV for these.
> I would like driver to include the sched.h here and this not be in
> header file.

In general, a header file should be self-contained as much as
possible.  Since you are calling it in an inline function, it'd be
more consistent to include sched.h in it.


Takashi


More information about the Alsa-devel mailing list