diff options
Diffstat (limited to 'sound/pci/intel8x0.c')
-rw-r--r-- | sound/pci/intel8x0.c | 40 |
1 files changed, 15 insertions, 25 deletions
diff --git a/sound/pci/intel8x0.c b/sound/pci/intel8x0.c index c8f51489684..f7b4d0c5d49 100644 --- a/sound/pci/intel8x0.c +++ b/sound/pci/intel8x0.c | |||
@@ -2692,36 +2692,26 @@ static void __devinit intel8x0_measure_ac97_clock(struct intel8x0 *chip) | |||
2692 | snd_ac97_update_power(chip->ac97[0], AC97_PCM_FRONT_DAC_RATE, 0); | 2692 | snd_ac97_update_power(chip->ac97[0], AC97_PCM_FRONT_DAC_RATE, 0); |
2693 | } | 2693 | } |
2694 | 2694 | ||
2695 | struct intel8x0_clock_list { | 2695 | static struct snd_pci_quirk intel8x0_clock_list[] __devinitdata = { |
2696 | unsigned short subvendor; | 2696 | SND_PCI_QUIRK(0x0e11, 0x008a, "AD1885", 41000), |
2697 | unsigned short subdevice; | 2697 | SND_PCI_QUIRK(0x1028, 0x00be, "AD1885", 44100), |
2698 | unsigned int rate; | 2698 | SND_PCI_QUIRK(0x1028, 0x0177, "AD1980", 48000), |
2699 | }; | 2699 | SND_PCI_QUIRK(0x1043, 0x80f3, "AD1985", 48000), |
2700 | 2700 | { } /* terminator */ | |
2701 | static struct intel8x0_clock_list intel8x0_clock_list[] __devinitdata = { | ||
2702 | { 0x0e11, 0x008a, 41000 }, /* Analog Devices AD1885 */ | ||
2703 | { 0x1028, 0x00be, 44100 }, /* Analog Devices AD1885 */ | ||
2704 | { 0x1028, 0x0177, 48000 }, /* Analog Devices AD1980 */ | ||
2705 | { 0x1043, 0x80f3, 48000 }, /* Analog Devices AD1985 */ | ||
2706 | { 0x0000, 0x0000, 00000 } /* terminator */ | ||
2707 | }; | 2701 | }; |
2708 | 2702 | ||
2709 | static int __devinit intel8x0_in_clock_list(struct intel8x0 *chip) | 2703 | static int __devinit intel8x0_in_clock_list(struct intel8x0 *chip) |
2710 | { | 2704 | { |
2711 | struct pci_dev *pci = chip->pci; | 2705 | struct pci_dev *pci = chip->pci; |
2712 | struct intel8x0_clock_list *wl; | 2706 | const struct snd_pci_quirk *wl; |
2713 | 2707 | ||
2714 | for (wl = intel8x0_clock_list; wl->subvendor; wl++) { | 2708 | wl = snd_pci_quirk_lookup(pci, intel8x0_clock_list); |
2715 | if (wl->subvendor == pci->subsystem_vendor && | 2709 | if (!wl) |
2716 | wl->subdevice == pci->subsystem_device) { | 2710 | return 0; |
2717 | printk(KERN_INFO "intel8x0: white list rate for %04x:%04x is %i\n", | 2711 | printk(KERN_INFO "intel8x0: white list rate for %04x:%04x is %i\n", |
2718 | pci->subsystem_vendor, | 2712 | pci->subsystem_vendor, pci->subsystem_device, wl->value); |
2719 | pci->subsystem_device, wl->rate); | 2713 | chip->ac97_bus->clock = wl->value; |
2720 | chip->ac97_bus->clock = wl->rate; | 2714 | return 1; |
2721 | return 1; | ||
2722 | } | ||
2723 | } | ||
2724 | return 0; | ||
2725 | } | 2715 | } |
2726 | 2716 | ||
2727 | #ifdef CONFIG_PROC_FS | 2717 | #ifdef CONFIG_PROC_FS |