[alsa-devel] [PATCH 1/2] acore: deprecated function in wrappers.c

Takashi Iwai tiwai at suse.de
Fri Feb 25 16:55:06 CET 2011


At Fri, 25 Feb 2011 16:51:53 +0100,
Grzegorz Daniluk wrote:
> 
> Takashi Iwai wrote:
> >
> > Erm... this code is defined _only_ for very old kernels just for
> > compatible wrapper, so following the rule for new kernels doesn't make
> > sense.
> >
> >
> >   
> Then something else is wrong, since this code caused the compilation 
> error(attached below) when I was doing the cross-compilation for the 
> system without PCI for the 2.6.35 kernel (the kernel version was 
> correctly recognized during ./configure):
> 
> /root/alsa-driver-1.0.24/acore/wrappers.c: In function 
> 'snd_pci_dev_present':
> /root/alsa-driver-1.0.24/acore/wrappers.c:200: error: implicit 
> declaration of function 'pci_find_device'
> make[3]: *** [/root/alsa-driver-1.0.24/acore/wrappers.o] Error 1

Then configure script didn't detect the condition properly.
Check CONFIG_HAVE_PCI_DEV_PRESENT in you config.log.  Most likely
a wrong gcc option or path is given, and the check is screwed up.


Takashi



> 
> Greg
> 
> >> Signed-off-by: Grzegorz Daniluk <g.daniluk at elproma.com.pl>
> >> ---
> >>
> >> diff -uprN a/acore/wrappers.c b/acore/wrappers.c
> >> --- a/acore/wrappers.c    2011-01-27 12:09:20.000000000 +0000
> >> +++ b/acore/wrappers.c    2011-02-25 13:41:46.000000000 +0000
> >> @@ -197,7 +197,7 @@ EXPORT_SYMBOL(snd_compat_devfs_mk_cdev);
> >>  int snd_pci_dev_present(const struct pci_device_id *ids)
> >>  {
> >>      while (ids->vendor || ids->subvendor) {
> >> -        if (pci_find_device(ids->vendor, ids->subvendor, NULL))
> >> +        if (pci_get_device(ids->vendor, ids->subvendor, NULL))
> >>              return 1;
> >>          ids++;
> >>      }
> >> _______________________________________________
> >> Alsa-devel mailing list
> >> Alsa-devel at alsa-project.org
> >> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
> >>
> >>     
> >
> >   
> 


More information about the Alsa-devel mailing list