aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorSteve French <sfrench@us.ibm.com>2008-03-01 13:29:55 -0500
committerSteve French <sfrench@us.ibm.com>2008-03-01 13:29:55 -0500
commit0dbd888936a23514716b8d944775bc56f731363a (patch)
treea2c60cdc45bdcbed47680731fa8188bffe58c098 /sound
parent0b442d2c28479332610c46e1a74e5638ab63a97d (diff)
parentd395991c117d43bfca97101a931a41d062a93852 (diff)
Merge branch 'master' of /pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'sound')
-rw-r--r--sound/drivers/opl3/opl3_synth.c8
-rw-r--r--sound/isa/sb/sb8_main.c2
-rw-r--r--sound/pci/bt87x.c9
-rw-r--r--sound/pci/hda/hda_codec.c14
-rw-r--r--sound/pci/hda/hda_intel.c23
-rw-r--r--sound/pci/hda/hda_proc.c3
-rw-r--r--sound/pci/hda/patch_analog.c8
-rw-r--r--sound/pci/hda/patch_conexant.c12
-rw-r--r--sound/pci/hda/patch_realtek.c30
-rw-r--r--sound/pci/ice1712/phase.c2
-rw-r--r--sound/pci/ice1712/revo.c2
-rw-r--r--sound/pci/intel8x0.c12
-rw-r--r--sound/pci/oxygen/hifier.c1
-rw-r--r--sound/pci/oxygen/oxygen.c35
-rw-r--r--sound/pci/oxygen/oxygen_lib.c10
-rw-r--r--sound/pci/oxygen/oxygen_pcm.c2
-rw-r--r--sound/pci/oxygen/virtuoso.c1
-rw-r--r--sound/pci/rme9652/hdsp.c7
-rw-r--r--sound/soc/codecs/tlv320aic3x.c4
-rw-r--r--sound/soc/codecs/wm9712.c3
-rw-r--r--sound/soc/fsl/mpc8610_hpcd.c2
-rw-r--r--sound/soc/pxa/corgi.c6
-rw-r--r--sound/soc/pxa/poodle.c3
-rw-r--r--sound/soc/pxa/spitz.c3
-rw-r--r--sound/soc/pxa/tosa.c3
-rw-r--r--sound/usb/caiaq/caiaq-device.c6
-rw-r--r--sound/usb/usbaudio.c38
-rw-r--r--sound/usb/usbmidi.c19
28 files changed, 210 insertions, 58 deletions
diff --git a/sound/drivers/opl3/opl3_synth.c b/sound/drivers/opl3/opl3_synth.c
index a7bf7a4b1f85..fb64c890109b 100644
--- a/sound/drivers/opl3/opl3_synth.c
+++ b/sound/drivers/opl3/opl3_synth.c
@@ -22,6 +22,10 @@
22#include <sound/opl3.h> 22#include <sound/opl3.h>
23#include <sound/asound_fm.h> 23#include <sound/asound_fm.h>
24 24
25#if defined(CONFIG_SND_SEQUENCER) || defined(CONFIG_SND_SEQUENCER_MODULE)
26#define OPL3_SUPPORT_SYNTH
27#endif
28
25/* 29/*
26 * There is 18 possible 2 OP voices 30 * There is 18 possible 2 OP voices
27 * (9 in the left and 9 in the right). 31 * (9 in the left and 9 in the right).
@@ -155,9 +159,11 @@ int snd_opl3_ioctl(struct snd_hwdep * hw, struct file *file,
155#endif 159#endif
156 return snd_opl3_set_connection(opl3, (int) arg); 160 return snd_opl3_set_connection(opl3, (int) arg);
157 161
162#ifdef OPL3_SUPPORT_SYNTH
158 case SNDRV_DM_FM_IOCTL_CLEAR_PATCHES: 163 case SNDRV_DM_FM_IOCTL_CLEAR_PATCHES:
159 snd_opl3_clear_patches(opl3); 164 snd_opl3_clear_patches(opl3);
160 return 0; 165 return 0;
166#endif
161 167
162#ifdef CONFIG_SND_DEBUG 168#ifdef CONFIG_SND_DEBUG
163 default: 169 default:
@@ -178,6 +184,7 @@ int snd_opl3_release(struct snd_hwdep * hw, struct file *file)
178 return 0; 184 return 0;
179} 185}
180 186
187#ifdef OPL3_SUPPORT_SYNTH
181/* 188/*
182 * write the device - load patches 189 * write the device - load patches
183 */ 190 */
@@ -341,6 +348,7 @@ void snd_opl3_clear_patches(struct snd_opl3 *opl3)
341 } 348 }
342 memset(opl3->patch_table, 0, sizeof(opl3->patch_table)); 349 memset(opl3->patch_table, 0, sizeof(opl3->patch_table));
343} 350}
351#endif /* OPL3_SUPPORT_SYNTH */
344 352
345/* ------------------------------ */ 353/* ------------------------------ */
346 354
diff --git a/sound/isa/sb/sb8_main.c b/sound/isa/sb/sb8_main.c
index 6304c3a89ba0..fe03bb820532 100644
--- a/sound/isa/sb/sb8_main.c
+++ b/sound/isa/sb/sb8_main.c
@@ -277,7 +277,7 @@ static int snd_sb8_capture_prepare(struct snd_pcm_substream *substream)
277 } else { 277 } else {
278 snd_sbdsp_command(chip, 256 - runtime->rate_den); 278 snd_sbdsp_command(chip, 256 - runtime->rate_den);
279 } 279 }
280 if (chip->capture_format != SB_DSP_OUTPUT) { 280 if (chip->capture_format != SB_DSP_INPUT) {
281 count--; 281 count--;
282 snd_sbdsp_command(chip, SB_DSP_BLOCK_SIZE); 282 snd_sbdsp_command(chip, SB_DSP_BLOCK_SIZE);
283 snd_sbdsp_command(chip, count & 0xff); 283 snd_sbdsp_command(chip, count & 0xff);
diff --git a/sound/pci/bt87x.c b/sound/pci/bt87x.c
index c9a2421cf6f0..4ecdd635ed1d 100644
--- a/sound/pci/bt87x.c
+++ b/sound/pci/bt87x.c
@@ -681,15 +681,12 @@ static struct snd_kcontrol_new snd_bt87x_capture_source = {
681 681
682static int snd_bt87x_free(struct snd_bt87x *chip) 682static int snd_bt87x_free(struct snd_bt87x *chip)
683{ 683{
684 if (chip->mmio) { 684 if (chip->mmio)
685 snd_bt87x_stop(chip); 685 snd_bt87x_stop(chip);
686 if (chip->irq >= 0)
687 synchronize_irq(chip->irq);
688
689 iounmap(chip->mmio);
690 }
691 if (chip->irq >= 0) 686 if (chip->irq >= 0)
692 free_irq(chip->irq, chip); 687 free_irq(chip->irq, chip);
688 if (chip->mmio)
689 iounmap(chip->mmio);
693 pci_release_regions(chip->pci); 690 pci_release_regions(chip->pci);
694 pci_disable_device(chip->pci); 691 pci_disable_device(chip->pci);
695 kfree(chip); 692 kfree(chip);
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index 26812dc2b7f2..37c413923db8 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -1055,6 +1055,12 @@ int snd_hda_add_vmaster(struct hda_codec *codec, char *name,
1055 const char **s; 1055 const char **s;
1056 int err; 1056 int err;
1057 1057
1058 for (s = slaves; *s && !snd_hda_find_mixer_ctl(codec, *s); s++)
1059 ;
1060 if (!*s) {
1061 snd_printdd("No slave found for %s\n", name);
1062 return 0;
1063 }
1058 kctl = snd_ctl_make_virtual_master(name, tlv); 1064 kctl = snd_ctl_make_virtual_master(name, tlv);
1059 if (!kctl) 1065 if (!kctl)
1060 return -ENOMEM; 1066 return -ENOMEM;
@@ -1197,8 +1203,8 @@ int snd_hda_mixer_bind_ctls_info(struct snd_kcontrol *kcontrol,
1197 struct hda_bind_ctls *c; 1203 struct hda_bind_ctls *c;
1198 int err; 1204 int err;
1199 1205
1200 c = (struct hda_bind_ctls *)kcontrol->private_value;
1201 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */ 1206 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */
1207 c = (struct hda_bind_ctls *)kcontrol->private_value;
1202 kcontrol->private_value = *c->values; 1208 kcontrol->private_value = *c->values;
1203 err = c->ops->info(kcontrol, uinfo); 1209 err = c->ops->info(kcontrol, uinfo);
1204 kcontrol->private_value = (long)c; 1210 kcontrol->private_value = (long)c;
@@ -1213,8 +1219,8 @@ int snd_hda_mixer_bind_ctls_get(struct snd_kcontrol *kcontrol,
1213 struct hda_bind_ctls *c; 1219 struct hda_bind_ctls *c;
1214 int err; 1220 int err;
1215 1221
1216 c = (struct hda_bind_ctls *)kcontrol->private_value;
1217 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */ 1222 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */
1223 c = (struct hda_bind_ctls *)kcontrol->private_value;
1218 kcontrol->private_value = *c->values; 1224 kcontrol->private_value = *c->values;
1219 err = c->ops->get(kcontrol, ucontrol); 1225 err = c->ops->get(kcontrol, ucontrol);
1220 kcontrol->private_value = (long)c; 1226 kcontrol->private_value = (long)c;
@@ -1230,8 +1236,8 @@ int snd_hda_mixer_bind_ctls_put(struct snd_kcontrol *kcontrol,
1230 unsigned long *vals; 1236 unsigned long *vals;
1231 int err = 0, change = 0; 1237 int err = 0, change = 0;
1232 1238
1233 c = (struct hda_bind_ctls *)kcontrol->private_value;
1234 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */ 1239 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */
1240 c = (struct hda_bind_ctls *)kcontrol->private_value;
1235 for (vals = c->values; *vals; vals++) { 1241 for (vals = c->values; *vals; vals++) {
1236 kcontrol->private_value = *vals; 1242 kcontrol->private_value = *vals;
1237 err = c->ops->put(kcontrol, ucontrol); 1243 err = c->ops->put(kcontrol, ucontrol);
@@ -1251,8 +1257,8 @@ int snd_hda_mixer_bind_tlv(struct snd_kcontrol *kcontrol, int op_flag,
1251 struct hda_bind_ctls *c; 1257 struct hda_bind_ctls *c;
1252 int err; 1258 int err;
1253 1259
1254 c = (struct hda_bind_ctls *)kcontrol->private_value;
1255 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */ 1260 mutex_lock(&codec->spdif_mutex); /* reuse spdif_mutex */
1261 c = (struct hda_bind_ctls *)kcontrol->private_value;
1256 kcontrol->private_value = *c->values; 1262 kcontrol->private_value = *c->values;
1257 err = c->ops->tlv(kcontrol, op_flag, size, tlv); 1263 err = c->ops->tlv(kcontrol, op_flag, size, tlv);
1258 kcontrol->private_value = (long)c; 1264 kcontrol->private_value = (long)c;
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 56f8a3050751..4be36c84b36c 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -275,6 +275,11 @@ enum {
275#define NVIDIA_HDA_TRANSREG_ADDR 0x4e 275#define NVIDIA_HDA_TRANSREG_ADDR 0x4e
276#define NVIDIA_HDA_ENABLE_COHBITS 0x0f 276#define NVIDIA_HDA_ENABLE_COHBITS 0x0f
277 277
278/* Defines for Intel SCH HDA snoop control */
279#define INTEL_SCH_HDA_DEVC 0x78
280#define INTEL_SCH_HDA_DEVC_NOSNOOP (0x1<<11)
281
282
278/* 283/*
279 */ 284 */
280 285
@@ -868,6 +873,8 @@ static void update_pci_byte(struct pci_dev *pci, unsigned int reg,
868 873
869static void azx_init_pci(struct azx *chip) 874static void azx_init_pci(struct azx *chip)
870{ 875{
876 unsigned short snoop;
877
871 /* Clear bits 0-2 of PCI register TCSEL (at offset 0x44) 878 /* Clear bits 0-2 of PCI register TCSEL (at offset 0x44)
872 * TCSEL == Traffic Class Select Register, which sets PCI express QOS 879 * TCSEL == Traffic Class Select Register, which sets PCI express QOS
873 * Ensuring these bits are 0 clears playback static on some HD Audio 880 * Ensuring these bits are 0 clears playback static on some HD Audio
@@ -888,6 +895,19 @@ static void azx_init_pci(struct azx *chip)
888 NVIDIA_HDA_TRANSREG_ADDR, 895 NVIDIA_HDA_TRANSREG_ADDR,
889 0x0f, NVIDIA_HDA_ENABLE_COHBITS); 896 0x0f, NVIDIA_HDA_ENABLE_COHBITS);
890 break; 897 break;
898 case AZX_DRIVER_SCH:
899 pci_read_config_word(chip->pci, INTEL_SCH_HDA_DEVC, &snoop);
900 if (snoop & INTEL_SCH_HDA_DEVC_NOSNOOP) {
901 pci_write_config_word(chip->pci, INTEL_SCH_HDA_DEVC, \
902 snoop & (~INTEL_SCH_HDA_DEVC_NOSNOOP));
903 pci_read_config_word(chip->pci,
904 INTEL_SCH_HDA_DEVC, &snoop);
905 snd_printdd("HDA snoop disabled, enabling ... %s\n",\
906 (snoop & INTEL_SCH_HDA_DEVC_NOSNOOP) \
907 ? "Failed" : "OK");
908 }
909 break;
910
891 } 911 }
892} 912}
893 913
@@ -1040,6 +1060,7 @@ static int azx_setup_controller(struct azx *chip, struct azx_dev *azx_dev)
1040 1060
1041static unsigned int azx_max_codecs[] __devinitdata = { 1061static unsigned int azx_max_codecs[] __devinitdata = {
1042 [AZX_DRIVER_ICH] = 3, 1062 [AZX_DRIVER_ICH] = 3,
1063 [AZX_DRIVER_SCH] = 3,
1043 [AZX_DRIVER_ATI] = 4, 1064 [AZX_DRIVER_ATI] = 4,
1044 [AZX_DRIVER_ATIHDMI] = 4, 1065 [AZX_DRIVER_ATIHDMI] = 4,
1045 [AZX_DRIVER_VIA] = 3, /* FIXME: correct? */ 1066 [AZX_DRIVER_VIA] = 3, /* FIXME: correct? */
@@ -1797,7 +1818,7 @@ static int __devinit azx_create(struct snd_card *card, struct pci_dev *pci,
1797 */ 1818 */
1798 chip->playback_streams = (gcap & (0xF << 12)) >> 12; 1819 chip->playback_streams = (gcap & (0xF << 12)) >> 12;
1799 chip->capture_streams = (gcap & (0xF << 8)) >> 8; 1820 chip->capture_streams = (gcap & (0xF << 8)) >> 8;
1800 chip->playback_index_offset = (gcap & (0xF << 12)) >> 12; 1821 chip->playback_index_offset = chip->capture_streams;
1801 chip->capture_index_offset = 0; 1822 chip->capture_index_offset = 0;
1802 } else { 1823 } else {
1803 /* gcap didn't give any info, switching to old method */ 1824 /* gcap didn't give any info, switching to old method */
diff --git a/sound/pci/hda/hda_proc.c b/sound/pci/hda/hda_proc.c
index 35a630d1770f..5633f77f8f3b 100644
--- a/sound/pci/hda/hda_proc.c
+++ b/sound/pci/hda/hda_proc.c
@@ -584,7 +584,8 @@ static void print_codec_info(struct snd_info_entry *entry,
584 print_amp_caps(buffer, codec, nid, HDA_INPUT); 584 print_amp_caps(buffer, codec, nid, HDA_INPUT);
585 snd_iprintf(buffer, " Amp-In vals: "); 585 snd_iprintf(buffer, " Amp-In vals: ");
586 print_amp_vals(buffer, codec, nid, HDA_INPUT, 586 print_amp_vals(buffer, codec, nid, HDA_INPUT,
587 wid_caps & AC_WCAP_STEREO, conn_len); 587 wid_caps & AC_WCAP_STEREO,
588 wid_type == AC_WID_PIN ? 1 : conn_len);
588 } 589 }
589 if (wid_caps & AC_WCAP_OUT_AMP) { 590 if (wid_caps & AC_WCAP_OUT_AMP) {
590 snd_iprintf(buffer, " Amp-Out caps: "); 591 snd_iprintf(buffer, " Amp-Out caps: ");
diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c
index 19f08846d6fc..c8649282c2cf 100644
--- a/sound/pci/hda/patch_analog.c
+++ b/sound/pci/hda/patch_analog.c
@@ -1778,9 +1778,9 @@ static hda_nid_t ad1988_capsrc_nids[3] = {
1778static struct hda_input_mux ad1988_6stack_capture_source = { 1778static struct hda_input_mux ad1988_6stack_capture_source = {
1779 .num_items = 5, 1779 .num_items = 5,
1780 .items = { 1780 .items = {
1781 { "Front Mic", 0x0 }, 1781 { "Front Mic", 0x1 }, /* port-B */
1782 { "Line", 0x1 }, 1782 { "Line", 0x2 }, /* port-C */
1783 { "Mic", 0x4 }, 1783 { "Mic", 0x4 }, /* port-E */
1784 { "CD", 0x5 }, 1784 { "CD", 0x5 },
1785 { "Mix", 0x9 }, 1785 { "Mix", 0x9 },
1786 }, 1786 },
@@ -1789,7 +1789,7 @@ static struct hda_input_mux ad1988_6stack_capture_source = {
1789static struct hda_input_mux ad1988_laptop_capture_source = { 1789static struct hda_input_mux ad1988_laptop_capture_source = {
1790 .num_items = 3, 1790 .num_items = 3,
1791 .items = { 1791 .items = {
1792 { "Mic/Line", 0x0 }, 1792 { "Mic/Line", 0x1 }, /* port-B */
1793 { "CD", 0x5 }, 1793 { "CD", 0x5 },
1794 { "Mix", 0x9 }, 1794 { "Mix", 0x9 },
1795 }, 1795 },
diff --git a/sound/pci/hda/patch_conexant.c b/sound/pci/hda/patch_conexant.c
index f6dd51cda7b2..7206b30cbf94 100644
--- a/sound/pci/hda/patch_conexant.c
+++ b/sound/pci/hda/patch_conexant.c
@@ -488,7 +488,7 @@ static int conexant_ch_mode_put(struct snd_kcontrol *kcontrol,
488static hda_nid_t cxt5045_dac_nids[1] = { 0x19 }; 488static hda_nid_t cxt5045_dac_nids[1] = { 0x19 };
489static hda_nid_t cxt5045_adc_nids[1] = { 0x1a }; 489static hda_nid_t cxt5045_adc_nids[1] = { 0x1a };
490static hda_nid_t cxt5045_capsrc_nids[1] = { 0x1a }; 490static hda_nid_t cxt5045_capsrc_nids[1] = { 0x1a };
491#define CXT5045_SPDIF_OUT 0x13 491#define CXT5045_SPDIF_OUT 0x18
492 492
493static struct hda_channel_mode cxt5045_modes[1] = { 493static struct hda_channel_mode cxt5045_modes[1] = {
494 { 2, NULL }, 494 { 2, NULL },
@@ -658,6 +658,7 @@ static struct hda_verb cxt5045_init_verbs[] = {
658 {0x1a, AC_VERB_SET_AMP_GAIN_MUTE, 658 {0x1a, AC_VERB_SET_AMP_GAIN_MUTE,
659 AC_AMP_SET_INPUT|AC_AMP_SET_RIGHT|AC_AMP_SET_LEFT|0x17}, 659 AC_AMP_SET_INPUT|AC_AMP_SET_RIGHT|AC_AMP_SET_LEFT|0x17},
660 /* SPDIF route: PCM */ 660 /* SPDIF route: PCM */
661 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
661 { 0x13, AC_VERB_SET_CONNECT_SEL, 0x0 }, 662 { 0x13, AC_VERB_SET_CONNECT_SEL, 0x0 },
662 /* EAPD */ 663 /* EAPD */
663 {0x10, AC_VERB_SET_EAPD_BTLENABLE, 0x2 }, /* default on */ 664 {0x10, AC_VERB_SET_EAPD_BTLENABLE, 0x2 }, /* default on */
@@ -683,6 +684,7 @@ static struct hda_verb cxt5045_benq_init_verbs[] = {
683 {0x1a, AC_VERB_SET_AMP_GAIN_MUTE, 684 {0x1a, AC_VERB_SET_AMP_GAIN_MUTE,
684 AC_AMP_SET_INPUT|AC_AMP_SET_RIGHT|AC_AMP_SET_LEFT|0x17}, 685 AC_AMP_SET_INPUT|AC_AMP_SET_RIGHT|AC_AMP_SET_LEFT|0x17},
685 /* SPDIF route: PCM */ 686 /* SPDIF route: PCM */
687 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
686 {0x13, AC_VERB_SET_CONNECT_SEL, 0x0}, 688 {0x13, AC_VERB_SET_CONNECT_SEL, 0x0},
687 /* EAPD */ 689 /* EAPD */
688 {0x10, AC_VERB_SET_EAPD_BTLENABLE, 0x2}, /* default on */ 690 {0x10, AC_VERB_SET_EAPD_BTLENABLE, 0x2}, /* default on */
@@ -781,7 +783,8 @@ static struct hda_verb cxt5045_test_init_verbs[] = {
781 * PCM format, copyright asserted, no pre-emphasis and no validity 783 * PCM format, copyright asserted, no pre-emphasis and no validity
782 * control. 784 * control.
783 */ 785 */
784 {0x13, AC_VERB_SET_DIGI_CONVERT_1, 0}, 786 {0x13, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_OUT},
787 {0x18, AC_VERB_SET_DIGI_CONVERT_1, 0},
785 788
786 /* Start with output sum widgets muted and their output gains at min */ 789 /* Start with output sum widgets muted and their output gains at min */
787 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)}, 790 {0x17, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(0)},
@@ -1227,6 +1230,11 @@ static struct hda_verb cxt5047_toshiba_init_verbs[] = {
1227static struct hda_verb cxt5047_hp_init_verbs[] = { 1230static struct hda_verb cxt5047_hp_init_verbs[] = {
1228 /* pin sensing on HP jack */ 1231 /* pin sensing on HP jack */
1229 {0x13, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | CONEXANT_HP_EVENT}, 1232 {0x13, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | CONEXANT_HP_EVENT},
1233 /* 0x13 is actually shared by both HP and speaker;
1234 * setting the connection to 0 (=0x19) makes the master volume control
1235 * working mysteriouslly...
1236 */
1237 {0x13, AC_VERB_SET_CONNECT_SEL, 0x0},
1230 /* Record selector: Ext Mic */ 1238 /* Record selector: Ext Mic */
1231 {0x12, AC_VERB_SET_CONNECT_SEL,0x03}, 1239 {0x12, AC_VERB_SET_CONNECT_SEL,0x03},
1232 {0x19, AC_VERB_SET_AMP_GAIN_MUTE, 1240 {0x19, AC_VERB_SET_AMP_GAIN_MUTE,
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 586d98f1b63d..33282f9c01c7 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -3973,8 +3973,8 @@ static struct snd_kcontrol_new alc260_fujitsu_mixer[] = {
3973 ALC_PIN_MODE("Mic/Line Jack Mode", 0x12, ALC_PIN_DIR_IN), 3973 ALC_PIN_MODE("Mic/Line Jack Mode", 0x12, ALC_PIN_DIR_IN),
3974 HDA_CODEC_VOLUME("Beep Playback Volume", 0x07, 0x05, HDA_INPUT), 3974 HDA_CODEC_VOLUME("Beep Playback Volume", 0x07, 0x05, HDA_INPUT),
3975 HDA_CODEC_MUTE("Beep Playback Switch", 0x07, 0x05, HDA_INPUT), 3975 HDA_CODEC_MUTE("Beep Playback Switch", 0x07, 0x05, HDA_INPUT),
3976 HDA_CODEC_VOLUME("Internal Speaker Playback Volume", 0x09, 0x0, HDA_OUTPUT), 3976 HDA_CODEC_VOLUME("Speaker Playback Volume", 0x09, 0x0, HDA_OUTPUT),
3977 HDA_BIND_MUTE("Internal Speaker Playback Switch", 0x09, 2, HDA_INPUT), 3977 HDA_BIND_MUTE("Speaker Playback Switch", 0x09, 2, HDA_INPUT),
3978 { } /* end */ 3978 { } /* end */
3979}; 3979};
3980 3980
@@ -4005,9 +4005,9 @@ static struct snd_kcontrol_new alc260_acer_mixer[] = {
4005 HDA_CODEC_VOLUME("Master Playback Volume", 0x08, 0x0, HDA_OUTPUT), 4005 HDA_CODEC_VOLUME("Master Playback Volume", 0x08, 0x0, HDA_OUTPUT),
4006 HDA_BIND_MUTE("Master Playback Switch", 0x08, 2, HDA_INPUT), 4006 HDA_BIND_MUTE("Master Playback Switch", 0x08, 2, HDA_INPUT),
4007 ALC_PIN_MODE("Headphone Jack Mode", 0x0f, ALC_PIN_DIR_INOUT), 4007 ALC_PIN_MODE("Headphone Jack Mode", 0x0f, ALC_PIN_DIR_INOUT),
4008 HDA_CODEC_VOLUME_MONO("Mono Speaker Playback Volume", 0x0a, 1, 0x0, 4008 HDA_CODEC_VOLUME_MONO("Speaker Playback Volume", 0x0a, 1, 0x0,
4009 HDA_OUTPUT), 4009 HDA_OUTPUT),
4010 HDA_BIND_MUTE_MONO("Mono Speaker Playback Switch", 0x0a, 1, 2, 4010 HDA_BIND_MUTE_MONO("Speaker Playback Switch", 0x0a, 1, 2,
4011 HDA_INPUT), 4011 HDA_INPUT),
4012 HDA_CODEC_VOLUME("CD Playback Volume", 0x07, 0x04, HDA_INPUT), 4012 HDA_CODEC_VOLUME("CD Playback Volume", 0x07, 0x04, HDA_INPUT),
4013 HDA_CODEC_MUTE("CD Playback Switch", 0x07, 0x04, HDA_INPUT), 4013 HDA_CODEC_MUTE("CD Playback Switch", 0x07, 0x04, HDA_INPUT),
@@ -5227,10 +5227,14 @@ static int alc882_mux_enum_put(struct snd_kcontrol *kcontrol,
5227 const struct hda_input_mux *imux = spec->input_mux; 5227 const struct hda_input_mux *imux = spec->input_mux;
5228 unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id); 5228 unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id);
5229 static hda_nid_t capture_mixers[3] = { 0x24, 0x23, 0x22 }; 5229 static hda_nid_t capture_mixers[3] = { 0x24, 0x23, 0x22 };
5230 hda_nid_t nid = capture_mixers[adc_idx]; 5230 hda_nid_t nid;
5231 unsigned int *cur_val = &spec->cur_mux[adc_idx]; 5231 unsigned int *cur_val = &spec->cur_mux[adc_idx];
5232 unsigned int i, idx; 5232 unsigned int i, idx;
5233 5233
5234 if (spec->num_adc_nids < 3)
5235 nid = capture_mixers[adc_idx + 1];
5236 else
5237 nid = capture_mixers[adc_idx];
5234 idx = ucontrol->value.enumerated.item[0]; 5238 idx = ucontrol->value.enumerated.item[0];
5235 if (idx >= imux->num_items) 5239 if (idx >= imux->num_items)
5236 idx = imux->num_items - 1; 5240 idx = imux->num_items - 1;
@@ -6457,7 +6461,7 @@ static int alc883_mux_enum_put(struct snd_kcontrol *kcontrol,
6457 struct alc_spec *spec = codec->spec; 6461 struct alc_spec *spec = codec->spec;
6458 const struct hda_input_mux *imux = spec->input_mux; 6462 const struct hda_input_mux *imux = spec->input_mux;
6459 unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id); 6463 unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id);
6460 static hda_nid_t capture_mixers[3] = { 0x24, 0x23, 0x22 }; 6464 static hda_nid_t capture_mixers[2] = { 0x23, 0x22 };
6461 hda_nid_t nid = capture_mixers[adc_idx]; 6465 hda_nid_t nid = capture_mixers[adc_idx];
6462 unsigned int *cur_val = &spec->cur_mux[adc_idx]; 6466 unsigned int *cur_val = &spec->cur_mux[adc_idx];
6463 unsigned int i, idx; 6467 unsigned int i, idx;
@@ -7635,6 +7639,7 @@ static struct snd_pci_quirk alc883_cfg_tbl[] = {
7635 SND_PCI_QUIRK(0x17aa, 0x3bfc, "Lenovo NB0763", ALC883_LENOVO_NB0763), 7639 SND_PCI_QUIRK(0x17aa, 0x3bfc, "Lenovo NB0763", ALC883_LENOVO_NB0763),
7636 SND_PCI_QUIRK(0x17aa, 0x3bfd, "Lenovo NB0763", ALC883_LENOVO_NB0763), 7640 SND_PCI_QUIRK(0x17aa, 0x3bfd, "Lenovo NB0763", ALC883_LENOVO_NB0763),
7637 SND_PCI_QUIRK(0x17c0, 0x4071, "MEDION MD2", ALC883_MEDION_MD2), 7641 SND_PCI_QUIRK(0x17c0, 0x4071, "MEDION MD2", ALC883_MEDION_MD2),
7642 SND_PCI_QUIRK(0x17f2, 0x5000, "Albatron KI690-AM2", ALC883_6ST_DIG),
7638 SND_PCI_QUIRK(0x1991, 0x5625, "Haier W66", ALC883_HAIER_W66), 7643 SND_PCI_QUIRK(0x1991, 0x5625, "Haier W66", ALC883_HAIER_W66),
7639 SND_PCI_QUIRK(0x8086, 0xd601, "D102GGC", ALC883_3ST_6ch), 7644 SND_PCI_QUIRK(0x8086, 0xd601, "D102GGC", ALC883_3ST_6ch),
7640 {} 7645 {}
@@ -8098,7 +8103,7 @@ static struct snd_kcontrol_new alc262_base_mixer[] = {
8098 HDA_CODEC_MUTE("Front Mic Playback Switch", 0x0b, 0x01, HDA_INPUT), 8103 HDA_CODEC_MUTE("Front Mic Playback Switch", 0x0b, 0x01, HDA_INPUT),
8099 HDA_CODEC_VOLUME("Front Mic Boost", 0x19, 0, HDA_INPUT), 8104 HDA_CODEC_VOLUME("Front Mic Boost", 0x19, 0, HDA_INPUT),
8100 /* HDA_CODEC_VOLUME("PC Beep Playback Volume", 0x0b, 0x05, HDA_INPUT), 8105 /* HDA_CODEC_VOLUME("PC Beep Playback Volume", 0x0b, 0x05, HDA_INPUT),
8101 HDA_CODEC_MUTE("PC Beelp Playback Switch", 0x0b, 0x05, HDA_INPUT), */ 8106 HDA_CODEC_MUTE("PC Beep Playback Switch", 0x0b, 0x05, HDA_INPUT), */
8102 HDA_CODEC_VOLUME("Headphone Playback Volume", 0x0D, 0x0, HDA_OUTPUT), 8107 HDA_CODEC_VOLUME("Headphone Playback Volume", 0x0D, 0x0, HDA_OUTPUT),
8103 HDA_CODEC_MUTE("Headphone Playback Switch", 0x15, 0x0, HDA_OUTPUT), 8108 HDA_CODEC_MUTE("Headphone Playback Switch", 0x15, 0x0, HDA_OUTPUT),
8104 HDA_CODEC_VOLUME_MONO("Mono Playback Volume", 0x0e, 2, 0x0, HDA_OUTPUT), 8109 HDA_CODEC_VOLUME_MONO("Mono Playback Volume", 0x0e, 2, 0x0, HDA_OUTPUT),
@@ -8120,7 +8125,7 @@ static struct snd_kcontrol_new alc262_hippo1_mixer[] = {
8120 HDA_CODEC_MUTE("Front Mic Playback Switch", 0x0b, 0x01, HDA_INPUT), 8125 HDA_CODEC_MUTE("Front Mic Playback Switch", 0x0b, 0x01, HDA_INPUT),
8121 HDA_CODEC_VOLUME("Front Mic Boost", 0x19, 0, HDA_INPUT), 8126 HDA_CODEC_VOLUME("Front Mic Boost", 0x19, 0, HDA_INPUT),
8122 /* HDA_CODEC_VOLUME("PC Beep Playback Volume", 0x0b, 0x05, HDA_INPUT), 8127 /* HDA_CODEC_VOLUME("PC Beep Playback Volume", 0x0b, 0x05, HDA_INPUT),
8123 HDA_CODEC_MUTE("PC Beelp Playback Switch", 0x0b, 0x05, HDA_INPUT), */ 8128 HDA_CODEC_MUTE("PC Beep Playback Switch", 0x0b, 0x05, HDA_INPUT), */
8124 /*HDA_CODEC_VOLUME("Headphone Playback Volume", 0x0D, 0x0, HDA_OUTPUT),*/ 8129 /*HDA_CODEC_VOLUME("Headphone Playback Volume", 0x0D, 0x0, HDA_OUTPUT),*/
8125 HDA_CODEC_MUTE("Headphone Playback Switch", 0x1b, 0x0, HDA_OUTPUT), 8130 HDA_CODEC_MUTE("Headphone Playback Switch", 0x1b, 0x0, HDA_OUTPUT),
8126 { } /* end */ 8131 { } /* end */
@@ -9234,6 +9239,7 @@ static struct snd_pci_quirk alc262_cfg_tbl[] = {
9234 SND_PCI_QUIRK(0x104d, 0x900e, "Sony ASSAMD", ALC262_SONY_ASSAMD), 9239 SND_PCI_QUIRK(0x104d, 0x900e, "Sony ASSAMD", ALC262_SONY_ASSAMD),
9235 SND_PCI_QUIRK(0x104d, 0x9015, "Sony 0x9015", ALC262_SONY_ASSAMD), 9240 SND_PCI_QUIRK(0x104d, 0x9015, "Sony 0x9015", ALC262_SONY_ASSAMD),
9236 SND_PCI_QUIRK(0x10cf, 0x1397, "Fujitsu", ALC262_FUJITSU), 9241 SND_PCI_QUIRK(0x10cf, 0x1397, "Fujitsu", ALC262_FUJITSU),
9242 SND_PCI_QUIRK(0x10cf, 0x142d, "Fujitsu Lifebook E8410", ALC262_FUJITSU),
9237 SND_PCI_QUIRK(0x144d, 0xc032, "Samsung Q1 Ultra", ALC262_ULTRA), 9243 SND_PCI_QUIRK(0x144d, 0xc032, "Samsung Q1 Ultra", ALC262_ULTRA),
9238 SND_PCI_QUIRK(0x17ff, 0x0560, "Benq ED8", ALC262_BENQ_ED8), 9244 SND_PCI_QUIRK(0x17ff, 0x0560, "Benq ED8", ALC262_BENQ_ED8),
9239 SND_PCI_QUIRK(0x17ff, 0x058d, "Benq T31-16", ALC262_BENQ_T31), 9245 SND_PCI_QUIRK(0x17ff, 0x058d, "Benq T31-16", ALC262_BENQ_T31),
@@ -12989,8 +12995,8 @@ static struct snd_kcontrol_new alc662_lenovo_101e_mixer[] = {
12989static struct snd_kcontrol_new alc662_eeepc_p701_mixer[] = { 12995static struct snd_kcontrol_new alc662_eeepc_p701_mixer[] = {
12990 HDA_CODEC_MUTE("Speaker Playback Switch", 0x14, 0x0, HDA_OUTPUT), 12996 HDA_CODEC_MUTE("Speaker Playback Switch", 0x14, 0x0, HDA_OUTPUT),
12991 12997
12992 HDA_CODEC_VOLUME("LineOut Playback Volume", 0x02, 0x0, HDA_OUTPUT), 12998 HDA_CODEC_VOLUME("Line-Out Playback Volume", 0x02, 0x0, HDA_OUTPUT),
12993 HDA_CODEC_MUTE("LineOut Playback Switch", 0x1b, 0x0, HDA_OUTPUT), 12999 HDA_CODEC_MUTE("Line-Out Playback Switch", 0x1b, 0x0, HDA_OUTPUT),
12994 13000
12995 HDA_CODEC_VOLUME("e-Mic Boost", 0x18, 0, HDA_INPUT), 13001 HDA_CODEC_VOLUME("e-Mic Boost", 0x18, 0, HDA_INPUT),
12996 HDA_CODEC_VOLUME("e-Mic Playback Volume", 0x0b, 0x0, HDA_INPUT), 13002 HDA_CODEC_VOLUME("e-Mic Playback Volume", 0x0b, 0x0, HDA_INPUT),
@@ -13003,8 +13009,8 @@ static struct snd_kcontrol_new alc662_eeepc_p701_mixer[] = {
13003}; 13009};
13004 13010
13005static struct snd_kcontrol_new alc662_eeepc_ep20_mixer[] = { 13011static struct snd_kcontrol_new alc662_eeepc_ep20_mixer[] = {
13006 HDA_CODEC_VOLUME("LineOut Playback Volume", 0x02, 0x0, HDA_OUTPUT), 13012 HDA_CODEC_VOLUME("Line-Out Playback Volume", 0x02, 0x0, HDA_OUTPUT),
13007 HDA_CODEC_MUTE("LineOut Playback Switch", 0x14, 0x0, HDA_OUTPUT), 13013 HDA_CODEC_MUTE("Line-Out Playback Switch", 0x14, 0x0, HDA_OUTPUT),
13008 HDA_CODEC_VOLUME("Surround Playback Volume", 0x03, 0x0, HDA_OUTPUT), 13014 HDA_CODEC_VOLUME("Surround Playback Volume", 0x03, 0x0, HDA_OUTPUT),
13009 HDA_BIND_MUTE("Surround Playback Switch", 0x03, 2, HDA_INPUT), 13015 HDA_BIND_MUTE("Surround Playback Switch", 0x03, 2, HDA_INPUT),
13010 HDA_CODEC_VOLUME_MONO("Center Playback Volume", 0x04, 1, 0x0, HDA_OUTPUT), 13016 HDA_CODEC_VOLUME_MONO("Center Playback Volume", 0x04, 1, 0x0, HDA_OUTPUT),
diff --git a/sound/pci/ice1712/phase.c b/sound/pci/ice1712/phase.c
index 9ab4a9f383cb..5a158b73dcaa 100644
--- a/sound/pci/ice1712/phase.c
+++ b/sound/pci/ice1712/phase.c
@@ -51,7 +51,7 @@
51struct phase28_spec { 51struct phase28_spec {
52 unsigned short master[2]; 52 unsigned short master[2];
53 unsigned short vol[8]; 53 unsigned short vol[8];
54} phase28; 54};
55 55
56/* WM8770 registers */ 56/* WM8770 registers */
57#define WM_DAC_ATTEN 0x00 /* DAC1-8 analog attenuation */ 57#define WM_DAC_ATTEN 0x00 /* DAC1-8 analog attenuation */
diff --git a/sound/pci/ice1712/revo.c b/sound/pci/ice1712/revo.c
index ddd5fc8d4fe1..301bf929acd9 100644
--- a/sound/pci/ice1712/revo.c
+++ b/sound/pci/ice1712/revo.c
@@ -36,7 +36,7 @@
36struct revo51_spec { 36struct revo51_spec {
37 struct snd_i2c_device *dev; 37 struct snd_i2c_device *dev;
38 struct snd_pt2258 *pt2258; 38 struct snd_pt2258 *pt2258;
39} revo51; 39};
40 40
41static void revo_i2s_mclk_changed(struct snd_ice1712 *ice) 41static void revo_i2s_mclk_changed(struct snd_ice1712 *ice)
42{ 42{
diff --git a/sound/pci/intel8x0.c b/sound/pci/intel8x0.c
index 061072c7db03..c52abd0bf22e 100644
--- a/sound/pci/intel8x0.c
+++ b/sound/pci/intel8x0.c
@@ -1708,6 +1708,12 @@ static struct ac97_pcm ac97_pcm_defs[] __devinitdata = {
1708}; 1708};
1709 1709
1710static struct ac97_quirk ac97_quirks[] __devinitdata = { 1710static struct ac97_quirk ac97_quirks[] __devinitdata = {
1711 {
1712 .subvendor = 0x0e11,
1713 .subdevice = 0x000e,
1714 .name = "Compaq Deskpro EN", /* AD1885 */
1715 .type = AC97_TUNE_HP_ONLY
1716 },
1711 { 1717 {
1712 .subvendor = 0x0e11, 1718 .subvendor = 0x0e11,
1713 .subdevice = 0x008a, 1719 .subdevice = 0x008a,
@@ -1740,6 +1746,12 @@ static struct ac97_quirk ac97_quirks[] __devinitdata = {
1740 }, 1746 },
1741 { 1747 {
1742 .subvendor = 0x1025, 1748 .subvendor = 0x1025,
1749 .subdevice = 0x0082,
1750 .name = "Acer Travelmate 2310",
1751 .type = AC97_TUNE_HP_ONLY
1752 },
1753 {
1754 .subvendor = 0x1025,
1743 .subdevice = 0x0083, 1755 .subdevice = 0x0083,
1744 .name = "Acer Aspire 3003LCi", 1756 .name = "Acer Aspire 3003LCi",
1745 .type = AC97_TUNE_HP_ONLY 1757 .type = AC97_TUNE_HP_ONLY
diff --git a/sound/pci/oxygen/hifier.c b/sound/pci/oxygen/hifier.c
index 3ea1f05228a1..666f69a3312e 100644
--- a/sound/pci/oxygen/hifier.c
+++ b/sound/pci/oxygen/hifier.c
@@ -150,6 +150,7 @@ static const struct oxygen_model model_hifier = {
150 .shortname = "C-Media CMI8787", 150 .shortname = "C-Media CMI8787",
151 .longname = "C-Media Oxygen HD Audio", 151 .longname = "C-Media Oxygen HD Audio",
152 .chip = "CMI8788", 152 .chip = "CMI8788",
153 .owner = THIS_MODULE,
153 .init = hifier_init, 154 .init = hifier_init,
154 .control_filter = hifier_control_filter, 155 .control_filter = hifier_control_filter,
155 .mixer_init = hifier_mixer_init, 156 .mixer_init = hifier_mixer_init,
diff --git a/sound/pci/oxygen/oxygen.c b/sound/pci/oxygen/oxygen.c
index f31a0eb409b0..9a9941bb0460 100644
--- a/sound/pci/oxygen/oxygen.c
+++ b/sound/pci/oxygen/oxygen.c
@@ -28,7 +28,9 @@
28 * GPIO 1 -> DFS1 of AK5385 28 * GPIO 1 -> DFS1 of AK5385
29 */ 29 */
30 30
31#include <linux/mutex.h>
31#include <linux/pci.h> 32#include <linux/pci.h>
33#include <sound/ac97_codec.h>
32#include <sound/control.h> 34#include <sound/control.h>
33#include <sound/core.h> 35#include <sound/core.h>
34#include <sound/initval.h> 36#include <sound/initval.h>
@@ -37,6 +39,7 @@
37#include <sound/tlv.h> 39#include <sound/tlv.h>
38#include "oxygen.h" 40#include "oxygen.h"
39#include "ak4396.h" 41#include "ak4396.h"
42#include "cm9780.h"
40 43
41MODULE_AUTHOR("Clemens Ladisch <clemens@ladisch.de>"); 44MODULE_AUTHOR("Clemens Ladisch <clemens@ladisch.de>");
42MODULE_DESCRIPTION("C-Media CMI8788 driver"); 45MODULE_DESCRIPTION("C-Media CMI8788 driver");
@@ -75,6 +78,8 @@ MODULE_DEVICE_TABLE(pci, oxygen_ids);
75#define GPIO_AK5385_DFS_DOUBLE 0x0001 78#define GPIO_AK5385_DFS_DOUBLE 0x0001
76#define GPIO_AK5385_DFS_QUAD 0x0002 79#define GPIO_AK5385_DFS_QUAD 0x0002
77 80
81#define GPIO_LINE_MUTE CM9780_GPO0
82
78#define WM8785_R0 0 83#define WM8785_R0 0
79#define WM8785_R1 1 84#define WM8785_R1 1
80#define WM8785_R2 2 85#define WM8785_R2 2
@@ -180,16 +185,23 @@ static void wm8785_init(struct oxygen *chip)
180 snd_component_add(chip->card, "WM8785"); 185 snd_component_add(chip->card, "WM8785");
181} 186}
182 187
188static void cmi9780_init(struct oxygen *chip)
189{
190 oxygen_ac97_clear_bits(chip, 0, CM9780_GPIO_STATUS, GPIO_LINE_MUTE);
191}
192
183static void generic_init(struct oxygen *chip) 193static void generic_init(struct oxygen *chip)
184{ 194{
185 ak4396_init(chip); 195 ak4396_init(chip);
186 wm8785_init(chip); 196 wm8785_init(chip);
197 cmi9780_init(chip);
187} 198}
188 199
189static void meridian_init(struct oxygen *chip) 200static void meridian_init(struct oxygen *chip)
190{ 201{
191 ak4396_init(chip); 202 ak4396_init(chip);
192 ak5385_init(chip); 203 ak5385_init(chip);
204 cmi9780_init(chip);
193} 205}
194 206
195static void generic_cleanup(struct oxygen *chip) 207static void generic_cleanup(struct oxygen *chip)
@@ -285,6 +297,27 @@ static void set_ak5385_params(struct oxygen *chip,
285 value, GPIO_AK5385_DFS_MASK); 297 value, GPIO_AK5385_DFS_MASK);
286} 298}
287 299
300static void cmi9780_switch_hook(struct oxygen *chip, unsigned int codec,
301 unsigned int reg, int mute)
302{
303 if (codec != 0)
304 return;
305 switch (reg) {
306 case AC97_LINE:
307 oxygen_write_ac97_masked(chip, 0, CM9780_GPIO_STATUS,
308 mute ? GPIO_LINE_MUTE : 0,
309 GPIO_LINE_MUTE);
310 break;
311 case AC97_MIC:
312 case AC97_CD:
313 case AC97_AUX:
314 if (!mute)
315 oxygen_ac97_set_bits(chip, 0, CM9780_GPIO_STATUS,
316 GPIO_LINE_MUTE);
317 break;
318 }
319}
320
288static const DECLARE_TLV_DB_LINEAR(ak4396_db_scale, TLV_DB_GAIN_MUTE, 0); 321static const DECLARE_TLV_DB_LINEAR(ak4396_db_scale, TLV_DB_GAIN_MUTE, 0);
289 322
290static int ak4396_control_filter(struct snd_kcontrol_new *template) 323static int ak4396_control_filter(struct snd_kcontrol_new *template)
@@ -308,6 +341,7 @@ static const struct oxygen_model model_generic = {
308 .set_adc_params = set_wm8785_params, 341 .set_adc_params = set_wm8785_params,
309 .update_dac_volume = update_ak4396_volume, 342 .update_dac_volume = update_ak4396_volume,
310 .update_dac_mute = update_ak4396_mute, 343 .update_dac_mute = update_ak4396_mute,
344 .ac97_switch_hook = cmi9780_switch_hook,
311 .model_data_size = sizeof(struct generic_data), 345 .model_data_size = sizeof(struct generic_data),
312 .dac_channels = 8, 346 .dac_channels = 8,
313 .used_channels = OXYGEN_CHANNEL_A | 347 .used_channels = OXYGEN_CHANNEL_A |
@@ -331,6 +365,7 @@ static const struct oxygen_model model_meridian = {
331 .set_adc_params = set_ak5385_params, 365 .set_adc_params = set_ak5385_params,
332 .update_dac_volume = update_ak4396_volume, 366 .update_dac_volume = update_ak4396_volume,
333 .update_dac_mute = update_ak4396_mute, 367 .update_dac_mute = update_ak4396_mute,
368 .ac97_switch_hook = cmi9780_switch_hook,
334 .model_data_size = sizeof(struct generic_data), 369 .model_data_size = sizeof(struct generic_data),
335 .dac_channels = 8, 370 .dac_channels = 8,
336 .used_channels = OXYGEN_CHANNEL_B | 371 .used_channels = OXYGEN_CHANNEL_B |
diff --git a/sound/pci/oxygen/oxygen_lib.c b/sound/pci/oxygen/oxygen_lib.c
index 6eb36dd11476..78c21155218e 100644
--- a/sound/pci/oxygen/oxygen_lib.c
+++ b/sound/pci/oxygen/oxygen_lib.c
@@ -204,7 +204,7 @@ static void oxygen_proc_read(struct snd_info_entry *entry,
204 mutex_unlock(&chip->mutex); 204 mutex_unlock(&chip->mutex);
205} 205}
206 206
207static void __devinit oxygen_proc_init(struct oxygen *chip) 207static void oxygen_proc_init(struct oxygen *chip)
208{ 208{
209 struct snd_info_entry *entry; 209 struct snd_info_entry *entry;
210 210
@@ -215,7 +215,7 @@ static void __devinit oxygen_proc_init(struct oxygen *chip)
215#define oxygen_proc_init(chip) 215#define oxygen_proc_init(chip)
216#endif 216#endif
217 217
218static void __devinit oxygen_init(struct oxygen *chip) 218static void oxygen_init(struct oxygen *chip)
219{ 219{
220 unsigned int i; 220 unsigned int i;
221 221
@@ -399,8 +399,8 @@ static void oxygen_card_free(struct snd_card *card)
399 pci_disable_device(chip->pci); 399 pci_disable_device(chip->pci);
400} 400}
401 401
402int __devinit oxygen_pci_probe(struct pci_dev *pci, int index, char *id, 402int oxygen_pci_probe(struct pci_dev *pci, int index, char *id,
403 int midi, const struct oxygen_model *model) 403 int midi, const struct oxygen_model *model)
404{ 404{
405 struct snd_card *card; 405 struct snd_card *card;
406 struct oxygen *chip; 406 struct oxygen *chip;
@@ -507,7 +507,7 @@ err_card:
507} 507}
508EXPORT_SYMBOL(oxygen_pci_probe); 508EXPORT_SYMBOL(oxygen_pci_probe);
509 509
510void __devexit oxygen_pci_remove(struct pci_dev *pci) 510void oxygen_pci_remove(struct pci_dev *pci)
511{ 511{
512 snd_card_free(pci_get_drvdata(pci)); 512 snd_card_free(pci_get_drvdata(pci));
513 pci_set_drvdata(pci, NULL); 513 pci_set_drvdata(pci, NULL);
diff --git a/sound/pci/oxygen/oxygen_pcm.c b/sound/pci/oxygen/oxygen_pcm.c
index dfad3db35c82..b70046aca657 100644
--- a/sound/pci/oxygen/oxygen_pcm.c
+++ b/sound/pci/oxygen/oxygen_pcm.c
@@ -634,7 +634,7 @@ static void oxygen_pcm_free(struct snd_pcm *pcm)
634 snd_pcm_lib_preallocate_free_for_all(pcm); 634 snd_pcm_lib_preallocate_free_for_all(pcm);
635} 635}
636 636
637int __devinit oxygen_pcm_init(struct oxygen *chip) 637int oxygen_pcm_init(struct oxygen *chip)
638{ 638{
639 struct snd_pcm *pcm; 639 struct snd_pcm *pcm;
640 int outs, ins; 640 int outs, ins;
diff --git a/sound/pci/oxygen/virtuoso.c b/sound/pci/oxygen/virtuoso.c
index 40e92f5cd69c..d163397b85cc 100644
--- a/sound/pci/oxygen/virtuoso.c
+++ b/sound/pci/oxygen/virtuoso.c
@@ -389,6 +389,7 @@ static const struct oxygen_model model_xonar = {
389 .shortname = "Asus AV200", 389 .shortname = "Asus AV200",
390 .longname = "Asus Virtuoso 200", 390 .longname = "Asus Virtuoso 200",
391 .chip = "AV200", 391 .chip = "AV200",
392 .owner = THIS_MODULE,
392 .init = xonar_init, 393 .init = xonar_init,
393 .control_filter = xonar_control_filter, 394 .control_filter = xonar_control_filter,
394 .mixer_init = xonar_mixer_init, 395 .mixer_init = xonar_mixer_init,
diff --git a/sound/pci/rme9652/hdsp.c b/sound/pci/rme9652/hdsp.c
index c2bd4384316a..1be84f22d0de 100644
--- a/sound/pci/rme9652/hdsp.c
+++ b/sound/pci/rme9652/hdsp.c
@@ -745,7 +745,7 @@ static int hdsp_get_iobox_version (struct hdsp *hdsp)
745 745
746 746
747#ifdef HDSP_FW_LOADER 747#ifdef HDSP_FW_LOADER
748static int __devinit hdsp_request_fw_loader(struct hdsp *hdsp); 748static int hdsp_request_fw_loader(struct hdsp *hdsp);
749#endif 749#endif
750 750
751static int hdsp_check_for_firmware (struct hdsp *hdsp, int load_on_demand) 751static int hdsp_check_for_firmware (struct hdsp *hdsp, int load_on_demand)
@@ -4688,8 +4688,7 @@ static struct snd_pcm_ops snd_hdsp_capture_ops = {
4688 .copy = snd_hdsp_capture_copy, 4688 .copy = snd_hdsp_capture_copy,
4689}; 4689};
4690 4690
4691static int __devinit snd_hdsp_create_hwdep(struct snd_card *card, 4691static int snd_hdsp_create_hwdep(struct snd_card *card, struct hdsp *hdsp)
4692 struct hdsp *hdsp)
4693{ 4692{
4694 struct snd_hwdep *hw; 4693 struct snd_hwdep *hw;
4695 int err; 4694 int err;
@@ -4857,7 +4856,7 @@ static int snd_hdsp_create_alsa_devices(struct snd_card *card, struct hdsp *hdsp
4857 4856
4858#ifdef HDSP_FW_LOADER 4857#ifdef HDSP_FW_LOADER
4859/* load firmware via hotplug fw loader */ 4858/* load firmware via hotplug fw loader */
4860static int __devinit hdsp_request_fw_loader(struct hdsp *hdsp) 4859static int hdsp_request_fw_loader(struct hdsp *hdsp)
4861{ 4860{
4862 const char *fwfile; 4861 const char *fwfile;
4863 const struct firmware *fw; 4862 const struct firmware *fw;
diff --git a/sound/soc/codecs/tlv320aic3x.c b/sound/soc/codecs/tlv320aic3x.c
index 710e0287ef8c..569ecaca0e8b 100644
--- a/sound/soc/codecs/tlv320aic3x.c
+++ b/sound/soc/codecs/tlv320aic3x.c
@@ -681,8 +681,8 @@ static const struct aic3x_rate_divs aic3x_divs[] = {
681 {22579200, 48000, 48000, 0x0, 8, 7075}, 681 {22579200, 48000, 48000, 0x0, 8, 7075},
682 {33868800, 48000, 48000, 0x0, 5, 8049}, 682 {33868800, 48000, 48000, 0x0, 5, 8049},
683 /* 64k */ 683 /* 64k */
684 {22579200, 96000, 96000, 0x1, 8, 7075}, 684 {22579200, 64000, 96000, 0x1, 8, 7075},
685 {33868800, 96000, 96000, 0x1, 5, 8049}, 685 {33868800, 64000, 96000, 0x1, 5, 8049},
686 /* 88.2k */ 686 /* 88.2k */
687 {22579200, 88200, 88200, 0x0, 8, 0}, 687 {22579200, 88200, 88200, 0x0, 8, 0},
688 {33868800, 88200, 88200, 0x0, 5, 3333}, 688 {33868800, 88200, 88200, 0x0, 5, 3333},
diff --git a/sound/soc/codecs/wm9712.c b/sound/soc/codecs/wm9712.c
index 590baea3c4c3..524f7450804f 100644
--- a/sound/soc/codecs/wm9712.c
+++ b/sound/soc/codecs/wm9712.c
@@ -176,7 +176,8 @@ static int wm9712_add_controls(struct snd_soc_codec *codec)
176 * the codec only has a single control that is shared by both channels. 176 * the codec only has a single control that is shared by both channels.
177 * This makes it impossible to determine the audio path. 177 * This makes it impossible to determine the audio path.
178 */ 178 */
179static int mixer_event (struct snd_soc_dapm_widget *w, int event) 179static int mixer_event(struct snd_soc_dapm_widget *w,
180 struct snd_kcontrol *k, int event)
180{ 181{
181 u16 l, r, beep, line, phone, mic, pcm, aux; 182 u16 l, r, beep, line, phone, mic, pcm, aux;
182 183
diff --git a/sound/soc/fsl/mpc8610_hpcd.c b/sound/soc/fsl/mpc8610_hpcd.c
index f26c4b2e8b6e..a00aac7a71f1 100644
--- a/sound/soc/fsl/mpc8610_hpcd.c
+++ b/sound/soc/fsl/mpc8610_hpcd.c
@@ -315,7 +315,7 @@ static int mpc8610_hpcd_probe(struct of_device *ofdev,
315 machine_data->dai_format = SND_SOC_DAIFMT_LEFT_J; 315 machine_data->dai_format = SND_SOC_DAIFMT_LEFT_J;
316 machine_data->codec_clk_direction = SND_SOC_CLOCK_IN; 316 machine_data->codec_clk_direction = SND_SOC_CLOCK_IN;
317 machine_data->cpu_clk_direction = SND_SOC_CLOCK_OUT; 317 machine_data->cpu_clk_direction = SND_SOC_CLOCK_OUT;
318 } else if (strcasecmp(sprop, "rj-master") == 0) { 318 } else if (strcasecmp(sprop, "rj-slave") == 0) {
319 machine_data->dai_format = SND_SOC_DAIFMT_RIGHT_J; 319 machine_data->dai_format = SND_SOC_DAIFMT_RIGHT_J;
320 machine_data->codec_clk_direction = SND_SOC_CLOCK_OUT; 320 machine_data->codec_clk_direction = SND_SOC_CLOCK_OUT;
321 machine_data->cpu_clk_direction = SND_SOC_CLOCK_IN; 321 machine_data->cpu_clk_direction = SND_SOC_CLOCK_IN;
diff --git a/sound/soc/pxa/corgi.c b/sound/soc/pxa/corgi.c
index 3f34e531bebf..1a70a6ac98ce 100644
--- a/sound/soc/pxa/corgi.c
+++ b/sound/soc/pxa/corgi.c
@@ -215,7 +215,8 @@ static int corgi_set_spk(struct snd_kcontrol *kcontrol,
215 return 1; 215 return 1;
216} 216}
217 217
218static int corgi_amp_event(struct snd_soc_dapm_widget *w, int event) 218static int corgi_amp_event(struct snd_soc_dapm_widget *w,
219 struct snd_kcontrol *k, int event)
219{ 220{
220 if (SND_SOC_DAPM_EVENT_ON(event)) 221 if (SND_SOC_DAPM_EVENT_ON(event))
221 set_scoop_gpio(&corgiscoop_device.dev, CORGI_SCP_APM_ON); 222 set_scoop_gpio(&corgiscoop_device.dev, CORGI_SCP_APM_ON);
@@ -225,7 +226,8 @@ static int corgi_amp_event(struct snd_soc_dapm_widget *w, int event)
225 return 0; 226 return 0;
226} 227}
227 228
228static int corgi_mic_event(struct snd_soc_dapm_widget *w, int event) 229static int corgi_mic_event(struct snd_soc_dapm_widget *w,
230 struct snd_kcontrol *k, int event)
229{ 231{
230 if (SND_SOC_DAPM_EVENT_ON(event)) 232 if (SND_SOC_DAPM_EVENT_ON(event))
231 set_scoop_gpio(&corgiscoop_device.dev, CORGI_SCP_MIC_BIAS); 233 set_scoop_gpio(&corgiscoop_device.dev, CORGI_SCP_MIC_BIAS);
diff --git a/sound/soc/pxa/poodle.c b/sound/soc/pxa/poodle.c
index 5ae59bd309a3..4fbf8bba9627 100644
--- a/sound/soc/pxa/poodle.c
+++ b/sound/soc/pxa/poodle.c
@@ -196,7 +196,8 @@ static int poodle_set_spk(struct snd_kcontrol *kcontrol,
196 return 1; 196 return 1;
197} 197}
198 198
199static int poodle_amp_event(struct snd_soc_dapm_widget *w, int event) 199static int poodle_amp_event(struct snd_soc_dapm_widget *w,
200 struct snd_kcontrol *k, int event)
200{ 201{
201 if (SND_SOC_DAPM_EVENT_ON(event)) 202 if (SND_SOC_DAPM_EVENT_ON(event))
202 locomo_gpio_write(&poodle_locomo_device.dev, 203 locomo_gpio_write(&poodle_locomo_device.dev,
diff --git a/sound/soc/pxa/spitz.c b/sound/soc/pxa/spitz.c
index d56709e15435..ecca39033fcc 100644
--- a/sound/soc/pxa/spitz.c
+++ b/sound/soc/pxa/spitz.c
@@ -215,7 +215,8 @@ static int spitz_set_spk(struct snd_kcontrol *kcontrol,
215 return 1; 215 return 1;
216} 216}
217 217
218static int spitz_mic_bias(struct snd_soc_dapm_widget *w, int event) 218static int spitz_mic_bias(struct snd_soc_dapm_widget *w,
219 struct snd_kcontrol *k, int event)
219{ 220{
220 if (machine_is_borzoi() || machine_is_spitz()) { 221 if (machine_is_borzoi() || machine_is_spitz()) {
221 if (SND_SOC_DAPM_EVENT_ON(event)) 222 if (SND_SOC_DAPM_EVENT_ON(event))
diff --git a/sound/soc/pxa/tosa.c b/sound/soc/pxa/tosa.c
index e4d40b528ca4..7346d7e5d066 100644
--- a/sound/soc/pxa/tosa.c
+++ b/sound/soc/pxa/tosa.c
@@ -135,7 +135,8 @@ static int tosa_set_spk(struct snd_kcontrol *kcontrol,
135} 135}
136 136
137/* tosa dapm event handlers */ 137/* tosa dapm event handlers */
138static int tosa_hp_event(struct snd_soc_dapm_widget *w, int event) 138static int tosa_hp_event(struct snd_soc_dapm_widget *w,
139 struct snd_kcontrol *k, int event)
139{ 140{
140 if (SND_SOC_DAPM_EVENT_ON(event)) 141 if (SND_SOC_DAPM_EVENT_ON(event))
141 set_tc6393_gpio(&tc6393_device.dev,TOSA_TC6393_L_MUTE); 142 set_tc6393_gpio(&tc6393_device.dev,TOSA_TC6393_L_MUTE);
diff --git a/sound/usb/caiaq/caiaq-device.c b/sound/usb/caiaq/caiaq-device.c
index 58d25e4e7d6c..7c44a2c7f963 100644
--- a/sound/usb/caiaq/caiaq-device.c
+++ b/sound/usb/caiaq/caiaq-device.c
@@ -245,7 +245,7 @@ int snd_usb_caiaq_set_auto_msg (struct snd_usb_caiaqdev *dev,
245 tmp, sizeof(tmp)); 245 tmp, sizeof(tmp));
246} 246}
247 247
248static void setup_card(struct snd_usb_caiaqdev *dev) 248static void __devinit setup_card(struct snd_usb_caiaqdev *dev)
249{ 249{
250 int ret; 250 int ret;
251 char val[4]; 251 char val[4];
@@ -359,7 +359,7 @@ static struct snd_card* create_card(struct usb_device* usb_dev)
359 return card; 359 return card;
360} 360}
361 361
362static int init_card(struct snd_usb_caiaqdev *dev) 362static int __devinit init_card(struct snd_usb_caiaqdev *dev)
363{ 363{
364 char *c; 364 char *c;
365 struct usb_device *usb_dev = dev->chip.dev; 365 struct usb_device *usb_dev = dev->chip.dev;
@@ -428,7 +428,7 @@ static int init_card(struct snd_usb_caiaqdev *dev)
428 return 0; 428 return 0;
429} 429}
430 430
431static int snd_probe(struct usb_interface *intf, 431static int __devinit snd_probe(struct usb_interface *intf,
432 const struct usb_device_id *id) 432 const struct usb_device_id *id)
433{ 433{
434 int ret; 434 int ret;
diff --git a/sound/usb/usbaudio.c b/sound/usb/usbaudio.c
index 8fa935665702..675672f313be 100644
--- a/sound/usb/usbaudio.c
+++ b/sound/usb/usbaudio.c
@@ -479,6 +479,33 @@ static int retire_playback_sync_urb_hs(struct snd_usb_substream *subs,
479 return 0; 479 return 0;
480} 480}
481 481
482/*
483 * process after E-Mu 0202/0404 high speed playback sync complete
484 *
485 * These devices return the number of samples per packet instead of the number
486 * of samples per microframe.
487 */
488static int retire_playback_sync_urb_hs_emu(struct snd_usb_substream *subs,
489 struct snd_pcm_runtime *runtime,
490 struct urb *urb)
491{
492 unsigned int f;
493 unsigned long flags;
494
495 if (urb->iso_frame_desc[0].status == 0 &&
496 urb->iso_frame_desc[0].actual_length == 4) {
497 f = combine_quad((u8*)urb->transfer_buffer) & 0x0fffffff;
498 f >>= subs->datainterval;
499 if (f >= subs->freqn - subs->freqn / 8 && f <= subs->freqmax) {
500 spin_lock_irqsave(&subs->lock, flags);
501 subs->freqm = f;
502 spin_unlock_irqrestore(&subs->lock, flags);
503 }
504 }
505
506 return 0;
507}
508
482/* determine the number of frames in the next packet */ 509/* determine the number of frames in the next packet */
483static int snd_usb_audio_next_packet_size(struct snd_usb_substream *subs) 510static int snd_usb_audio_next_packet_size(struct snd_usb_substream *subs)
484{ 511{
@@ -2219,10 +2246,17 @@ static void init_substream(struct snd_usb_stream *as, int stream, struct audiofo
2219 subs->stream = as; 2246 subs->stream = as;
2220 subs->direction = stream; 2247 subs->direction = stream;
2221 subs->dev = as->chip->dev; 2248 subs->dev = as->chip->dev;
2222 if (snd_usb_get_speed(subs->dev) == USB_SPEED_FULL) 2249 if (snd_usb_get_speed(subs->dev) == USB_SPEED_FULL) {
2223 subs->ops = audio_urb_ops[stream]; 2250 subs->ops = audio_urb_ops[stream];
2224 else 2251 } else {
2225 subs->ops = audio_urb_ops_high_speed[stream]; 2252 subs->ops = audio_urb_ops_high_speed[stream];
2253 switch (as->chip->usb_id) {
2254 case USB_ID(0x041e, 0x3f02): /* E-Mu 0202 USB */
2255 case USB_ID(0x041e, 0x3f04): /* E-Mu 0404 USB */
2256 subs->ops.retire_sync = retire_playback_sync_urb_hs_emu;
2257 break;
2258 }
2259 }
2226 snd_pcm_set_ops(as->pcm, stream, 2260 snd_pcm_set_ops(as->pcm, stream,
2227 stream == SNDRV_PCM_STREAM_PLAYBACK ? 2261 stream == SNDRV_PCM_STREAM_PLAYBACK ?
2228 &snd_usb_playback_ops : &snd_usb_capture_ops); 2262 &snd_usb_playback_ops : &snd_usb_capture_ops);
diff --git a/sound/usb/usbmidi.c b/sound/usb/usbmidi.c
index 750e929d5870..6676a177c99e 100644
--- a/sound/usb/usbmidi.c
+++ b/sound/usb/usbmidi.c
@@ -104,12 +104,14 @@ struct snd_usb_midi {
104 struct usb_protocol_ops* usb_protocol_ops; 104 struct usb_protocol_ops* usb_protocol_ops;
105 struct list_head list; 105 struct list_head list;
106 struct timer_list error_timer; 106 struct timer_list error_timer;
107 spinlock_t disc_lock;
107 108
108 struct snd_usb_midi_endpoint { 109 struct snd_usb_midi_endpoint {
109 struct snd_usb_midi_out_endpoint *out; 110 struct snd_usb_midi_out_endpoint *out;
110 struct snd_usb_midi_in_endpoint *in; 111 struct snd_usb_midi_in_endpoint *in;
111 } endpoints[MIDI_MAX_ENDPOINTS]; 112 } endpoints[MIDI_MAX_ENDPOINTS];
112 unsigned long input_triggered; 113 unsigned long input_triggered;
114 unsigned char disconnected;
113}; 115};
114 116
115struct snd_usb_midi_out_endpoint { 117struct snd_usb_midi_out_endpoint {
@@ -306,6 +308,11 @@ static void snd_usbmidi_error_timer(unsigned long data)
306 struct snd_usb_midi *umidi = (struct snd_usb_midi *)data; 308 struct snd_usb_midi *umidi = (struct snd_usb_midi *)data;
307 int i; 309 int i;
308 310
311 spin_lock(&umidi->disc_lock);
312 if (umidi->disconnected) {
313 spin_unlock(&umidi->disc_lock);
314 return;
315 }
309 for (i = 0; i < MIDI_MAX_ENDPOINTS; ++i) { 316 for (i = 0; i < MIDI_MAX_ENDPOINTS; ++i) {
310 struct snd_usb_midi_in_endpoint *in = umidi->endpoints[i].in; 317 struct snd_usb_midi_in_endpoint *in = umidi->endpoints[i].in;
311 if (in && in->error_resubmit) { 318 if (in && in->error_resubmit) {
@@ -316,6 +323,7 @@ static void snd_usbmidi_error_timer(unsigned long data)
316 if (umidi->endpoints[i].out) 323 if (umidi->endpoints[i].out)
317 snd_usbmidi_do_output(umidi->endpoints[i].out); 324 snd_usbmidi_do_output(umidi->endpoints[i].out);
318 } 325 }
326 spin_unlock(&umidi->disc_lock);
319} 327}
320 328
321/* helper function to send static data that may not DMA-able */ 329/* helper function to send static data that may not DMA-able */
@@ -1049,7 +1057,14 @@ void snd_usbmidi_disconnect(struct list_head* p)
1049 int i; 1057 int i;
1050 1058
1051 umidi = list_entry(p, struct snd_usb_midi, list); 1059 umidi = list_entry(p, struct snd_usb_midi, list);
1052 del_timer_sync(&umidi->error_timer); 1060 /*
1061 * an URB's completion handler may start the timer and
1062 * a timer may submit an URB. To reliably break the cycle
1063 * a flag under lock must be used
1064 */
1065 spin_lock_irq(&umidi->disc_lock);
1066 umidi->disconnected = 1;
1067 spin_unlock_irq(&umidi->disc_lock);
1053 for (i = 0; i < MIDI_MAX_ENDPOINTS; ++i) { 1068 for (i = 0; i < MIDI_MAX_ENDPOINTS; ++i) {
1054 struct snd_usb_midi_endpoint* ep = &umidi->endpoints[i]; 1069 struct snd_usb_midi_endpoint* ep = &umidi->endpoints[i];
1055 if (ep->out) 1070 if (ep->out)
@@ -1062,6 +1077,7 @@ void snd_usbmidi_disconnect(struct list_head* p)
1062 if (ep->in) 1077 if (ep->in)
1063 usb_kill_urb(ep->in->urb); 1078 usb_kill_urb(ep->in->urb);
1064 } 1079 }
1080 del_timer_sync(&umidi->error_timer);
1065} 1081}
1066 1082
1067static void snd_usbmidi_rawmidi_free(struct snd_rawmidi *rmidi) 1083static void snd_usbmidi_rawmidi_free(struct snd_rawmidi *rmidi)
@@ -1685,6 +1701,7 @@ int snd_usb_create_midi_interface(struct snd_usb_audio* chip,
1685 umidi->quirk = quirk; 1701 umidi->quirk = quirk;
1686 umidi->usb_protocol_ops = &snd_usbmidi_standard_ops; 1702 umidi->usb_protocol_ops = &snd_usbmidi_standard_ops;
1687 init_timer(&umidi->error_timer); 1703 init_timer(&umidi->error_timer);
1704 spin_lock_init(&umidi->disc_lock);
1688 umidi->error_timer.function = snd_usbmidi_error_timer; 1705 umidi->error_timer.function = snd_usbmidi_error_timer;
1689 umidi->error_timer.data = (unsigned long)umidi; 1706 umidi->error_timer.data = (unsigned long)umidi;
1690 1707