diff options
Diffstat (limited to 'sound')
53 files changed, 415 insertions, 334 deletions
diff --git a/sound/isa/cmi8330.c b/sound/isa/cmi8330.c index de83608719ea..3ee0269e5bd0 100644 --- a/sound/isa/cmi8330.c +++ b/sound/isa/cmi8330.c | |||
| @@ -338,7 +338,7 @@ static int __devinit snd_cmi8330_pnp(int dev, struct snd_cmi8330 *acard, | |||
| 338 | return -EBUSY; | 338 | return -EBUSY; |
| 339 | 339 | ||
| 340 | acard->mpu = pnp_request_card_device(card, id->devs[2].id, NULL); | 340 | acard->mpu = pnp_request_card_device(card, id->devs[2].id, NULL); |
| 341 | if (acard->play == NULL) | 341 | if (acard->mpu == NULL) |
| 342 | return -EBUSY; | 342 | return -EBUSY; |
| 343 | 343 | ||
| 344 | pdev = acard->cap; | 344 | pdev = acard->cap; |
diff --git a/sound/oss/kahlua.c b/sound/oss/kahlua.c index c180598f1710..89466b056be7 100644 --- a/sound/oss/kahlua.c +++ b/sound/oss/kahlua.c | |||
| @@ -199,7 +199,7 @@ MODULE_LICENSE("GPL"); | |||
| 199 | */ | 199 | */ |
| 200 | 200 | ||
| 201 | static struct pci_device_id id_tbl[] = { | 201 | static struct pci_device_id id_tbl[] = { |
| 202 | { PCI_VENDOR_ID_CYRIX, PCI_DEVICE_ID_CYRIX_5530_AUDIO, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, | 202 | { PCI_VDEVICE(CYRIX, PCI_DEVICE_ID_CYRIX_5530_AUDIO), 0 }, |
| 203 | { } | 203 | { } |
| 204 | }; | 204 | }; |
| 205 | 205 | ||
diff --git a/sound/oss/mpu401.c b/sound/oss/mpu401.c index 6c0a770ed054..1b2316f35b1f 100644 --- a/sound/oss/mpu401.c +++ b/sound/oss/mpu401.c | |||
| @@ -926,31 +926,21 @@ static struct midi_operations mpu401_midi_operations[MAX_MIDI_DEV]; | |||
| 926 | static void mpu401_chk_version(int n, struct mpu_config *devc) | 926 | static void mpu401_chk_version(int n, struct mpu_config *devc) |
| 927 | { | 927 | { |
| 928 | int tmp; | 928 | int tmp; |
| 929 | unsigned long flags; | ||
| 930 | 929 | ||
| 931 | devc->version = devc->revision = 0; | 930 | devc->version = devc->revision = 0; |
| 932 | 931 | ||
| 933 | spin_lock_irqsave(&devc->lock,flags); | 932 | tmp = mpu_cmd(n, 0xAC, 0); |
| 934 | if ((tmp = mpu_cmd(n, 0xAC, 0)) < 0) | 933 | if (tmp < 0) |
| 935 | { | ||
| 936 | spin_unlock_irqrestore(&devc->lock,flags); | ||
| 937 | return; | 934 | return; |
| 938 | } | ||
| 939 | if ((tmp & 0xf0) > 0x20) /* Why it's larger than 2.x ??? */ | 935 | if ((tmp & 0xf0) > 0x20) /* Why it's larger than 2.x ??? */ |
| 940 | { | ||
| 941 | spin_unlock_irqrestore(&devc->lock,flags); | ||
| 942 | return; | 936 | return; |
| 943 | } | ||
| 944 | devc->version = tmp; | 937 | devc->version = tmp; |
| 945 | 938 | ||
| 946 | if ((tmp = mpu_cmd(n, 0xAD, 0)) < 0) | 939 | if ((tmp = mpu_cmd(n, 0xAD, 0)) < 0) { |
| 947 | { | ||
| 948 | devc->version = 0; | 940 | devc->version = 0; |
| 949 | spin_unlock_irqrestore(&devc->lock,flags); | ||
| 950 | return; | 941 | return; |
| 951 | } | 942 | } |
| 952 | devc->revision = tmp; | 943 | devc->revision = tmp; |
| 953 | spin_unlock_irqrestore(&devc->lock,flags); | ||
| 954 | } | 944 | } |
| 955 | 945 | ||
| 956 | int attach_mpu401(struct address_info *hw_config, struct module *owner) | 946 | int attach_mpu401(struct address_info *hw_config, struct module *owner) |
diff --git a/sound/pci/atiixp.c b/sound/pci/atiixp.c index 71515ddb4593..d6752dff2a44 100644 --- a/sound/pci/atiixp.c +++ b/sound/pci/atiixp.c | |||
| @@ -287,10 +287,10 @@ struct atiixp { | |||
| 287 | /* | 287 | /* |
| 288 | */ | 288 | */ |
| 289 | static struct pci_device_id snd_atiixp_ids[] = { | 289 | static struct pci_device_id snd_atiixp_ids[] = { |
| 290 | { 0x1002, 0x4341, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* SB200 */ | 290 | { PCI_VDEVICE(ATI, 0x4341), 0 }, /* SB200 */ |
| 291 | { 0x1002, 0x4361, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* SB300 */ | 291 | { PCI_VDEVICE(ATI, 0x4361), 0 }, /* SB300 */ |
| 292 | { 0x1002, 0x4370, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* SB400 */ | 292 | { PCI_VDEVICE(ATI, 0x4370), 0 }, /* SB400 */ |
| 293 | { 0x1002, 0x4382, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* SB600 */ | 293 | { PCI_VDEVICE(ATI, 0x4382), 0 }, /* SB600 */ |
| 294 | { 0, } | 294 | { 0, } |
| 295 | }; | 295 | }; |
| 296 | 296 | ||
diff --git a/sound/pci/atiixp_modem.c b/sound/pci/atiixp_modem.c index c3136cccc559..e7e147bf8eb2 100644 --- a/sound/pci/atiixp_modem.c +++ b/sound/pci/atiixp_modem.c | |||
| @@ -262,8 +262,8 @@ struct atiixp_modem { | |||
| 262 | /* | 262 | /* |
| 263 | */ | 263 | */ |
| 264 | static struct pci_device_id snd_atiixp_ids[] = { | 264 | static struct pci_device_id snd_atiixp_ids[] = { |
| 265 | { 0x1002, 0x434d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* SB200 */ | 265 | { PCI_VDEVICE(ATI, 0x434d), 0 }, /* SB200 */ |
| 266 | { 0x1002, 0x4378, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* SB400 */ | 266 | { PCI_VDEVICE(ATI, 0x4378), 0 }, /* SB400 */ |
| 267 | { 0, } | 267 | { 0, } |
| 268 | }; | 268 | }; |
| 269 | 269 | ||
diff --git a/sound/pci/au88x0/au8810.c b/sound/pci/au88x0/au8810.c index fce22c7af0ea..c0e8c6b295cb 100644 --- a/sound/pci/au88x0/au8810.c +++ b/sound/pci/au88x0/au8810.c | |||
| @@ -1,8 +1,7 @@ | |||
| 1 | #include "au8810.h" | 1 | #include "au8810.h" |
| 2 | #include "au88x0.h" | 2 | #include "au88x0.h" |
| 3 | static struct pci_device_id snd_vortex_ids[] = { | 3 | static struct pci_device_id snd_vortex_ids[] = { |
| 4 | {PCI_VENDOR_ID_AUREAL, PCI_DEVICE_ID_AUREAL_ADVANTAGE, | 4 | {PCI_VDEVICE(AUREAL, PCI_DEVICE_ID_AUREAL_ADVANTAGE), 1,}, |
| 5 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 1,}, | ||
| 6 | {0,} | 5 | {0,} |
| 7 | }; | 6 | }; |
| 8 | 7 | ||
diff --git a/sound/pci/au88x0/au8820.c b/sound/pci/au88x0/au8820.c index d1fbcce07257..a6527330df58 100644 --- a/sound/pci/au88x0/au8820.c +++ b/sound/pci/au88x0/au8820.c | |||
| @@ -1,8 +1,7 @@ | |||
| 1 | #include "au8820.h" | 1 | #include "au8820.h" |
| 2 | #include "au88x0.h" | 2 | #include "au88x0.h" |
| 3 | static struct pci_device_id snd_vortex_ids[] = { | 3 | static struct pci_device_id snd_vortex_ids[] = { |
| 4 | {PCI_VENDOR_ID_AUREAL, PCI_DEVICE_ID_AUREAL_VORTEX_1, | 4 | {PCI_VDEVICE(AUREAL, PCI_DEVICE_ID_AUREAL_VORTEX_1), 0,}, |
| 5 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0,}, | ||
| 6 | {0,} | 5 | {0,} |
| 7 | }; | 6 | }; |
| 8 | 7 | ||
diff --git a/sound/pci/au88x0/au8830.c b/sound/pci/au88x0/au8830.c index d4f2717c14fb..6c702ad4352a 100644 --- a/sound/pci/au88x0/au8830.c +++ b/sound/pci/au88x0/au8830.c | |||
| @@ -1,8 +1,7 @@ | |||
| 1 | #include "au8830.h" | 1 | #include "au8830.h" |
| 2 | #include "au88x0.h" | 2 | #include "au88x0.h" |
| 3 | static struct pci_device_id snd_vortex_ids[] = { | 3 | static struct pci_device_id snd_vortex_ids[] = { |
| 4 | {PCI_VENDOR_ID_AUREAL, PCI_DEVICE_ID_AUREAL_VORTEX_2, | 4 | {PCI_VDEVICE(AUREAL, PCI_DEVICE_ID_AUREAL_VORTEX_2), 0,}, |
| 5 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0,}, | ||
| 6 | {0,} | 5 | {0,} |
| 7 | }; | 6 | }; |
| 8 | 7 | ||
diff --git a/sound/pci/ca0106/ca0106_main.c b/sound/pci/ca0106/ca0106_main.c index 57b992a5c057..f24bf1ecb36d 100644 --- a/sound/pci/ca0106/ca0106_main.c +++ b/sound/pci/ca0106/ca0106_main.c | |||
| @@ -1876,7 +1876,7 @@ static int snd_ca0106_resume(struct pci_dev *pci) | |||
| 1876 | 1876 | ||
| 1877 | // PCI IDs | 1877 | // PCI IDs |
| 1878 | static struct pci_device_id snd_ca0106_ids[] = { | 1878 | static struct pci_device_id snd_ca0106_ids[] = { |
| 1879 | { 0x1102, 0x0007, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* Audigy LS or Live 24bit */ | 1879 | { PCI_VDEVICE(CREATIVE, 0x0007), 0 }, /* Audigy LS or Live 24bit */ |
| 1880 | { 0, } | 1880 | { 0, } |
| 1881 | }; | 1881 | }; |
| 1882 | MODULE_DEVICE_TABLE(pci, snd_ca0106_ids); | 1882 | MODULE_DEVICE_TABLE(pci, snd_ca0106_ids); |
diff --git a/sound/pci/cmipci.c b/sound/pci/cmipci.c index 449fe02f666e..ddcd4a9fd7e6 100644 --- a/sound/pci/cmipci.c +++ b/sound/pci/cmipci.c | |||
| @@ -2797,11 +2797,11 @@ static inline void snd_cmipci_proc_init(struct cmipci *cm) {} | |||
| 2797 | 2797 | ||
| 2798 | 2798 | ||
| 2799 | static struct pci_device_id snd_cmipci_ids[] = { | 2799 | static struct pci_device_id snd_cmipci_ids[] = { |
| 2800 | {PCI_VENDOR_ID_CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8338A, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 2800 | {PCI_VDEVICE(CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8338A), 0}, |
| 2801 | {PCI_VENDOR_ID_CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8338B, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 2801 | {PCI_VDEVICE(CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8338B), 0}, |
| 2802 | {PCI_VENDOR_ID_CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8738, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 2802 | {PCI_VDEVICE(CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8738), 0}, |
| 2803 | {PCI_VENDOR_ID_CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8738B, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 2803 | {PCI_VDEVICE(CMEDIA, PCI_DEVICE_ID_CMEDIA_CM8738B), 0}, |
| 2804 | {PCI_VENDOR_ID_AL, PCI_DEVICE_ID_CMEDIA_CM8738, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 2804 | {PCI_VDEVICE(AL, PCI_DEVICE_ID_CMEDIA_CM8738), 0}, |
| 2805 | {0,}, | 2805 | {0,}, |
| 2806 | }; | 2806 | }; |
| 2807 | 2807 | ||
diff --git a/sound/pci/cs4281.c b/sound/pci/cs4281.c index f6286f84a221..e2e0359bb056 100644 --- a/sound/pci/cs4281.c +++ b/sound/pci/cs4281.c | |||
| @@ -495,7 +495,7 @@ struct cs4281 { | |||
| 495 | static irqreturn_t snd_cs4281_interrupt(int irq, void *dev_id); | 495 | static irqreturn_t snd_cs4281_interrupt(int irq, void *dev_id); |
| 496 | 496 | ||
| 497 | static struct pci_device_id snd_cs4281_ids[] = { | 497 | static struct pci_device_id snd_cs4281_ids[] = { |
| 498 | { 0x1013, 0x6005, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* CS4281 */ | 498 | { PCI_VDEVICE(CIRRUS, 0x6005), 0, }, /* CS4281 */ |
| 499 | { 0, } | 499 | { 0, } |
| 500 | }; | 500 | }; |
| 501 | 501 | ||
diff --git a/sound/pci/cs46xx/cs46xx.c b/sound/pci/cs46xx/cs46xx.c index c9b3e3d48cbc..033aec430117 100644 --- a/sound/pci/cs46xx/cs46xx.c +++ b/sound/pci/cs46xx/cs46xx.c | |||
| @@ -65,9 +65,9 @@ module_param_array(mmap_valid, bool, NULL, 0444); | |||
| 65 | MODULE_PARM_DESC(mmap_valid, "Support OSS mmap."); | 65 | MODULE_PARM_DESC(mmap_valid, "Support OSS mmap."); |
| 66 | 66 | ||
| 67 | static struct pci_device_id snd_cs46xx_ids[] = { | 67 | static struct pci_device_id snd_cs46xx_ids[] = { |
| 68 | { 0x1013, 0x6001, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* CS4280 */ | 68 | { PCI_VDEVICE(CIRRUS, 0x6001), 0, }, /* CS4280 */ |
| 69 | { 0x1013, 0x6003, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* CS4612 */ | 69 | { PCI_VDEVICE(CIRRUS, 0x6003), 0, }, /* CS4612 */ |
| 70 | { 0x1013, 0x6004, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* CS4615 */ | 70 | { PCI_VDEVICE(CIRRUS, 0x6004), 0, }, /* CS4615 */ |
| 71 | { 0, } | 71 | { 0, } |
| 72 | }; | 72 | }; |
| 73 | 73 | ||
diff --git a/sound/pci/emu10k1/emu10k1.c b/sound/pci/emu10k1/emu10k1.c index c7f3b994101c..168af67d938e 100644 --- a/sound/pci/emu10k1/emu10k1.c +++ b/sound/pci/emu10k1/emu10k1.c | |||
| @@ -77,9 +77,9 @@ MODULE_PARM_DESC(subsystem, "Force card subsystem model."); | |||
| 77 | * Class 0401: 1102:0008 (rev 00) Subsystem: 1102:1001 -> Audigy2 Value Model:SB0400 | 77 | * Class 0401: 1102:0008 (rev 00) Subsystem: 1102:1001 -> Audigy2 Value Model:SB0400 |
| 78 | */ | 78 | */ |
| 79 | static struct pci_device_id snd_emu10k1_ids[] = { | 79 | static struct pci_device_id snd_emu10k1_ids[] = { |
| 80 | { 0x1102, 0x0002, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* EMU10K1 */ | 80 | { PCI_VDEVICE(CREATIVE, 0x0002), 0 }, /* EMU10K1 */ |
| 81 | { 0x1102, 0x0004, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 1 }, /* Audigy */ | 81 | { PCI_VDEVICE(CREATIVE, 0x0004), 1 }, /* Audigy */ |
| 82 | { 0x1102, 0x0008, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 1 }, /* Audigy 2 Value SB0400 */ | 82 | { PCI_VDEVICE(CREATIVE, 0x0008), 1 }, /* Audigy 2 Value SB0400 */ |
| 83 | { 0, } | 83 | { 0, } |
| 84 | }; | 84 | }; |
| 85 | 85 | ||
diff --git a/sound/pci/emu10k1/emu10k1x.c b/sound/pci/emu10k1/emu10k1x.c index 4d3ad793e98f..36e08bd2b3cc 100644 --- a/sound/pci/emu10k1/emu10k1x.c +++ b/sound/pci/emu10k1/emu10k1x.c | |||
| @@ -1607,7 +1607,7 @@ static void __devexit snd_emu10k1x_remove(struct pci_dev *pci) | |||
| 1607 | 1607 | ||
| 1608 | // PCI IDs | 1608 | // PCI IDs |
| 1609 | static struct pci_device_id snd_emu10k1x_ids[] = { | 1609 | static struct pci_device_id snd_emu10k1x_ids[] = { |
| 1610 | { 0x1102, 0x0006, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* Dell OEM version (EMU10K1) */ | 1610 | { PCI_VDEVICE(CREATIVE, 0x0006), 0 }, /* Dell OEM version (EMU10K1) */ |
| 1611 | { 0, } | 1611 | { 0, } |
| 1612 | }; | 1612 | }; |
| 1613 | MODULE_DEVICE_TABLE(pci, snd_emu10k1x_ids); | 1613 | MODULE_DEVICE_TABLE(pci, snd_emu10k1x_ids); |
diff --git a/sound/pci/emu10k1/p16v.c b/sound/pci/emu10k1/p16v.c index e617acaf10e3..61b8ab39800f 100644 --- a/sound/pci/emu10k1/p16v.c +++ b/sound/pci/emu10k1/p16v.c | |||
| @@ -644,7 +644,7 @@ int __devinit snd_p16v_pcm(struct snd_emu10k1 *emu, int device, struct snd_pcm * | |||
| 644 | int err; | 644 | int err; |
| 645 | int capture=1; | 645 | int capture=1; |
| 646 | 646 | ||
| 647 | /* snd_printk("KERN_DEBUG snd_p16v_pcm called. device=%d\n", device); */ | 647 | /* snd_printk(KERN_DEBUG "snd_p16v_pcm called. device=%d\n", device); */ |
| 648 | emu->p16v_device_offset = device; | 648 | emu->p16v_device_offset = device; |
| 649 | if (rpcm) | 649 | if (rpcm) |
| 650 | *rpcm = NULL; | 650 | *rpcm = NULL; |
diff --git a/sound/pci/ens1370.c b/sound/pci/ens1370.c index 18f4d1e98c46..2b82c5c723e1 100644 --- a/sound/pci/ens1370.c +++ b/sound/pci/ens1370.c | |||
| @@ -445,12 +445,12 @@ static irqreturn_t snd_audiopci_interrupt(int irq, void *dev_id); | |||
| 445 | 445 | ||
| 446 | static struct pci_device_id snd_audiopci_ids[] = { | 446 | static struct pci_device_id snd_audiopci_ids[] = { |
| 447 | #ifdef CHIP1370 | 447 | #ifdef CHIP1370 |
| 448 | { 0x1274, 0x5000, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* ES1370 */ | 448 | { PCI_VDEVICE(ENSONIQ, 0x5000), 0, }, /* ES1370 */ |
| 449 | #endif | 449 | #endif |
| 450 | #ifdef CHIP1371 | 450 | #ifdef CHIP1371 |
| 451 | { 0x1274, 0x1371, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* ES1371 */ | 451 | { PCI_VDEVICE(ENSONIQ, 0x1371), 0, }, /* ES1371 */ |
| 452 | { 0x1274, 0x5880, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* ES1373 - CT5880 */ | 452 | { PCI_VDEVICE(ENSONIQ, 0x5880), 0, }, /* ES1373 - CT5880 */ |
| 453 | { 0x1102, 0x8938, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* Ectiva EV1938 */ | 453 | { PCI_VDEVICE(ECTIVA, 0x8938), 0, }, /* Ectiva EV1938 */ |
| 454 | #endif | 454 | #endif |
| 455 | { 0, } | 455 | { 0, } |
| 456 | }; | 456 | }; |
diff --git a/sound/pci/es1938.c b/sound/pci/es1938.c index fbd2ac09aa34..820318ee62c1 100644 --- a/sound/pci/es1938.c +++ b/sound/pci/es1938.c | |||
| @@ -244,7 +244,7 @@ struct es1938 { | |||
| 244 | static irqreturn_t snd_es1938_interrupt(int irq, void *dev_id); | 244 | static irqreturn_t snd_es1938_interrupt(int irq, void *dev_id); |
| 245 | 245 | ||
| 246 | static struct pci_device_id snd_es1938_ids[] = { | 246 | static struct pci_device_id snd_es1938_ids[] = { |
| 247 | { 0x125d, 0x1969, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* Solo-1 */ | 247 | { PCI_VDEVICE(ESS, 0x1969), 0, }, /* Solo-1 */ |
| 248 | { 0, } | 248 | { 0, } |
| 249 | }; | 249 | }; |
| 250 | 250 | ||
diff --git a/sound/pci/hda/hda_beep.c b/sound/pci/hda/hda_beep.c index 29272f2e95a0..b0275a050870 100644 --- a/sound/pci/hda/hda_beep.c +++ b/sound/pci/hda/hda_beep.c | |||
| @@ -50,19 +50,22 @@ static void snd_hda_generate_beep(struct work_struct *work) | |||
| 50 | * The tone frequency of beep generator on IDT/STAC codecs is | 50 | * The tone frequency of beep generator on IDT/STAC codecs is |
| 51 | * defined from the 8bit tone parameter, in Hz, | 51 | * defined from the 8bit tone parameter, in Hz, |
| 52 | * freq = 48000 * (257 - tone) / 1024 | 52 | * freq = 48000 * (257 - tone) / 1024 |
| 53 | * that is from 12kHz to 93.75kHz in step of 46.875 hz | 53 | * that is from 12kHz to 93.75Hz in steps of 46.875 Hz |
| 54 | */ | 54 | */ |
| 55 | static int beep_linear_tone(struct hda_beep *beep, int hz) | 55 | static int beep_linear_tone(struct hda_beep *beep, int hz) |
| 56 | { | 56 | { |
| 57 | if (hz <= 0) | ||
| 58 | return 0; | ||
| 57 | hz *= 1000; /* fixed point */ | 59 | hz *= 1000; /* fixed point */ |
| 58 | hz = hz - DIGBEEP_HZ_MIN; | 60 | hz = hz - DIGBEEP_HZ_MIN |
| 61 | + DIGBEEP_HZ_STEP / 2; /* round to nearest step */ | ||
| 59 | if (hz < 0) | 62 | if (hz < 0) |
| 60 | hz = 0; /* turn off PC beep*/ | 63 | hz = 0; /* turn off PC beep*/ |
| 61 | else if (hz >= (DIGBEEP_HZ_MAX - DIGBEEP_HZ_MIN)) | 64 | else if (hz >= (DIGBEEP_HZ_MAX - DIGBEEP_HZ_MIN)) |
| 62 | hz = 0xff; | 65 | hz = 1; /* max frequency */ |
| 63 | else { | 66 | else { |
| 64 | hz /= DIGBEEP_HZ_STEP; | 67 | hz /= DIGBEEP_HZ_STEP; |
| 65 | hz++; | 68 | hz = 255 - hz; |
| 66 | } | 69 | } |
| 67 | return hz; | 70 | return hz; |
| 68 | } | 71 | } |
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c index 462e2cedaa6a..26d255de6beb 100644 --- a/sound/pci/hda/hda_codec.c +++ b/sound/pci/hda/hda_codec.c | |||
| @@ -3470,10 +3470,16 @@ int snd_hda_multi_out_analog_open(struct hda_codec *codec, | |||
| 3470 | } | 3470 | } |
| 3471 | mutex_lock(&codec->spdif_mutex); | 3471 | mutex_lock(&codec->spdif_mutex); |
| 3472 | if (mout->share_spdif) { | 3472 | if (mout->share_spdif) { |
| 3473 | runtime->hw.rates &= mout->spdif_rates; | 3473 | if ((runtime->hw.rates & mout->spdif_rates) && |
| 3474 | runtime->hw.formats &= mout->spdif_formats; | 3474 | (runtime->hw.formats & mout->spdif_formats)) { |
| 3475 | if (mout->spdif_maxbps < hinfo->maxbps) | 3475 | runtime->hw.rates &= mout->spdif_rates; |
| 3476 | hinfo->maxbps = mout->spdif_maxbps; | 3476 | runtime->hw.formats &= mout->spdif_formats; |
| 3477 | if (mout->spdif_maxbps < hinfo->maxbps) | ||
| 3478 | hinfo->maxbps = mout->spdif_maxbps; | ||
| 3479 | } else { | ||
| 3480 | mout->share_spdif = 0; | ||
| 3481 | /* FIXME: need notify? */ | ||
| 3482 | } | ||
| 3477 | } | 3483 | } |
| 3478 | mutex_unlock(&codec->spdif_mutex); | 3484 | mutex_unlock(&codec->spdif_mutex); |
| 3479 | } | 3485 | } |
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c index 4e9ea7080270..77c1b840ca8b 100644 --- a/sound/pci/hda/hda_intel.c +++ b/sound/pci/hda/hda_intel.c | |||
| @@ -1454,6 +1454,18 @@ static int azx_pcm_open(struct snd_pcm_substream *substream) | |||
| 1454 | mutex_unlock(&chip->open_mutex); | 1454 | mutex_unlock(&chip->open_mutex); |
| 1455 | return err; | 1455 | return err; |
| 1456 | } | 1456 | } |
| 1457 | snd_pcm_limit_hw_rates(runtime); | ||
| 1458 | /* sanity check */ | ||
| 1459 | if (snd_BUG_ON(!runtime->hw.channels_min) || | ||
| 1460 | snd_BUG_ON(!runtime->hw.channels_max) || | ||
| 1461 | snd_BUG_ON(!runtime->hw.formats) || | ||
| 1462 | snd_BUG_ON(!runtime->hw.rates)) { | ||
| 1463 | azx_release_device(azx_dev); | ||
| 1464 | hinfo->ops.close(hinfo, apcm->codec, substream); | ||
| 1465 | snd_hda_power_down(apcm->codec); | ||
| 1466 | mutex_unlock(&chip->open_mutex); | ||
| 1467 | return -EINVAL; | ||
| 1468 | } | ||
| 1457 | spin_lock_irqsave(&chip->reg_lock, flags); | 1469 | spin_lock_irqsave(&chip->reg_lock, flags); |
| 1458 | azx_dev->substream = substream; | 1470 | azx_dev->substream = substream; |
| 1459 | azx_dev->running = 0; | 1471 | azx_dev->running = 0; |
| @@ -1462,7 +1474,6 @@ static int azx_pcm_open(struct snd_pcm_substream *substream) | |||
| 1462 | runtime->private_data = azx_dev; | 1474 | runtime->private_data = azx_dev; |
| 1463 | snd_pcm_set_sync(substream); | 1475 | snd_pcm_set_sync(substream); |
| 1464 | mutex_unlock(&chip->open_mutex); | 1476 | mutex_unlock(&chip->open_mutex); |
| 1465 | |||
| 1466 | return 0; | 1477 | return 0; |
| 1467 | } | 1478 | } |
| 1468 | 1479 | ||
| @@ -2322,9 +2333,19 @@ static int __devinit azx_create(struct snd_card *card, struct pci_dev *pci, | |||
| 2322 | gcap = azx_readw(chip, GCAP); | 2333 | gcap = azx_readw(chip, GCAP); |
| 2323 | snd_printdd(SFX "chipset global capabilities = 0x%x\n", gcap); | 2334 | snd_printdd(SFX "chipset global capabilities = 0x%x\n", gcap); |
| 2324 | 2335 | ||
| 2325 | /* ATI chips seems buggy about 64bit DMA addresses */ | 2336 | /* disable SB600 64bit support for safety */ |
| 2326 | if (chip->driver_type == AZX_DRIVER_ATI) | 2337 | if ((chip->driver_type == AZX_DRIVER_ATI) || |
| 2327 | gcap &= ~ICH6_GCAP_64OK; | 2338 | (chip->driver_type == AZX_DRIVER_ATIHDMI)) { |
| 2339 | struct pci_dev *p_smbus; | ||
| 2340 | p_smbus = pci_get_device(PCI_VENDOR_ID_ATI, | ||
| 2341 | PCI_DEVICE_ID_ATI_SBX00_SMBUS, | ||
| 2342 | NULL); | ||
| 2343 | if (p_smbus) { | ||
| 2344 | if (p_smbus->revision < 0x30) | ||
| 2345 | gcap &= ~ICH6_GCAP_64OK; | ||
| 2346 | pci_dev_put(p_smbus); | ||
| 2347 | } | ||
| 2348 | } | ||
| 2328 | 2349 | ||
| 2329 | /* allow 64bit DMA address if supported by H/W */ | 2350 | /* allow 64bit DMA address if supported by H/W */ |
| 2330 | if ((gcap & ICH6_GCAP_64OK) && !pci_set_dma_mask(pci, DMA_BIT_MASK(64))) | 2351 | if ((gcap & ICH6_GCAP_64OK) && !pci_set_dma_mask(pci, DMA_BIT_MASK(64))) |
diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c index 84cc49ca9148..be7d25fa7f35 100644 --- a/sound/pci/hda/patch_analog.c +++ b/sound/pci/hda/patch_analog.c | |||
| @@ -72,6 +72,7 @@ struct ad198x_spec { | |||
| 72 | hda_nid_t private_dac_nids[AUTO_CFG_MAX_OUTS]; | 72 | hda_nid_t private_dac_nids[AUTO_CFG_MAX_OUTS]; |
| 73 | 73 | ||
| 74 | unsigned int jack_present :1; | 74 | unsigned int jack_present :1; |
| 75 | unsigned int inv_jack_detect:1; | ||
| 75 | 76 | ||
| 76 | #ifdef CONFIG_SND_HDA_POWER_SAVE | 77 | #ifdef CONFIG_SND_HDA_POWER_SAVE |
| 77 | struct hda_loopback_check loopback; | 78 | struct hda_loopback_check loopback; |
| @@ -669,39 +670,13 @@ static struct hda_input_mux ad1986a_automic_capture_source = { | |||
| 669 | }, | 670 | }, |
| 670 | }; | 671 | }; |
| 671 | 672 | ||
| 672 | static struct snd_kcontrol_new ad1986a_laptop_eapd_mixers[] = { | 673 | static struct snd_kcontrol_new ad1986a_laptop_master_mixers[] = { |
| 673 | HDA_BIND_VOL("Master Playback Volume", &ad1986a_laptop_master_vol), | 674 | HDA_BIND_VOL("Master Playback Volume", &ad1986a_laptop_master_vol), |
| 674 | HDA_BIND_SW("Master Playback Switch", &ad1986a_laptop_master_sw), | 675 | HDA_BIND_SW("Master Playback Switch", &ad1986a_laptop_master_sw), |
| 675 | HDA_CODEC_VOLUME("PCM Playback Volume", 0x03, 0x0, HDA_OUTPUT), | ||
| 676 | HDA_CODEC_MUTE("PCM Playback Switch", 0x03, 0x0, HDA_OUTPUT), | ||
| 677 | HDA_CODEC_VOLUME("Internal Mic Playback Volume", 0x17, 0, HDA_OUTPUT), | ||
| 678 | HDA_CODEC_MUTE("Internal Mic Playback Switch", 0x17, 0, HDA_OUTPUT), | ||
| 679 | HDA_CODEC_VOLUME("Mic Playback Volume", 0x13, 0x0, HDA_OUTPUT), | ||
| 680 | HDA_CODEC_MUTE("Mic Playback Switch", 0x13, 0x0, HDA_OUTPUT), | ||
| 681 | HDA_CODEC_VOLUME("Mic Boost", 0x0f, 0x0, HDA_OUTPUT), | ||
| 682 | HDA_CODEC_VOLUME("Capture Volume", 0x12, 0x0, HDA_OUTPUT), | ||
| 683 | HDA_CODEC_MUTE("Capture Switch", 0x12, 0x0, HDA_OUTPUT), | ||
| 684 | { | ||
| 685 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | ||
| 686 | .name = "Capture Source", | ||
| 687 | .info = ad198x_mux_enum_info, | ||
| 688 | .get = ad198x_mux_enum_get, | ||
| 689 | .put = ad198x_mux_enum_put, | ||
| 690 | }, | ||
| 691 | { | ||
| 692 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | ||
| 693 | .name = "External Amplifier", | ||
| 694 | .info = ad198x_eapd_info, | ||
| 695 | .get = ad198x_eapd_get, | ||
| 696 | .put = ad198x_eapd_put, | ||
| 697 | .private_value = 0x1b | (1 << 8), /* port-D, inversed */ | ||
| 698 | }, | ||
| 699 | { } /* end */ | 676 | { } /* end */ |
| 700 | }; | 677 | }; |
| 701 | 678 | ||
| 702 | static struct snd_kcontrol_new ad1986a_samsung_mixers[] = { | 679 | static struct snd_kcontrol_new ad1986a_laptop_eapd_mixers[] = { |
| 703 | HDA_BIND_VOL("Master Playback Volume", &ad1986a_laptop_master_vol), | ||
| 704 | HDA_BIND_SW("Master Playback Switch", &ad1986a_laptop_master_sw), | ||
| 705 | HDA_CODEC_VOLUME("PCM Playback Volume", 0x03, 0x0, HDA_OUTPUT), | 680 | HDA_CODEC_VOLUME("PCM Playback Volume", 0x03, 0x0, HDA_OUTPUT), |
| 706 | HDA_CODEC_MUTE("PCM Playback Switch", 0x03, 0x0, HDA_OUTPUT), | 681 | HDA_CODEC_MUTE("PCM Playback Switch", 0x03, 0x0, HDA_OUTPUT), |
| 707 | HDA_CODEC_VOLUME("Mic Playback Volume", 0x13, 0x0, HDA_OUTPUT), | 682 | HDA_CODEC_VOLUME("Mic Playback Volume", 0x13, 0x0, HDA_OUTPUT), |
| @@ -727,6 +702,12 @@ static struct snd_kcontrol_new ad1986a_samsung_mixers[] = { | |||
| 727 | { } /* end */ | 702 | { } /* end */ |
| 728 | }; | 703 | }; |
| 729 | 704 | ||
| 705 | static struct snd_kcontrol_new ad1986a_laptop_intmic_mixers[] = { | ||
| 706 | HDA_CODEC_VOLUME("Internal Mic Playback Volume", 0x17, 0, HDA_OUTPUT), | ||
| 707 | HDA_CODEC_MUTE("Internal Mic Playback Switch", 0x17, 0, HDA_OUTPUT), | ||
| 708 | { } /* end */ | ||
| 709 | }; | ||
| 710 | |||
| 730 | /* re-connect the mic boost input according to the jack sensing */ | 711 | /* re-connect the mic boost input according to the jack sensing */ |
| 731 | static void ad1986a_automic(struct hda_codec *codec) | 712 | static void ad1986a_automic(struct hda_codec *codec) |
| 732 | { | 713 | { |
| @@ -776,8 +757,9 @@ static void ad1986a_hp_automute(struct hda_codec *codec) | |||
| 776 | unsigned int present; | 757 | unsigned int present; |
| 777 | 758 | ||
| 778 | present = snd_hda_codec_read(codec, 0x1a, 0, AC_VERB_GET_PIN_SENSE, 0); | 759 | present = snd_hda_codec_read(codec, 0x1a, 0, AC_VERB_GET_PIN_SENSE, 0); |
| 779 | /* Lenovo N100 seems to report the reversed bit for HP jack-sensing */ | 760 | spec->jack_present = !!(present & 0x80000000); |
| 780 | spec->jack_present = !(present & 0x80000000); | 761 | if (spec->inv_jack_detect) |
| 762 | spec->jack_present = !spec->jack_present; | ||
| 781 | ad1986a_update_hp(codec); | 763 | ad1986a_update_hp(codec); |
| 782 | } | 764 | } |
| 783 | 765 | ||
| @@ -816,7 +798,7 @@ static int ad1986a_hp_master_sw_put(struct snd_kcontrol *kcontrol, | |||
| 816 | return change; | 798 | return change; |
| 817 | } | 799 | } |
| 818 | 800 | ||
| 819 | static struct snd_kcontrol_new ad1986a_laptop_automute_mixers[] = { | 801 | static struct snd_kcontrol_new ad1986a_automute_master_mixers[] = { |
| 820 | HDA_BIND_VOL("Master Playback Volume", &ad1986a_laptop_master_vol), | 802 | HDA_BIND_VOL("Master Playback Volume", &ad1986a_laptop_master_vol), |
| 821 | { | 803 | { |
| 822 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 804 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
| @@ -826,33 +808,10 @@ static struct snd_kcontrol_new ad1986a_laptop_automute_mixers[] = { | |||
| 826 | .put = ad1986a_hp_master_sw_put, | 808 | .put = ad1986a_hp_master_sw_put, |
| 827 | .private_value = HDA_COMPOSE_AMP_VAL(0x1a, 3, 0, HDA_OUTPUT), | 809 | .private_value = HDA_COMPOSE_AMP_VAL(0x1a, 3, 0, HDA_OUTPUT), |
| 828 | }, | 810 | }, |
| 829 | HDA_CODEC_VOLUME("PCM Playback Volume", 0x03, 0x0, HDA_OUTPUT), | ||
| 830 | HDA_CODEC_MUTE("PCM Playback Switch", 0x03, 0x0, HDA_OUTPUT), | ||
| 831 | HDA_CODEC_VOLUME("Internal Mic Playback Volume", 0x17, 0x0, HDA_OUTPUT), | ||
| 832 | HDA_CODEC_MUTE("Internal Mic Playback Switch", 0x17, 0x0, HDA_OUTPUT), | ||
| 833 | HDA_CODEC_VOLUME("Mic Playback Volume", 0x13, 0x0, HDA_OUTPUT), | ||
| 834 | HDA_CODEC_MUTE("Mic Playback Switch", 0x13, 0x0, HDA_OUTPUT), | ||
| 835 | HDA_CODEC_VOLUME("Mic Boost", 0x0f, 0x0, HDA_OUTPUT), | ||
| 836 | HDA_CODEC_VOLUME("Capture Volume", 0x12, 0x0, HDA_OUTPUT), | ||
| 837 | HDA_CODEC_MUTE("Capture Switch", 0x12, 0x0, HDA_OUTPUT), | ||
| 838 | { | ||
| 839 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | ||
| 840 | .name = "Capture Source", | ||
| 841 | .info = ad198x_mux_enum_info, | ||
| 842 | .get = ad198x_mux_enum_get, | ||
| 843 | .put = ad198x_mux_enum_put, | ||
| 844 | }, | ||
| 845 | { | ||
| 846 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | ||
| 847 | .name = "External Amplifier", | ||
| 848 | .info = ad198x_eapd_info, | ||
| 849 | .get = ad198x_eapd_get, | ||
| 850 | .put = ad198x_eapd_put, | ||
| 851 | .private_value = 0x1b | (1 << 8), /* port-D, inversed */ | ||
| 852 | }, | ||
| 853 | { } /* end */ | 811 | { } /* end */ |
| 854 | }; | 812 | }; |
| 855 | 813 | ||
| 814 | |||
| 856 | /* | 815 | /* |
| 857 | * initialization verbs | 816 | * initialization verbs |
| 858 | */ | 817 | */ |
| @@ -981,6 +940,27 @@ static struct hda_verb ad1986a_hp_init_verbs[] = { | |||
| 981 | {} | 940 | {} |
| 982 | }; | 941 | }; |
| 983 | 942 | ||
| 943 | static void ad1986a_samsung_p50_unsol_event(struct hda_codec *codec, | ||
| 944 | unsigned int res) | ||
| 945 | { | ||
| 946 | switch (res >> 26) { | ||
| 947 | case AD1986A_HP_EVENT: | ||
| 948 | ad1986a_hp_automute(codec); | ||
| 949 | break; | ||
| 950 | case AD1986A_MIC_EVENT: | ||
| 951 | ad1986a_automic(codec); | ||
| 952 | break; | ||
| 953 | } | ||
| 954 | } | ||
| 955 | |||
| 956 | static int ad1986a_samsung_p50_init(struct hda_codec *codec) | ||
| 957 | { | ||
| 958 | ad198x_init(codec); | ||
| 959 | ad1986a_hp_automute(codec); | ||
| 960 | ad1986a_automic(codec); | ||
| 961 | return 0; | ||
| 962 | } | ||
| 963 | |||
| 984 | 964 | ||
| 985 | /* models */ | 965 | /* models */ |
| 986 | enum { | 966 | enum { |
| @@ -991,6 +971,7 @@ enum { | |||
| 991 | AD1986A_LAPTOP_AUTOMUTE, | 971 | AD1986A_LAPTOP_AUTOMUTE, |
| 992 | AD1986A_ULTRA, | 972 | AD1986A_ULTRA, |
| 993 | AD1986A_SAMSUNG, | 973 | AD1986A_SAMSUNG, |
| 974 | AD1986A_SAMSUNG_P50, | ||
| 994 | AD1986A_MODELS | 975 | AD1986A_MODELS |
| 995 | }; | 976 | }; |
| 996 | 977 | ||
| @@ -1002,6 +983,7 @@ static const char *ad1986a_models[AD1986A_MODELS] = { | |||
| 1002 | [AD1986A_LAPTOP_AUTOMUTE] = "laptop-automute", | 983 | [AD1986A_LAPTOP_AUTOMUTE] = "laptop-automute", |
| 1003 | [AD1986A_ULTRA] = "ultra", | 984 | [AD1986A_ULTRA] = "ultra", |
| 1004 | [AD1986A_SAMSUNG] = "samsung", | 985 | [AD1986A_SAMSUNG] = "samsung", |
| 986 | [AD1986A_SAMSUNG_P50] = "samsung-p50", | ||
| 1005 | }; | 987 | }; |
| 1006 | 988 | ||
| 1007 | static struct snd_pci_quirk ad1986a_cfg_tbl[] = { | 989 | static struct snd_pci_quirk ad1986a_cfg_tbl[] = { |
| @@ -1024,6 +1006,7 @@ static struct snd_pci_quirk ad1986a_cfg_tbl[] = { | |||
| 1024 | SND_PCI_QUIRK(0x1179, 0xff40, "Toshiba", AD1986A_LAPTOP_EAPD), | 1006 | SND_PCI_QUIRK(0x1179, 0xff40, "Toshiba", AD1986A_LAPTOP_EAPD), |
| 1025 | SND_PCI_QUIRK(0x144d, 0xb03c, "Samsung R55", AD1986A_3STACK), | 1007 | SND_PCI_QUIRK(0x144d, 0xb03c, "Samsung R55", AD1986A_3STACK), |
| 1026 | SND_PCI_QUIRK(0x144d, 0xc01e, "FSC V2060", AD1986A_LAPTOP), | 1008 | SND_PCI_QUIRK(0x144d, 0xc01e, "FSC V2060", AD1986A_LAPTOP), |
| 1009 | SND_PCI_QUIRK(0x144d, 0xc024, "Samsung P50", AD1986A_SAMSUNG_P50), | ||
| 1027 | SND_PCI_QUIRK(0x144d, 0xc027, "Samsung Q1", AD1986A_ULTRA), | 1010 | SND_PCI_QUIRK(0x144d, 0xc027, "Samsung Q1", AD1986A_ULTRA), |
| 1028 | SND_PCI_QUIRK_MASK(0x144d, 0xff00, 0xc000, "Samsung", AD1986A_SAMSUNG), | 1011 | SND_PCI_QUIRK_MASK(0x144d, 0xff00, 0xc000, "Samsung", AD1986A_SAMSUNG), |
| 1029 | SND_PCI_QUIRK(0x144d, 0xc504, "Samsung Q35", AD1986A_3STACK), | 1012 | SND_PCI_QUIRK(0x144d, 0xc504, "Samsung Q35", AD1986A_3STACK), |
| @@ -1111,7 +1094,10 @@ static int patch_ad1986a(struct hda_codec *codec) | |||
| 1111 | spec->multiout.dac_nids = ad1986a_laptop_dac_nids; | 1094 | spec->multiout.dac_nids = ad1986a_laptop_dac_nids; |
| 1112 | break; | 1095 | break; |
| 1113 | case AD1986A_LAPTOP_EAPD: | 1096 | case AD1986A_LAPTOP_EAPD: |
| 1114 | spec->mixers[0] = ad1986a_laptop_eapd_mixers; | 1097 | spec->num_mixers = 3; |
| 1098 | spec->mixers[0] = ad1986a_laptop_master_mixers; | ||
| 1099 | spec->mixers[1] = ad1986a_laptop_eapd_mixers; | ||
| 1100 | spec->mixers[2] = ad1986a_laptop_intmic_mixers; | ||
| 1115 | spec->num_init_verbs = 2; | 1101 | spec->num_init_verbs = 2; |
| 1116 | spec->init_verbs[1] = ad1986a_eapd_init_verbs; | 1102 | spec->init_verbs[1] = ad1986a_eapd_init_verbs; |
| 1117 | spec->multiout.max_channels = 2; | 1103 | spec->multiout.max_channels = 2; |
| @@ -1122,7 +1108,9 @@ static int patch_ad1986a(struct hda_codec *codec) | |||
| 1122 | spec->input_mux = &ad1986a_laptop_eapd_capture_source; | 1108 | spec->input_mux = &ad1986a_laptop_eapd_capture_source; |
| 1123 | break; | 1109 | break; |
| 1124 | case AD1986A_SAMSUNG: | 1110 | case AD1986A_SAMSUNG: |
| 1125 | spec->mixers[0] = ad1986a_samsung_mixers; | 1111 | spec->num_mixers = 2; |
| 1112 | spec->mixers[0] = ad1986a_laptop_master_mixers; | ||
| 1113 | spec->mixers[1] = ad1986a_laptop_eapd_mixers; | ||
| 1126 | spec->num_init_verbs = 3; | 1114 | spec->num_init_verbs = 3; |
| 1127 | spec->init_verbs[1] = ad1986a_eapd_init_verbs; | 1115 | spec->init_verbs[1] = ad1986a_eapd_init_verbs; |
| 1128 | spec->init_verbs[2] = ad1986a_automic_verbs; | 1116 | spec->init_verbs[2] = ad1986a_automic_verbs; |
| @@ -1135,8 +1123,28 @@ static int patch_ad1986a(struct hda_codec *codec) | |||
| 1135 | codec->patch_ops.unsol_event = ad1986a_automic_unsol_event; | 1123 | codec->patch_ops.unsol_event = ad1986a_automic_unsol_event; |
| 1136 | codec->patch_ops.init = ad1986a_automic_init; | 1124 | codec->patch_ops.init = ad1986a_automic_init; |
| 1137 | break; | 1125 | break; |
| 1126 | case AD1986A_SAMSUNG_P50: | ||
| 1127 | spec->num_mixers = 2; | ||
| 1128 | spec->mixers[0] = ad1986a_automute_master_mixers; | ||
| 1129 | spec->mixers[1] = ad1986a_laptop_eapd_mixers; | ||
| 1130 | spec->num_init_verbs = 4; | ||
| 1131 | spec->init_verbs[1] = ad1986a_eapd_init_verbs; | ||
| 1132 | spec->init_verbs[2] = ad1986a_automic_verbs; | ||
| 1133 | spec->init_verbs[3] = ad1986a_hp_init_verbs; | ||
| 1134 | spec->multiout.max_channels = 2; | ||
| 1135 | spec->multiout.num_dacs = 1; | ||
| 1136 | spec->multiout.dac_nids = ad1986a_laptop_dac_nids; | ||
| 1137 | if (!is_jack_available(codec, 0x25)) | ||
| 1138 | spec->multiout.dig_out_nid = 0; | ||
| 1139 | spec->input_mux = &ad1986a_automic_capture_source; | ||
| 1140 | codec->patch_ops.unsol_event = ad1986a_samsung_p50_unsol_event; | ||
| 1141 | codec->patch_ops.init = ad1986a_samsung_p50_init; | ||
| 1142 | break; | ||
| 1138 | case AD1986A_LAPTOP_AUTOMUTE: | 1143 | case AD1986A_LAPTOP_AUTOMUTE: |
| 1139 | spec->mixers[0] = ad1986a_laptop_automute_mixers; | 1144 | spec->num_mixers = 3; |
| 1145 | spec->mixers[0] = ad1986a_automute_master_mixers; | ||
| 1146 | spec->mixers[1] = ad1986a_laptop_eapd_mixers; | ||
| 1147 | spec->mixers[2] = ad1986a_laptop_intmic_mixers; | ||
| 1140 | spec->num_init_verbs = 3; | 1148 | spec->num_init_verbs = 3; |
| 1141 | spec->init_verbs[1] = ad1986a_eapd_init_verbs; | 1149 | spec->init_verbs[1] = ad1986a_eapd_init_verbs; |
| 1142 | spec->init_verbs[2] = ad1986a_hp_init_verbs; | 1150 | spec->init_verbs[2] = ad1986a_hp_init_verbs; |
| @@ -1148,6 +1156,10 @@ static int patch_ad1986a(struct hda_codec *codec) | |||
| 1148 | spec->input_mux = &ad1986a_laptop_eapd_capture_source; | 1156 | spec->input_mux = &ad1986a_laptop_eapd_capture_source; |
| 1149 | codec->patch_ops.unsol_event = ad1986a_hp_unsol_event; | 1157 | codec->patch_ops.unsol_event = ad1986a_hp_unsol_event; |
| 1150 | codec->patch_ops.init = ad1986a_hp_init; | 1158 | codec->patch_ops.init = ad1986a_hp_init; |
| 1159 | /* Lenovo N100 seems to report the reversed bit | ||
| 1160 | * for HP jack-sensing | ||
| 1161 | */ | ||
| 1162 | spec->inv_jack_detect = 1; | ||
| 1151 | break; | 1163 | break; |
| 1152 | case AD1986A_ULTRA: | 1164 | case AD1986A_ULTRA: |
| 1153 | spec->mixers[0] = ad1986a_laptop_eapd_mixers; | 1165 | spec->mixers[0] = ad1986a_laptop_eapd_mixers; |
| @@ -3734,9 +3746,30 @@ static struct snd_kcontrol_new ad1884a_laptop_mixers[] = { | |||
| 3734 | { } /* end */ | 3746 | { } /* end */ |
| 3735 | }; | 3747 | }; |
| 3736 | 3748 | ||
| 3749 | static int ad1884a_mobile_master_sw_put(struct snd_kcontrol *kcontrol, | ||
| 3750 | struct snd_ctl_elem_value *ucontrol) | ||
| 3751 | { | ||
| 3752 | struct hda_codec *codec = snd_kcontrol_chip(kcontrol); | ||
| 3753 | int ret = snd_hda_mixer_amp_switch_put(kcontrol, ucontrol); | ||
| 3754 | int mute = (!ucontrol->value.integer.value[0] && | ||
| 3755 | !ucontrol->value.integer.value[1]); | ||
| 3756 | /* toggle GPIO1 according to the mute state */ | ||
| 3757 | snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_DATA, | ||
| 3758 | mute ? 0x02 : 0x0); | ||
| 3759 | return ret; | ||
| 3760 | } | ||
| 3761 | |||
| 3737 | static struct snd_kcontrol_new ad1884a_mobile_mixers[] = { | 3762 | static struct snd_kcontrol_new ad1884a_mobile_mixers[] = { |
| 3738 | HDA_CODEC_VOLUME("Master Playback Volume", 0x21, 0x0, HDA_OUTPUT), | 3763 | HDA_CODEC_VOLUME("Master Playback Volume", 0x21, 0x0, HDA_OUTPUT), |
| 3739 | HDA_CODEC_MUTE("Master Playback Switch", 0x21, 0x0, HDA_OUTPUT), | 3764 | /*HDA_CODEC_MUTE("Master Playback Switch", 0x21, 0x0, HDA_OUTPUT),*/ |
| 3765 | { | ||
| 3766 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | ||
| 3767 | .name = "Master Playback Switch", | ||
| 3768 | .info = snd_hda_mixer_amp_switch_info, | ||
| 3769 | .get = snd_hda_mixer_amp_switch_get, | ||
| 3770 | .put = ad1884a_mobile_master_sw_put, | ||
| 3771 | .private_value = HDA_COMPOSE_AMP_VAL(0x21, 3, 0, HDA_OUTPUT), | ||
| 3772 | }, | ||
| 3740 | HDA_CODEC_VOLUME("PCM Playback Volume", 0x20, 0x5, HDA_INPUT), | 3773 | HDA_CODEC_VOLUME("PCM Playback Volume", 0x20, 0x5, HDA_INPUT), |
| 3741 | HDA_CODEC_MUTE("PCM Playback Switch", 0x20, 0x5, HDA_INPUT), | 3774 | HDA_CODEC_MUTE("PCM Playback Switch", 0x20, 0x5, HDA_INPUT), |
| 3742 | HDA_CODEC_VOLUME("Mic Capture Volume", 0x14, 0x0, HDA_INPUT), | 3775 | HDA_CODEC_VOLUME("Mic Capture Volume", 0x14, 0x0, HDA_INPUT), |
| @@ -3857,6 +3890,10 @@ static struct hda_verb ad1884a_mobile_verbs[] = { | |||
| 3857 | /* unsolicited event for pin-sense */ | 3890 | /* unsolicited event for pin-sense */ |
| 3858 | {0x11, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | AD1884A_HP_EVENT}, | 3891 | {0x11, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | AD1884A_HP_EVENT}, |
| 3859 | {0x14, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | AD1884A_MIC_EVENT}, | 3892 | {0x14, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | AD1884A_MIC_EVENT}, |
| 3893 | /* allow to touch GPIO1 (for mute control) */ | ||
| 3894 | {0x01, AC_VERB_SET_GPIO_MASK, 0x02}, | ||
| 3895 | {0x01, AC_VERB_SET_GPIO_DIRECTION, 0x02}, | ||
| 3896 | {0x01, AC_VERB_SET_GPIO_DATA, 0x02}, /* first muted */ | ||
| 3860 | { } /* end */ | 3897 | { } /* end */ |
| 3861 | }; | 3898 | }; |
| 3862 | 3899 | ||
| @@ -3966,6 +4003,7 @@ static struct snd_pci_quirk ad1884a_cfg_tbl[] = { | |||
| 3966 | SND_PCI_QUIRK(0x103c, 0x3037, "HP 2230s", AD1884A_LAPTOP), | 4003 | SND_PCI_QUIRK(0x103c, 0x3037, "HP 2230s", AD1884A_LAPTOP), |
| 3967 | SND_PCI_QUIRK(0x103c, 0x3056, "HP", AD1884A_MOBILE), | 4004 | SND_PCI_QUIRK(0x103c, 0x3056, "HP", AD1884A_MOBILE), |
| 3968 | SND_PCI_QUIRK_MASK(0x103c, 0xfff0, 0x3070, "HP", AD1884A_MOBILE), | 4005 | SND_PCI_QUIRK_MASK(0x103c, 0xfff0, 0x3070, "HP", AD1884A_MOBILE), |
| 4006 | SND_PCI_QUIRK_MASK(0x103c, 0xfff0, 0x30d0, "HP laptop", AD1884A_LAPTOP), | ||
| 3969 | SND_PCI_QUIRK_MASK(0x103c, 0xfff0, 0x30e0, "HP laptop", AD1884A_LAPTOP), | 4007 | SND_PCI_QUIRK_MASK(0x103c, 0xfff0, 0x30e0, "HP laptop", AD1884A_LAPTOP), |
| 3970 | SND_PCI_QUIRK_MASK(0x103c, 0xff00, 0x3600, "HP laptop", AD1884A_LAPTOP), | 4008 | SND_PCI_QUIRK_MASK(0x103c, 0xff00, 0x3600, "HP laptop", AD1884A_LAPTOP), |
| 3971 | SND_PCI_QUIRK(0x17aa, 0x20ac, "Thinkpad X300", AD1884A_THINKPAD), | 4009 | SND_PCI_QUIRK(0x17aa, 0x20ac, "Thinkpad X300", AD1884A_THINKPAD), |
diff --git a/sound/pci/hda/patch_ca0110.c b/sound/pci/hda/patch_ca0110.c index 392d108c3558..019ca7cb56d7 100644 --- a/sound/pci/hda/patch_ca0110.c +++ b/sound/pci/hda/patch_ca0110.c | |||
| @@ -510,7 +510,7 @@ static int ca0110_parse_auto_config(struct hda_codec *codec) | |||
| 510 | } | 510 | } |
| 511 | 511 | ||
| 512 | 512 | ||
| 513 | int patch_ca0110(struct hda_codec *codec) | 513 | static int patch_ca0110(struct hda_codec *codec) |
| 514 | { | 514 | { |
| 515 | struct ca0110_spec *spec; | 515 | struct ca0110_spec *spec; |
| 516 | int err; | 516 | int err; |
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 334533197425..bbb9b42e2604 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
| @@ -945,12 +945,13 @@ static void alc_fix_pll_init(struct hda_codec *codec, hda_nid_t nid, | |||
| 945 | static void alc_automute_pin(struct hda_codec *codec) | 945 | static void alc_automute_pin(struct hda_codec *codec) |
| 946 | { | 946 | { |
| 947 | struct alc_spec *spec = codec->spec; | 947 | struct alc_spec *spec = codec->spec; |
| 948 | unsigned int present; | 948 | unsigned int present, pincap; |
| 949 | unsigned int nid = spec->autocfg.hp_pins[0]; | 949 | unsigned int nid = spec->autocfg.hp_pins[0]; |
| 950 | int i; | 950 | int i; |
| 951 | 951 | ||
| 952 | /* need to execute and sync at first */ | 952 | pincap = snd_hda_query_pin_caps(codec, nid); |
| 953 | snd_hda_codec_read(codec, nid, 0, AC_VERB_SET_PIN_SENSE, 0); | 953 | if (pincap & AC_PINCAP_TRIG_REQ) /* need trigger? */ |
| 954 | snd_hda_codec_read(codec, nid, 0, AC_VERB_SET_PIN_SENSE, 0); | ||
| 954 | present = snd_hda_codec_read(codec, nid, 0, | 955 | present = snd_hda_codec_read(codec, nid, 0, |
| 955 | AC_VERB_GET_PIN_SENSE, 0); | 956 | AC_VERB_GET_PIN_SENSE, 0); |
| 956 | spec->jack_present = (present & AC_PINSENSE_PRESENCE) != 0; | 957 | spec->jack_present = (present & AC_PINSENSE_PRESENCE) != 0; |
| @@ -1392,7 +1393,7 @@ static struct hda_verb alc888_fujitsu_xa3530_verbs[] = { | |||
| 1392 | static void alc_automute_amp(struct hda_codec *codec) | 1393 | static void alc_automute_amp(struct hda_codec *codec) |
| 1393 | { | 1394 | { |
| 1394 | struct alc_spec *spec = codec->spec; | 1395 | struct alc_spec *spec = codec->spec; |
| 1395 | unsigned int val, mute; | 1396 | unsigned int val, mute, pincap; |
| 1396 | hda_nid_t nid; | 1397 | hda_nid_t nid; |
| 1397 | int i; | 1398 | int i; |
| 1398 | 1399 | ||
| @@ -1401,6 +1402,10 @@ static void alc_automute_amp(struct hda_codec *codec) | |||
| 1401 | nid = spec->autocfg.hp_pins[i]; | 1402 | nid = spec->autocfg.hp_pins[i]; |
| 1402 | if (!nid) | 1403 | if (!nid) |
| 1403 | break; | 1404 | break; |
| 1405 | pincap = snd_hda_query_pin_caps(codec, nid); | ||
| 1406 | if (pincap & AC_PINCAP_TRIG_REQ) /* need trigger? */ | ||
| 1407 | snd_hda_codec_read(codec, nid, 0, | ||
| 1408 | AC_VERB_SET_PIN_SENSE, 0); | ||
| 1404 | val = snd_hda_codec_read(codec, nid, 0, | 1409 | val = snd_hda_codec_read(codec, nid, 0, |
| 1405 | AC_VERB_GET_PIN_SENSE, 0); | 1410 | AC_VERB_GET_PIN_SENSE, 0); |
| 1406 | if (val & AC_PINSENSE_PRESENCE) { | 1411 | if (val & AC_PINSENSE_PRESENCE) { |
| @@ -1471,6 +1476,10 @@ static struct hda_verb alc888_acer_aspire_4930g_verbs[] = { | |||
| 1471 | static struct hda_verb alc888_acer_aspire_6530g_verbs[] = { | 1476 | static struct hda_verb alc888_acer_aspire_6530g_verbs[] = { |
| 1472 | /* Bias voltage on for external mic port */ | 1477 | /* Bias voltage on for external mic port */ |
| 1473 | {0x18, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_IN | PIN_VREF80}, | 1478 | {0x18, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_IN | PIN_VREF80}, |
| 1479 | /* Front Mic: set to PIN_IN (empty by default) */ | ||
| 1480 | {0x12, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_IN}, | ||
| 1481 | /* Unselect Front Mic by default in input mixer 3 */ | ||
| 1482 | {0x22, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0xb)}, | ||
| 1474 | /* Enable unsolicited event for HP jack */ | 1483 | /* Enable unsolicited event for HP jack */ |
| 1475 | {0x15, AC_VERB_SET_UNSOLICITED_ENABLE, ALC880_HP_EVENT | AC_USRSP_EN}, | 1484 | {0x15, AC_VERB_SET_UNSOLICITED_ENABLE, ALC880_HP_EVENT | AC_USRSP_EN}, |
| 1476 | /* Enable speaker output */ | 1485 | /* Enable speaker output */ |
| @@ -1560,18 +1569,22 @@ static struct hda_input_mux alc888_2_capture_sources[2] = { | |||
| 1560 | static struct hda_input_mux alc888_acer_aspire_6530_sources[2] = { | 1569 | static struct hda_input_mux alc888_acer_aspire_6530_sources[2] = { |
| 1561 | /* Interal mic only available on one ADC */ | 1570 | /* Interal mic only available on one ADC */ |
| 1562 | { | 1571 | { |
| 1563 | .num_items = 3, | 1572 | .num_items = 5, |
| 1564 | .items = { | 1573 | .items = { |
| 1565 | { "Ext Mic", 0x0 }, | 1574 | { "Ext Mic", 0x0 }, |
| 1575 | { "Line In", 0x2 }, | ||
| 1566 | { "CD", 0x4 }, | 1576 | { "CD", 0x4 }, |
| 1577 | { "Input Mix", 0xa }, | ||
| 1567 | { "Int Mic", 0xb }, | 1578 | { "Int Mic", 0xb }, |
| 1568 | }, | 1579 | }, |
| 1569 | }, | 1580 | }, |
| 1570 | { | 1581 | { |
| 1571 | .num_items = 2, | 1582 | .num_items = 4, |
| 1572 | .items = { | 1583 | .items = { |
| 1573 | { "Ext Mic", 0x0 }, | 1584 | { "Ext Mic", 0x0 }, |
| 1585 | { "Line In", 0x2 }, | ||
| 1574 | { "CD", 0x4 }, | 1586 | { "CD", 0x4 }, |
| 1587 | { "Input Mix", 0xa }, | ||
| 1575 | }, | 1588 | }, |
| 1576 | } | 1589 | } |
| 1577 | }; | 1590 | }; |
| @@ -1639,6 +1652,17 @@ static void alc888_acer_aspire_4930g_init_hook(struct hda_codec *codec) | |||
| 1639 | alc_automute_amp(codec); | 1652 | alc_automute_amp(codec); |
| 1640 | } | 1653 | } |
| 1641 | 1654 | ||
| 1655 | static void alc888_acer_aspire_6530g_init_hook(struct hda_codec *codec) | ||
| 1656 | { | ||
| 1657 | struct alc_spec *spec = codec->spec; | ||
| 1658 | |||
| 1659 | spec->autocfg.hp_pins[0] = 0x15; | ||
| 1660 | spec->autocfg.speaker_pins[0] = 0x14; | ||
| 1661 | spec->autocfg.speaker_pins[1] = 0x16; | ||
| 1662 | spec->autocfg.speaker_pins[2] = 0x17; | ||
| 1663 | alc_automute_amp(codec); | ||
| 1664 | } | ||
| 1665 | |||
| 1642 | static void alc889_acer_aspire_8930g_init_hook(struct hda_codec *codec) | 1666 | static void alc889_acer_aspire_8930g_init_hook(struct hda_codec *codec) |
| 1643 | { | 1667 | { |
| 1644 | struct alc_spec *spec = codec->spec; | 1668 | struct alc_spec *spec = codec->spec; |
| @@ -6895,9 +6919,6 @@ static struct hda_verb alc882_targa_verbs[] = { | |||
| 6895 | {0x1b, AC_VERB_SET_CONNECT_SEL, 0x00}, /* HP */ | 6919 | {0x1b, AC_VERB_SET_CONNECT_SEL, 0x00}, /* HP */ |
| 6896 | 6920 | ||
| 6897 | {0x14, AC_VERB_SET_UNSOLICITED_ENABLE, ALC880_HP_EVENT | AC_USRSP_EN}, | 6921 | {0x14, AC_VERB_SET_UNSOLICITED_ENABLE, ALC880_HP_EVENT | AC_USRSP_EN}, |
| 6898 | {0x01, AC_VERB_SET_GPIO_MASK, 0x03}, | ||
| 6899 | {0x01, AC_VERB_SET_GPIO_DIRECTION, 0x03}, | ||
| 6900 | {0x01, AC_VERB_SET_GPIO_DATA, 0x03}, | ||
| 6901 | { } /* end */ | 6922 | { } /* end */ |
| 6902 | }; | 6923 | }; |
| 6903 | 6924 | ||
| @@ -7217,7 +7238,8 @@ static struct alc_config_preset alc882_presets[] = { | |||
| 7217 | }, | 7238 | }, |
| 7218 | [ALC882_TARGA] = { | 7239 | [ALC882_TARGA] = { |
| 7219 | .mixers = { alc882_targa_mixer, alc882_chmode_mixer }, | 7240 | .mixers = { alc882_targa_mixer, alc882_chmode_mixer }, |
| 7220 | .init_verbs = { alc882_init_verbs, alc882_targa_verbs}, | 7241 | .init_verbs = { alc882_init_verbs, alc880_gpio3_init_verbs, |
| 7242 | alc882_targa_verbs}, | ||
| 7221 | .num_dacs = ARRAY_SIZE(alc882_dac_nids), | 7243 | .num_dacs = ARRAY_SIZE(alc882_dac_nids), |
| 7222 | .dac_nids = alc882_dac_nids, | 7244 | .dac_nids = alc882_dac_nids, |
| 7223 | .dig_out_nid = ALC882_DIGOUT_NID, | 7245 | .dig_out_nid = ALC882_DIGOUT_NID, |
| @@ -8189,6 +8211,8 @@ static struct snd_kcontrol_new alc888_acer_aspire_6530_mixer[] = { | |||
| 8189 | HDA_BIND_MUTE("Front Playback Switch", 0x0c, 2, HDA_INPUT), | 8211 | HDA_BIND_MUTE("Front Playback Switch", 0x0c, 2, HDA_INPUT), |
| 8190 | HDA_CODEC_VOLUME("LFE Playback Volume", 0x0f, 0x0, HDA_OUTPUT), | 8212 | HDA_CODEC_VOLUME("LFE Playback Volume", 0x0f, 0x0, HDA_OUTPUT), |
| 8191 | HDA_BIND_MUTE("LFE Playback Switch", 0x0f, 2, HDA_INPUT), | 8213 | HDA_BIND_MUTE("LFE Playback Switch", 0x0f, 2, HDA_INPUT), |
| 8214 | HDA_CODEC_VOLUME("Line Playback Volume", 0x0b, 0x02, HDA_INPUT), | ||
| 8215 | HDA_CODEC_MUTE("Line Playback Switch", 0x0b, 0x02, HDA_INPUT), | ||
| 8192 | HDA_CODEC_VOLUME("CD Playback Volume", 0x0b, 0x04, HDA_INPUT), | 8216 | HDA_CODEC_VOLUME("CD Playback Volume", 0x0b, 0x04, HDA_INPUT), |
| 8193 | HDA_CODEC_MUTE("CD Playback Switch", 0x0b, 0x04, HDA_INPUT), | 8217 | HDA_CODEC_MUTE("CD Playback Switch", 0x0b, 0x04, HDA_INPUT), |
| 8194 | HDA_CODEC_VOLUME("Mic Playback Volume", 0x0b, 0x0, HDA_INPUT), | 8218 | HDA_CODEC_VOLUME("Mic Playback Volume", 0x0b, 0x0, HDA_INPUT), |
| @@ -9064,7 +9088,7 @@ static struct snd_pci_quirk alc883_cfg_tbl[] = { | |||
| 9064 | SND_PCI_QUIRK(0x1025, 0x0157, "Acer X3200", ALC883_AUTO), | 9088 | SND_PCI_QUIRK(0x1025, 0x0157, "Acer X3200", ALC883_AUTO), |
| 9065 | SND_PCI_QUIRK(0x1025, 0x0158, "Acer AX1700-U3700A", ALC883_AUTO), | 9089 | SND_PCI_QUIRK(0x1025, 0x0158, "Acer AX1700-U3700A", ALC883_AUTO), |
| 9066 | SND_PCI_QUIRK(0x1025, 0x015e, "Acer Aspire 6930G", | 9090 | SND_PCI_QUIRK(0x1025, 0x015e, "Acer Aspire 6930G", |
| 9067 | ALC888_ACER_ASPIRE_4930G), | 9091 | ALC888_ACER_ASPIRE_6530G), |
| 9068 | SND_PCI_QUIRK(0x1025, 0x0166, "Acer Aspire 6530G", | 9092 | SND_PCI_QUIRK(0x1025, 0x0166, "Acer Aspire 6530G", |
| 9069 | ALC888_ACER_ASPIRE_6530G), | 9093 | ALC888_ACER_ASPIRE_6530G), |
| 9070 | /* default Acer -- disabled as it causes more problems. | 9094 | /* default Acer -- disabled as it causes more problems. |
| @@ -9212,7 +9236,8 @@ static struct alc_config_preset alc883_presets[] = { | |||
| 9212 | }, | 9236 | }, |
| 9213 | [ALC883_TARGA_DIG] = { | 9237 | [ALC883_TARGA_DIG] = { |
| 9214 | .mixers = { alc883_targa_mixer, alc883_chmode_mixer }, | 9238 | .mixers = { alc883_targa_mixer, alc883_chmode_mixer }, |
| 9215 | .init_verbs = { alc883_init_verbs, alc883_targa_verbs}, | 9239 | .init_verbs = { alc883_init_verbs, alc880_gpio3_init_verbs, |
| 9240 | alc883_targa_verbs}, | ||
| 9216 | .num_dacs = ARRAY_SIZE(alc883_dac_nids), | 9241 | .num_dacs = ARRAY_SIZE(alc883_dac_nids), |
| 9217 | .dac_nids = alc883_dac_nids, | 9242 | .dac_nids = alc883_dac_nids, |
| 9218 | .dig_out_nid = ALC883_DIGOUT_NID, | 9243 | .dig_out_nid = ALC883_DIGOUT_NID, |
| @@ -9225,7 +9250,8 @@ static struct alc_config_preset alc883_presets[] = { | |||
| 9225 | }, | 9250 | }, |
| 9226 | [ALC883_TARGA_2ch_DIG] = { | 9251 | [ALC883_TARGA_2ch_DIG] = { |
| 9227 | .mixers = { alc883_targa_2ch_mixer}, | 9252 | .mixers = { alc883_targa_2ch_mixer}, |
| 9228 | .init_verbs = { alc883_init_verbs, alc883_targa_verbs}, | 9253 | .init_verbs = { alc883_init_verbs, alc880_gpio3_init_verbs, |
| 9254 | alc883_targa_verbs}, | ||
| 9229 | .num_dacs = ARRAY_SIZE(alc883_dac_nids), | 9255 | .num_dacs = ARRAY_SIZE(alc883_dac_nids), |
| 9230 | .dac_nids = alc883_dac_nids, | 9256 | .dac_nids = alc883_dac_nids, |
| 9231 | .adc_nids = alc883_adc_nids_alt, | 9257 | .adc_nids = alc883_adc_nids_alt, |
| @@ -9317,7 +9343,7 @@ static struct alc_config_preset alc883_presets[] = { | |||
| 9317 | ARRAY_SIZE(alc888_2_capture_sources), | 9343 | ARRAY_SIZE(alc888_2_capture_sources), |
| 9318 | .input_mux = alc888_acer_aspire_6530_sources, | 9344 | .input_mux = alc888_acer_aspire_6530_sources, |
| 9319 | .unsol_event = alc_automute_amp_unsol_event, | 9345 | .unsol_event = alc_automute_amp_unsol_event, |
| 9320 | .init_hook = alc888_acer_aspire_4930g_init_hook, | 9346 | .init_hook = alc888_acer_aspire_6530g_init_hook, |
| 9321 | }, | 9347 | }, |
| 9322 | [ALC888_ACER_ASPIRE_8930G] = { | 9348 | [ALC888_ACER_ASPIRE_8930G] = { |
| 9323 | .mixers = { alc888_base_mixer, | 9349 | .mixers = { alc888_base_mixer, |
| @@ -12437,6 +12463,8 @@ static int alc268_parse_auto_config(struct hda_codec *codec) | |||
| 12437 | if (err < 0) | 12463 | if (err < 0) |
| 12438 | return err; | 12464 | return err; |
| 12439 | 12465 | ||
| 12466 | alc_ssid_check(codec, 0x15, 0x1b, 0x14); | ||
| 12467 | |||
| 12440 | return 1; | 12468 | return 1; |
| 12441 | } | 12469 | } |
| 12442 | 12470 | ||
| @@ -12848,20 +12876,11 @@ static struct snd_kcontrol_new alc269_lifebook_mixer[] = { | |||
| 12848 | { } | 12876 | { } |
| 12849 | }; | 12877 | }; |
| 12850 | 12878 | ||
| 12851 | /* bind volumes of both NID 0x0c and 0x0d */ | ||
| 12852 | static struct hda_bind_ctls alc269_epc_bind_vol = { | ||
| 12853 | .ops = &snd_hda_bind_vol, | ||
| 12854 | .values = { | ||
| 12855 | HDA_COMPOSE_AMP_VAL(0x02, 3, 0, HDA_OUTPUT), | ||
| 12856 | HDA_COMPOSE_AMP_VAL(0x03, 3, 0, HDA_OUTPUT), | ||
| 12857 | 0 | ||
| 12858 | }, | ||
| 12859 | }; | ||
| 12860 | |||
| 12861 | static struct snd_kcontrol_new alc269_eeepc_mixer[] = { | 12879 | static struct snd_kcontrol_new alc269_eeepc_mixer[] = { |
| 12862 | HDA_CODEC_MUTE("iSpeaker Playback Switch", 0x14, 0x0, HDA_OUTPUT), | 12880 | HDA_CODEC_MUTE("Speaker Playback Switch", 0x14, 0x0, HDA_OUTPUT), |
| 12863 | HDA_BIND_VOL("LineOut Playback Volume", &alc269_epc_bind_vol), | 12881 | HDA_CODEC_VOLUME("Speaker Playback Volume", 0x02, 0x0, HDA_OUTPUT), |
| 12864 | HDA_CODEC_MUTE("LineOut Playback Switch", 0x15, 0x0, HDA_OUTPUT), | 12882 | HDA_CODEC_MUTE("Headphone Playback Switch", 0x15, 0x0, HDA_OUTPUT), |
| 12883 | HDA_CODEC_VOLUME("Headphone Playback Volume", 0x03, 0x0, HDA_OUTPUT), | ||
| 12865 | { } /* end */ | 12884 | { } /* end */ |
| 12866 | }; | 12885 | }; |
| 12867 | 12886 | ||
| @@ -12874,12 +12893,7 @@ static struct snd_kcontrol_new alc269_epc_capture_mixer[] = { | |||
| 12874 | }; | 12893 | }; |
| 12875 | 12894 | ||
| 12876 | /* FSC amilo */ | 12895 | /* FSC amilo */ |
| 12877 | static struct snd_kcontrol_new alc269_fujitsu_mixer[] = { | 12896 | #define alc269_fujitsu_mixer alc269_eeepc_mixer |
| 12878 | HDA_CODEC_MUTE("Speaker Playback Switch", 0x14, 0x0, HDA_OUTPUT), | ||
| 12879 | HDA_CODEC_MUTE("Headphone Playback Switch", 0x15, 0x0, HDA_OUTPUT), | ||
| 12880 | HDA_BIND_VOL("PCM Playback Volume", &alc269_epc_bind_vol), | ||
| 12881 | { } /* end */ | ||
| 12882 | }; | ||
| 12883 | 12897 | ||
| 12884 | static struct hda_verb alc269_quanta_fl1_verbs[] = { | 12898 | static struct hda_verb alc269_quanta_fl1_verbs[] = { |
| 12885 | {0x15, AC_VERB_SET_CONNECT_SEL, 0x01}, | 12899 | {0x15, AC_VERB_SET_CONNECT_SEL, 0x01}, |
| @@ -13345,6 +13359,8 @@ static int alc269_parse_auto_config(struct hda_codec *codec) | |||
| 13345 | if (!spec->cap_mixer && !spec->no_analog) | 13359 | if (!spec->cap_mixer && !spec->no_analog) |
| 13346 | set_capture_mixer(spec); | 13360 | set_capture_mixer(spec); |
| 13347 | 13361 | ||
| 13362 | alc_ssid_check(codec, 0x15, 0x1b, 0x14); | ||
| 13363 | |||
| 13348 | return 1; | 13364 | return 1; |
| 13349 | } | 13365 | } |
| 13350 | 13366 | ||
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c index 14f3c3e0f62d..41b5b3a18c1e 100644 --- a/sound/pci/hda/patch_sigmatel.c +++ b/sound/pci/hda/patch_sigmatel.c | |||
| @@ -1590,8 +1590,6 @@ static struct snd_pci_quirk stac9200_cfg_tbl[] = { | |||
| 1590 | /* SigmaTel reference board */ | 1590 | /* SigmaTel reference board */ |
| 1591 | SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0x2668, | 1591 | SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0x2668, |
| 1592 | "DFI LanParty", STAC_REF), | 1592 | "DFI LanParty", STAC_REF), |
| 1593 | SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0xfb30, | ||
| 1594 | "SigmaTel",STAC_9205_REF), | ||
| 1595 | SND_PCI_QUIRK(PCI_VENDOR_ID_DFI, 0x3101, | 1593 | SND_PCI_QUIRK(PCI_VENDOR_ID_DFI, 0x3101, |
| 1596 | "DFI LanParty", STAC_REF), | 1594 | "DFI LanParty", STAC_REF), |
| 1597 | /* Dell laptops have BIOS problem */ | 1595 | /* Dell laptops have BIOS problem */ |
| @@ -2344,6 +2342,8 @@ static struct snd_pci_quirk stac9205_cfg_tbl[] = { | |||
| 2344 | /* SigmaTel reference board */ | 2342 | /* SigmaTel reference board */ |
| 2345 | SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0x2668, | 2343 | SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0x2668, |
| 2346 | "DFI LanParty", STAC_9205_REF), | 2344 | "DFI LanParty", STAC_9205_REF), |
| 2345 | SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0xfb30, | ||
| 2346 | "SigmaTel", STAC_9205_REF), | ||
| 2347 | SND_PCI_QUIRK(PCI_VENDOR_ID_DFI, 0x3101, | 2347 | SND_PCI_QUIRK(PCI_VENDOR_ID_DFI, 0x3101, |
| 2348 | "DFI LanParty", STAC_9205_REF), | 2348 | "DFI LanParty", STAC_9205_REF), |
| 2349 | /* Dell */ | 2349 | /* Dell */ |
diff --git a/sound/pci/hda/patch_via.c b/sound/pci/hda/patch_via.c index 8e004fb6961a..9008b4b013aa 100644 --- a/sound/pci/hda/patch_via.c +++ b/sound/pci/hda/patch_via.c | |||
| @@ -210,7 +210,9 @@ struct via_spec { | |||
| 210 | /* capture */ | 210 | /* capture */ |
| 211 | unsigned int num_adc_nids; | 211 | unsigned int num_adc_nids; |
| 212 | hda_nid_t *adc_nids; | 212 | hda_nid_t *adc_nids; |
| 213 | hda_nid_t mux_nids[3]; | ||
| 213 | hda_nid_t dig_in_nid; | 214 | hda_nid_t dig_in_nid; |
| 215 | hda_nid_t dig_in_pin; | ||
| 214 | 216 | ||
| 215 | /* capture source */ | 217 | /* capture source */ |
| 216 | const struct hda_input_mux *input_mux; | 218 | const struct hda_input_mux *input_mux; |
| @@ -319,6 +321,9 @@ static void via_auto_set_output_and_unmute(struct hda_codec *codec, | |||
| 319 | pin_type); | 321 | pin_type); |
| 320 | snd_hda_codec_write(codec, nid, 0, AC_VERB_SET_AMP_GAIN_MUTE, | 322 | snd_hda_codec_write(codec, nid, 0, AC_VERB_SET_AMP_GAIN_MUTE, |
| 321 | AMP_OUT_UNMUTE); | 323 | AMP_OUT_UNMUTE); |
| 324 | if (snd_hda_query_pin_caps(codec, nid) & AC_PINCAP_EAPD) | ||
| 325 | snd_hda_codec_write(codec, nid, 0, | ||
| 326 | AC_VERB_SET_EAPD_BTLENABLE, 0x02); | ||
| 322 | } | 327 | } |
| 323 | 328 | ||
| 324 | 329 | ||
| @@ -387,27 +392,12 @@ static int via_mux_enum_put(struct snd_kcontrol *kcontrol, | |||
| 387 | struct hda_codec *codec = snd_kcontrol_chip(kcontrol); | 392 | struct hda_codec *codec = snd_kcontrol_chip(kcontrol); |
| 388 | struct via_spec *spec = codec->spec; | 393 | struct via_spec *spec = codec->spec; |
| 389 | unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id); | 394 | unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id); |
| 390 | unsigned int vendor_id = codec->vendor_id; | 395 | |
| 391 | 396 | if (!spec->mux_nids[adc_idx]) | |
| 392 | /* AIW0 lydia 060801 add for correct sw0 input select */ | 397 | return -EINVAL; |
| 393 | if (IS_VT1708_VENDORID(vendor_id) && (adc_idx == 0)) | 398 | return snd_hda_input_mux_put(codec, spec->input_mux, ucontrol, |
| 394 | return snd_hda_input_mux_put(codec, spec->input_mux, ucontrol, | 399 | spec->mux_nids[adc_idx], |
| 395 | 0x18, &spec->cur_mux[adc_idx]); | 400 | &spec->cur_mux[adc_idx]); |
| 396 | else if ((IS_VT1709_10CH_VENDORID(vendor_id) || | ||
| 397 | IS_VT1709_6CH_VENDORID(vendor_id)) && (adc_idx == 0)) | ||
| 398 | return snd_hda_input_mux_put(codec, spec->input_mux, ucontrol, | ||
| 399 | 0x19, &spec->cur_mux[adc_idx]); | ||
| 400 | else if ((IS_VT1708B_8CH_VENDORID(vendor_id) || | ||
| 401 | IS_VT1708B_4CH_VENDORID(vendor_id)) && (adc_idx == 0)) | ||
| 402 | return snd_hda_input_mux_put(codec, spec->input_mux, ucontrol, | ||
| 403 | 0x17, &spec->cur_mux[adc_idx]); | ||
| 404 | else if (IS_VT1702_VENDORID(vendor_id) && (adc_idx == 0)) | ||
| 405 | return snd_hda_input_mux_put(codec, spec->input_mux, ucontrol, | ||
| 406 | 0x13, &spec->cur_mux[adc_idx]); | ||
| 407 | else | ||
| 408 | return snd_hda_input_mux_put(codec, spec->input_mux, ucontrol, | ||
| 409 | spec->adc_nids[adc_idx], | ||
| 410 | &spec->cur_mux[adc_idx]); | ||
| 411 | } | 401 | } |
| 412 | 402 | ||
| 413 | static int via_independent_hp_info(struct snd_kcontrol *kcontrol, | 403 | static int via_independent_hp_info(struct snd_kcontrol *kcontrol, |
| @@ -998,25 +988,11 @@ static int via_init(struct hda_codec *codec) | |||
| 998 | 988 | ||
| 999 | /* Lydia Add for EAPD enable */ | 989 | /* Lydia Add for EAPD enable */ |
| 1000 | if (!spec->dig_in_nid) { /* No Digital In connection */ | 990 | if (!spec->dig_in_nid) { /* No Digital In connection */ |
| 1001 | if (IS_VT1708_VENDORID(codec->vendor_id)) { | 991 | if (spec->dig_in_pin) { |
| 1002 | snd_hda_codec_write(codec, VT1708_DIGIN_PIN, 0, | 992 | snd_hda_codec_write(codec, spec->dig_in_pin, 0, |
| 1003 | AC_VERB_SET_PIN_WIDGET_CONTROL, | ||
| 1004 | PIN_OUT); | ||
| 1005 | snd_hda_codec_write(codec, VT1708_DIGIN_PIN, 0, | ||
| 1006 | AC_VERB_SET_EAPD_BTLENABLE, 0x02); | ||
| 1007 | } else if (IS_VT1709_10CH_VENDORID(codec->vendor_id) || | ||
| 1008 | IS_VT1709_6CH_VENDORID(codec->vendor_id)) { | ||
| 1009 | snd_hda_codec_write(codec, VT1709_DIGIN_PIN, 0, | ||
| 1010 | AC_VERB_SET_PIN_WIDGET_CONTROL, | 993 | AC_VERB_SET_PIN_WIDGET_CONTROL, |
| 1011 | PIN_OUT); | 994 | PIN_OUT); |
| 1012 | snd_hda_codec_write(codec, VT1709_DIGIN_PIN, 0, | 995 | snd_hda_codec_write(codec, spec->dig_in_pin, 0, |
| 1013 | AC_VERB_SET_EAPD_BTLENABLE, 0x02); | ||
| 1014 | } else if (IS_VT1708B_8CH_VENDORID(codec->vendor_id) || | ||
| 1015 | IS_VT1708B_4CH_VENDORID(codec->vendor_id)) { | ||
| 1016 | snd_hda_codec_write(codec, VT1708B_DIGIN_PIN, 0, | ||
| 1017 | AC_VERB_SET_PIN_WIDGET_CONTROL, | ||
| 1018 | PIN_OUT); | ||
| 1019 | snd_hda_codec_write(codec, VT1708B_DIGIN_PIN, 0, | ||
| 1020 | AC_VERB_SET_EAPD_BTLENABLE, 0x02); | 996 | AC_VERB_SET_EAPD_BTLENABLE, 0x02); |
| 1021 | } | 997 | } |
| 1022 | } else /* enable SPDIF-input pin */ | 998 | } else /* enable SPDIF-input pin */ |
| @@ -1326,6 +1302,7 @@ static int vt1708_parse_auto_config(struct hda_codec *codec) | |||
| 1326 | 1302 | ||
| 1327 | if (spec->autocfg.dig_outs) | 1303 | if (spec->autocfg.dig_outs) |
| 1328 | spec->multiout.dig_out_nid = VT1708_DIGOUT_NID; | 1304 | spec->multiout.dig_out_nid = VT1708_DIGOUT_NID; |
| 1305 | spec->dig_in_pin = VT1708_DIGIN_PIN; | ||
| 1329 | if (spec->autocfg.dig_in_pin) | 1306 | if (spec->autocfg.dig_in_pin) |
| 1330 | spec->dig_in_nid = VT1708_DIGIN_NID; | 1307 | spec->dig_in_nid = VT1708_DIGIN_NID; |
| 1331 | 1308 | ||
| @@ -1352,6 +1329,34 @@ static int via_auto_init(struct hda_codec *codec) | |||
| 1352 | return 0; | 1329 | return 0; |
| 1353 | } | 1330 | } |
| 1354 | 1331 | ||
| 1332 | static int get_mux_nids(struct hda_codec *codec) | ||
| 1333 | { | ||
| 1334 | struct via_spec *spec = codec->spec; | ||
| 1335 | hda_nid_t nid, conn[8]; | ||
| 1336 | unsigned int type; | ||
| 1337 | int i, n; | ||
| 1338 | |||
| 1339 | for (i = 0; i < spec->num_adc_nids; i++) { | ||
| 1340 | nid = spec->adc_nids[i]; | ||
| 1341 | while (nid) { | ||
| 1342 | type = (get_wcaps(codec, nid) & AC_WCAP_TYPE) | ||
| 1343 | >> AC_WCAP_TYPE_SHIFT; | ||
| 1344 | if (type == AC_WID_PIN) | ||
| 1345 | break; | ||
| 1346 | n = snd_hda_get_connections(codec, nid, conn, | ||
| 1347 | ARRAY_SIZE(conn)); | ||
| 1348 | if (n <= 0) | ||
| 1349 | break; | ||
| 1350 | if (n > 1) { | ||
| 1351 | spec->mux_nids[i] = nid; | ||
| 1352 | break; | ||
| 1353 | } | ||
| 1354 | nid = conn[0]; | ||
| 1355 | } | ||
| 1356 | } | ||
| 1357 | return 0; | ||
| 1358 | } | ||
| 1359 | |||
| 1355 | static int patch_vt1708(struct hda_codec *codec) | 1360 | static int patch_vt1708(struct hda_codec *codec) |
| 1356 | { | 1361 | { |
| 1357 | struct via_spec *spec; | 1362 | struct via_spec *spec; |
| @@ -1799,6 +1804,7 @@ static int vt1709_parse_auto_config(struct hda_codec *codec) | |||
| 1799 | 1804 | ||
| 1800 | if (spec->autocfg.dig_outs) | 1805 | if (spec->autocfg.dig_outs) |
| 1801 | spec->multiout.dig_out_nid = VT1709_DIGOUT_NID; | 1806 | spec->multiout.dig_out_nid = VT1709_DIGOUT_NID; |
| 1807 | spec->dig_in_pin = VT1709_DIGIN_PIN; | ||
| 1802 | if (spec->autocfg.dig_in_pin) | 1808 | if (spec->autocfg.dig_in_pin) |
| 1803 | spec->dig_in_nid = VT1709_DIGIN_NID; | 1809 | spec->dig_in_nid = VT1709_DIGIN_NID; |
| 1804 | 1810 | ||
| @@ -1859,6 +1865,7 @@ static int patch_vt1709_10ch(struct hda_codec *codec) | |||
| 1859 | if (!spec->adc_nids && spec->input_mux) { | 1865 | if (!spec->adc_nids && spec->input_mux) { |
| 1860 | spec->adc_nids = vt1709_adc_nids; | 1866 | spec->adc_nids = vt1709_adc_nids; |
| 1861 | spec->num_adc_nids = ARRAY_SIZE(vt1709_adc_nids); | 1867 | spec->num_adc_nids = ARRAY_SIZE(vt1709_adc_nids); |
| 1868 | get_mux_nids(codec); | ||
| 1862 | spec->mixers[spec->num_mixers] = vt1709_capture_mixer; | 1869 | spec->mixers[spec->num_mixers] = vt1709_capture_mixer; |
| 1863 | spec->num_mixers++; | 1870 | spec->num_mixers++; |
| 1864 | } | 1871 | } |
| @@ -1952,6 +1959,7 @@ static int patch_vt1709_6ch(struct hda_codec *codec) | |||
| 1952 | if (!spec->adc_nids && spec->input_mux) { | 1959 | if (!spec->adc_nids && spec->input_mux) { |
| 1953 | spec->adc_nids = vt1709_adc_nids; | 1960 | spec->adc_nids = vt1709_adc_nids; |
| 1954 | spec->num_adc_nids = ARRAY_SIZE(vt1709_adc_nids); | 1961 | spec->num_adc_nids = ARRAY_SIZE(vt1709_adc_nids); |
| 1962 | get_mux_nids(codec); | ||
| 1955 | spec->mixers[spec->num_mixers] = vt1709_capture_mixer; | 1963 | spec->mixers[spec->num_mixers] = vt1709_capture_mixer; |
| 1956 | spec->num_mixers++; | 1964 | spec->num_mixers++; |
| 1957 | } | 1965 | } |
| @@ -2344,6 +2352,7 @@ static int vt1708B_parse_auto_config(struct hda_codec *codec) | |||
| 2344 | 2352 | ||
| 2345 | if (spec->autocfg.dig_outs) | 2353 | if (spec->autocfg.dig_outs) |
| 2346 | spec->multiout.dig_out_nid = VT1708B_DIGOUT_NID; | 2354 | spec->multiout.dig_out_nid = VT1708B_DIGOUT_NID; |
| 2355 | spec->dig_in_pin = VT1708B_DIGIN_PIN; | ||
| 2347 | if (spec->autocfg.dig_in_pin) | 2356 | if (spec->autocfg.dig_in_pin) |
| 2348 | spec->dig_in_nid = VT1708B_DIGIN_NID; | 2357 | spec->dig_in_nid = VT1708B_DIGIN_NID; |
| 2349 | 2358 | ||
| @@ -2404,6 +2413,7 @@ static int patch_vt1708B_8ch(struct hda_codec *codec) | |||
| 2404 | if (!spec->adc_nids && spec->input_mux) { | 2413 | if (!spec->adc_nids && spec->input_mux) { |
| 2405 | spec->adc_nids = vt1708B_adc_nids; | 2414 | spec->adc_nids = vt1708B_adc_nids; |
| 2406 | spec->num_adc_nids = ARRAY_SIZE(vt1708B_adc_nids); | 2415 | spec->num_adc_nids = ARRAY_SIZE(vt1708B_adc_nids); |
| 2416 | get_mux_nids(codec); | ||
| 2407 | spec->mixers[spec->num_mixers] = vt1708B_capture_mixer; | 2417 | spec->mixers[spec->num_mixers] = vt1708B_capture_mixer; |
| 2408 | spec->num_mixers++; | 2418 | spec->num_mixers++; |
| 2409 | } | 2419 | } |
| @@ -2455,6 +2465,7 @@ static int patch_vt1708B_4ch(struct hda_codec *codec) | |||
| 2455 | if (!spec->adc_nids && spec->input_mux) { | 2465 | if (!spec->adc_nids && spec->input_mux) { |
| 2456 | spec->adc_nids = vt1708B_adc_nids; | 2466 | spec->adc_nids = vt1708B_adc_nids; |
| 2457 | spec->num_adc_nids = ARRAY_SIZE(vt1708B_adc_nids); | 2467 | spec->num_adc_nids = ARRAY_SIZE(vt1708B_adc_nids); |
| 2468 | get_mux_nids(codec); | ||
| 2458 | spec->mixers[spec->num_mixers] = vt1708B_capture_mixer; | 2469 | spec->mixers[spec->num_mixers] = vt1708B_capture_mixer; |
| 2459 | spec->num_mixers++; | 2470 | spec->num_mixers++; |
| 2460 | } | 2471 | } |
| @@ -2889,6 +2900,7 @@ static int patch_vt1708S(struct hda_codec *codec) | |||
| 2889 | if (!spec->adc_nids && spec->input_mux) { | 2900 | if (!spec->adc_nids && spec->input_mux) { |
| 2890 | spec->adc_nids = vt1708S_adc_nids; | 2901 | spec->adc_nids = vt1708S_adc_nids; |
| 2891 | spec->num_adc_nids = ARRAY_SIZE(vt1708S_adc_nids); | 2902 | spec->num_adc_nids = ARRAY_SIZE(vt1708S_adc_nids); |
| 2903 | get_mux_nids(codec); | ||
| 2892 | spec->mixers[spec->num_mixers] = vt1708S_capture_mixer; | 2904 | spec->mixers[spec->num_mixers] = vt1708S_capture_mixer; |
| 2893 | spec->num_mixers++; | 2905 | spec->num_mixers++; |
| 2894 | } | 2906 | } |
| @@ -3206,6 +3218,7 @@ static int patch_vt1702(struct hda_codec *codec) | |||
| 3206 | if (!spec->adc_nids && spec->input_mux) { | 3218 | if (!spec->adc_nids && spec->input_mux) { |
| 3207 | spec->adc_nids = vt1702_adc_nids; | 3219 | spec->adc_nids = vt1702_adc_nids; |
| 3208 | spec->num_adc_nids = ARRAY_SIZE(vt1702_adc_nids); | 3220 | spec->num_adc_nids = ARRAY_SIZE(vt1702_adc_nids); |
| 3221 | get_mux_nids(codec); | ||
| 3209 | spec->mixers[spec->num_mixers] = vt1702_capture_mixer; | 3222 | spec->mixers[spec->num_mixers] = vt1702_capture_mixer; |
| 3210 | spec->num_mixers++; | 3223 | spec->num_mixers++; |
| 3211 | } | 3224 | } |
diff --git a/sound/pci/ice1712/ice1712.c b/sound/pci/ice1712/ice1712.c index 0d0cdbdb4486..cecf1ffeeaaa 100644 --- a/sound/pci/ice1712/ice1712.c +++ b/sound/pci/ice1712/ice1712.c | |||
| @@ -107,7 +107,7 @@ MODULE_PARM_DESC(dxr_enable, "Enable DXR support for Terratec DMX6FIRE."); | |||
| 107 | 107 | ||
| 108 | 108 | ||
| 109 | static const struct pci_device_id snd_ice1712_ids[] = { | 109 | static const struct pci_device_id snd_ice1712_ids[] = { |
| 110 | { PCI_VENDOR_ID_ICE, PCI_DEVICE_ID_ICE_1712, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, /* ICE1712 */ | 110 | { PCI_VDEVICE(ICE, PCI_DEVICE_ID_ICE_1712), 0 }, /* ICE1712 */ |
| 111 | { 0, } | 111 | { 0, } |
| 112 | }; | 112 | }; |
| 113 | 113 | ||
diff --git a/sound/pci/ice1712/ice1724.c b/sound/pci/ice1712/ice1724.c index 36ade77cf371..cc84a831eb21 100644 --- a/sound/pci/ice1712/ice1724.c +++ b/sound/pci/ice1712/ice1724.c | |||
| @@ -93,7 +93,7 @@ MODULE_PARM_DESC(model, "Use the given board model."); | |||
| 93 | 93 | ||
| 94 | /* Both VT1720 and VT1724 have the same PCI IDs */ | 94 | /* Both VT1720 and VT1724 have the same PCI IDs */ |
| 95 | static const struct pci_device_id snd_vt1724_ids[] = { | 95 | static const struct pci_device_id snd_vt1724_ids[] = { |
| 96 | { PCI_VENDOR_ID_ICE, PCI_DEVICE_ID_VT1724, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, | 96 | { PCI_VDEVICE(ICE, PCI_DEVICE_ID_VT1724), 0 }, |
| 97 | { 0, } | 97 | { 0, } |
| 98 | }; | 98 | }; |
| 99 | 99 | ||
diff --git a/sound/pci/intel8x0.c b/sound/pci/intel8x0.c index 8aa5687f392a..171ada535209 100644 --- a/sound/pci/intel8x0.c +++ b/sound/pci/intel8x0.c | |||
| @@ -421,29 +421,29 @@ struct intel8x0 { | |||
| 421 | }; | 421 | }; |
| 422 | 422 | ||
| 423 | static struct pci_device_id snd_intel8x0_ids[] = { | 423 | static struct pci_device_id snd_intel8x0_ids[] = { |
| 424 | { 0x8086, 0x2415, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 82801AA */ | 424 | { PCI_VDEVICE(INTEL, 0x2415), DEVICE_INTEL }, /* 82801AA */ |
| 425 | { 0x8086, 0x2425, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 82901AB */ | 425 | { PCI_VDEVICE(INTEL, 0x2425), DEVICE_INTEL }, /* 82901AB */ |
| 426 | { 0x8086, 0x2445, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 82801BA */ | 426 | { PCI_VDEVICE(INTEL, 0x2445), DEVICE_INTEL }, /* 82801BA */ |
| 427 | { 0x8086, 0x2485, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* ICH3 */ | 427 | { PCI_VDEVICE(INTEL, 0x2485), DEVICE_INTEL }, /* ICH3 */ |
| 428 | { 0x8086, 0x24c5, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL_ICH4 }, /* ICH4 */ | 428 | { PCI_VDEVICE(INTEL, 0x24c5), DEVICE_INTEL_ICH4 }, /* ICH4 */ |
| 429 | { 0x8086, 0x24d5, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL_ICH4 }, /* ICH5 */ | 429 | { PCI_VDEVICE(INTEL, 0x24d5), DEVICE_INTEL_ICH4 }, /* ICH5 */ |
| 430 | { 0x8086, 0x25a6, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL_ICH4 }, /* ESB */ | 430 | { PCI_VDEVICE(INTEL, 0x25a6), DEVICE_INTEL_ICH4 }, /* ESB */ |
| 431 | { 0x8086, 0x266e, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL_ICH4 }, /* ICH6 */ | 431 | { PCI_VDEVICE(INTEL, 0x266e), DEVICE_INTEL_ICH4 }, /* ICH6 */ |
| 432 | { 0x8086, 0x27de, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL_ICH4 }, /* ICH7 */ | 432 | { PCI_VDEVICE(INTEL, 0x27de), DEVICE_INTEL_ICH4 }, /* ICH7 */ |
| 433 | { 0x8086, 0x2698, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL_ICH4 }, /* ESB2 */ | 433 | { PCI_VDEVICE(INTEL, 0x2698), DEVICE_INTEL_ICH4 }, /* ESB2 */ |
| 434 | { 0x8086, 0x7195, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 440MX */ | 434 | { PCI_VDEVICE(INTEL, 0x7195), DEVICE_INTEL }, /* 440MX */ |
| 435 | { 0x1039, 0x7012, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_SIS }, /* SI7012 */ | 435 | { PCI_VDEVICE(SI, 0x7012), DEVICE_SIS }, /* SI7012 */ |
| 436 | { 0x10de, 0x01b1, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE */ | 436 | { PCI_VDEVICE(NVIDIA, 0x01b1), DEVICE_NFORCE }, /* NFORCE */ |
| 437 | { 0x10de, 0x003a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* MCP04 */ | 437 | { PCI_VDEVICE(NVIDIA, 0x003a), DEVICE_NFORCE }, /* MCP04 */ |
| 438 | { 0x10de, 0x006a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE2 */ | 438 | { PCI_VDEVICE(NVIDIA, 0x006a), DEVICE_NFORCE }, /* NFORCE2 */ |
| 439 | { 0x10de, 0x0059, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* CK804 */ | 439 | { PCI_VDEVICE(NVIDIA, 0x0059), DEVICE_NFORCE }, /* CK804 */ |
| 440 | { 0x10de, 0x008a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* CK8 */ | 440 | { PCI_VDEVICE(NVIDIA, 0x008a), DEVICE_NFORCE }, /* CK8 */ |
| 441 | { 0x10de, 0x00da, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE3 */ | 441 | { PCI_VDEVICE(NVIDIA, 0x00da), DEVICE_NFORCE }, /* NFORCE3 */ |
| 442 | { 0x10de, 0x00ea, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* CK8S */ | 442 | { PCI_VDEVICE(NVIDIA, 0x00ea), DEVICE_NFORCE }, /* CK8S */ |
| 443 | { 0x10de, 0x026b, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* MCP51 */ | 443 | { PCI_VDEVICE(NVIDIA, 0x026b), DEVICE_NFORCE }, /* MCP51 */ |
| 444 | { 0x1022, 0x746d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD8111 */ | 444 | { PCI_VDEVICE(AMD, 0x746d), DEVICE_INTEL }, /* AMD8111 */ |
| 445 | { 0x1022, 0x7445, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD768 */ | 445 | { PCI_VDEVICE(AMD, 0x7445), DEVICE_INTEL }, /* AMD768 */ |
| 446 | { 0x10b9, 0x5455, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_ALI }, /* Ali5455 */ | 446 | { PCI_VDEVICE(AL, 0x5455), DEVICE_ALI }, /* Ali5455 */ |
| 447 | { 0, } | 447 | { 0, } |
| 448 | }; | 448 | }; |
| 449 | 449 | ||
diff --git a/sound/pci/intel8x0m.c b/sound/pci/intel8x0m.c index 6ec0fc50d6be..9e7d12e7673f 100644 --- a/sound/pci/intel8x0m.c +++ b/sound/pci/intel8x0m.c | |||
| @@ -220,24 +220,24 @@ struct intel8x0m { | |||
| 220 | }; | 220 | }; |
| 221 | 221 | ||
| 222 | static struct pci_device_id snd_intel8x0m_ids[] = { | 222 | static struct pci_device_id snd_intel8x0m_ids[] = { |
| 223 | { 0x8086, 0x2416, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 82801AA */ | 223 | { PCI_VDEVICE(INTEL, 0x2416), DEVICE_INTEL }, /* 82801AA */ |
| 224 | { 0x8086, 0x2426, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 82901AB */ | 224 | { PCI_VDEVICE(INTEL, 0x2426), DEVICE_INTEL }, /* 82901AB */ |
| 225 | { 0x8086, 0x2446, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 82801BA */ | 225 | { PCI_VDEVICE(INTEL, 0x2446), DEVICE_INTEL }, /* 82801BA */ |
| 226 | { 0x8086, 0x2486, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* ICH3 */ | 226 | { PCI_VDEVICE(INTEL, 0x2486), DEVICE_INTEL }, /* ICH3 */ |
| 227 | { 0x8086, 0x24c6, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* ICH4 */ | 227 | { PCI_VDEVICE(INTEL, 0x24c6), DEVICE_INTEL }, /* ICH4 */ |
| 228 | { 0x8086, 0x24d6, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* ICH5 */ | 228 | { PCI_VDEVICE(INTEL, 0x24d6), DEVICE_INTEL }, /* ICH5 */ |
| 229 | { 0x8086, 0x266d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* ICH6 */ | 229 | { PCI_VDEVICE(INTEL, 0x266d), DEVICE_INTEL }, /* ICH6 */ |
| 230 | { 0x8086, 0x27dd, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* ICH7 */ | 230 | { PCI_VDEVICE(INTEL, 0x27dd), DEVICE_INTEL }, /* ICH7 */ |
| 231 | { 0x8086, 0x7196, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* 440MX */ | 231 | { PCI_VDEVICE(INTEL, 0x7196), DEVICE_INTEL }, /* 440MX */ |
| 232 | { 0x1022, 0x7446, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD768 */ | 232 | { PCI_VDEVICE(AMD, 0x7446), DEVICE_INTEL }, /* AMD768 */ |
| 233 | { 0x1039, 0x7013, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_SIS }, /* SI7013 */ | 233 | { PCI_VDEVICE(SI, 0x7013), DEVICE_SIS }, /* SI7013 */ |
| 234 | { 0x10de, 0x01c1, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE */ | 234 | { PCI_VDEVICE(NVIDIA, 0x01c1), DEVICE_NFORCE }, /* NFORCE */ |
| 235 | { 0x10de, 0x0069, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE2 */ | 235 | { PCI_VDEVICE(NVIDIA, 0x0069), DEVICE_NFORCE }, /* NFORCE2 */ |
| 236 | { 0x10de, 0x0089, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE2s */ | 236 | { PCI_VDEVICE(NVIDIA, 0x0089), DEVICE_NFORCE }, /* NFORCE2s */ |
| 237 | { 0x10de, 0x00d9, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE3 */ | 237 | { PCI_VDEVICE(NVIDIA, 0x00d9), DEVICE_NFORCE }, /* NFORCE3 */ |
| 238 | #if 0 | 238 | #if 0 |
| 239 | { 0x1022, 0x746d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD8111 */ | 239 | { PCI_VDEVICE(AMD, 0x746d), DEVICE_INTEL }, /* AMD8111 */ |
| 240 | { 0x10b9, 0x5455, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_ALI }, /* Ali5455 */ | 240 | { PCI_VDEVICE(AL, 0x5455), DEVICE_ALI }, /* Ali5455 */ |
| 241 | #endif | 241 | #endif |
| 242 | { 0, } | 242 | { 0, } |
| 243 | }; | 243 | }; |
diff --git a/sound/pci/lx6464es/lx6464es.c b/sound/pci/lx6464es/lx6464es.c index 18da2ef04d09..11b8c6514b3d 100644 --- a/sound/pci/lx6464es/lx6464es.c +++ b/sound/pci/lx6464es/lx6464es.c | |||
| @@ -654,13 +654,12 @@ static int __devinit lx_init_ethersound_config(struct lx6464es *chip) | |||
| 654 | int i; | 654 | int i; |
| 655 | u32 orig_conf_es = lx_dsp_reg_read(chip, eReg_CONFES); | 655 | u32 orig_conf_es = lx_dsp_reg_read(chip, eReg_CONFES); |
| 656 | 656 | ||
| 657 | u32 default_conf_es = (64 << IOCR_OUTPUTS_OFFSET) | | 657 | /* configure 64 io channels */ |
| 658 | u32 conf_es = (orig_conf_es & CONFES_READ_PART_MASK) | | ||
| 658 | (64 << IOCR_INPUTS_OFFSET) | | 659 | (64 << IOCR_INPUTS_OFFSET) | |
| 660 | (64 << IOCR_OUTPUTS_OFFSET) | | ||
| 659 | (FREQ_RATIO_SINGLE_MODE << FREQ_RATIO_OFFSET); | 661 | (FREQ_RATIO_SINGLE_MODE << FREQ_RATIO_OFFSET); |
| 660 | 662 | ||
| 661 | u32 conf_es = (orig_conf_es & CONFES_READ_PART_MASK) | ||
| 662 | | (default_conf_es & CONFES_WRITE_PART_MASK); | ||
| 663 | |||
| 664 | snd_printdd("->lx_init_ethersound\n"); | 663 | snd_printdd("->lx_init_ethersound\n"); |
| 665 | 664 | ||
| 666 | chip->freq_ratio = FREQ_RATIO_SINGLE_MODE; | 665 | chip->freq_ratio = FREQ_RATIO_SINGLE_MODE; |
diff --git a/sound/pci/mixart/mixart.c b/sound/pci/mixart/mixart.c index 82bc5b9e7629..a83d1968a845 100644 --- a/sound/pci/mixart/mixart.c +++ b/sound/pci/mixart/mixart.c | |||
| @@ -61,7 +61,7 @@ MODULE_PARM_DESC(enable, "Enable Digigram " CARD_NAME " soundcard."); | |||
| 61 | */ | 61 | */ |
| 62 | 62 | ||
| 63 | static struct pci_device_id snd_mixart_ids[] = { | 63 | static struct pci_device_id snd_mixart_ids[] = { |
| 64 | { 0x1057, 0x0003, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* MC8240 */ | 64 | { PCI_VDEVICE(MOTOROLA, 0x0003), 0, }, /* MC8240 */ |
| 65 | { 0, } | 65 | { 0, } |
| 66 | }; | 66 | }; |
| 67 | 67 | ||
diff --git a/sound/pci/nm256/nm256.c b/sound/pci/nm256/nm256.c index 522a040855d4..97a0731331a1 100644 --- a/sound/pci/nm256/nm256.c +++ b/sound/pci/nm256/nm256.c | |||
| @@ -263,9 +263,9 @@ struct nm256 { | |||
| 263 | * PCI ids | 263 | * PCI ids |
| 264 | */ | 264 | */ |
| 265 | static struct pci_device_id snd_nm256_ids[] = { | 265 | static struct pci_device_id snd_nm256_ids[] = { |
| 266 | {PCI_VENDOR_ID_NEOMAGIC, PCI_DEVICE_ID_NEOMAGIC_NM256AV_AUDIO, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 266 | {PCI_VDEVICE(NEOMAGIC, PCI_DEVICE_ID_NEOMAGIC_NM256AV_AUDIO), 0}, |
| 267 | {PCI_VENDOR_ID_NEOMAGIC, PCI_DEVICE_ID_NEOMAGIC_NM256ZX_AUDIO, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 267 | {PCI_VDEVICE(NEOMAGIC, PCI_DEVICE_ID_NEOMAGIC_NM256ZX_AUDIO), 0}, |
| 268 | {PCI_VENDOR_ID_NEOMAGIC, PCI_DEVICE_ID_NEOMAGIC_NM256XL_PLUS_AUDIO, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, | 268 | {PCI_VDEVICE(NEOMAGIC, PCI_DEVICE_ID_NEOMAGIC_NM256XL_PLUS_AUDIO), 0}, |
| 269 | {0,}, | 269 | {0,}, |
| 270 | }; | 270 | }; |
| 271 | 271 | ||
diff --git a/sound/pci/oxygen/oxygen_mixer.c b/sound/pci/oxygen/oxygen_mixer.c index 304da169bfdc..5401c547c4e3 100644 --- a/sound/pci/oxygen/oxygen_mixer.c +++ b/sound/pci/oxygen/oxygen_mixer.c | |||
| @@ -575,8 +575,10 @@ static int ac97_switch_put(struct snd_kcontrol *ctl, | |||
| 575 | static int ac97_volume_info(struct snd_kcontrol *ctl, | 575 | static int ac97_volume_info(struct snd_kcontrol *ctl, |
| 576 | struct snd_ctl_elem_info *info) | 576 | struct snd_ctl_elem_info *info) |
| 577 | { | 577 | { |
| 578 | int stereo = (ctl->private_value >> 16) & 1; | ||
| 579 | |||
| 578 | info->type = SNDRV_CTL_ELEM_TYPE_INTEGER; | 580 | info->type = SNDRV_CTL_ELEM_TYPE_INTEGER; |
| 579 | info->count = 2; | 581 | info->count = stereo ? 2 : 1; |
| 580 | info->value.integer.min = 0; | 582 | info->value.integer.min = 0; |
| 581 | info->value.integer.max = 0x1f; | 583 | info->value.integer.max = 0x1f; |
| 582 | return 0; | 584 | return 0; |
| @@ -587,6 +589,7 @@ static int ac97_volume_get(struct snd_kcontrol *ctl, | |||
| 587 | { | 589 | { |
| 588 | struct oxygen *chip = ctl->private_data; | 590 | struct oxygen *chip = ctl->private_data; |
| 589 | unsigned int codec = (ctl->private_value >> 24) & 1; | 591 | unsigned int codec = (ctl->private_value >> 24) & 1; |
| 592 | int stereo = (ctl->private_value >> 16) & 1; | ||
| 590 | unsigned int index = ctl->private_value & 0xff; | 593 | unsigned int index = ctl->private_value & 0xff; |
| 591 | u16 reg; | 594 | u16 reg; |
| 592 | 595 | ||
| @@ -594,7 +597,8 @@ static int ac97_volume_get(struct snd_kcontrol *ctl, | |||
| 594 | reg = oxygen_read_ac97(chip, codec, index); | 597 | reg = oxygen_read_ac97(chip, codec, index); |
| 595 | mutex_unlock(&chip->mutex); | 598 | mutex_unlock(&chip->mutex); |
| 596 | value->value.integer.value[0] = 31 - (reg & 0x1f); | 599 | value->value.integer.value[0] = 31 - (reg & 0x1f); |
| 597 | value->value.integer.value[1] = 31 - ((reg >> 8) & 0x1f); | 600 | if (stereo) |
| 601 | value->value.integer.value[1] = 31 - ((reg >> 8) & 0x1f); | ||
| 598 | return 0; | 602 | return 0; |
| 599 | } | 603 | } |
| 600 | 604 | ||
| @@ -603,6 +607,7 @@ static int ac97_volume_put(struct snd_kcontrol *ctl, | |||
| 603 | { | 607 | { |
| 604 | struct oxygen *chip = ctl->private_data; | 608 | struct oxygen *chip = ctl->private_data; |
| 605 | unsigned int codec = (ctl->private_value >> 24) & 1; | 609 | unsigned int codec = (ctl->private_value >> 24) & 1; |
| 610 | int stereo = (ctl->private_value >> 16) & 1; | ||
| 606 | unsigned int index = ctl->private_value & 0xff; | 611 | unsigned int index = ctl->private_value & 0xff; |
| 607 | u16 oldreg, newreg; | 612 | u16 oldreg, newreg; |
| 608 | int change; | 613 | int change; |
| @@ -612,8 +617,11 @@ static int ac97_volume_put(struct snd_kcontrol *ctl, | |||
| 612 | newreg = oldreg; | 617 | newreg = oldreg; |
| 613 | newreg = (newreg & ~0x1f) | | 618 | newreg = (newreg & ~0x1f) | |
| 614 | (31 - (value->value.integer.value[0] & 0x1f)); | 619 | (31 - (value->value.integer.value[0] & 0x1f)); |
| 615 | newreg = (newreg & ~0x1f00) | | 620 | if (stereo) |
| 616 | ((31 - (value->value.integer.value[0] & 0x1f)) << 8); | 621 | newreg = (newreg & ~0x1f00) | |
| 622 | ((31 - (value->value.integer.value[1] & 0x1f)) << 8); | ||
| 623 | else | ||
| 624 | newreg = (newreg & ~0x1f00) | ((newreg & 0x1f) << 8); | ||
| 617 | change = newreg != oldreg; | 625 | change = newreg != oldreg; |
| 618 | if (change) | 626 | if (change) |
| 619 | oxygen_write_ac97(chip, codec, index, newreg); | 627 | oxygen_write_ac97(chip, codec, index, newreg); |
| @@ -673,7 +681,7 @@ static int ac97_fp_rec_volume_put(struct snd_kcontrol *ctl, | |||
| 673 | .private_value = ((codec) << 24) | ((invert) << 16) | \ | 681 | .private_value = ((codec) << 24) | ((invert) << 16) | \ |
| 674 | ((bitnr) << 8) | (index), \ | 682 | ((bitnr) << 8) | (index), \ |
| 675 | } | 683 | } |
| 676 | #define AC97_VOLUME(xname, codec, index) { \ | 684 | #define AC97_VOLUME(xname, codec, index, stereo) { \ |
| 677 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, \ | 685 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, \ |
| 678 | .name = xname, \ | 686 | .name = xname, \ |
| 679 | .access = SNDRV_CTL_ELEM_ACCESS_READWRITE | \ | 687 | .access = SNDRV_CTL_ELEM_ACCESS_READWRITE | \ |
| @@ -682,7 +690,7 @@ static int ac97_fp_rec_volume_put(struct snd_kcontrol *ctl, | |||
| 682 | .get = ac97_volume_get, \ | 690 | .get = ac97_volume_get, \ |
| 683 | .put = ac97_volume_put, \ | 691 | .put = ac97_volume_put, \ |
| 684 | .tlv = { .p = ac97_db_scale, }, \ | 692 | .tlv = { .p = ac97_db_scale, }, \ |
| 685 | .private_value = ((codec) << 24) | (index), \ | 693 | .private_value = ((codec) << 24) | ((stereo) << 16) | (index), \ |
| 686 | } | 694 | } |
| 687 | 695 | ||
| 688 | static DECLARE_TLV_DB_SCALE(monitor_db_scale, -1000, 1000, 0); | 696 | static DECLARE_TLV_DB_SCALE(monitor_db_scale, -1000, 1000, 0); |
| @@ -882,18 +890,18 @@ static const struct { | |||
| 882 | }; | 890 | }; |
| 883 | 891 | ||
| 884 | static const struct snd_kcontrol_new ac97_controls[] = { | 892 | static const struct snd_kcontrol_new ac97_controls[] = { |
| 885 | AC97_VOLUME("Mic Capture Volume", 0, AC97_MIC), | 893 | AC97_VOLUME("Mic Capture Volume", 0, AC97_MIC, 0), |
| 886 | AC97_SWITCH("Mic Capture Switch", 0, AC97_MIC, 15, 1), | 894 | AC97_SWITCH("Mic Capture Switch", 0, AC97_MIC, 15, 1), |
| 887 | AC97_SWITCH("Mic Boost (+20dB)", 0, AC97_MIC, 6, 0), | 895 | AC97_SWITCH("Mic Boost (+20dB)", 0, AC97_MIC, 6, 0), |
| 888 | AC97_SWITCH("Line Capture Switch", 0, AC97_LINE, 15, 1), | 896 | AC97_SWITCH("Line Capture Switch", 0, AC97_LINE, 15, 1), |
| 889 | AC97_VOLUME("CD Capture Volume", 0, AC97_CD), | 897 | AC97_VOLUME("CD Capture Volume", 0, AC97_CD, 1), |
| 890 | AC97_SWITCH("CD Capture Switch", 0, AC97_CD, 15, 1), | 898 | AC97_SWITCH("CD Capture Switch", 0, AC97_CD, 15, 1), |
| 891 | AC97_VOLUME("Aux Capture Volume", 0, AC97_AUX), | 899 | AC97_VOLUME("Aux Capture Volume", 0, AC97_AUX, 1), |
| 892 | AC97_SWITCH("Aux Capture Switch", 0, AC97_AUX, 15, 1), | 900 | AC97_SWITCH("Aux Capture Switch", 0, AC97_AUX, 15, 1), |
| 893 | }; | 901 | }; |
| 894 | 902 | ||
| 895 | static const struct snd_kcontrol_new ac97_fp_controls[] = { | 903 | static const struct snd_kcontrol_new ac97_fp_controls[] = { |
| 896 | AC97_VOLUME("Front Panel Playback Volume", 1, AC97_HEADPHONE), | 904 | AC97_VOLUME("Front Panel Playback Volume", 1, AC97_HEADPHONE, 1), |
| 897 | AC97_SWITCH("Front Panel Playback Switch", 1, AC97_HEADPHONE, 15, 1), | 905 | AC97_SWITCH("Front Panel Playback Switch", 1, AC97_HEADPHONE, 15, 1), |
| 898 | { | 906 | { |
| 899 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 907 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
diff --git a/sound/pci/oxygen/virtuoso.c b/sound/pci/oxygen/virtuoso.c index bf971f7cfdc6..6ebcb6bdd712 100644 --- a/sound/pci/oxygen/virtuoso.c +++ b/sound/pci/oxygen/virtuoso.c | |||
| @@ -635,6 +635,8 @@ static void xonar_d2_resume(struct oxygen *chip) | |||
| 635 | 635 | ||
| 636 | static void xonar_d1_resume(struct oxygen *chip) | 636 | static void xonar_d1_resume(struct oxygen *chip) |
| 637 | { | 637 | { |
| 638 | oxygen_set_bits8(chip, OXYGEN_FUNCTION, OXYGEN_FUNCTION_RESET_CODEC); | ||
| 639 | msleep(1); | ||
| 638 | cs43xx_init(chip); | 640 | cs43xx_init(chip); |
| 639 | xonar_enable_output(chip); | 641 | xonar_enable_output(chip); |
| 640 | } | 642 | } |
diff --git a/sound/pci/rme32.c b/sound/pci/rme32.c index d7b966e7c4cf..f977dba7cbd0 100644 --- a/sound/pci/rme32.c +++ b/sound/pci/rme32.c | |||
| @@ -227,12 +227,9 @@ struct rme32 { | |||
| 227 | }; | 227 | }; |
| 228 | 228 | ||
| 229 | static struct pci_device_id snd_rme32_ids[] = { | 229 | static struct pci_device_id snd_rme32_ids[] = { |
| 230 | {PCI_VENDOR_ID_XILINX_RME, PCI_DEVICE_ID_RME_DIGI32, | 230 | {PCI_VDEVICE(XILINX_RME, PCI_DEVICE_ID_RME_DIGI32), 0,}, |
| 231 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0,}, | 231 | {PCI_VDEVICE(XILINX_RME, PCI_DEVICE_ID_RME_DIGI32_8), 0,}, |
| 232 | {PCI_VENDOR_ID_XILINX_RME, PCI_DEVICE_ID_RME_DIGI32_8, | 232 | {PCI_VDEVICE(XILINX_RME, PCI_DEVICE_ID_RME_DIGI32_PRO), 0,}, |
| 233 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0,}, | ||
| 234 | {PCI_VENDOR_ID_XILINX_RME, PCI_DEVICE_ID_RME_DIGI32_PRO, | ||
| 235 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0,}, | ||
| 236 | {0,} | 233 | {0,} |
| 237 | }; | 234 | }; |
| 238 | 235 | ||
diff --git a/sound/pci/rme96.c b/sound/pci/rme96.c index 55fb1c131f58..2ba5c0fd55db 100644 --- a/sound/pci/rme96.c +++ b/sound/pci/rme96.c | |||
| @@ -232,14 +232,10 @@ struct rme96 { | |||
| 232 | }; | 232 | }; |
| 233 | 233 | ||
| 234 | static struct pci_device_id snd_rme96_ids[] = { | 234 | static struct pci_device_id snd_rme96_ids[] = { |
| 235 | { PCI_VENDOR_ID_XILINX, PCI_DEVICE_ID_RME_DIGI96, | 235 | { PCI_VDEVICE(XILINX, PCI_DEVICE_ID_RME_DIGI96), 0, }, |
| 236 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, | 236 | { PCI_VDEVICE(XILINX, PCI_DEVICE_ID_RME_DIGI96_8), 0, }, |
| 237 | { PCI_VENDOR_ID_XILINX, PCI_DEVICE_ID_RME_DIGI96_8, | 237 | { PCI_VDEVICE(XILINX, PCI_DEVICE_ID_RME_DIGI96_8_PRO), 0, }, |
| 238 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, | 238 | { PCI_VDEVICE(XILINX, PCI_DEVICE_ID_RME_DIGI96_8_PAD_OR_PST), 0, }, |
| 239 | { PCI_VENDOR_ID_XILINX, PCI_DEVICE_ID_RME_DIGI96_8_PRO, | ||
| 240 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, | ||
| 241 | { PCI_VENDOR_ID_XILINX, PCI_DEVICE_ID_RME_DIGI96_8_PAD_OR_PST, | ||
| 242 | PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, | ||
| 243 | { 0, } | 239 | { 0, } |
| 244 | }; | 240 | }; |
| 245 | 241 | ||
diff --git a/sound/pci/sonicvibes.c b/sound/pci/sonicvibes.c index 7dc60ad4772e..1f6406c4534d 100644 --- a/sound/pci/sonicvibes.c +++ b/sound/pci/sonicvibes.c | |||
| @@ -243,7 +243,7 @@ struct sonicvibes { | |||
| 243 | }; | 243 | }; |
| 244 | 244 | ||
| 245 | static struct pci_device_id snd_sonic_ids[] = { | 245 | static struct pci_device_id snd_sonic_ids[] = { |
| 246 | { 0x5333, 0xca00, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, | 246 | { PCI_VDEVICE(S3, 0xca00), 0, }, |
| 247 | { 0, } | 247 | { 0, } |
| 248 | }; | 248 | }; |
| 249 | 249 | ||
diff --git a/sound/pci/via82xx.c b/sound/pci/via82xx.c index 949fcaf6b70e..acfa4760da49 100644 --- a/sound/pci/via82xx.c +++ b/sound/pci/via82xx.c | |||
| @@ -402,9 +402,9 @@ struct via82xx { | |||
| 402 | 402 | ||
| 403 | static struct pci_device_id snd_via82xx_ids[] = { | 403 | static struct pci_device_id snd_via82xx_ids[] = { |
| 404 | /* 0x1106, 0x3058 */ | 404 | /* 0x1106, 0x3058 */ |
| 405 | { PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C686_5, PCI_ANY_ID, PCI_ANY_ID, 0, 0, TYPE_CARD_VIA686, }, /* 686A */ | 405 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C686_5), TYPE_CARD_VIA686, }, /* 686A */ |
| 406 | /* 0x1106, 0x3059 */ | 406 | /* 0x1106, 0x3059 */ |
| 407 | { PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8233_5, PCI_ANY_ID, PCI_ANY_ID, 0, 0, TYPE_CARD_VIA8233, }, /* VT8233 */ | 407 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_8233_5), TYPE_CARD_VIA8233, }, /* VT8233 */ |
| 408 | { 0, } | 408 | { 0, } |
| 409 | }; | 409 | }; |
| 410 | 410 | ||
diff --git a/sound/pci/via82xx_modem.c b/sound/pci/via82xx_modem.c index 0d54e3503c1e..47eb61561dfc 100644 --- a/sound/pci/via82xx_modem.c +++ b/sound/pci/via82xx_modem.c | |||
| @@ -261,7 +261,7 @@ struct via82xx_modem { | |||
| 261 | }; | 261 | }; |
| 262 | 262 | ||
| 263 | static struct pci_device_id snd_via82xx_modem_ids[] = { | 263 | static struct pci_device_id snd_via82xx_modem_ids[] = { |
| 264 | { 0x1106, 0x3068, PCI_ANY_ID, PCI_ANY_ID, 0, 0, TYPE_CARD_VIA82XX_MODEM, }, | 264 | { PCI_VDEVICE(VIA, 0x3068), TYPE_CARD_VIA82XX_MODEM, }, |
| 265 | { 0, } | 265 | { 0, } |
| 266 | }; | 266 | }; |
| 267 | 267 | ||
diff --git a/sound/pci/ymfpci/ymfpci.c b/sound/pci/ymfpci/ymfpci.c index 4af66661f9b0..e6b18b90d451 100644 --- a/sound/pci/ymfpci/ymfpci.c +++ b/sound/pci/ymfpci/ymfpci.c | |||
| @@ -67,12 +67,12 @@ module_param_array(rear_switch, bool, NULL, 0444); | |||
| 67 | MODULE_PARM_DESC(rear_switch, "Enable shared rear/line-in switch"); | 67 | MODULE_PARM_DESC(rear_switch, "Enable shared rear/line-in switch"); |
| 68 | 68 | ||
| 69 | static struct pci_device_id snd_ymfpci_ids[] = { | 69 | static struct pci_device_id snd_ymfpci_ids[] = { |
| 70 | { 0x1073, 0x0004, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* YMF724 */ | 70 | { PCI_VDEVICE(YAMAHA, 0x0004), 0, }, /* YMF724 */ |
| 71 | { 0x1073, 0x000d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* YMF724F */ | 71 | { PCI_VDEVICE(YAMAHA, 0x000d), 0, }, /* YMF724F */ |
| 72 | { 0x1073, 0x000a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* YMF740 */ | 72 | { PCI_VDEVICE(YAMAHA, 0x000a), 0, }, /* YMF740 */ |
| 73 | { 0x1073, 0x000c, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* YMF740C */ | 73 | { PCI_VDEVICE(YAMAHA, 0x000c), 0, }, /* YMF740C */ |
| 74 | { 0x1073, 0x0010, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* YMF744 */ | 74 | { PCI_VDEVICE(YAMAHA, 0x0010), 0, }, /* YMF744 */ |
| 75 | { 0x1073, 0x0012, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* YMF754 */ | 75 | { PCI_VDEVICE(YAMAHA, 0x0012), 0, }, /* YMF754 */ |
| 76 | { 0, } | 76 | { 0, } |
| 77 | }; | 77 | }; |
| 78 | 78 | ||
diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c index 173a239a541c..bb0db55e0e98 100644 --- a/sound/soc/atmel/sam9g20_wm8731.c +++ b/sound/soc/atmel/sam9g20_wm8731.c | |||
| @@ -281,38 +281,6 @@ static struct snd_soc_card snd_soc_at91sam9g20ek = { | |||
| 281 | .set_bias_level = at91sam9g20ek_set_bias_level, | 281 | .set_bias_level = at91sam9g20ek_set_bias_level, |
| 282 | }; | 282 | }; |
| 283 | 283 | ||
| 284 | /* | ||
| 285 | * FIXME: This is a temporary bodge to avoid cross-tree merge issues. | ||
| 286 | * New drivers should register the wm8731 I2C device in the machine | ||
| 287 | * setup code (under arch/arm for ARM systems). | ||
| 288 | */ | ||
| 289 | static int wm8731_i2c_register(void) | ||
| 290 | { | ||
| 291 | struct i2c_board_info info; | ||
| 292 | struct i2c_adapter *adapter; | ||
| 293 | struct i2c_client *client; | ||
| 294 | |||
| 295 | memset(&info, 0, sizeof(struct i2c_board_info)); | ||
| 296 | info.addr = 0x1b; | ||
| 297 | strlcpy(info.type, "wm8731", I2C_NAME_SIZE); | ||
| 298 | |||
| 299 | adapter = i2c_get_adapter(0); | ||
| 300 | if (!adapter) { | ||
| 301 | printk(KERN_ERR "can't get i2c adapter 0\n"); | ||
| 302 | return -ENODEV; | ||
| 303 | } | ||
| 304 | |||
| 305 | client = i2c_new_device(adapter, &info); | ||
| 306 | i2c_put_adapter(adapter); | ||
| 307 | if (!client) { | ||
| 308 | printk(KERN_ERR "can't add i2c device at 0x%x\n", | ||
| 309 | (unsigned int)info.addr); | ||
| 310 | return -ENODEV; | ||
| 311 | } | ||
| 312 | |||
| 313 | return 0; | ||
| 314 | } | ||
| 315 | |||
| 316 | static struct snd_soc_device at91sam9g20ek_snd_devdata = { | 284 | static struct snd_soc_device at91sam9g20ek_snd_devdata = { |
| 317 | .card = &snd_soc_at91sam9g20ek, | 285 | .card = &snd_soc_at91sam9g20ek, |
| 318 | .codec_dev = &soc_codec_dev_wm8731, | 286 | .codec_dev = &soc_codec_dev_wm8731, |
| @@ -367,10 +335,6 @@ static int __init at91sam9g20ek_init(void) | |||
| 367 | } | 335 | } |
| 368 | ssc_p->ssc = ssc; | 336 | ssc_p->ssc = ssc; |
| 369 | 337 | ||
| 370 | ret = wm8731_i2c_register(); | ||
| 371 | if (ret != 0) | ||
| 372 | goto err_ssc; | ||
| 373 | |||
| 374 | at91sam9g20ek_snd_device = platform_device_alloc("soc-audio", -1); | 338 | at91sam9g20ek_snd_device = platform_device_alloc("soc-audio", -1); |
| 375 | if (!at91sam9g20ek_snd_device) { | 339 | if (!at91sam9g20ek_snd_device) { |
| 376 | printk(KERN_ERR "ASoC: Platform device allocation failed\n"); | 340 | printk(KERN_ERR "ASoC: Platform device allocation failed\n"); |
diff --git a/sound/soc/codecs/wm8753.c b/sound/soc/codecs/wm8753.c index d28eeaceb857..49c4b2898aff 100644 --- a/sound/soc/codecs/wm8753.c +++ b/sound/soc/codecs/wm8753.c | |||
| @@ -79,7 +79,7 @@ static const u16 wm8753_reg[] = { | |||
| 79 | 0x0097, 0x0097, 0x0000, 0x0004, | 79 | 0x0097, 0x0097, 0x0000, 0x0004, |
| 80 | 0x0000, 0x0083, 0x0024, 0x01ba, | 80 | 0x0000, 0x0083, 0x0024, 0x01ba, |
| 81 | 0x0000, 0x0083, 0x0024, 0x01ba, | 81 | 0x0000, 0x0083, 0x0024, 0x01ba, |
| 82 | 0x0000, 0x0000 | 82 | 0x0000, 0x0000, 0x0000 |
| 83 | }; | 83 | }; |
| 84 | 84 | ||
| 85 | /* codec private data */ | 85 | /* codec private data */ |
| @@ -1660,11 +1660,11 @@ static int wm8753_register(struct wm8753_priv *wm8753) | |||
| 1660 | codec->set_bias_level = wm8753_set_bias_level; | 1660 | codec->set_bias_level = wm8753_set_bias_level; |
| 1661 | codec->dai = wm8753_dai; | 1661 | codec->dai = wm8753_dai; |
| 1662 | codec->num_dai = 2; | 1662 | codec->num_dai = 2; |
| 1663 | codec->reg_cache_size = ARRAY_SIZE(wm8753->reg_cache); | 1663 | codec->reg_cache_size = ARRAY_SIZE(wm8753->reg_cache) + 1; |
| 1664 | codec->reg_cache = &wm8753->reg_cache; | 1664 | codec->reg_cache = &wm8753->reg_cache; |
| 1665 | codec->private_data = wm8753; | 1665 | codec->private_data = wm8753; |
| 1666 | 1666 | ||
| 1667 | memcpy(codec->reg_cache, wm8753_reg, sizeof(codec->reg_cache)); | 1667 | memcpy(codec->reg_cache, wm8753_reg, sizeof(wm8753->reg_cache)); |
| 1668 | INIT_DELAYED_WORK(&codec->delayed_work, wm8753_work); | 1668 | INIT_DELAYED_WORK(&codec->delayed_work, wm8753_work); |
| 1669 | 1669 | ||
| 1670 | ret = wm8753_reset(codec); | 1670 | ret = wm8753_reset(codec); |
diff --git a/sound/soc/fsl/Kconfig b/sound/soc/fsl/Kconfig index 5dbebf82249c..8cb65ccad35f 100644 --- a/sound/soc/fsl/Kconfig +++ b/sound/soc/fsl/Kconfig | |||
| @@ -33,7 +33,7 @@ config SND_SOC_MPC5200_I2S | |||
| 33 | config SND_SOC_MPC5200_AC97 | 33 | config SND_SOC_MPC5200_AC97 |
| 34 | tristate "Freescale MPC5200 PSC in AC97 mode driver" | 34 | tristate "Freescale MPC5200 PSC in AC97 mode driver" |
| 35 | depends on PPC_MPC52xx && PPC_BESTCOMM | 35 | depends on PPC_MPC52xx && PPC_BESTCOMM |
| 36 | select AC97_BUS | 36 | select SND_SOC_AC97_BUS |
| 37 | select SND_MPC52xx_DMA | 37 | select SND_MPC52xx_DMA |
| 38 | select PPC_BESTCOMM_GEN_BD | 38 | select PPC_BESTCOMM_GEN_BD |
| 39 | help | 39 | help |
| @@ -41,7 +41,7 @@ config SND_SOC_MPC5200_AC97 | |||
| 41 | 41 | ||
| 42 | config SND_MPC52xx_SOC_PCM030 | 42 | config SND_MPC52xx_SOC_PCM030 |
| 43 | tristate "SoC AC97 Audio support for Phytec pcm030 and WM9712" | 43 | tristate "SoC AC97 Audio support for Phytec pcm030 and WM9712" |
| 44 | depends on PPC_MPC5200_SIMPLE && BROKEN | 44 | depends on PPC_MPC5200_SIMPLE |
| 45 | select SND_SOC_MPC5200_AC97 | 45 | select SND_SOC_MPC5200_AC97 |
| 46 | select SND_SOC_WM9712 | 46 | select SND_SOC_WM9712 |
| 47 | help | 47 | help |
| @@ -50,7 +50,7 @@ config SND_MPC52xx_SOC_PCM030 | |||
| 50 | 50 | ||
| 51 | config SND_MPC52xx_SOC_EFIKA | 51 | config SND_MPC52xx_SOC_EFIKA |
| 52 | tristate "SoC AC97 Audio support for bbplan Efika and STAC9766" | 52 | tristate "SoC AC97 Audio support for bbplan Efika and STAC9766" |
| 53 | depends on PPC_EFIKA && BROKEN | 53 | depends on PPC_EFIKA |
| 54 | select SND_SOC_MPC5200_AC97 | 54 | select SND_SOC_MPC5200_AC97 |
| 55 | select SND_SOC_STAC9766 | 55 | select SND_SOC_STAC9766 |
| 56 | help | 56 | help |
diff --git a/sound/soc/fsl/mpc5200_dma.c b/sound/soc/fsl/mpc5200_dma.c index efec33a1c5bd..f0a2d4071998 100644 --- a/sound/soc/fsl/mpc5200_dma.c +++ b/sound/soc/fsl/mpc5200_dma.c | |||
| @@ -456,6 +456,7 @@ int mpc5200_audio_dma_create(struct of_device *op) | |||
| 456 | return -ENODEV; | 456 | return -ENODEV; |
| 457 | 457 | ||
| 458 | spin_lock_init(&psc_dma->lock); | 458 | spin_lock_init(&psc_dma->lock); |
| 459 | mutex_init(&psc_dma->mutex); | ||
| 459 | psc_dma->id = be32_to_cpu(*prop); | 460 | psc_dma->id = be32_to_cpu(*prop); |
| 460 | psc_dma->irq = irq; | 461 | psc_dma->irq = irq; |
| 461 | psc_dma->psc_regs = regs; | 462 | psc_dma->psc_regs = regs; |
diff --git a/sound/soc/fsl/mpc5200_dma.h b/sound/soc/fsl/mpc5200_dma.h index 2000803f06a7..8d396bb9d9fe 100644 --- a/sound/soc/fsl/mpc5200_dma.h +++ b/sound/soc/fsl/mpc5200_dma.h | |||
| @@ -55,6 +55,7 @@ struct psc_dma { | |||
| 55 | unsigned int irq; | 55 | unsigned int irq; |
| 56 | struct device *dev; | 56 | struct device *dev; |
| 57 | spinlock_t lock; | 57 | spinlock_t lock; |
| 58 | struct mutex mutex; | ||
| 58 | u32 sicr; | 59 | u32 sicr; |
| 59 | uint sysclk; | 60 | uint sysclk; |
| 60 | int imr; | 61 | int imr; |
diff --git a/sound/soc/fsl/mpc5200_psc_ac97.c b/sound/soc/fsl/mpc5200_psc_ac97.c index 794a247b3eb5..7eb549985d49 100644 --- a/sound/soc/fsl/mpc5200_psc_ac97.c +++ b/sound/soc/fsl/mpc5200_psc_ac97.c | |||
| @@ -34,13 +34,20 @@ static unsigned short psc_ac97_read(struct snd_ac97 *ac97, unsigned short reg) | |||
| 34 | int status; | 34 | int status; |
| 35 | unsigned int val; | 35 | unsigned int val; |
| 36 | 36 | ||
| 37 | mutex_lock(&psc_dma->mutex); | ||
| 38 | |||
| 37 | /* Wait for command send status zero = ready */ | 39 | /* Wait for command send status zero = ready */ |
| 38 | status = spin_event_timeout(!(in_be16(&psc_dma->psc_regs->sr_csr.status) & | 40 | status = spin_event_timeout(!(in_be16(&psc_dma->psc_regs->sr_csr.status) & |
| 39 | MPC52xx_PSC_SR_CMDSEND), 100, 0); | 41 | MPC52xx_PSC_SR_CMDSEND), 100, 0); |
| 40 | if (status == 0) { | 42 | if (status == 0) { |
| 41 | pr_err("timeout on ac97 bus (rdy)\n"); | 43 | pr_err("timeout on ac97 bus (rdy)\n"); |
| 44 | mutex_unlock(&psc_dma->mutex); | ||
| 42 | return -ENODEV; | 45 | return -ENODEV; |
| 43 | } | 46 | } |
| 47 | |||
| 48 | /* Force clear the data valid bit */ | ||
| 49 | in_be32(&psc_dma->psc_regs->ac97_data); | ||
| 50 | |||
| 44 | /* Send the read */ | 51 | /* Send the read */ |
| 45 | out_be32(&psc_dma->psc_regs->ac97_cmd, (1<<31) | ((reg & 0x7f) << 24)); | 52 | out_be32(&psc_dma->psc_regs->ac97_cmd, (1<<31) | ((reg & 0x7f) << 24)); |
| 46 | 53 | ||
| @@ -50,16 +57,19 @@ static unsigned short psc_ac97_read(struct snd_ac97 *ac97, unsigned short reg) | |||
| 50 | if (status == 0) { | 57 | if (status == 0) { |
| 51 | pr_err("timeout on ac97 read (val) %x\n", | 58 | pr_err("timeout on ac97 read (val) %x\n", |
| 52 | in_be16(&psc_dma->psc_regs->sr_csr.status)); | 59 | in_be16(&psc_dma->psc_regs->sr_csr.status)); |
| 60 | mutex_unlock(&psc_dma->mutex); | ||
| 53 | return -ENODEV; | 61 | return -ENODEV; |
| 54 | } | 62 | } |
| 55 | /* Get the data */ | 63 | /* Get the data */ |
| 56 | val = in_be32(&psc_dma->psc_regs->ac97_data); | 64 | val = in_be32(&psc_dma->psc_regs->ac97_data); |
| 57 | if (((val >> 24) & 0x7f) != reg) { | 65 | if (((val >> 24) & 0x7f) != reg) { |
| 58 | pr_err("reg echo error on ac97 read\n"); | 66 | pr_err("reg echo error on ac97 read\n"); |
| 67 | mutex_unlock(&psc_dma->mutex); | ||
| 59 | return -ENODEV; | 68 | return -ENODEV; |
| 60 | } | 69 | } |
| 61 | val = (val >> 8) & 0xffff; | 70 | val = (val >> 8) & 0xffff; |
| 62 | 71 | ||
| 72 | mutex_unlock(&psc_dma->mutex); | ||
| 63 | return (unsigned short) val; | 73 | return (unsigned short) val; |
| 64 | } | 74 | } |
| 65 | 75 | ||
| @@ -68,16 +78,21 @@ static void psc_ac97_write(struct snd_ac97 *ac97, | |||
| 68 | { | 78 | { |
| 69 | int status; | 79 | int status; |
| 70 | 80 | ||
| 81 | mutex_lock(&psc_dma->mutex); | ||
| 82 | |||
| 71 | /* Wait for command status zero = ready */ | 83 | /* Wait for command status zero = ready */ |
| 72 | status = spin_event_timeout(!(in_be16(&psc_dma->psc_regs->sr_csr.status) & | 84 | status = spin_event_timeout(!(in_be16(&psc_dma->psc_regs->sr_csr.status) & |
| 73 | MPC52xx_PSC_SR_CMDSEND), 100, 0); | 85 | MPC52xx_PSC_SR_CMDSEND), 100, 0); |
| 74 | if (status == 0) { | 86 | if (status == 0) { |
| 75 | pr_err("timeout on ac97 bus (write)\n"); | 87 | pr_err("timeout on ac97 bus (write)\n"); |
| 76 | return; | 88 | goto out; |
| 77 | } | 89 | } |
| 78 | /* Write data */ | 90 | /* Write data */ |
| 79 | out_be32(&psc_dma->psc_regs->ac97_cmd, | 91 | out_be32(&psc_dma->psc_regs->ac97_cmd, |
| 80 | ((reg & 0x7f) << 24) | (val << 8)); | 92 | ((reg & 0x7f) << 24) | (val << 8)); |
| 93 | |||
| 94 | out: | ||
| 95 | mutex_unlock(&psc_dma->mutex); | ||
| 81 | } | 96 | } |
| 82 | 97 | ||
| 83 | static void psc_ac97_warm_reset(struct snd_ac97 *ac97) | 98 | static void psc_ac97_warm_reset(struct snd_ac97 *ac97) |
diff --git a/sound/soc/omap/omap-pcm.c b/sound/soc/omap/omap-pcm.c index 6454e15f7d28..84a1950880eb 100644 --- a/sound/soc/omap/omap-pcm.c +++ b/sound/soc/omap/omap-pcm.c | |||
| @@ -216,12 +216,15 @@ static snd_pcm_uframes_t omap_pcm_pointer(struct snd_pcm_substream *substream) | |||
| 216 | dma_addr_t ptr; | 216 | dma_addr_t ptr; |
| 217 | snd_pcm_uframes_t offset; | 217 | snd_pcm_uframes_t offset; |
| 218 | 218 | ||
| 219 | if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) | 219 | if (substream->stream == SNDRV_PCM_STREAM_CAPTURE) { |
| 220 | ptr = omap_get_dma_src_pos(prtd->dma_ch); | ||
| 221 | else | ||
| 222 | ptr = omap_get_dma_dst_pos(prtd->dma_ch); | 220 | ptr = omap_get_dma_dst_pos(prtd->dma_ch); |
| 221 | offset = bytes_to_frames(runtime, ptr - runtime->dma_addr); | ||
| 222 | } else if (!(cpu_is_omap1510())) { | ||
| 223 | ptr = omap_get_dma_src_pos(prtd->dma_ch); | ||
| 224 | offset = bytes_to_frames(runtime, ptr - runtime->dma_addr); | ||
| 225 | } else | ||
| 226 | offset = prtd->period_index * runtime->period_size; | ||
| 223 | 227 | ||
| 224 | offset = bytes_to_frames(runtime, ptr - runtime->dma_addr); | ||
| 225 | if (offset >= runtime->buffer_size) | 228 | if (offset >= runtime->buffer_size) |
| 226 | offset = 0; | 229 | offset = 0; |
| 227 | 230 | ||
diff --git a/sound/soc/pxa/pxa2xx-i2s.c b/sound/soc/pxa/pxa2xx-i2s.c index 4743e262895d..6b8f655d1ad8 100644 --- a/sound/soc/pxa/pxa2xx-i2s.c +++ b/sound/soc/pxa/pxa2xx-i2s.c | |||
| @@ -167,6 +167,7 @@ static int pxa2xx_i2s_hw_params(struct snd_pcm_substream *substream, | |||
| 167 | 167 | ||
| 168 | BUG_ON(IS_ERR(clk_i2s)); | 168 | BUG_ON(IS_ERR(clk_i2s)); |
| 169 | clk_enable(clk_i2s); | 169 | clk_enable(clk_i2s); |
| 170 | dai->private_data = dai; | ||
| 170 | pxa_i2s_wait(); | 171 | pxa_i2s_wait(); |
| 171 | 172 | ||
| 172 | if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) | 173 | if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) |
| @@ -255,7 +256,10 @@ static void pxa2xx_i2s_shutdown(struct snd_pcm_substream *substream, | |||
| 255 | if ((SACR1 & (SACR1_DREC | SACR1_DRPL)) == (SACR1_DREC | SACR1_DRPL)) { | 256 | if ((SACR1 & (SACR1_DREC | SACR1_DRPL)) == (SACR1_DREC | SACR1_DRPL)) { |
| 256 | SACR0 &= ~SACR0_ENB; | 257 | SACR0 &= ~SACR0_ENB; |
| 257 | pxa_i2s_wait(); | 258 | pxa_i2s_wait(); |
| 258 | clk_disable(clk_i2s); | 259 | if (dai->private_data != NULL) { |
| 260 | clk_disable(clk_i2s); | ||
| 261 | dai->private_data = NULL; | ||
| 262 | } | ||
| 259 | } | 263 | } |
| 260 | } | 264 | } |
| 261 | 265 | ||
| @@ -336,6 +340,7 @@ static int pxa2xx_i2s_probe(struct platform_device *dev) | |||
| 336 | return PTR_ERR(clk_i2s); | 340 | return PTR_ERR(clk_i2s); |
| 337 | 341 | ||
| 338 | pxa_i2s_dai.dev = &dev->dev; | 342 | pxa_i2s_dai.dev = &dev->dev; |
| 343 | pxa_i2s_dai.private_data = NULL; | ||
| 339 | ret = snd_soc_register_dai(&pxa_i2s_dai); | 344 | ret = snd_soc_register_dai(&pxa_i2s_dai); |
| 340 | if (ret != 0) | 345 | if (ret != 0) |
| 341 | clk_put(clk_i2s); | 346 | clk_put(clk_i2s); |
diff --git a/sound/sound_core.c b/sound/sound_core.c index 12522e6913d9..a41f8b127f49 100644 --- a/sound/sound_core.c +++ b/sound/sound_core.c | |||
| @@ -10,6 +10,8 @@ | |||
| 10 | #include <linux/module.h> | 10 | #include <linux/module.h> |
| 11 | #include <linux/device.h> | 11 | #include <linux/device.h> |
| 12 | #include <linux/err.h> | 12 | #include <linux/err.h> |
| 13 | #include <linux/kdev_t.h> | ||
| 14 | #include <linux/major.h> | ||
| 13 | #include <sound/core.h> | 15 | #include <sound/core.h> |
| 14 | 16 | ||
| 15 | #ifdef CONFIG_SOUND_OSS_CORE | 17 | #ifdef CONFIG_SOUND_OSS_CORE |
| @@ -29,6 +31,8 @@ MODULE_LICENSE("GPL"); | |||
| 29 | 31 | ||
| 30 | static char *sound_nodename(struct device *dev) | 32 | static char *sound_nodename(struct device *dev) |
| 31 | { | 33 | { |
| 34 | if (MAJOR(dev->devt) == SOUND_MAJOR) | ||
| 35 | return NULL; | ||
| 32 | return kasprintf(GFP_KERNEL, "snd/%s", dev_name(dev)); | 36 | return kasprintf(GFP_KERNEL, "snd/%s", dev_name(dev)); |
| 33 | } | 37 | } |
| 34 | 38 | ||
| @@ -104,7 +108,6 @@ module_exit(cleanup_soundcore); | |||
| 104 | #include <linux/types.h> | 108 | #include <linux/types.h> |
| 105 | #include <linux/kernel.h> | 109 | #include <linux/kernel.h> |
| 106 | #include <linux/sound.h> | 110 | #include <linux/sound.h> |
| 107 | #include <linux/major.h> | ||
| 108 | #include <linux/kmod.h> | 111 | #include <linux/kmod.h> |
| 109 | 112 | ||
| 110 | #define SOUND_STEP 16 | 113 | #define SOUND_STEP 16 |
diff --git a/sound/usb/caiaq/device.c b/sound/usb/caiaq/device.c index 0e5db719de24..de38108f0b28 100644 --- a/sound/usb/caiaq/device.c +++ b/sound/usb/caiaq/device.c | |||
| @@ -35,7 +35,7 @@ | |||
| 35 | #include "input.h" | 35 | #include "input.h" |
| 36 | 36 | ||
| 37 | MODULE_AUTHOR("Daniel Mack <daniel@caiaq.de>"); | 37 | MODULE_AUTHOR("Daniel Mack <daniel@caiaq.de>"); |
| 38 | MODULE_DESCRIPTION("caiaq USB audio, version 1.3.17"); | 38 | MODULE_DESCRIPTION("caiaq USB audio, version 1.3.18"); |
| 39 | MODULE_LICENSE("GPL"); | 39 | MODULE_LICENSE("GPL"); |
| 40 | MODULE_SUPPORTED_DEVICE("{{Native Instruments, RigKontrol2}," | 40 | MODULE_SUPPORTED_DEVICE("{{Native Instruments, RigKontrol2}," |
| 41 | "{Native Instruments, RigKontrol3}," | 41 | "{Native Instruments, RigKontrol3}," |
| @@ -349,7 +349,9 @@ static void __devinit setup_card(struct snd_usb_caiaqdev *dev) | |||
| 349 | log("Unable to set up control system (ret=%d)\n", ret); | 349 | log("Unable to set up control system (ret=%d)\n", ret); |
| 350 | } | 350 | } |
| 351 | 351 | ||
| 352 | static int create_card(struct usb_device* usb_dev, struct snd_card **cardp) | 352 | static int create_card(struct usb_device *usb_dev, |
| 353 | struct usb_interface *intf, | ||
| 354 | struct snd_card **cardp) | ||
| 353 | { | 355 | { |
| 354 | int devnum; | 356 | int devnum; |
| 355 | int err; | 357 | int err; |
| @@ -374,7 +376,7 @@ static int create_card(struct usb_device* usb_dev, struct snd_card **cardp) | |||
| 374 | dev->chip.usb_id = USB_ID(le16_to_cpu(usb_dev->descriptor.idVendor), | 376 | dev->chip.usb_id = USB_ID(le16_to_cpu(usb_dev->descriptor.idVendor), |
| 375 | le16_to_cpu(usb_dev->descriptor.idProduct)); | 377 | le16_to_cpu(usb_dev->descriptor.idProduct)); |
| 376 | spin_lock_init(&dev->spinlock); | 378 | spin_lock_init(&dev->spinlock); |
| 377 | snd_card_set_dev(card, &usb_dev->dev); | 379 | snd_card_set_dev(card, &intf->dev); |
| 378 | 380 | ||
| 379 | *cardp = card; | 381 | *cardp = card; |
| 380 | return 0; | 382 | return 0; |
| @@ -461,7 +463,7 @@ static int __devinit snd_probe(struct usb_interface *intf, | |||
| 461 | struct snd_card *card; | 463 | struct snd_card *card; |
| 462 | struct usb_device *device = interface_to_usbdev(intf); | 464 | struct usb_device *device = interface_to_usbdev(intf); |
| 463 | 465 | ||
| 464 | ret = create_card(device, &card); | 466 | ret = create_card(device, intf, &card); |
| 465 | 467 | ||
| 466 | if (ret < 0) | 468 | if (ret < 0) |
| 467 | return ret; | 469 | return ret; |
diff --git a/sound/usb/usx2y/us122l.c b/sound/usb/usx2y/us122l.c index a5aae9d67f31..fd44946ce4b3 100644 --- a/sound/usb/usx2y/us122l.c +++ b/sound/usb/usx2y/us122l.c | |||
| @@ -514,7 +514,6 @@ static int usx2y_create_card(struct usb_device *device, struct snd_card **cardp) | |||
| 514 | US122L(card)->chip.dev->bus->busnum, | 514 | US122L(card)->chip.dev->bus->busnum, |
| 515 | US122L(card)->chip.dev->devnum | 515 | US122L(card)->chip.dev->devnum |
| 516 | ); | 516 | ); |
| 517 | snd_card_set_dev(card, &device->dev); | ||
| 518 | *cardp = card; | 517 | *cardp = card; |
| 519 | return 0; | 518 | return 0; |
| 520 | } | 519 | } |
| @@ -531,6 +530,7 @@ static int us122l_usb_probe(struct usb_interface *intf, | |||
| 531 | if (err < 0) | 530 | if (err < 0) |
| 532 | return err; | 531 | return err; |
| 533 | 532 | ||
| 533 | snd_card_set_dev(card, &intf->dev); | ||
| 534 | if (!us122l_create_card(card)) { | 534 | if (!us122l_create_card(card)) { |
| 535 | snd_card_free(card); | 535 | snd_card_free(card); |
| 536 | return -EINVAL; | 536 | return -EINVAL; |
diff --git a/sound/usb/usx2y/usbusx2y.c b/sound/usb/usx2y/usbusx2y.c index 5ce0da23ee96..cb4bb8373ca2 100644 --- a/sound/usb/usx2y/usbusx2y.c +++ b/sound/usb/usx2y/usbusx2y.c | |||
| @@ -364,7 +364,6 @@ static int usX2Y_create_card(struct usb_device *device, struct snd_card **cardp) | |||
| 364 | 0,//us428(card)->usbmidi.ifnum, | 364 | 0,//us428(card)->usbmidi.ifnum, |
| 365 | usX2Y(card)->chip.dev->bus->busnum, usX2Y(card)->chip.dev->devnum | 365 | usX2Y(card)->chip.dev->bus->busnum, usX2Y(card)->chip.dev->devnum |
| 366 | ); | 366 | ); |
| 367 | snd_card_set_dev(card, &device->dev); | ||
| 368 | *cardp = card; | 367 | *cardp = card; |
| 369 | return 0; | 368 | return 0; |
| 370 | } | 369 | } |
| @@ -388,6 +387,7 @@ static int usX2Y_usb_probe(struct usb_device *device, | |||
| 388 | err = usX2Y_create_card(device, &card); | 387 | err = usX2Y_create_card(device, &card); |
| 389 | if (err < 0) | 388 | if (err < 0) |
| 390 | return err; | 389 | return err; |
| 390 | snd_card_set_dev(card, &intf->dev); | ||
| 391 | if ((err = usX2Y_hwdep_new(card, device)) < 0 || | 391 | if ((err = usX2Y_hwdep_new(card, device)) < 0 || |
| 392 | (err = snd_card_register(card)) < 0) { | 392 | (err = snd_card_register(card)) < 0) { |
| 393 | snd_card_free(card); | 393 | snd_card_free(card); |
diff --git a/sound/usb/usx2y/usbusx2yaudio.c b/sound/usb/usx2y/usbusx2yaudio.c index dd1ab6177840..9efd27f6b52f 100644 --- a/sound/usb/usx2y/usbusx2yaudio.c +++ b/sound/usb/usx2y/usbusx2yaudio.c | |||
| @@ -296,9 +296,10 @@ static void usX2Y_error_urb_status(struct usX2Ydev *usX2Y, | |||
| 296 | static void usX2Y_error_sequence(struct usX2Ydev *usX2Y, | 296 | static void usX2Y_error_sequence(struct usX2Ydev *usX2Y, |
| 297 | struct snd_usX2Y_substream *subs, struct urb *urb) | 297 | struct snd_usX2Y_substream *subs, struct urb *urb) |
| 298 | { | 298 | { |
| 299 | snd_printk(KERN_ERR "Sequence Error!(hcd_frame=%i ep=%i%s;wait=%i,frame=%i).\n" | 299 | snd_printk(KERN_ERR |
| 300 | KERN_ERR "Most propably some urb of usb-frame %i is still missing.\n" | 300 | "Sequence Error!(hcd_frame=%i ep=%i%s;wait=%i,frame=%i).\n" |
| 301 | KERN_ERR "Cause could be too long delays in usb-hcd interrupt handling.\n", | 301 | "Most propably some urb of usb-frame %i is still missing.\n" |
| 302 | "Cause could be too long delays in usb-hcd interrupt handling.\n", | ||
| 302 | usb_get_current_frame_number(usX2Y->chip.dev), | 303 | usb_get_current_frame_number(usX2Y->chip.dev), |
| 303 | subs->endpoint, usb_pipein(urb->pipe) ? "in" : "out", | 304 | subs->endpoint, usb_pipein(urb->pipe) ? "in" : "out", |
| 304 | usX2Y->wait_iso_frame, urb->start_frame, usX2Y->wait_iso_frame); | 305 | usX2Y->wait_iso_frame, urb->start_frame, usX2Y->wait_iso_frame); |
