Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
ALSA: hda - Make the HP EliteBook 8530p use AD1884A model laptop
ALSA: gusextreme: Fix build errors
ALSA: hdsp: check for iobox and upload firmware during ioctl
ALSA: HDSP: check for io box before uploading firmware
ALSA: hda - Add another HP model (6730s) for AD1884A
alsa: fix snd_BUG_on() and friends
ALSA: hda - Add a quirk for MEDION MD96630
ALSA: hda - Limit the number of GPIOs show in proc

+35 -9
+7 -3
include/sound/core.h
··· 385 385 386 386 #else /* !CONFIG_SND_DEBUG */ 387 387 388 - #define snd_printd(fmt, args...) /* nothing */ 389 - #define snd_BUG() /* nothing */ 390 - #define snd_BUG_ON(cond) ({/*(void)(cond);*/ 0;}) /* always false */ 388 + #define snd_printd(fmt, args...) do { } while (0) 389 + #define snd_BUG() do { } while (0) 390 + static inline int __snd_bug_on(void) 391 + { 392 + return 0; 393 + } 394 + #define snd_BUG_ON(cond) __snd_bug_on() /* always false */ 391 395 392 396 #endif /* CONFIG_SND_DEBUG */ 393 397
+1 -1
sound/isa/Kconfig
··· 211 211 212 212 config SND_GUSEXTREME 213 213 tristate "Gravis UltraSound Extreme" 214 - select SND_HWDEP 214 + select SND_OPL3_LIB 215 215 select SND_MPU401_UART 216 216 select SND_PCM 217 217 help
+2
sound/pci/hda/hda_proc.c
··· 483 483 (gpio & AC_GPIO_UNSOLICITED) ? 1 : 0, 484 484 (gpio & AC_GPIO_WAKE) ? 1 : 0); 485 485 max = gpio & AC_GPIO_IO_COUNT; 486 + if (!max || max > 8) 487 + return; 486 488 enable = snd_hda_codec_read(codec, nid, 0, 487 489 AC_VERB_GET_GPIO_MASK, 0); 488 490 direction = snd_hda_codec_read(codec, nid, 0,
+2
sound/pci/hda/patch_analog.c
··· 3861 3861 static struct snd_pci_quirk ad1884a_cfg_tbl[] = { 3862 3862 SND_PCI_QUIRK(0x103c, 0x3030, "HP", AD1884A_MOBILE), 3863 3863 SND_PCI_QUIRK(0x103c, 0x3056, "HP", AD1884A_MOBILE), 3864 + SND_PCI_QUIRK(0x103c, 0x30e7, "HP EliteBook 8530p", AD1884A_LAPTOP), 3865 + SND_PCI_QUIRK(0x103c, 0x3614, "HP 6730s", AD1884A_LAPTOP), 3864 3866 SND_PCI_QUIRK(0x17aa, 0x20ac, "Thinkpad X300", AD1884A_THINKPAD), 3865 3867 {} 3866 3868 };
+1
sound/pci/hda/patch_realtek.c
··· 8469 8469 SND_PCI_QUIRK(0x17aa, 0x3bfd, "Lenovo NB0763", ALC883_LENOVO_NB0763), 8470 8470 SND_PCI_QUIRK(0x17aa, 0x101d, "Lenovo Sky", ALC888_LENOVO_SKY), 8471 8471 SND_PCI_QUIRK(0x17c0, 0x4071, "MEDION MD2", ALC883_MEDION_MD2), 8472 + SND_PCI_QUIRK(0x17c0, 0x4085, "MEDION MD96630", ALC888_LENOVO_MS7195_DIG), 8472 8473 SND_PCI_QUIRK(0x17f2, 0x5000, "Albatron KI690-AM2", ALC883_6ST_DIG), 8473 8474 SND_PCI_QUIRK(0x1991, 0x5625, "Haier W66", ALC883_HAIER_W66), 8474 8475 SND_PCI_QUIRK(0x8086, 0x0001, "DG33BUC", ALC883_3ST_6ch_INTEL),
+22 -5
sound/pci/rme9652/hdsp.c
··· 4548 4548 { 4549 4549 struct hdsp *hdsp = (struct hdsp *)hw->private_data; 4550 4550 void __user *argp = (void __user *)arg; 4551 + int err; 4551 4552 4552 4553 switch (cmd) { 4553 4554 case SNDRV_HDSP_IOCTL_GET_PEAK_RMS: { 4554 4555 struct hdsp_peak_rms __user *peak_rms = (struct hdsp_peak_rms __user *)arg; 4556 + 4557 + err = hdsp_check_for_iobox(hdsp); 4558 + if (err < 0) 4559 + return err; 4560 + 4561 + err = hdsp_check_for_firmware(hdsp, 1); 4562 + if (err < 0) 4563 + return err; 4555 4564 4556 4565 if (!(hdsp->state & HDSP_FirmwareLoaded)) { 4557 4566 snd_printk(KERN_ERR "Hammerfall-DSP: firmware needs to be uploaded to the card.\n"); ··· 4581 4572 unsigned long flags; 4582 4573 int i; 4583 4574 4584 - if (!(hdsp->state & HDSP_FirmwareLoaded)) { 4585 - snd_printk(KERN_ERR "Hammerfall-DSP: Firmware needs to be uploaded to the card.\n"); 4586 - return -EINVAL; 4587 - } 4575 + err = hdsp_check_for_iobox(hdsp); 4576 + if (err < 0) 4577 + return err; 4578 + 4579 + err = hdsp_check_for_firmware(hdsp, 1); 4580 + if (err < 0) 4581 + return err; 4582 + 4588 4583 spin_lock_irqsave(&hdsp->lock, flags); 4589 4584 info.pref_sync_ref = (unsigned char)hdsp_pref_sync_ref(hdsp); 4590 4585 info.wordclock_sync_check = (unsigned char)hdsp_wc_sync_check(hdsp); ··· 5058 5045 /* we wait 2 seconds to let freshly inserted cardbus cards do their hardware init */ 5059 5046 ssleep(2); 5060 5047 5048 + err = hdsp_check_for_iobox(hdsp); 5049 + if (err < 0) 5050 + return err; 5051 + 5061 5052 if ((hdsp_read (hdsp, HDSP_statusRegister) & HDSP_DllError) != 0) { 5062 5053 #ifdef HDSP_FW_LOADER 5063 5054 if ((err = hdsp_request_fw_loader(hdsp)) < 0) ··· 5074 5057 /* init is complete, we return */ 5075 5058 return 0; 5076 5059 #endif 5077 - /* no iobox connected, we defer initialization */ 5060 + /* we defer initialization */ 5078 5061 snd_printk(KERN_INFO "Hammerfall-DSP: card initialization pending : waiting for firmware\n"); 5079 5062 if ((err = snd_hdsp_create_hwdep(card, hdsp)) < 0) 5080 5063 return err;