aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDylan Reid <dgreid@chromium.org>2014-02-28 18:41:31 -0500
committerTakashi Iwai <tiwai@suse.de>2014-03-01 05:23:41 -0500
commitf0a220dedd59e23cec7a9a057b3f2f415f47fac6 (patch)
tree24f4d73efd8bc74272790ea3091ed002367a1970
parent154867cf4ea8307d7acac2dcf7952873105ceb1c (diff)
ALSA: core - Define snd_pci_quirk without CONFIG_PCI
The hda codecs all use this struct and, with an HDA platform driver, will be able to be built without PCI. Signed-off-by: Dylan Reid <dgreid@chromium.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r--include/sound/core.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/include/sound/core.h b/include/sound/core.h
index aac9a8590265..d3f5f818e0b9 100644
--- a/include/sound/core.h
+++ b/include/sound/core.h
@@ -433,7 +433,6 @@ static inline void snd_printdd(const char *format, ...) {}
433#define gameport_get_port_data(gp) (gp)->port_data 433#define gameport_get_port_data(gp) (gp)->port_data
434#endif 434#endif
435 435
436#ifdef CONFIG_PCI
437/* PCI quirk list helper */ 436/* PCI quirk list helper */
438struct snd_pci_quirk { 437struct snd_pci_quirk {
439 unsigned short subvendor; /* PCI subvendor ID */ 438 unsigned short subvendor; /* PCI subvendor ID */
@@ -469,12 +468,26 @@ struct snd_pci_quirk {
469#define snd_pci_quirk_name(q) "" 468#define snd_pci_quirk_name(q) ""
470#endif 469#endif
471 470
471#ifdef CONFIG_PCI
472const struct snd_pci_quirk * 472const struct snd_pci_quirk *
473snd_pci_quirk_lookup(struct pci_dev *pci, const struct snd_pci_quirk *list); 473snd_pci_quirk_lookup(struct pci_dev *pci, const struct snd_pci_quirk *list);
474 474
475const struct snd_pci_quirk * 475const struct snd_pci_quirk *
476snd_pci_quirk_lookup_id(u16 vendor, u16 device, 476snd_pci_quirk_lookup_id(u16 vendor, u16 device,
477 const struct snd_pci_quirk *list); 477 const struct snd_pci_quirk *list);
478#else
479static inline const struct snd_pci_quirk *
480snd_pci_quirk_lookup(struct pci_dev *pci, const struct snd_pci_quirk *list)
481{
482 return NULL;
483}
484
485static inline const struct snd_pci_quirk *
486snd_pci_quirk_lookup_id(u16 vendor, u16 device,
487 const struct snd_pci_quirk *list)
488{
489 return NULL;
490}
478#endif 491#endif
479 492
480#endif /* __SOUND_CORE_H */ 493#endif /* __SOUND_CORE_H */