Skip to contentSkip to conversation

ALSA: Include linux/pci.h in sound/core.h

PATCH In review Axel Lin 1 participant 2 messages Jan 30, 2012 Sound

lore
Share & tools
lore

Axel Lin

author
#0 lore raw

PATCH 1/1 ALSA: Include linux/pci.h in sound/core.h

commit d1458279b "ALSA: Add snd_pci_quirk_lookup_id()" introduces below build
waring:
CC sound/sound_core.o
In file included from sound/sound_core.c:15:
include/sound/core.h:454: warning: 'struct pci_dev' declared inside parameter list include/sound/core.h:454: warning: its scope is only this definition or declaration, which is probably not what you want

Include linux/pci.h to fix the build warning.

---
 include/sound/core.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
include/sound/core.h +1 -0
index 5ab255f..4ea14f2 100644
@@ -28,6 +28,7 @@
 #include <linux/pm.h>			/* pm_message_t */
 #include <linux/device.h>
 #include <linux/stringify.h>
+#include <linux/pci.h>
 
 /* number of supported soundcards */
 #ifdef CONFIG_SND_DYNAMIC_MINORS
Signature · 1 line
1.7.5.4
author
#1 lore raw

2012/1/30 Axel Lin <[email protected]>:

Quoted 9 lines

commit d1458279b "ALSA: Add snd_pci_quirk_lookup_id()" introduces below build
waring:
 CC      sound/sound_core.o
In file included from sound/sound_core.c:15:
include/sound/core.h:454: warning: 'struct pci_dev' declared inside parameter list include/sound/core.h:454: warning: its scope is only this definition or declaration, which is probably not what you want

Include linux/pci.h to fix the build warning.

oh.. The correct fix should be to add #ifdef CONFIG_PCI guard for snd_pci_quirk_*
I'll send the fix now.

Axel