Re: [PATCH v4 12/32] sound: usb: Export USB SND APIs for modules

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 25 Jul 2023 07:33:57 +0200,
Greg KH wrote:
> 
> On Mon, Jul 24, 2023 at 07:33:56PM -0700, Wesley Cheng wrote:
> > --- a/sound/usb/pcm.c
> > +++ b/sound/usb/pcm.c
> > @@ -87,7 +87,7 @@ static snd_pcm_uframes_t snd_usb_pcm_pointer(struct snd_pcm_substream *substream
> >  /*
> >   * find a matching audio format
> >   */
> > -static const struct audioformat *
> > +const struct audioformat *
> >  find_format(struct list_head *fmt_list_head, snd_pcm_format_t format,
> >  	    unsigned int rate, unsigned int channels, bool strict_match,
> >  	    struct snd_usb_substream *subs)
> > @@ -147,8 +147,9 @@ find_format(struct list_head *fmt_list_head, snd_pcm_format_t format,
> >  	}
> >  	return found;
> >  }
> > +EXPORT_SYMBOL_GPL(find_format);
> 
> This is a horrible symbol name for a global function, same for the other
> ones in this file.  If you really want to export them, please put them
> in the proper "snd_" prefix namespace, or better yet, use a module
> namespace as well to ensure that we know who is using them.

Yes, please add snd_usb_ prefix for all exported symbols from
USB-audio driver code.

Also, make sure that EXPORT_SYMBOL_GPL() is used for those, too.


thanks,

Takashi



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux