Merge git://git.kernel.org/pub/scm/linux/kernel/git/perex/alsa

+364 -111
+9 -1
Documentation/sound/alsa/ALSA-Configuration.txt
··· 837 838 Module for AC'97 motherboards from Intel and compatibles. 839 * Intel i810/810E, i815, i820, i830, i84x, MX440 840 * SiS 7012 (SiS 735) 841 - * NVidia NForce, NForce2 842 * AMD AMD768, AMD8111 843 * ALi m5455 844 ··· 870 -------------------- 871 872 Module for Intel ICH (i8x0) chipset MC97 modems. 873 874 ac97_clock - AC'97 codec clock base (0 = auto-detect) 875
··· 837 838 Module for AC'97 motherboards from Intel and compatibles. 839 * Intel i810/810E, i815, i820, i830, i84x, MX440 840 + ICH5, ICH6, ICH7, ESB2 841 * SiS 7012 (SiS 735) 842 + * NVidia NForce, NForce2, NForce3, MCP04, CK804 843 + CK8, CK8S, MCP501 844 * AMD AMD768, AMD8111 845 * ALi m5455 846 ··· 868 -------------------- 869 870 Module for Intel ICH (i8x0) chipset MC97 modems. 871 + * Intel i810/810E, i815, i820, i830, i84x, MX440 872 + ICH5, ICH6, ICH7 873 + * SiS 7013 (SiS 735) 874 + * NVidia NForce, NForce2, NForce2s, NForce3 875 + * AMD AMD8111 876 + * ALi m5455 877 878 ac97_clock - AC'97 codec clock base (0 = auto-detect) 879
+2 -2
Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl
··· 5206 You need to pass the <function>snd_dma_pci_data(pci)</function>, 5207 where pci is the struct <structname>pci_dev</structname> pointer 5208 of the chip as well. 5209 - The <type>snd_sg_buf_t</type> instance is created as 5210 substream-&gt;dma_private. You can cast 5211 the pointer like: 5212 5213 <informalexample> 5214 <programlisting> 5215 <![CDATA[ 5216 - struct snd_sg_buf *sgbuf = (struct snd_sg_buf_t*)substream->dma_private; 5217 ]]> 5218 </programlisting> 5219 </informalexample>
··· 5206 You need to pass the <function>snd_dma_pci_data(pci)</function>, 5207 where pci is the struct <structname>pci_dev</structname> pointer 5208 of the chip as well. 5209 + The <type>struct snd_sg_buf</type> instance is created as 5210 substream-&gt;dma_private. You can cast 5211 the pointer like: 5212 5213 <informalexample> 5214 <programlisting> 5215 <![CDATA[ 5216 + struct snd_sg_buf *sgbuf = (struct snd_sg_buf *)substream->dma_private; 5217 ]]> 5218 </programlisting> 5219 </informalexample>
+7 -2
drivers/pnp/card.c
··· 363 364 int pnp_register_card_driver(struct pnp_card_driver * drv) 365 { 366 - int count = 0; 367 struct list_head *pos, *temp; 368 369 drv->link.name = drv->name; ··· 374 drv->link.suspend = drv->suspend ? card_suspend : NULL; 375 drv->link.resume = drv->resume ? card_resume : NULL; 376 377 spin_lock(&pnp_lock); 378 list_add_tail(&drv->global_list, &pnp_card_drivers); 379 spin_unlock(&pnp_lock); 380 - pnp_register_driver(&drv->link); 381 382 list_for_each_safe(pos,temp,&pnp_cards){ 383 struct pnp_card *card = list_entry(pos, struct pnp_card, global_list);
··· 363 364 int pnp_register_card_driver(struct pnp_card_driver * drv) 365 { 366 + int count; 367 struct list_head *pos, *temp; 368 369 drv->link.name = drv->name; ··· 374 drv->link.suspend = drv->suspend ? card_suspend : NULL; 375 drv->link.resume = drv->resume ? card_resume : NULL; 376 377 + count = pnp_register_driver(&drv->link); 378 + if (count < 0) 379 + return count; 380 + 381 spin_lock(&pnp_lock); 382 list_add_tail(&drv->global_list, &pnp_card_drivers); 383 spin_unlock(&pnp_lock); 384 + 385 + count = 0; 386 387 list_for_each_safe(pos,temp,&pnp_cards){ 388 struct pnp_card *card = list_entry(pos, struct pnp_card, global_list);
+11 -22
sound/core/info.c
··· 444 return mask; 445 } 446 447 - static inline int _snd_info_entry_ioctl(struct inode *inode, struct file *file, 448 - unsigned int cmd, unsigned long arg) 449 { 450 struct snd_info_private_data *data; 451 struct snd_info_entry *entry; ··· 463 break; 464 } 465 return -ENOTTY; 466 - } 467 - 468 - /* FIXME: need to unlock BKL to allow preemption */ 469 - static int snd_info_entry_ioctl(struct inode *inode, struct file *file, 470 - unsigned int cmd, unsigned long arg) 471 - { 472 - int err; 473 - unlock_kernel(); 474 - err = _snd_info_entry_ioctl(inode, file, cmd, arg); 475 - lock_kernel(); 476 - return err; 477 } 478 479 static int snd_info_entry_mmap(struct file *file, struct vm_area_struct *vma) ··· 488 489 static struct file_operations snd_info_entry_operations = 490 { 491 - .owner = THIS_MODULE, 492 - .llseek = snd_info_entry_llseek, 493 - .read = snd_info_entry_read, 494 - .write = snd_info_entry_write, 495 - .poll = snd_info_entry_poll, 496 - .ioctl = snd_info_entry_ioctl, 497 - .mmap = snd_info_entry_mmap, 498 - .open = snd_info_entry_open, 499 - .release = snd_info_entry_release, 500 }; 501 502 /**
··· 444 return mask; 445 } 446 447 + static long snd_info_entry_ioctl(struct file *file, unsigned int cmd, 448 + unsigned long arg) 449 { 450 struct snd_info_private_data *data; 451 struct snd_info_entry *entry; ··· 463 break; 464 } 465 return -ENOTTY; 466 } 467 468 static int snd_info_entry_mmap(struct file *file, struct vm_area_struct *vma) ··· 499 500 static struct file_operations snd_info_entry_operations = 501 { 502 + .owner = THIS_MODULE, 503 + .llseek = snd_info_entry_llseek, 504 + .read = snd_info_entry_read, 505 + .write = snd_info_entry_write, 506 + .poll = snd_info_entry_poll, 507 + .unlocked_ioctl = snd_info_entry_ioctl, 508 + .mmap = snd_info_entry_mmap, 509 + .open = snd_info_entry_open, 510 + .release = snd_info_entry_release, 511 }; 512 513 /**
+1 -1
sound/drivers/serial-u16550.c
··· 789 790 if ((err = snd_uart16550_detect(uart)) <= 0) { 791 printk(KERN_ERR "no UART detected at 0x%lx\n", iobase); 792 - return err; 793 } 794 795 if (irq >= 0 && irq != SNDRV_AUTO_IRQ) {
··· 789 790 if ((err = snd_uart16550_detect(uart)) <= 0) { 791 printk(KERN_ERR "no UART detected at 0x%lx\n", iobase); 792 + return -ENODEV; 793 } 794 795 if (irq >= 0 && irq != SNDRV_AUTO_IRQ) {
+6
sound/isa/cmi8330.c
··· 109 MODULE_PARM_DESC(wssdma, "DMA for CMI8330 WSS driver."); 110 111 static struct platform_device *platform_devices[SNDRV_CARDS]; 112 static int pnp_registered; 113 114 #define CMI8330_RMUX3D 16 115 #define CMI8330_MUTEMUX 17 ··· 674 { 675 int i; 676 677 if (pnp_registered) 678 pnp_unregister_card_driver(&cmi8330_pnpc_driver); 679 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 680 platform_device_unregister(platform_devices[i]); 681 platform_driver_unregister(&snd_cmi8330_driver); ··· 704 cards++; 705 } 706 707 err = pnp_register_card_driver(&cmi8330_pnpc_driver); 708 if (err >= 0) { 709 pnp_registered = 1; 710 cards += err; 711 } 712 713 if (!cards) { 714 #ifdef MODULE
··· 109 MODULE_PARM_DESC(wssdma, "DMA for CMI8330 WSS driver."); 110 111 static struct platform_device *platform_devices[SNDRV_CARDS]; 112 + #ifdef CONFIG_PNP 113 static int pnp_registered; 114 + #endif 115 116 #define CMI8330_RMUX3D 16 117 #define CMI8330_MUTEMUX 17 ··· 672 { 673 int i; 674 675 + #ifdef CONFIG_PNP 676 if (pnp_registered) 677 pnp_unregister_card_driver(&cmi8330_pnpc_driver); 678 + #endif 679 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 680 platform_device_unregister(platform_devices[i]); 681 platform_driver_unregister(&snd_cmi8330_driver); ··· 700 cards++; 701 } 702 703 + #ifdef CONFIG_PNP 704 err = pnp_register_card_driver(&cmi8330_pnpc_driver); 705 if (err >= 0) { 706 pnp_registered = 1; 707 cards += err; 708 } 709 + #endif 710 711 if (!cards) { 712 #ifdef MODULE
+11 -2
sound/isa/cs423x/cs4236.c
··· 75 76 #ifdef CS4232 77 #define IDENT "CS4232" 78 #else 79 #define IDENT "CS4236+" 80 #endif 81 82 static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX; /* Index 0-MAX */ ··· 127 MODULE_PARM_DESC(dma2, "DMA2 # for " IDENT " driver."); 128 129 static struct platform_device *platform_devices[SNDRV_CARDS]; 130 static int pnpc_registered; 131 #ifdef CS4232 132 static int pnp_registered; 133 #endif 134 135 struct snd_card_cs4236 { 136 struct snd_cs4231 *chip; ··· 162 #endif /* CS4232 */ 163 164 #ifdef CS4232 165 - #define CS423X_DRIVER "snd_cs4232" 166 #define CS423X_ISAPNP_DRIVER "cs4232_isapnp" 167 static struct pnp_card_device_id snd_cs423x_pnpids[] = { 168 /* Philips PCA70PS */ ··· 178 { .id = "CSC7632", .devs = { { "CSC0000" }, { "CSC0010" }, { "PNPb006" } } }, 179 /* SIC CrystalWave 32 (CS4232) */ 180 { .id = "CSCf032", .devs = { { "CSC0000" }, { "CSC0010" }, { "CSC0003" } } }, 181 /* --- */ 182 { .id = "" } /* end */ 183 }; 184 #else /* CS4236 */ 185 - #define CS423X_DRIVER "snd_cs4236" 186 #define CS423X_ISAPNP_DRIVER "cs4236_isapnp" 187 static struct pnp_card_device_id snd_cs423x_pnpids[] = { 188 /* Intel Marlin Spike Motherboard - CS4235 */ ··· 751 { 752 int i; 753 754 if (pnpc_registered) 755 pnp_unregister_card_driver(&cs423x_pnpc_driver); 756 #ifdef CS4232 757 if (pnp_registered) 758 pnp_unregister_driver(&cs4232_pnp_driver); 759 #endif 760 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 761 platform_device_unregister(platform_devices[i]); 762 platform_driver_unregister(&cs423x_nonpnp_driver); ··· 784 platform_devices[i] = device; 785 cards++; 786 } 787 #ifdef CS4232 788 i = pnp_register_driver(&cs4232_pnp_driver); 789 if (i >= 0) { ··· 797 pnpc_registered = 1; 798 cards += i; 799 } 800 if (!cards) { 801 #ifdef MODULE 802 printk(KERN_ERR IDENT " soundcard not found or device busy\n");
··· 75 76 #ifdef CS4232 77 #define IDENT "CS4232" 78 + #define CS423X_DRIVER "snd_cs4232" 79 #else 80 #define IDENT "CS4236+" 81 + #define CS423X_DRIVER "snd_cs4236" 82 #endif 83 84 static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX; /* Index 0-MAX */ ··· 125 MODULE_PARM_DESC(dma2, "DMA2 # for " IDENT " driver."); 126 127 static struct platform_device *platform_devices[SNDRV_CARDS]; 128 + #ifdef CONFIG_PNP 129 static int pnpc_registered; 130 #ifdef CS4232 131 static int pnp_registered; 132 #endif 133 + #endif /* CONFIG_PNP */ 134 135 struct snd_card_cs4236 { 136 struct snd_cs4231 *chip; ··· 158 #endif /* CS4232 */ 159 160 #ifdef CS4232 161 #define CS423X_ISAPNP_DRIVER "cs4232_isapnp" 162 static struct pnp_card_device_id snd_cs423x_pnpids[] = { 163 /* Philips PCA70PS */ ··· 175 { .id = "CSC7632", .devs = { { "CSC0000" }, { "CSC0010" }, { "PNPb006" } } }, 176 /* SIC CrystalWave 32 (CS4232) */ 177 { .id = "CSCf032", .devs = { { "CSC0000" }, { "CSC0010" }, { "CSC0003" } } }, 178 + /* Netfinity 3000 on-board soundcard */ 179 + { .id = "CSCe825", .devs = { { "CSC0100" }, { "CSC0110" }, { "CSC010f" } } }, 180 /* --- */ 181 { .id = "" } /* end */ 182 }; 183 #else /* CS4236 */ 184 #define CS423X_ISAPNP_DRIVER "cs4236_isapnp" 185 static struct pnp_card_device_id snd_cs423x_pnpids[] = { 186 /* Intel Marlin Spike Motherboard - CS4235 */ ··· 747 { 748 int i; 749 750 + #ifdef CONFIG_PNP 751 if (pnpc_registered) 752 pnp_unregister_card_driver(&cs423x_pnpc_driver); 753 #ifdef CS4232 754 if (pnp_registered) 755 pnp_unregister_driver(&cs4232_pnp_driver); 756 #endif 757 + #endif /* CONFIG_PNP */ 758 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 759 platform_device_unregister(platform_devices[i]); 760 platform_driver_unregister(&cs423x_nonpnp_driver); ··· 778 platform_devices[i] = device; 779 cards++; 780 } 781 + #ifdef CONFIG_PNP 782 #ifdef CS4232 783 i = pnp_register_driver(&cs4232_pnp_driver); 784 if (i >= 0) { ··· 790 pnpc_registered = 1; 791 cards += i; 792 } 793 + #endif /* CONFIG_PNP */ 794 + 795 if (!cards) { 796 #ifdef MODULE 797 printk(KERN_ERR IDENT " soundcard not found or device busy\n");
+5 -1
sound/isa/es18xx.c
··· 1878 MODULE_PARM_DESC(dma2, "DMA 2 # for ES18xx driver."); 1879 1880 static struct platform_device *platform_devices[SNDRV_CARDS]; 1881 - static int pnp_registered; 1882 1883 #ifdef CONFIG_PNP 1884 1885 static struct pnp_card_device_id snd_audiodrive_pnpids[] = { 1886 /* ESS 1868 (integrated on Compaq dual P-Pro motherboard and Genius 18PnP 3D) */ ··· 2209 { 2210 int i; 2211 2212 if (pnp_registered) 2213 pnp_unregister_card_driver(&es18xx_pnpc_driver); 2214 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 2215 platform_device_unregister(platform_devices[i]); 2216 platform_driver_unregister(&snd_es18xx_nonpnp_driver); ··· 2239 cards++; 2240 } 2241 2242 i = pnp_register_card_driver(&es18xx_pnpc_driver); 2243 if (i >= 0) { 2244 pnp_registered = 1; 2245 cards += i; 2246 } 2247 2248 if(!cards) { 2249 #ifdef MODULE
··· 1878 MODULE_PARM_DESC(dma2, "DMA 2 # for ES18xx driver."); 1879 1880 static struct platform_device *platform_devices[SNDRV_CARDS]; 1881 1882 #ifdef CONFIG_PNP 1883 + static int pnp_registered; 1884 1885 static struct pnp_card_device_id snd_audiodrive_pnpids[] = { 1886 /* ESS 1868 (integrated on Compaq dual P-Pro motherboard and Genius 18PnP 3D) */ ··· 2209 { 2210 int i; 2211 2212 + #ifdef CONFIG_PNP 2213 if (pnp_registered) 2214 pnp_unregister_card_driver(&es18xx_pnpc_driver); 2215 + #endif 2216 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 2217 platform_device_unregister(platform_devices[i]); 2218 platform_driver_unregister(&snd_es18xx_nonpnp_driver); ··· 2237 cards++; 2238 } 2239 2240 + #ifdef CONFIG_PNP 2241 i = pnp_register_card_driver(&es18xx_pnpc_driver); 2242 if (i >= 0) { 2243 pnp_registered = 1; 2244 cards += i; 2245 } 2246 + #endif 2247 2248 if(!cards) { 2249 #ifdef MODULE
+1 -1
sound/isa/gus/gusclassic.c
··· 195 goto _err; 196 } 197 sprintf(card->longname + strlen(card->longname), " at 0x%lx, irq %d, dma %d", gus->gf1.port, xirq, xdma1); 198 - if (dma2 >= 0) 199 sprintf(card->longname + strlen(card->longname), "&%d", xdma2); 200 201 snd_card_set_dev(card, &pdev->dev);
··· 195 goto _err; 196 } 197 sprintf(card->longname + strlen(card->longname), " at 0x%lx, irq %d, dma %d", gus->gf1.port, xirq, xdma1); 198 + if (xdma2 >= 0) 199 sprintf(card->longname + strlen(card->longname), "&%d", xdma2); 200 201 snd_card_set_dev(card, &pdev->dev);
+9 -3
sound/isa/opl3sa2.c
··· 91 MODULE_PARM_DESC(opl3sa3_ymode, "Speaker size selection for 3D Enhancement mode: Desktop/Large Notebook/Small Notebook/HiFi."); 92 93 static struct platform_device *platform_devices[SNDRV_CARDS]; 94 static int pnp_registered; 95 static int pnpc_registered; 96 97 /* control ports */ 98 #define OPL3SA2_PM_CTRL 0x01 ··· 723 } 724 sprintf(card->longname, "%s at 0x%lx, irq %d, dma %d", 725 card->shortname, chip->port, xirq, xdma1); 726 - if (dma2 >= 0) 727 sprintf(card->longname + strlen(card->longname), "&%d", xdma2); 728 729 return snd_card_register(card); ··· 781 #endif 782 783 static struct pnp_driver opl3sa2_pnp_driver = { 784 - .name = "opl3sa2-pnpbios", 785 .id_table = snd_opl3sa2_pnpbiosids, 786 .probe = snd_opl3sa2_pnp_detect, 787 .remove = __devexit_p(snd_opl3sa2_pnp_remove), ··· 848 849 static struct pnp_card_driver opl3sa2_pnpc_driver = { 850 .flags = PNP_DRIVER_RES_DISABLE, 851 - .name = "opl3sa2", 852 .id_table = snd_opl3sa2_pnpids, 853 .probe = snd_opl3sa2_pnp_cdetect, 854 .remove = __devexit_p(snd_opl3sa2_pnp_cremove), ··· 931 { 932 int i; 933 934 if (pnpc_registered) 935 pnp_unregister_card_driver(&opl3sa2_pnpc_driver); 936 if (pnp_registered) 937 pnp_unregister_driver(&opl3sa2_pnp_driver); 938 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 939 platform_device_unregister(platform_devices[i]); 940 platform_driver_unregister(&snd_opl3sa2_nonpnp_driver); ··· 965 cards++; 966 } 967 968 err = pnp_register_driver(&opl3sa2_pnp_driver); 969 if (err >= 0) { 970 pnp_registered = 1; ··· 976 pnpc_registered = 1; 977 cards += err; 978 } 979 980 if (!cards) { 981 #ifdef MODULE
··· 91 MODULE_PARM_DESC(opl3sa3_ymode, "Speaker size selection for 3D Enhancement mode: Desktop/Large Notebook/Small Notebook/HiFi."); 92 93 static struct platform_device *platform_devices[SNDRV_CARDS]; 94 + #ifdef CONFIG_PNP 95 static int pnp_registered; 96 static int pnpc_registered; 97 + #endif 98 99 /* control ports */ 100 #define OPL3SA2_PM_CTRL 0x01 ··· 721 } 722 sprintf(card->longname, "%s at 0x%lx, irq %d, dma %d", 723 card->shortname, chip->port, xirq, xdma1); 724 + if (xdma2 >= 0) 725 sprintf(card->longname + strlen(card->longname), "&%d", xdma2); 726 727 return snd_card_register(card); ··· 779 #endif 780 781 static struct pnp_driver opl3sa2_pnp_driver = { 782 + .name = "snd-opl3sa2-pnpbios", 783 .id_table = snd_opl3sa2_pnpbiosids, 784 .probe = snd_opl3sa2_pnp_detect, 785 .remove = __devexit_p(snd_opl3sa2_pnp_remove), ··· 846 847 static struct pnp_card_driver opl3sa2_pnpc_driver = { 848 .flags = PNP_DRIVER_RES_DISABLE, 849 + .name = "snd-opl3sa2-cpnp", 850 .id_table = snd_opl3sa2_pnpids, 851 .probe = snd_opl3sa2_pnp_cdetect, 852 .remove = __devexit_p(snd_opl3sa2_pnp_cremove), ··· 929 { 930 int i; 931 932 + #ifdef CONFIG_PNP 933 if (pnpc_registered) 934 pnp_unregister_card_driver(&opl3sa2_pnpc_driver); 935 if (pnp_registered) 936 pnp_unregister_driver(&opl3sa2_pnp_driver); 937 + #endif 938 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 939 platform_device_unregister(platform_devices[i]); 940 platform_driver_unregister(&snd_opl3sa2_nonpnp_driver); ··· 961 cards++; 962 } 963 964 + #ifdef CONFIG_PNP 965 err = pnp_register_driver(&opl3sa2_pnp_driver); 966 if (err >= 0) { 967 pnp_registered = 1; ··· 971 pnpc_registered = 1; 972 cards += err; 973 } 974 + #endif 975 976 if (!cards) { 977 #ifdef MODULE
+1 -1
sound/isa/opti9xx/opti92x-ad1848.c
··· 1349 int error; 1350 struct snd_pcm *pcm; 1351 1352 - if ((error = snd_pcm_new(codec->card, "OPTi 82C93X", device, 1, 1, &pcm))) 1353 return error; 1354 1355 snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_PLAYBACK, &snd_opti93x_playback_ops);
··· 1349 int error; 1350 struct snd_pcm *pcm; 1351 1352 + if ((error = snd_pcm_new(codec->card, "OPTi 82C93X", device, 1, 1, &pcm)) < 0) 1353 return error; 1354 1355 snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_PLAYBACK, &snd_opti93x_playback_ops);
+2 -2
sound/isa/sb/sb16.c
··· 179 { .id = "CTL0086", .devs = { { "CTL0041" } } }, 180 /* Sound Blaster Vibra16X */ 181 { .id = "CTL00f0", .devs = { { "CTL0043" } } }, 182 #else /* SNDRV_SBAWE defined */ 183 /* Sound Blaster AWE 32 PnP */ 184 { .id = "CTL0035", .devs = { { "CTL0031" }, { "CTL0021" } } }, ··· 237 { .id = "CTLXXXX" , .devs = { { "CTL0044" }, { "CTL0023" } } }, 238 { .id = "CTLXXXX" , .devs = { { "CTL0045" }, { "CTL0022" } } }, 239 #endif /* SNDRV_SBAWE */ 240 - /* Sound Blaster 16 PnP (Virtual PC 2004)*/ 241 - { .id = "tBA03b0", .devs = { { "PNPb003" } } }, 242 { .id = "", } 243 }; 244
··· 179 { .id = "CTL0086", .devs = { { "CTL0041" } } }, 180 /* Sound Blaster Vibra16X */ 181 { .id = "CTL00f0", .devs = { { "CTL0043" } } }, 182 + /* Sound Blaster 16 (Virtual PC 2004) */ 183 + { .id = "tBA03b0", .devs = { {.id="PNPb003" } } }, 184 #else /* SNDRV_SBAWE defined */ 185 /* Sound Blaster AWE 32 PnP */ 186 { .id = "CTL0035", .devs = { { "CTL0031" }, { "CTL0021" } } }, ··· 235 { .id = "CTLXXXX" , .devs = { { "CTL0044" }, { "CTL0023" } } }, 236 { .id = "CTLXXXX" , .devs = { { "CTL0045" }, { "CTL0022" } } }, 237 #endif /* SNDRV_SBAWE */ 238 { .id = "", } 239 }; 240
+5 -1
sound/isa/sscape.c
··· 69 MODULE_PARM_DESC(dma, "DMA # for SoundScape driver."); 70 71 static struct platform_device *platform_devices[SNDRV_CARDS]; 72 - static int pnp_registered; 73 74 #ifdef CONFIG_PNP 75 static struct pnp_card_device_id sscape_pnpids[] = { 76 { .id = "ENS3081", .devs = { { "ENS0000" } } }, 77 { .id = "" } /* end */ ··· 1391 { 1392 int i; 1393 1394 if (pnp_registered) 1395 pnp_unregister_card_driver(&sscape_pnpc_driver); 1396 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 1397 platform_device_unregister(platform_devices[i]); 1398 platform_driver_unregister(&snd_sscape_driver); ··· 1468 ret = sscape_manual_probe(); 1469 if (ret < 0) 1470 return ret; 1471 if (pnp_register_card_driver(&sscape_pnpc_driver) >= 0) 1472 pnp_registered = 1; 1473 return 0; 1474 } 1475
··· 69 MODULE_PARM_DESC(dma, "DMA # for SoundScape driver."); 70 71 static struct platform_device *platform_devices[SNDRV_CARDS]; 72 73 #ifdef CONFIG_PNP 74 + static int pnp_registered; 75 static struct pnp_card_device_id sscape_pnpids[] = { 76 { .id = "ENS3081", .devs = { { "ENS0000" } } }, 77 { .id = "" } /* end */ ··· 1391 { 1392 int i; 1393 1394 + #ifdef CONFIG_PNP 1395 if (pnp_registered) 1396 pnp_unregister_card_driver(&sscape_pnpc_driver); 1397 + #endif 1398 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 1399 platform_device_unregister(platform_devices[i]); 1400 platform_driver_unregister(&snd_sscape_driver); ··· 1466 ret = sscape_manual_probe(); 1467 if (ret < 0) 1468 return ret; 1469 + #ifdef CONFIG_PNP 1470 if (pnp_register_card_driver(&sscape_pnpc_driver) >= 0) 1471 pnp_registered = 1; 1472 + #endif 1473 return 0; 1474 } 1475
+5 -2
sound/isa/wavefront/wavefront.c
··· 84 MODULE_PARM_DESC(use_cs4232_midi, "Use CS4232 MPU-401 interface (inaccessibly located inside your computer)"); 85 86 static struct platform_device *platform_devices[SNDRV_CARDS]; 87 - static int pnp_registered; 88 - 89 90 #ifdef CONFIG_PNP 91 92 static struct pnp_card_device_id snd_wavefront_pnpids[] = { 93 /* Tropez */ ··· 694 { 695 int i; 696 697 if (pnp_registered) 698 pnp_unregister_card_driver(&wavefront_pnpc_driver); 699 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 700 platform_device_unregister(platform_devices[i]); 701 platform_driver_unregister(&snd_wavefront_driver); ··· 726 cards++; 727 } 728 729 i = pnp_register_card_driver(&wavefront_pnpc_driver); 730 if (i >= 0) { 731 pnp_registered = 1; 732 cards += i; 733 } 734 735 if (!cards) { 736 #ifdef MODULE
··· 84 MODULE_PARM_DESC(use_cs4232_midi, "Use CS4232 MPU-401 interface (inaccessibly located inside your computer)"); 85 86 static struct platform_device *platform_devices[SNDRV_CARDS]; 87 88 #ifdef CONFIG_PNP 89 + static int pnp_registered; 90 91 static struct pnp_card_device_id snd_wavefront_pnpids[] = { 92 /* Tropez */ ··· 695 { 696 int i; 697 698 + #ifdef CONFIG_PNP 699 if (pnp_registered) 700 pnp_unregister_card_driver(&wavefront_pnpc_driver); 701 + #endif 702 for (i = 0; i < ARRAY_SIZE(platform_devices); ++i) 703 platform_device_unregister(platform_devices[i]); 704 platform_driver_unregister(&snd_wavefront_driver); ··· 725 cards++; 726 } 727 728 + #ifdef CONFIG_PNP 729 i = pnp_register_card_driver(&wavefront_pnpc_driver); 730 if (i >= 0) { 731 pnp_registered = 1; 732 cards += i; 733 } 734 + #endif 735 736 if (!cards) { 737 #ifdef MODULE
+1 -1
sound/isa/wavefront/wavefront_synth.c
··· 866 divided by 2. 867 */ 868 869 - u16 sample_short; 870 u32 length; 871 u16 __user *data_end = NULL; 872 unsigned int i;
··· 866 divided by 2. 867 */ 868 869 + u16 sample_short = 0; 870 u32 length; 871 u16 __user *data_end = NULL; 872 unsigned int i;
+39 -14
sound/pci/ac97/ac97_patch.c
··· 1621 AC97_SINGLE("Line Jack Sense", AC97_AD_JACK_SPDIF, 12, 1, 0), 1622 }; 1623 1624 static int patch_ad1981a_specific(struct snd_ac97 * ac97) 1625 { 1626 return patch_build_controls(ac97, snd_ac97_ad1981x_jack_sense, 1627 ARRAY_SIZE(snd_ac97_ad1981x_jack_sense)); 1628 } ··· 1654 #endif 1655 }; 1656 1657 static void check_ad1981_hp_jack_sense(struct snd_ac97 *ac97) 1658 { 1659 - u32 subid = ((u32)ac97->subsystem_vendor << 16) | ac97->subsystem_device; 1660 - switch (subid) { 1661 - case 0x0e11005a: /* HP nc4000/4010 */ 1662 - case 0x103c0890: /* HP nc6000 */ 1663 - case 0x103c0938: /* HP nc4220 */ 1664 - case 0x103c099c: /* HP nx6110 */ 1665 - case 0x103c0944: /* HP nc6220 */ 1666 - case 0x103c0934: /* HP nc8220 */ 1667 - case 0x103c006d: /* HP nx9105 */ 1668 - case 0x17340088: /* FSC Scenic-W */ 1669 /* enable headphone jack sense */ 1670 snd_ac97_update_bits(ac97, AC97_AD_JACK_SPDIF, 1<<11, 1<<11); 1671 - break; 1672 - } 1673 } 1674 1675 int patch_ad1981a(struct snd_ac97 *ac97) ··· 1695 1696 if ((err = patch_build_controls(ac97, &snd_ac97_ad198x_2cmic, 1)) < 0) 1697 return err; 1698 return patch_build_controls(ac97, snd_ac97_ad1981x_jack_sense, 1699 ARRAY_SIZE(snd_ac97_ad1981x_jack_sense)); 1700 } ··· 2235 /* Vref disable (bit12), 1kOhm (bit13) */ 2236 snd_ac97_update_bits(ac97, AC97_ALC850_MISC1, (1<<12)|(1<<13), 2237 shared ? (1<<12) : (1<<13)); 2238 - /* MIC-IN = 1, CENTER-LFE = 2 */ 2239 snd_ac97_update_bits(ac97, AC97_ALC850_JACK_SELECT, 7 << 4, 2240 - shared ? (2<<4) : (1<<4)); 2241 } 2242 2243 static const struct snd_kcontrol_new snd_ac97_controls_alc850[] = {
··· 1621 AC97_SINGLE("Line Jack Sense", AC97_AD_JACK_SPDIF, 12, 1, 0), 1622 }; 1623 1624 + /* black list to avoid HP/Line jack-sense controls 1625 + * (SS vendor << 16 | device) 1626 + */ 1627 + static unsigned int ad1981_jacks_blacklist[] = { 1628 + 0x10140554, /* Thinkpad T42p/R50p */ 1629 + 0 /* end */ 1630 + }; 1631 + 1632 + static int check_list(struct snd_ac97 *ac97, const unsigned int *list) 1633 + { 1634 + u32 subid = ((u32)ac97->subsystem_vendor << 16) | ac97->subsystem_device; 1635 + for (; *list; list++) 1636 + if (*list == subid) 1637 + return 1; 1638 + return 0; 1639 + } 1640 + 1641 static int patch_ad1981a_specific(struct snd_ac97 * ac97) 1642 { 1643 + if (check_list(ac97, ad1981_jacks_blacklist)) 1644 + return 0; 1645 return patch_build_controls(ac97, snd_ac97_ad1981x_jack_sense, 1646 ARRAY_SIZE(snd_ac97_ad1981x_jack_sense)); 1647 } ··· 1635 #endif 1636 }; 1637 1638 + /* white list to enable HP jack-sense bits 1639 + * (SS vendor << 16 | device) 1640 + */ 1641 + static unsigned int ad1981_jacks_whitelist[] = { 1642 + 0x0e11005a, /* HP nc4000/4010 */ 1643 + 0x103c0890, /* HP nc6000 */ 1644 + 0x103c0938, /* HP nc4220 */ 1645 + 0x103c099c, /* HP nx6110 */ 1646 + 0x103c0944, /* HP nc6220 */ 1647 + 0x103c0934, /* HP nc8220 */ 1648 + 0x103c006d, /* HP nx9105 */ 1649 + 0x17340088, /* FSC Scenic-W */ 1650 + 0 /* end */ 1651 + }; 1652 + 1653 static void check_ad1981_hp_jack_sense(struct snd_ac97 *ac97) 1654 { 1655 + if (check_list(ac97, ad1981_jacks_whitelist)) 1656 /* enable headphone jack sense */ 1657 snd_ac97_update_bits(ac97, AC97_AD_JACK_SPDIF, 1<<11, 1<<11); 1658 } 1659 1660 int patch_ad1981a(struct snd_ac97 *ac97) ··· 1672 1673 if ((err = patch_build_controls(ac97, &snd_ac97_ad198x_2cmic, 1)) < 0) 1674 return err; 1675 + if (check_list(ac97, ad1981_jacks_blacklist)) 1676 + return 0; 1677 return patch_build_controls(ac97, snd_ac97_ad1981x_jack_sense, 1678 ARRAY_SIZE(snd_ac97_ad1981x_jack_sense)); 1679 } ··· 2210 /* Vref disable (bit12), 1kOhm (bit13) */ 2211 snd_ac97_update_bits(ac97, AC97_ALC850_MISC1, (1<<12)|(1<<13), 2212 shared ? (1<<12) : (1<<13)); 2213 + /* MIC-IN = 1, CENTER-LFE = 5 */ 2214 snd_ac97_update_bits(ac97, AC97_ALC850_JACK_SELECT, 7 << 4, 2215 + shared ? (5<<4) : (1<<4)); 2216 } 2217 2218 static const struct snd_kcontrol_new snd_ac97_controls_alc850[] = {
+1 -1
sound/pci/ali5451/ali5451.c
··· 279 }; 280 281 static struct pci_device_id snd_ali_ids[] = { 282 - {0x10b9, 0x5451, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, 283 {0, } 284 }; 285 MODULE_DEVICE_TABLE(pci, snd_ali_ids);
··· 279 }; 280 281 static struct pci_device_id snd_ali_ids[] = { 282 + {PCI_DEVICE(PCI_VENDOR_ID_AL, PCI_DEVICE_ID_AL_M5451), 0, 0, 0}, 283 {0, } 284 }; 285 MODULE_DEVICE_TABLE(pci, snd_ali_ids);
+1 -1
sound/pci/au88x0/au88x0_eq.c
··· 849 snd_vortex_peaks_get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) 850 { 851 vortex_t *vortex = snd_kcontrol_chip(kcontrol); 852 - int i, count; 853 u16 peaks[20]; 854 855 vortex_Eqlzr_GetAllPeaks(vortex, peaks, &count);
··· 849 snd_vortex_peaks_get(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) 850 { 851 vortex_t *vortex = snd_kcontrol_chip(kcontrol); 852 + int i, count = 0; 853 u16 peaks[20]; 854 855 vortex_Eqlzr_GetAllPeaks(vortex, peaks, &count);
+3 -1
sound/pci/bt87x.c
··· 781 BT_DEVICE(PCI_DEVICE_ID_BROOKTREE_879, 0x0070, 0x13eb, 32000), 782 /* Viewcast Osprey 200 */ 783 BT_DEVICE(PCI_DEVICE_ID_BROOKTREE_878, 0x0070, 0xff01, 44100), 784 { } 785 }; 786 MODULE_DEVICE_TABLE(pci, snd_bt87x_ids); ··· 810 const struct pci_device_id *supported; 811 812 supported = pci_match_device(&driver, pci); 813 - if (supported) 814 return supported->driver_data; 815 816 for (i = 0; i < ARRAY_SIZE(blacklist); ++i)
··· 781 BT_DEVICE(PCI_DEVICE_ID_BROOKTREE_879, 0x0070, 0x13eb, 32000), 782 /* Viewcast Osprey 200 */ 783 BT_DEVICE(PCI_DEVICE_ID_BROOKTREE_878, 0x0070, 0xff01, 44100), 784 + /* AVerMedia Studio No. 103, 203, ...? */ 785 + BT_DEVICE(PCI_DEVICE_ID_BROOKTREE_878, 0x1461, 0x0003, 48000), 786 { } 787 }; 788 MODULE_DEVICE_TABLE(pci, snd_bt87x_ids); ··· 808 const struct pci_device_id *supported; 809 810 supported = pci_match_device(&driver, pci); 811 + if (supported && supported->driver_data > 0) 812 return supported->driver_data; 813 814 for (i = 0; i < ARRAY_SIZE(blacklist); ++i)
+11 -1
sound/pci/ca0106/ca0106_main.c
··· 199 .name = "MSI K8N Diamond MB [SB0438]", 200 .gpio_type = 1, 201 .i2c_adc = 1 } , 202 - /* Shuttle XPC SD31P which has an onboard Creative Labs Sound Blaster Live! 24-bit EAX 203 * high-definition 7.1 audio processor". 204 * Added using info from andrewvegan in alsa bug #1298 205 */ ··· 208 .name = "Shuttle XPC SD31P [SD31P]", 209 .gpio_type = 1, 210 .i2c_adc = 1 } , 211 { .serial = 0, 212 .name = "AudigyLS [Unknown]" } 213 };
··· 199 .name = "MSI K8N Diamond MB [SB0438]", 200 .gpio_type = 1, 201 .i2c_adc = 1 } , 202 + /* Shuttle XPC SD31P which has an onboard Creative Labs 203 + * Sound Blaster Live! 24-bit EAX 204 * high-definition 7.1 audio processor". 205 * Added using info from andrewvegan in alsa bug #1298 206 */ ··· 207 .name = "Shuttle XPC SD31P [SD31P]", 208 .gpio_type = 1, 209 .i2c_adc = 1 } , 210 + /* Shuttle XPC SD11G5 which has an onboard Creative Labs 211 + * Sound Blaster Live! 24-bit EAX 212 + * high-definition 7.1 audio processor". 213 + * Fixes ALSA bug#1600 214 + */ 215 + { .serial = 0x30411297, 216 + .name = "Shuttle XPC SD11G5 [SD11G5]", 217 + .gpio_type = 1, 218 + .i2c_adc = 1 } , 219 { .serial = 0, 220 .name = "AudigyLS [Unknown]" } 221 };
+1 -1
sound/pci/cs46xx/dsp_spos_scb_lib.c
··· 675 if (pass_through) { 676 /* wont work with any other rate than 677 the native DSP rate */ 678 - snd_assert (rate = 48000); 679 680 scb = cs46xx_dsp_create_generic_scb(chip,scb_name,(u32 *)&src_task_scb, 681 dest,"DMAREADER",parent_scb,
··· 675 if (pass_through) { 676 /* wont work with any other rate than 677 the native DSP rate */ 678 + snd_assert (rate == 48000); 679 680 scb = cs46xx_dsp_create_generic_scb(chip,scb_name,(u32 *)&src_task_scb, 681 dest,"DMAREADER",parent_scb,
+4 -2
sound/pci/cs5535audio/cs5535audio.c
··· 46 static int enable[SNDRV_CARDS] = SNDRV_DEFAULT_ENABLE_PNP; 47 48 static struct pci_device_id snd_cs5535audio_ids[] = { 49 - { PCI_VENDOR_ID_NS, PCI_DEVICE_ID_NS_CS5535_AUDIO, PCI_ANY_ID, 50 - PCI_ANY_ID, 0, 0, 0, }, 51 {} 52 }; 53
··· 46 static int enable[SNDRV_CARDS] = SNDRV_DEFAULT_ENABLE_PNP; 47 48 static struct pci_device_id snd_cs5535audio_ids[] = { 49 + { PCI_VENDOR_ID_NS, PCI_DEVICE_ID_NS_CS5535_AUDIO, 50 + PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, 51 + { PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CS5536_AUDIO, 52 + PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, 53 {} 54 }; 55
+6 -4
sound/pci/emu10k1/emumixer.c
··· 759 "Master Mono Playback Volume", 760 "PCM Out Path & Mute", 761 "Mono Output Select", 762 "Surround Playback Switch", 763 "Surround Playback Volume", 764 "Center Playback Switch", ··· 831 } 832 if (emu->audigy) { 833 /* set master volume to 0 dB */ 834 - snd_ac97_write(emu->ac97, AC97_MASTER, 0x0000); 835 /* set capture source to mic */ 836 - snd_ac97_write(emu->ac97, AC97_REC_SEL, 0x0000); 837 c = audigy_remove_ctls; 838 } else { 839 /* ··· 846 snd_emu10k1_ptr_write(emu, AC97SLOT, 0, AC97SLOT_CNTR|AC97SLOT_LFE|AC97SLOT_REAR_LEFT|AC97SLOT_REAR_RIGHT); 847 } 848 /* remove unused AC97 controls */ 849 - snd_ac97_write(emu->ac97, AC97_SURROUND_MASTER, 0x0202); 850 - snd_ac97_write(emu->ac97, AC97_CENTER_LFE_MASTER, 0x0202); 851 c = emu10k1_remove_ctls; 852 } 853 for (; *c; c++)
··· 759 "Master Mono Playback Volume", 760 "PCM Out Path & Mute", 761 "Mono Output Select", 762 + "Front Playback Switch", 763 + "Front Playback Volume", 764 "Surround Playback Switch", 765 "Surround Playback Volume", 766 "Center Playback Switch", ··· 829 } 830 if (emu->audigy) { 831 /* set master volume to 0 dB */ 832 + snd_ac97_write_cache(emu->ac97, AC97_MASTER, 0x0000); 833 /* set capture source to mic */ 834 + snd_ac97_write_cache(emu->ac97, AC97_REC_SEL, 0x0000); 835 c = audigy_remove_ctls; 836 } else { 837 /* ··· 844 snd_emu10k1_ptr_write(emu, AC97SLOT, 0, AC97SLOT_CNTR|AC97SLOT_LFE|AC97SLOT_REAR_LEFT|AC97SLOT_REAR_RIGHT); 845 } 846 /* remove unused AC97 controls */ 847 + snd_ac97_write_cache(emu->ac97, AC97_SURROUND_MASTER, 0x0202); 848 + snd_ac97_write_cache(emu->ac97, AC97_CENTER_LFE_MASTER, 0x0202); 849 c = emu10k1_remove_ctls; 850 } 851 for (; *c; c++)
+2
sound/pci/hda/hda_intel.c
··· 75 "{Intel, ICH6M}," 76 "{Intel, ICH7}," 77 "{Intel, ESB2}," 78 "{ATI, SB450}," 79 "{VIA, VT8251}," 80 "{VIA, VT8237A}," ··· 1587 { 0x8086, 0x2668, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ICH }, /* ICH6 */ 1588 { 0x8086, 0x27d8, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ICH }, /* ICH7 */ 1589 { 0x8086, 0x269a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ICH }, /* ESB2 */ 1590 { 0x1002, 0x437b, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ATI }, /* ATI SB450 */ 1591 { 0x1106, 0x3288, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_VIA }, /* VIA VT8251/VT8237A */ 1592 { 0x1039, 0x7502, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_SIS }, /* SIS966 */
··· 75 "{Intel, ICH6M}," 76 "{Intel, ICH7}," 77 "{Intel, ESB2}," 78 + "{Intel, ICH8}," 79 "{ATI, SB450}," 80 "{VIA, VT8251}," 81 "{VIA, VT8237A}," ··· 1586 { 0x8086, 0x2668, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ICH }, /* ICH6 */ 1587 { 0x8086, 0x27d8, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ICH }, /* ICH7 */ 1588 { 0x8086, 0x269a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ICH }, /* ESB2 */ 1589 + { 0x8086, 0x284b, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ICH }, /* ICH8 */ 1590 { 0x1002, 0x437b, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_ATI }, /* ATI SB450 */ 1591 { 0x1106, 0x3288, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_VIA }, /* VIA VT8251/VT8237A */ 1592 { 0x1039, 0x7502, PCI_ANY_ID, PCI_ANY_ID, 0, 0, AZX_DRIVER_SIS }, /* SIS966 */
+7 -4
sound/pci/hda/patch_realtek.c
··· 1668 { .pci_subvendor = 0x1043, .pci_subdevice = 0x8196, .config = ALC880_6ST }, /* ASUS P5GD1-HVM */ 1669 { .pci_subvendor = 0x1043, .pci_subdevice = 0x81b4, .config = ALC880_6ST }, 1670 { .pci_subvendor = 0x1019, .pci_subdevice = 0xa884, .config = ALC880_6ST }, /* Acer APFV */ 1671 1672 { .modelname = "6stack-digout", .config = ALC880_6ST_DIG }, 1673 { .pci_subvendor = 0x2668, .pci_subdevice = 0x8086, .config = ALC880_6ST_DIG }, ··· 2476 /* LINE-2 is used for line-out in rear */ 2477 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT}, 2478 /* select line-out */ 2479 - {0x15, AC_VERB_SET_CONNECT_SEL, 0x00}, 2480 /* LINE-OUT pin */ 2481 {0x0f, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT}, 2482 /* enable HP */ ··· 2946 */ 2947 static struct hda_board_config alc260_cfg_tbl[] = { 2948 { .modelname = "basic", .config = ALC260_BASIC }, 2949 { .modelname = "hp", .config = ALC260_HP }, 2950 { .pci_subvendor = 0x103c, .pci_subdevice = 0x3010, .config = ALC260_HP }, 2951 { .pci_subvendor = 0x103c, .pci_subdevice = 0x3011, .config = ALC260_HP }, ··· 3417 * configuration and preset 3418 */ 3419 static struct hda_board_config alc882_cfg_tbl[] = { 3420 - { .modelname = "3stack-dig", .config = ALC861_3ST_DIG }, 3421 - { .modelname = "6stack-dig", .config = ALC861_6ST_DIG }, 3422 { .pci_subvendor = 0x1462, .pci_subdevice = 0x6668, .config = ALC882_6ST_DIG }, /* MSI */ 3423 { .pci_subvendor = 0x105b, .pci_subdevice = 0x6668, .config = ALC882_6ST_DIG }, /* Foxconn */ 3424 { .pci_subvendor = 0x1019, .pci_subdevice = 0x6668, .config = ALC882_6ST_DIG }, /* ECS */ 3425 - { .modelname = "auto", .config = ALC861_AUTO }, 3426 {} 3427 }; 3428
··· 1668 { .pci_subvendor = 0x1043, .pci_subdevice = 0x8196, .config = ALC880_6ST }, /* ASUS P5GD1-HVM */ 1669 { .pci_subvendor = 0x1043, .pci_subdevice = 0x81b4, .config = ALC880_6ST }, 1670 { .pci_subvendor = 0x1019, .pci_subdevice = 0xa884, .config = ALC880_6ST }, /* Acer APFV */ 1671 + { .pci_subvendor = 0x1458, .pci_subdevice = 0xa102, .config = ALC880_6ST }, /* Gigabyte K8N51 */ 1672 1673 { .modelname = "6stack-digout", .config = ALC880_6ST_DIG }, 1674 { .pci_subvendor = 0x2668, .pci_subdevice = 0x8086, .config = ALC880_6ST_DIG }, ··· 2475 /* LINE-2 is used for line-out in rear */ 2476 {0x15, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT}, 2477 /* select line-out */ 2478 + {0x0e, AC_VERB_SET_CONNECT_SEL, 0x00}, 2479 /* LINE-OUT pin */ 2480 {0x0f, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT}, 2481 /* enable HP */ ··· 2945 */ 2946 static struct hda_board_config alc260_cfg_tbl[] = { 2947 { .modelname = "basic", .config = ALC260_BASIC }, 2948 + { .pci_subvendor = 0x104d, .pci_subdevice = 0x81bb, 2949 + .config = ALC260_BASIC }, /* Sony VAIO */ 2950 { .modelname = "hp", .config = ALC260_HP }, 2951 { .pci_subvendor = 0x103c, .pci_subdevice = 0x3010, .config = ALC260_HP }, 2952 { .pci_subvendor = 0x103c, .pci_subdevice = 0x3011, .config = ALC260_HP }, ··· 3414 * configuration and preset 3415 */ 3416 static struct hda_board_config alc882_cfg_tbl[] = { 3417 + { .modelname = "3stack-dig", .config = ALC882_3ST_DIG }, 3418 + { .modelname = "6stack-dig", .config = ALC882_6ST_DIG }, 3419 { .pci_subvendor = 0x1462, .pci_subdevice = 0x6668, .config = ALC882_6ST_DIG }, /* MSI */ 3420 { .pci_subvendor = 0x105b, .pci_subdevice = 0x6668, .config = ALC882_6ST_DIG }, /* Foxconn */ 3421 { .pci_subvendor = 0x1019, .pci_subdevice = 0x6668, .config = ALC882_6ST_DIG }, /* ECS */ 3422 + { .modelname = "auto", .config = ALC882_AUTO }, 3423 {} 3424 }; 3425
+1
sound/pci/hda/patch_si3054.c
··· 297 struct hda_codec_preset snd_hda_preset_si3054[] = { 298 { .id = 0x163c3055, .name = "Si3054", .patch = patch_si3054 }, 299 { .id = 0x163c3155, .name = "Si3054", .patch = patch_si3054 }, 300 {} 301 }; 302
··· 297 struct hda_codec_preset snd_hda_preset_si3054[] = { 298 { .id = 0x163c3055, .name = "Si3054", .patch = patch_si3054 }, 299 { .id = 0x163c3155, .name = "Si3054", .patch = patch_si3054 }, 300 + { .id = 0x11c13026, .name = "Si3054", .patch = patch_si3054 }, 301 {} 302 }; 303
+160 -16
sound/pci/hda/patch_sigmatel.c
··· 50 unsigned int surr_switch: 1; 51 unsigned int line_switch: 1; 52 unsigned int mic_switch: 1; 53 54 /* playback */ 55 struct hda_multi_out multiout; 56 - hda_nid_t dac_nids[4]; 57 58 /* capture */ 59 hda_nid_t *adc_nids; ··· 74 75 /* capture source */ 76 struct hda_input_mux *input_mux; 77 - unsigned int cur_mux[2]; 78 79 /* i/o switches */ 80 unsigned int io_switch[2]; ··· 108 0x12, 0x13, 109 }; 110 111 static hda_nid_t stac9200_pin_nids[8] = { 112 0x08, 0x09, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 113 }; ··· 123 static hda_nid_t stac922x_pin_nids[10] = { 124 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 125 0x0f, 0x10, 0x11, 0x15, 0x1b, 126 }; 127 128 static int stac92xx_mux_enum_info(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo) ··· 170 {} 171 }; 172 173 static struct snd_kcontrol_new stac9200_mixer[] = { 174 HDA_CODEC_VOLUME("Master Playback Volume", 0xb, 0, HDA_OUTPUT), 175 HDA_CODEC_MUTE("Master Playback Switch", 0xb, 0, HDA_OUTPUT), ··· 204 .put = stac92xx_mux_enum_put, 205 }, 206 HDA_CODEC_VOLUME("Capture Volume", 0x17, 0x0, HDA_INPUT), 207 HDA_CODEC_VOLUME("Mux Capture Volume", 0x12, 0x0, HDA_OUTPUT), 208 { } /* end */ 209 }; 210 ··· 277 }; 278 279 static unsigned int d945gtp3_pin_configs[10] = { 280 - 0x0221401f, 0x01a19022, 0x01813021, 0x01114010, 281 0x40000100, 0x40000100, 0x40000100, 0x40000100, 282 0x02a19120, 0x40000100, 283 }; 284 285 static unsigned int d945gtp5_pin_configs[10] = { 286 - 0x0221401f, 0x01111012, 0x01813024, 0x01114010, 287 - 0x01a19021, 0x01116011, 0x01452130, 0x40000100, 288 0x02a19320, 0x40000100, 289 }; 290 ··· 311 { .pci_subvendor = PCI_VENDOR_ID_INTEL, 312 .pci_subdevice = 0x0013, 313 .config = STAC_D945GTP5 }, /* Intel D955XBK - 5 Stack */ 314 {} /* terminator */ 315 }; 316 ··· 467 }, 468 }; 469 470 static struct hda_pcm_stream stac92xx_pcm_analog_capture = { 471 .substreams = 2, 472 .channels_min = 2, 473 .channels_max = 2, 474 - .nid = 0x06, /* NID to query formats and rates */ 475 .ops = { 476 .prepare = stac92xx_capture_pcm_prepare, 477 .cleanup = stac92xx_capture_pcm_cleanup ··· 501 info->name = "STAC92xx Analog"; 502 info->stream[SNDRV_PCM_STREAM_PLAYBACK] = stac92xx_pcm_analog_playback; 503 info->stream[SNDRV_PCM_STREAM_CAPTURE] = stac92xx_pcm_analog_capture; 504 505 if (spec->multiout.dig_out_nid || spec->dig_in_nid) { 506 codec->num_pcms++; ··· 667 return 0; 668 } 669 670 /* fill in the dac_nids table from the parsed pin configuration */ 671 static int stac92xx_auto_fill_dac_nids(struct hda_codec *codec, const struct auto_pin_cfg *cfg) 672 { ··· 691 AC_VERB_GET_CONNECT_LIST, 0) & 0xff; 692 } 693 694 - spec->multiout.num_dacs = cfg->line_outs; 695 696 return 0; 697 } ··· 848 stac92xx_auto_set_pinctl(codec, pin, AC_PINCTL_OUT_EN | AC_PINCTL_HP_EN); 849 } 850 851 - static int stac922x_parse_auto_config(struct hda_codec *codec) 852 { 853 struct sigmatel_spec *spec = codec->spec; 854 int err; 855 856 if ((err = snd_hda_parse_pin_def_config(codec, &spec->autocfg, NULL)) < 0) 857 return err; 858 if ((err = stac92xx_add_dyn_out_pins(codec, &spec->autocfg)) < 0) 859 return err; 860 if ((err = stac92xx_auto_fill_dac_nids(codec, &spec->autocfg)) < 0) 861 return err; 862 - if (! spec->autocfg.line_outs && ! spec->autocfg.hp_pin) 863 - return 0; /* can't find valid pin config */ 864 865 if ((err = stac92xx_auto_create_multi_out_ctls(spec, &spec->autocfg)) < 0 || 866 (err = stac92xx_auto_create_hp_ctls(codec, &spec->autocfg)) < 0 || ··· 874 spec->surr_switch = 1; 875 876 if (spec->autocfg.dig_out_pin) { 877 - spec->multiout.dig_out_nid = 0x08; 878 stac92xx_auto_set_pinctl(codec, spec->autocfg.dig_out_pin, AC_PINCTL_OUT_EN); 879 } 880 if (spec->autocfg.dig_in_pin) { 881 - spec->dig_in_nid = 0x09; 882 stac92xx_auto_set_pinctl(codec, spec->autocfg.dig_in_pin, AC_PINCTL_IN_EN); 883 } 884 ··· 923 struct sigmatel_spec *spec = codec->spec; 924 925 snd_hda_sequence_write(codec, spec->init); 926 - 927 - stac92xx_auto_init_multi_out(codec); 928 - stac92xx_auto_init_hp_out(codec); 929 930 return 0; 931 } ··· 1090 1091 spec->multiout.dac_nids = spec->dac_nids; 1092 1093 - err = stac922x_parse_auto_config(codec); 1094 if (err < 0) { 1095 stac92xx_free(codec); 1096 return err; ··· 1152 { .id = 0x83847681, .name = "STAC9220D/9223D A2", .patch = patch_stac922x }, 1153 { .id = 0x83847682, .name = "STAC9221 A2", .patch = patch_stac922x }, 1154 { .id = 0x83847683, .name = "STAC9221D A2", .patch = patch_stac922x }, 1155 {} /* terminator */ 1156 };
··· 50 unsigned int surr_switch: 1; 51 unsigned int line_switch: 1; 52 unsigned int mic_switch: 1; 53 + unsigned int alt_switch: 1; 54 55 /* playback */ 56 struct hda_multi_out multiout; 57 + hda_nid_t dac_nids[5]; 58 59 /* capture */ 60 hda_nid_t *adc_nids; ··· 73 74 /* capture source */ 75 struct hda_input_mux *input_mux; 76 + unsigned int cur_mux[3]; 77 78 /* i/o switches */ 79 unsigned int io_switch[2]; ··· 107 0x12, 0x13, 108 }; 109 110 + static hda_nid_t stac927x_adc_nids[3] = { 111 + 0x07, 0x08, 0x09 112 + }; 113 + 114 + static hda_nid_t stac927x_mux_nids[3] = { 115 + 0x15, 0x16, 0x17 116 + }; 117 + 118 static hda_nid_t stac9200_pin_nids[8] = { 119 0x08, 0x09, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 120 }; ··· 114 static hda_nid_t stac922x_pin_nids[10] = { 115 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 116 0x0f, 0x10, 0x11, 0x15, 0x1b, 117 + }; 118 + 119 + static hda_nid_t stac927x_pin_nids[14] = { 120 + 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 121 + 0x0f, 0x10, 0x11, 0x12, 0x13, 122 + 0x14, 0x21, 0x22, 0x23, 123 }; 124 125 static int stac92xx_mux_enum_info(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo) ··· 155 {} 156 }; 157 158 + static struct hda_verb stac927x_core_init[] = { 159 + /* set master volume and direct control */ 160 + { 0x24, AC_VERB_SET_VOLUME_KNOB_CONTROL, 0xff}, 161 + {} 162 + }; 163 + 164 static struct snd_kcontrol_new stac9200_mixer[] = { 165 HDA_CODEC_VOLUME("Master Playback Volume", 0xb, 0, HDA_OUTPUT), 166 HDA_CODEC_MUTE("Master Playback Switch", 0xb, 0, HDA_OUTPUT), ··· 183 .put = stac92xx_mux_enum_put, 184 }, 185 HDA_CODEC_VOLUME("Capture Volume", 0x17, 0x0, HDA_INPUT), 186 + HDA_CODEC_MUTE("Capture Switch", 0x17, 0x0, HDA_INPUT), 187 HDA_CODEC_VOLUME("Mux Capture Volume", 0x12, 0x0, HDA_OUTPUT), 188 + { } /* end */ 189 + }; 190 + 191 + static snd_kcontrol_new_t stac927x_mixer[] = { 192 + { 193 + .iface = SNDRV_CTL_ELEM_IFACE_MIXER, 194 + .name = "Input Source", 195 + .count = 1, 196 + .info = stac92xx_mux_enum_info, 197 + .get = stac92xx_mux_enum_get, 198 + .put = stac92xx_mux_enum_put, 199 + }, 200 + HDA_CODEC_VOLUME("InMux Capture Volume", 0x15, 0x0, HDA_OUTPUT), 201 + HDA_CODEC_VOLUME("InVol Capture Volume", 0x18, 0x0, HDA_INPUT), 202 + HDA_CODEC_MUTE("ADCMux Capture Switch", 0x1b, 0x0, HDA_OUTPUT), 203 { } /* end */ 204 }; 205 ··· 240 }; 241 242 static unsigned int d945gtp3_pin_configs[10] = { 243 + 0x0221401f, 0x01a19022, 0x01813021, 0x01014010, 244 0x40000100, 0x40000100, 0x40000100, 0x40000100, 245 0x02a19120, 0x40000100, 246 }; 247 248 static unsigned int d945gtp5_pin_configs[10] = { 249 + 0x0221401f, 0x01011012, 0x01813024, 0x01014010, 250 + 0x01a19021, 0x01016011, 0x01452130, 0x40000100, 251 0x02a19320, 0x40000100, 252 }; 253 ··· 274 { .pci_subvendor = PCI_VENDOR_ID_INTEL, 275 .pci_subdevice = 0x0013, 276 .config = STAC_D945GTP5 }, /* Intel D955XBK - 5 Stack */ 277 + { .pci_subvendor = PCI_VENDOR_ID_INTEL, 278 + .pci_subdevice = 0x0417, 279 + .config = STAC_D945GTP5 }, /* Intel D975XBK - 5 Stack */ 280 + {} /* terminator */ 281 + }; 282 + 283 + static unsigned int ref927x_pin_configs[14] = { 284 + 0x01813122, 0x01a19021, 0x01014010, 0x01016011, 285 + 0x01012012, 0x01011014, 0x40000100, 0x40000100, 286 + 0x40000100, 0x40000100, 0x40000100, 0x01441030, 287 + 0x01c41030, 0x40000100, 288 + }; 289 + 290 + static unsigned int *stac927x_brd_tbl[] = { 291 + ref927x_pin_configs, 292 + }; 293 + 294 + static struct hda_board_config stac927x_cfg_tbl[] = { 295 + { .modelname = "ref", 296 + .pci_subvendor = PCI_VENDOR_ID_INTEL, 297 + .pci_subdevice = 0x2668, /* DFI LanParty */ 298 + .config = STAC_REF }, /* SigmaTel reference board */ 299 {} /* terminator */ 300 }; 301 ··· 408 }, 409 }; 410 411 + static struct hda_pcm_stream stac92xx_pcm_analog_alt_playback = { 412 + .substreams = 1, 413 + .channels_min = 2, 414 + .channels_max = 2, 415 + .nid = 0x06, /* NID to query formats and rates */ 416 + .ops = { 417 + .open = stac92xx_playback_pcm_open, 418 + .prepare = stac92xx_playback_pcm_prepare, 419 + .cleanup = stac92xx_playback_pcm_cleanup 420 + }, 421 + }; 422 + 423 static struct hda_pcm_stream stac92xx_pcm_analog_capture = { 424 .substreams = 2, 425 .channels_min = 2, 426 .channels_max = 2, 427 + /* NID is set in stac92xx_build_pcms */ 428 .ops = { 429 .prepare = stac92xx_capture_pcm_prepare, 430 .cleanup = stac92xx_capture_pcm_cleanup ··· 430 info->name = "STAC92xx Analog"; 431 info->stream[SNDRV_PCM_STREAM_PLAYBACK] = stac92xx_pcm_analog_playback; 432 info->stream[SNDRV_PCM_STREAM_CAPTURE] = stac92xx_pcm_analog_capture; 433 + info->stream[SNDRV_PCM_STREAM_CAPTURE].nid = spec->adc_nids[0]; 434 + 435 + if (spec->alt_switch) { 436 + codec->num_pcms++; 437 + info++; 438 + info->name = "STAC92xx Analog Alt"; 439 + info->stream[SNDRV_PCM_STREAM_PLAYBACK] = stac92xx_pcm_analog_alt_playback; 440 + } 441 442 if (spec->multiout.dig_out_nid || spec->dig_in_nid) { 443 codec->num_pcms++; ··· 588 return 0; 589 } 590 591 + /* 592 + * XXX The line_out pin widget connection list may not be set to the 593 + * desired DAC nid. This is the case on 927x where ports A and B can 594 + * be routed to several DACs. 595 + * 596 + * This requires an analysis of the line-out/hp pin configuration 597 + * to provide a best fit for pin/DAC configurations that are routable. 598 + * For now, 927x DAC4 is not supported and 927x DAC1 output to ports 599 + * A and B is not supported. 600 + */ 601 /* fill in the dac_nids table from the parsed pin configuration */ 602 static int stac92xx_auto_fill_dac_nids(struct hda_codec *codec, const struct auto_pin_cfg *cfg) 603 { ··· 602 AC_VERB_GET_CONNECT_LIST, 0) & 0xff; 603 } 604 605 + if (cfg->line_outs) 606 + spec->multiout.num_dacs = cfg->line_outs; 607 + else if (cfg->hp_pin) { 608 + spec->multiout.dac_nids[0] = snd_hda_codec_read(codec, cfg->hp_pin, 0, 609 + AC_VERB_GET_CONNECT_LIST, 0) & 0xff; 610 + spec->multiout.num_dacs = 1; 611 + } 612 613 return 0; 614 } ··· 753 stac92xx_auto_set_pinctl(codec, pin, AC_PINCTL_OUT_EN | AC_PINCTL_HP_EN); 754 } 755 756 + static int stac92xx_parse_auto_config(struct hda_codec *codec, hda_nid_t dig_out, hda_nid_t dig_in) 757 { 758 struct sigmatel_spec *spec = codec->spec; 759 int err; 760 761 if ((err = snd_hda_parse_pin_def_config(codec, &spec->autocfg, NULL)) < 0) 762 return err; 763 + if (! spec->autocfg.line_outs && ! spec->autocfg.hp_pin) 764 + return 0; /* can't find valid pin config */ 765 + stac92xx_auto_init_multi_out(codec); 766 + stac92xx_auto_init_hp_out(codec); 767 if ((err = stac92xx_add_dyn_out_pins(codec, &spec->autocfg)) < 0) 768 return err; 769 if ((err = stac92xx_auto_fill_dac_nids(codec, &spec->autocfg)) < 0) 770 return err; 771 772 if ((err = stac92xx_auto_create_multi_out_ctls(spec, &spec->autocfg)) < 0 || 773 (err = stac92xx_auto_create_hp_ctls(codec, &spec->autocfg)) < 0 || ··· 777 spec->surr_switch = 1; 778 779 if (spec->autocfg.dig_out_pin) { 780 + spec->multiout.dig_out_nid = dig_out; 781 stac92xx_auto_set_pinctl(codec, spec->autocfg.dig_out_pin, AC_PINCTL_OUT_EN); 782 } 783 if (spec->autocfg.dig_in_pin) { 784 + spec->dig_in_nid = dig_in; 785 stac92xx_auto_set_pinctl(codec, spec->autocfg.dig_in_pin, AC_PINCTL_IN_EN); 786 } 787 ··· 826 struct sigmatel_spec *spec = codec->spec; 827 828 snd_hda_sequence_write(codec, spec->init); 829 830 return 0; 831 } ··· 996 997 spec->multiout.dac_nids = spec->dac_nids; 998 999 + err = stac92xx_parse_auto_config(codec, 0x08, 0x09); 1000 + if (err < 0) { 1001 + stac92xx_free(codec); 1002 + return err; 1003 + } 1004 + 1005 + codec->patch_ops = stac92xx_patch_ops; 1006 + 1007 + return 0; 1008 + } 1009 + 1010 + static int patch_stac927x(struct hda_codec *codec) 1011 + { 1012 + struct sigmatel_spec *spec; 1013 + int err; 1014 + 1015 + spec = kzalloc(sizeof(*spec), GFP_KERNEL); 1016 + if (spec == NULL) 1017 + return -ENOMEM; 1018 + 1019 + codec->spec = spec; 1020 + spec->board_config = snd_hda_check_board_config(codec, stac927x_cfg_tbl); 1021 + if (spec->board_config < 0) 1022 + snd_printdd(KERN_INFO "hda_codec: Unknown model for STAC927x, using BIOS defaults\n"); 1023 + else { 1024 + spec->num_pins = 14; 1025 + spec->pin_nids = stac927x_pin_nids; 1026 + spec->pin_configs = stac927x_brd_tbl[spec->board_config]; 1027 + stac92xx_set_config_regs(codec); 1028 + } 1029 + 1030 + spec->adc_nids = stac927x_adc_nids; 1031 + spec->mux_nids = stac927x_mux_nids; 1032 + spec->num_muxes = 3; 1033 + 1034 + spec->init = stac927x_core_init; 1035 + spec->mixer = stac927x_mixer; 1036 + 1037 + spec->multiout.dac_nids = spec->dac_nids; 1038 + 1039 + err = stac92xx_parse_auto_config(codec, 0x1e, 0x20); 1040 if (err < 0) { 1041 stac92xx_free(codec); 1042 return err; ··· 1018 { .id = 0x83847681, .name = "STAC9220D/9223D A2", .patch = patch_stac922x }, 1019 { .id = 0x83847682, .name = "STAC9221 A2", .patch = patch_stac922x }, 1020 { .id = 0x83847683, .name = "STAC9221D A2", .patch = patch_stac922x }, 1021 + { .id = 0x83847620, .name = "STAC9274", .patch = patch_stac927x }, 1022 + { .id = 0x83847621, .name = "STAC9274D", .patch = patch_stac927x }, 1023 + { .id = 0x83847622, .name = "STAC9273X", .patch = patch_stac927x }, 1024 + { .id = 0x83847623, .name = "STAC9273D", .patch = patch_stac927x }, 1025 + { .id = 0x83847624, .name = "STAC9272X", .patch = patch_stac927x }, 1026 + { .id = 0x83847625, .name = "STAC9272D", .patch = patch_stac927x }, 1027 + { .id = 0x83847626, .name = "STAC9271X", .patch = patch_stac927x }, 1028 + { .id = 0x83847627, .name = "STAC9271D", .patch = patch_stac927x }, 1029 + { .id = 0x83847628, .name = "STAC9274X5NH", .patch = patch_stac927x }, 1030 + { .id = 0x83847629, .name = "STAC9274D5NH", .patch = patch_stac927x }, 1031 {} /* terminator */ 1032 };
+8 -7
sound/pci/intel8x0.c
··· 427 { 0x10de, 0x008a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* CK8 */ 428 { 0x10de, 0x00da, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE3 */ 429 { 0x10de, 0x00ea, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* CK8S */ 430 { 0x1022, 0x746d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD8111 */ 431 { 0x1022, 0x7445, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD768 */ 432 { 0x10b9, 0x5455, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_ALI }, /* Ali5455 */ ··· 1806 }, 1807 { 1808 .subvendor = 0x1028, 1809 .subdevice = 0x0163, 1810 .name = "Dell Unknown", /* STAC9750/51 */ 1811 .type = AC97_TUNE_HP_ONLY ··· 1854 }, 1855 { 1856 .subvendor = 0x103c, 1857 - .subdevice = 0x099c, 1858 - .name = "HP nx6110", /* AD1981B */ 1859 - .type = AC97_TUNE_HP_ONLY 1860 - }, 1861 - { 1862 - .subvendor = 0x103c, 1863 .subdevice = 0x129d, 1864 .name = "HP xw8000", 1865 .type = AC97_TUNE_HP_ONLY ··· 1867 { 1868 .subvendor = 0x103c, 1869 .subdevice = 0x099c, 1870 - .name = "HP nc6120", 1871 .type = AC97_TUNE_HP_MUTE_LED 1872 }, 1873 {
··· 427 { 0x10de, 0x008a, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* CK8 */ 428 { 0x10de, 0x00da, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* NFORCE3 */ 429 { 0x10de, 0x00ea, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* CK8S */ 430 + { 0x10de, 0x026b, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE }, /* MCP51 */ 431 { 0x1022, 0x746d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD8111 */ 432 { 0x1022, 0x7445, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL }, /* AMD768 */ 433 { 0x10b9, 0x5455, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_ALI }, /* Ali5455 */ ··· 1805 }, 1806 { 1807 .subvendor = 0x1028, 1808 + .subdevice = 0x0151, 1809 + .name = "Dell Optiplex GX270", /* AD1981B */ 1810 + .type = AC97_TUNE_HP_ONLY 1811 + }, 1812 + { 1813 + .subvendor = 0x1028, 1814 .subdevice = 0x0163, 1815 .name = "Dell Unknown", /* STAC9750/51 */ 1816 .type = AC97_TUNE_HP_ONLY ··· 1847 }, 1848 { 1849 .subvendor = 0x103c, 1850 .subdevice = 0x129d, 1851 .name = "HP xw8000", 1852 .type = AC97_TUNE_HP_ONLY ··· 1866 { 1867 .subvendor = 0x103c, 1868 .subdevice = 0x099c, 1869 + .name = "HP nx6110/nc6120", 1870 .type = AC97_TUNE_HP_MUTE_LED 1871 }, 1872 {
+5 -4
sound/pci/pcxhr/pcxhr.c
··· 454 is_capture = (subs->stream == SNDRV_PCM_STREAM_CAPTURE); 455 stream_num = is_capture ? 0 : subs->number; 456 457 - snd_printdd("pcxhr_update_r_buffer(pcm%c%d) : addr(%p) bytes(%x) subs(%d)\n", 458 is_capture ? 'c' : 'p', 459 chip->chip_idx, (void*)subs->runtime->dma_addr, 460 subs->runtime->dma_bytes, subs->number); ··· 744 /* only the first stream can choose the sample rate */ 745 /* the further opened streams will be limited to its frequency (see open) */ 746 /* set the clock only once (first stream) */ 747 - if (mgr->sample_rate == 0) { 748 err = pcxhr_set_clock(mgr, subs->runtime->rate); 749 if (err) 750 break; 751 mgr->sample_rate = subs->runtime->rate; 752 - 753 - err = pcxhr_hardware_timer(mgr, 1); /* start the DSP-timer */ 754 } 755 } while(0); /* do only once (so we can use break instead of goto) */ 756
··· 454 is_capture = (subs->stream == SNDRV_PCM_STREAM_CAPTURE); 455 stream_num = is_capture ? 0 : subs->number; 456 457 + snd_printdd("pcxhr_update_r_buffer(pcm%c%d) : addr(%p) bytes(%zx) subs(%d)\n", 458 is_capture ? 'c' : 'p', 459 chip->chip_idx, (void*)subs->runtime->dma_addr, 460 subs->runtime->dma_bytes, subs->number); ··· 744 /* only the first stream can choose the sample rate */ 745 /* the further opened streams will be limited to its frequency (see open) */ 746 /* set the clock only once (first stream) */ 747 + if (mgr->sample_rate != subs->runtime->rate) { 748 err = pcxhr_set_clock(mgr, subs->runtime->rate); 749 if (err) 750 break; 751 + if (mgr->sample_rate == 0) 752 + /* start the DSP-timer */ 753 + err = pcxhr_hardware_timer(mgr, 1); 754 mgr->sample_rate = subs->runtime->rate; 755 } 756 } while(0); /* do only once (so we can use break instead of goto) */ 757
+3 -3
sound/pci/rme9652/hdspm.c
··· 3324 snd_dma_pci_data(hdspm->pci), 3325 wanted, 3326 wanted)) < 0) { 3327 - snd_printdd("Could not preallocate %d Bytes\n", wanted); 3328 3329 return err; 3330 } else 3331 - snd_printdd(" Preallocated %d Bytes\n", wanted); 3332 3333 return 0; 3334 } ··· 3510 3511 hdspm->monitor_outs = enable_monitor; 3512 3513 - snd_printdd("kmalloc Mixer memory of %d Bytes\n", 3514 sizeof(struct hdspm_mixer)); 3515 if ((hdspm->mixer = kmalloc(sizeof(struct hdspm_mixer), GFP_KERNEL)) 3516 == NULL) {
··· 3324 snd_dma_pci_data(hdspm->pci), 3325 wanted, 3326 wanted)) < 0) { 3327 + snd_printdd("Could not preallocate %zd Bytes\n", wanted); 3328 3329 return err; 3330 } else 3331 + snd_printdd(" Preallocated %zd Bytes\n", wanted); 3332 3333 return 0; 3334 } ··· 3510 3511 hdspm->monitor_outs = enable_monitor; 3512 3513 + snd_printdd("kmalloc Mixer memory of %zd Bytes\n", 3514 sizeof(struct hdspm_mixer)); 3515 if ((hdspm->mixer = kmalloc(sizeof(struct hdspm_mixer), GFP_KERNEL)) 3516 == NULL) {
+5 -3
sound/pci/trident/trident.c
··· 64 MODULE_PARM_DESC(wavetable_size, "Maximum memory size in kB for wavetable synth."); 65 66 static struct pci_device_id snd_trident_ids[] = { 67 - { 0x1023, 0x2000, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* Trident 4DWave DX PCI Audio */ 68 - { 0x1023, 0x2001, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* Trident 4DWave NX PCI Audio */ 69 - { 0x1039, 0x7018, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0, }, /* SiS SI7018 PCI Audio */ 70 { 0, } 71 }; 72
··· 64 MODULE_PARM_DESC(wavetable_size, "Maximum memory size in kB for wavetable synth."); 65 66 static struct pci_device_id snd_trident_ids[] = { 67 + {PCI_DEVICE(PCI_VENDOR_ID_TRIDENT, PCI_DEVICE_ID_TRIDENT_4DWAVE_DX), 68 + PCI_CLASS_MULTIMEDIA_AUDIO << 8, 0xffff00, 0}, 69 + {PCI_DEVICE(PCI_VENDOR_ID_TRIDENT, PCI_DEVICE_ID_TRIDENT_4DWAVE_NX), 70 + 0, 0, 0}, 71 + {PCI_DEVICE(PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_7018), 0, 0, 0}, 72 { 0, } 73 }; 74
+5
sound/pci/via82xx.c
··· 2340 { .subvendor = 0x1043, .subdevice = 0x80b0, .action = VIA_DXS_NO_VRA }, /* ASUS A7V600 & K8V*/ 2341 { .subvendor = 0x1043, .subdevice = 0x810d, .action = VIA_DXS_SRC }, /* ASUS */ 2342 { .subvendor = 0x1043, .subdevice = 0x812a, .action = VIA_DXS_SRC }, /* ASUS A8V Deluxe */ 2343 { .subvendor = 0x1071, .subdevice = 0x8375, .action = VIA_DXS_NO_VRA }, /* Vobis/Yakumo/Mitac notebook */ 2344 { .subvendor = 0x1071, .subdevice = 0x8399, .action = VIA_DXS_NO_VRA }, /* Umax AB 595T (VIA K8N800A - VT8237) */ 2345 { .subvendor = 0x10cf, .subdevice = 0x118e, .action = VIA_DXS_ENABLE }, /* FSC laptop */ ··· 2359 { .subvendor = 0x1462, .subdevice = 0x7023, .action = VIA_DXS_NO_VRA }, /* MSI K8T Neo2-FI */ 2360 { .subvendor = 0x1462, .subdevice = 0x7120, .action = VIA_DXS_ENABLE }, /* MSI KT4V */ 2361 { .subvendor = 0x1462, .subdevice = 0x7142, .action = VIA_DXS_ENABLE }, /* MSI K8MM-V */ 2362 { .subvendor = 0x147b, .subdevice = 0x1401, .action = VIA_DXS_ENABLE }, /* ABIT KD7(-RAID) */ 2363 { .subvendor = 0x147b, .subdevice = 0x1411, .action = VIA_DXS_ENABLE }, /* ABIT VA-20 */ 2364 { .subvendor = 0x147b, .subdevice = 0x1413, .action = VIA_DXS_ENABLE }, /* ABIT KV8 Pro */ ··· 2373 { .subvendor = 0x161f, .subdevice = 0x2032, .action = VIA_DXS_48K }, /* m680x machines */ 2374 { .subvendor = 0x1631, .subdevice = 0xe004, .action = VIA_DXS_ENABLE }, /* Easy Note 3174, Packard Bell */ 2375 { .subvendor = 0x1695, .subdevice = 0x3005, .action = VIA_DXS_ENABLE }, /* EPoX EP-8K9A */ 2376 { .subvendor = 0x1849, .subdevice = 0x3059, .action = VIA_DXS_NO_VRA }, /* ASRock K7VM2 */ 2377 { .subvendor = 0x1849, .subdevice = 0x9761, .action = VIA_DXS_SRC }, /* ASRock mobo(?) */ 2378 { .subvendor = 0x1919, .subdevice = 0x200a, .action = VIA_DXS_NO_VRA }, /* Soltek SL-K8Tpro-939 */
··· 2340 { .subvendor = 0x1043, .subdevice = 0x80b0, .action = VIA_DXS_NO_VRA }, /* ASUS A7V600 & K8V*/ 2341 { .subvendor = 0x1043, .subdevice = 0x810d, .action = VIA_DXS_SRC }, /* ASUS */ 2342 { .subvendor = 0x1043, .subdevice = 0x812a, .action = VIA_DXS_SRC }, /* ASUS A8V Deluxe */ 2343 + { .subvendor = 0x1043, .subdevice = 0x8174, .action = VIA_DXS_SRC }, /* ASUS */ 2344 { .subvendor = 0x1071, .subdevice = 0x8375, .action = VIA_DXS_NO_VRA }, /* Vobis/Yakumo/Mitac notebook */ 2345 { .subvendor = 0x1071, .subdevice = 0x8399, .action = VIA_DXS_NO_VRA }, /* Umax AB 595T (VIA K8N800A - VT8237) */ 2346 { .subvendor = 0x10cf, .subdevice = 0x118e, .action = VIA_DXS_ENABLE }, /* FSC laptop */ ··· 2358 { .subvendor = 0x1462, .subdevice = 0x7023, .action = VIA_DXS_NO_VRA }, /* MSI K8T Neo2-FI */ 2359 { .subvendor = 0x1462, .subdevice = 0x7120, .action = VIA_DXS_ENABLE }, /* MSI KT4V */ 2360 { .subvendor = 0x1462, .subdevice = 0x7142, .action = VIA_DXS_ENABLE }, /* MSI K8MM-V */ 2361 + { .subvendor = 0x1462, .subdevice = 0xb012, .action = VIA_DXS_SRC }, /* P4M800/VIA8237R */ 2362 { .subvendor = 0x147b, .subdevice = 0x1401, .action = VIA_DXS_ENABLE }, /* ABIT KD7(-RAID) */ 2363 { .subvendor = 0x147b, .subdevice = 0x1411, .action = VIA_DXS_ENABLE }, /* ABIT VA-20 */ 2364 { .subvendor = 0x147b, .subdevice = 0x1413, .action = VIA_DXS_ENABLE }, /* ABIT KV8 Pro */ ··· 2371 { .subvendor = 0x161f, .subdevice = 0x2032, .action = VIA_DXS_48K }, /* m680x machines */ 2372 { .subvendor = 0x1631, .subdevice = 0xe004, .action = VIA_DXS_ENABLE }, /* Easy Note 3174, Packard Bell */ 2373 { .subvendor = 0x1695, .subdevice = 0x3005, .action = VIA_DXS_ENABLE }, /* EPoX EP-8K9A */ 2374 + { .subvendor = 0x1695, .subdevice = 0x300e, .action = VIA_DXS_SRC }, /* EPoX 9HEAI */ 2375 + { .subvendor = 0x16f3, .subdevice = 0x6405, .action = VIA_DXS_SRC }, /* Jetway K8M8MS */ 2376 + { .subvendor = 0x1734, .subdevice = 0x1093, .action = VIA_DXS_SRC }, /* FSC */ 2377 { .subvendor = 0x1849, .subdevice = 0x3059, .action = VIA_DXS_NO_VRA }, /* ASRock K7VM2 */ 2378 { .subvendor = 0x1849, .subdevice = 0x9761, .action = VIA_DXS_SRC }, /* ASRock mobo(?) */ 2379 { .subvendor = 0x1919, .subdevice = 0x200a, .action = VIA_DXS_NO_VRA }, /* Soltek SL-K8Tpro-939 */
+2
sound/pci/ymfpci/ymfpci_main.c
··· 1229 spin_lock_irq(&chip->reg_lock); 1230 ucontrol->value.iec958.status[0] = (chip->spdif_bits >> 0) & 0xff; 1231 ucontrol->value.iec958.status[1] = (chip->spdif_bits >> 8) & 0xff; 1232 spin_unlock_irq(&chip->reg_lock); 1233 return 0; 1234 } ··· 1304 spin_lock_irq(&chip->reg_lock); 1305 ucontrol->value.iec958.status[0] = (chip->spdif_pcm_bits >> 0) & 0xff; 1306 ucontrol->value.iec958.status[1] = (chip->spdif_pcm_bits >> 8) & 0xff; 1307 spin_unlock_irq(&chip->reg_lock); 1308 return 0; 1309 }
··· 1229 spin_lock_irq(&chip->reg_lock); 1230 ucontrol->value.iec958.status[0] = (chip->spdif_bits >> 0) & 0xff; 1231 ucontrol->value.iec958.status[1] = (chip->spdif_bits >> 8) & 0xff; 1232 + ucontrol->value.iec958.status[3] = IEC958_AES3_CON_FS_48000; 1233 spin_unlock_irq(&chip->reg_lock); 1234 return 0; 1235 } ··· 1303 spin_lock_irq(&chip->reg_lock); 1304 ucontrol->value.iec958.status[0] = (chip->spdif_pcm_bits >> 0) & 0xff; 1305 ucontrol->value.iec958.status[1] = (chip->spdif_pcm_bits >> 8) & 0xff; 1306 + ucontrol->value.iec958.status[3] = IEC958_AES3_CON_FS_48000; 1307 spin_unlock_irq(&chip->reg_lock); 1308 return 0; 1309 }
+24 -7
sound/usb/usbaudio.c
··· 478 /* 479 * Prepare urb for streaming before playback starts. 480 * 481 - * We don't care about (or have) any data, so we just send a transfer delimiter. 482 */ 483 static int prepare_startup_playback_urb(struct snd_usb_substream *subs, 484 struct snd_pcm_runtime *runtime, 485 struct urb *urb) 486 { 487 - unsigned int i; 488 struct snd_urb_ctx *ctx = urb->context; 489 490 urb->dev = ctx->subs->dev; 491 urb->number_of_packets = subs->packs_per_ms; 492 for (i = 0; i < subs->packs_per_ms; ++i) { 493 - urb->iso_frame_desc[i].offset = 0; 494 - urb->iso_frame_desc[i].length = 0; 495 } 496 - urb->transfer_buffer_length = 0; 497 return 0; 498 } 499 ··· 2493 if (err < 0) 2494 return err; 2495 #if 1 2496 - /* FIXME: temporary hack for extigy/audigy 2 nx */ 2497 /* extigy apparently supports sample rates other than 48k 2498 * but not in ordinary way. so we enable only 48k atm. 2499 */ 2500 if (chip->usb_id == USB_ID(0x041e, 0x3000) || 2501 - chip->usb_id == USB_ID(0x041e, 0x3020)) { 2502 if (fmt[3] == USB_FORMAT_TYPE_I && 2503 fp->rates != SNDRV_PCM_RATE_48000 && 2504 fp->rates != SNDRV_PCM_RATE_96000)
··· 478 /* 479 * Prepare urb for streaming before playback starts. 480 * 481 + * We don't yet have data, so we send a frame of silence. 482 */ 483 static int prepare_startup_playback_urb(struct snd_usb_substream *subs, 484 struct snd_pcm_runtime *runtime, 485 struct urb *urb) 486 { 487 + unsigned int i, offs, counts; 488 struct snd_urb_ctx *ctx = urb->context; 489 + int stride = runtime->frame_bits >> 3; 490 491 + offs = 0; 492 urb->dev = ctx->subs->dev; 493 urb->number_of_packets = subs->packs_per_ms; 494 for (i = 0; i < subs->packs_per_ms; ++i) { 495 + /* calculate the size of a packet */ 496 + if (subs->fill_max) 497 + counts = subs->maxframesize; /* fixed */ 498 + else { 499 + subs->phase = (subs->phase & 0xffff) 500 + + (subs->freqm << subs->datainterval); 501 + counts = subs->phase >> 16; 502 + if (counts > subs->maxframesize) 503 + counts = subs->maxframesize; 504 + } 505 + urb->iso_frame_desc[i].offset = offs * stride; 506 + urb->iso_frame_desc[i].length = counts * stride; 507 + offs += counts; 508 } 509 + urb->transfer_buffer_length = offs * stride; 510 + memset(urb->transfer_buffer, 511 + subs->cur_audiofmt->format == SNDRV_PCM_FORMAT_U8 ? 0x80 : 0, 512 + offs * stride); 513 return 0; 514 } 515 ··· 2477 if (err < 0) 2478 return err; 2479 #if 1 2480 + /* FIXME: temporary hack for extigy/audigy 2 nx/zs */ 2481 /* extigy apparently supports sample rates other than 48k 2482 * but not in ordinary way. so we enable only 48k atm. 2483 */ 2484 if (chip->usb_id == USB_ID(0x041e, 0x3000) || 2485 + chip->usb_id == USB_ID(0x041e, 0x3020) || 2486 + chip->usb_id == USB_ID(0x041e, 0x3061)) { 2487 if (fmt[3] == USB_FORMAT_TYPE_I && 2488 fp->rates != SNDRV_PCM_RATE_48000 && 2489 fp->rates != SNDRV_PCM_RATE_96000)