aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2011-11-23 11:08:42 -0500
committerTakashi Iwai <tiwai@suse.de>2011-11-23 11:08:42 -0500
commitb37c0096b448d099d304bb47c4eada9117dba4cf (patch)
treec38f4c41874967a8f187e4c972b6365fb7a9f7cf /sound
parent8b940fc457fbf883053caf397586a61bd3cae23e (diff)
parent61071594f64ed12328046f94716d1d744bddc0a1 (diff)
Merge branch 'fix/hda' into topic/hda
Conflicts: sound/pci/hda/patch_realtek.c
Diffstat (limited to 'sound')
-rw-r--r--sound/pci/cs5535audio/cs5535audio_pcm.c2
-rw-r--r--sound/pci/hda/hda_codec.c6
-rw-r--r--sound/pci/hda/hda_eld.c28
-rw-r--r--sound/pci/hda/patch_cirrus.c55
-rw-r--r--sound/pci/hda/patch_hdmi.c16
-rw-r--r--sound/pci/hda/patch_realtek.c34
-rw-r--r--sound/pci/hda/patch_sigmatel.c2
-rw-r--r--sound/pci/lx6464es/lx_core.c23
-rw-r--r--sound/pci/lx6464es/lx_core.h3
-rw-r--r--sound/pci/rme9652/hdspm.c2
10 files changed, 111 insertions, 60 deletions
diff --git a/sound/pci/cs5535audio/cs5535audio_pcm.c b/sound/pci/cs5535audio/cs5535audio_pcm.c
index e083122ca55a..dbf94b189e75 100644
--- a/sound/pci/cs5535audio/cs5535audio_pcm.c
+++ b/sound/pci/cs5535audio/cs5535audio_pcm.c
@@ -148,7 +148,7 @@ static int cs5535audio_build_dma_packets(struct cs5535audio *cs5535au,
148 struct cs5535audio_dma_desc *desc = 148 struct cs5535audio_dma_desc *desc =
149 &((struct cs5535audio_dma_desc *) dma->desc_buf.area)[i]; 149 &((struct cs5535audio_dma_desc *) dma->desc_buf.area)[i];
150 desc->addr = cpu_to_le32(addr); 150 desc->addr = cpu_to_le32(addr);
151 desc->size = cpu_to_le32(period_bytes); 151 desc->size = cpu_to_le16(period_bytes);
152 desc->ctlreserved = cpu_to_le16(PRD_EOP); 152 desc->ctlreserved = cpu_to_le16(PRD_EOP);
153 desc_addr += sizeof(struct cs5535audio_dma_desc); 153 desc_addr += sizeof(struct cs5535audio_dma_desc);
154 addr += period_bytes; 154 addr += period_bytes;
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index e44b107fdc75..4562e9de6a1a 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -4046,9 +4046,9 @@ int snd_hda_check_board_codec_sid_config(struct hda_codec *codec,
4046 4046
4047 /* Search for codec ID */ 4047 /* Search for codec ID */
4048 for (q = tbl; q->subvendor; q++) { 4048 for (q = tbl; q->subvendor; q++) {
4049 unsigned long vendorid = (q->subdevice) | (q->subvendor << 16); 4049 unsigned int mask = 0xffff0000 | q->subdevice_mask;
4050 4050 unsigned int id = (q->subdevice | (q->subvendor << 16)) & mask;
4051 if (vendorid == codec->subsystem_id) 4051 if ((codec->subsystem_id & mask) == id)
4052 break; 4052 break;
4053 } 4053 }
4054 4054
diff --git a/sound/pci/hda/hda_eld.c b/sound/pci/hda/hda_eld.c
index 7ae7578bdcc0..c1da422e085a 100644
--- a/sound/pci/hda/hda_eld.c
+++ b/sound/pci/hda/hda_eld.c
@@ -347,18 +347,28 @@ int snd_hdmi_get_eld(struct hdmi_eld *eld,
347 347
348 for (i = 0; i < size; i++) { 348 for (i = 0; i < size; i++) {
349 unsigned int val = hdmi_get_eld_data(codec, nid, i); 349 unsigned int val = hdmi_get_eld_data(codec, nid, i);
350 /*
351 * Graphics driver might be writing to ELD buffer right now.
352 * Just abort. The caller will repoll after a while.
353 */
350 if (!(val & AC_ELDD_ELD_VALID)) { 354 if (!(val & AC_ELDD_ELD_VALID)) {
351 if (!i) {
352 snd_printd(KERN_INFO
353 "HDMI: invalid ELD data\n");
354 ret = -EINVAL;
355 goto error;
356 }
357 snd_printd(KERN_INFO 355 snd_printd(KERN_INFO
358 "HDMI: invalid ELD data byte %d\n", i); 356 "HDMI: invalid ELD data byte %d\n", i);
359 val = 0; 357 ret = -EINVAL;
360 } else 358 goto error;
361 val &= AC_ELDD_ELD_DATA; 359 }
360 val &= AC_ELDD_ELD_DATA;
361 /*
362 * The first byte cannot be zero. This can happen on some DVI
363 * connections. Some Intel chips may also need some 250ms delay
364 * to return non-zero ELD data, even when the graphics driver
365 * correctly writes ELD content before setting ELD_valid bit.
366 */
367 if (!val && !i) {
368 snd_printdd(KERN_INFO "HDMI: 0 ELD data\n");
369 ret = -EINVAL;
370 goto error;
371 }
362 buf[i] = val; 372 buf[i] = val;
363 } 373 }
364 374
diff --git a/sound/pci/hda/patch_cirrus.c b/sound/pci/hda/patch_cirrus.c
index 2a2d8645ba09..7bd2a52f2bac 100644
--- a/sound/pci/hda/patch_cirrus.c
+++ b/sound/pci/hda/patch_cirrus.c
@@ -58,6 +58,8 @@ struct cs_spec {
58 unsigned int gpio_mask; 58 unsigned int gpio_mask;
59 unsigned int gpio_dir; 59 unsigned int gpio_dir;
60 unsigned int gpio_data; 60 unsigned int gpio_data;
61 unsigned int gpio_eapd_hp; /* EAPD GPIO bit for headphones */
62 unsigned int gpio_eapd_speaker; /* EAPD GPIO bit for speakers */
61 63
62 struct hda_pcm pcm_rec[2]; /* PCM information */ 64 struct hda_pcm pcm_rec[2]; /* PCM information */
63 65
@@ -76,6 +78,7 @@ enum {
76 CS420X_MBP53, 78 CS420X_MBP53,
77 CS420X_MBP55, 79 CS420X_MBP55,
78 CS420X_IMAC27, 80 CS420X_IMAC27,
81 CS420X_APPLE,
79 CS420X_AUTO, 82 CS420X_AUTO,
80 CS420X_MODELS 83 CS420X_MODELS
81}; 84};
@@ -237,6 +240,15 @@ static int cs_dig_playback_pcm_cleanup(struct hda_pcm_stream *hinfo,
237 return snd_hda_multi_out_dig_cleanup(codec, &spec->multiout); 240 return snd_hda_multi_out_dig_cleanup(codec, &spec->multiout);
238} 241}
239 242
243static void cs_update_input_select(struct hda_codec *codec)
244{
245 struct cs_spec *spec = codec->spec;
246 if (spec->cur_adc)
247 snd_hda_codec_write(codec, spec->cur_adc, 0,
248 AC_VERB_SET_CONNECT_SEL,
249 spec->adc_idx[spec->cur_input]);
250}
251
240/* 252/*
241 * Analog capture 253 * Analog capture
242 */ 254 */
@@ -250,6 +262,7 @@ static int cs_capture_pcm_prepare(struct hda_pcm_stream *hinfo,
250 spec->cur_adc = spec->adc_nid[spec->cur_input]; 262 spec->cur_adc = spec->adc_nid[spec->cur_input];
251 spec->cur_adc_stream_tag = stream_tag; 263 spec->cur_adc_stream_tag = stream_tag;
252 spec->cur_adc_format = format; 264 spec->cur_adc_format = format;
265 cs_update_input_select(codec);
253 snd_hda_codec_setup_stream(codec, spec->cur_adc, stream_tag, 0, format); 266 snd_hda_codec_setup_stream(codec, spec->cur_adc, stream_tag, 0, format);
254 return 0; 267 return 0;
255} 268}
@@ -689,10 +702,8 @@ static int change_cur_input(struct hda_codec *codec, unsigned int idx,
689 spec->cur_adc_stream_tag, 0, 702 spec->cur_adc_stream_tag, 0,
690 spec->cur_adc_format); 703 spec->cur_adc_format);
691 } 704 }
692 snd_hda_codec_write(codec, spec->cur_adc, 0,
693 AC_VERB_SET_CONNECT_SEL,
694 spec->adc_idx[idx]);
695 spec->cur_input = idx; 705 spec->cur_input = idx;
706 cs_update_input_select(codec);
696 return 1; 707 return 1;
697} 708}
698 709
@@ -920,10 +931,9 @@ static void cs_automute(struct hda_codec *codec)
920 spdif_present ? 0 : PIN_OUT); 931 spdif_present ? 0 : PIN_OUT);
921 } 932 }
922 } 933 }
923 if (spec->board_config == CS420X_MBP53 || 934 if (spec->gpio_eapd_hp) {
924 spec->board_config == CS420X_MBP55 || 935 unsigned int gpio = hp_present ?
925 spec->board_config == CS420X_IMAC27) { 936 spec->gpio_eapd_hp : spec->gpio_eapd_speaker;
926 unsigned int gpio = hp_present ? 0x02 : 0x08;
927 snd_hda_codec_write(codec, 0x01, 0, 937 snd_hda_codec_write(codec, 0x01, 0,
928 AC_VERB_SET_GPIO_DATA, gpio); 938 AC_VERB_SET_GPIO_DATA, gpio);
929 } 939 }
@@ -973,10 +983,7 @@ static void cs_automic(struct hda_codec *codec)
973 } else { 983 } else {
974 spec->cur_input = spec->last_input; 984 spec->cur_input = spec->last_input;
975 } 985 }
976 986 cs_update_input_select(codec);
977 snd_hda_codec_write_cache(codec, spec->cur_adc, 0,
978 AC_VERB_SET_CONNECT_SEL,
979 spec->adc_idx[spec->cur_input]);
980 } else { 987 } else {
981 if (present) 988 if (present)
982 change_cur_input(codec, spec->automic_idx, 0); 989 change_cur_input(codec, spec->automic_idx, 0);
@@ -1073,9 +1080,7 @@ static void init_input(struct hda_codec *codec)
1073 cs_automic(codec); 1080 cs_automic(codec);
1074 else { 1081 else {
1075 spec->cur_adc = spec->adc_nid[spec->cur_input]; 1082 spec->cur_adc = spec->adc_nid[spec->cur_input];
1076 snd_hda_codec_write(codec, spec->cur_adc, 0, 1083 cs_update_input_select(codec);
1077 AC_VERB_SET_CONNECT_SEL,
1078 spec->adc_idx[spec->cur_input]);
1079 } 1084 }
1080 } else { 1085 } else {
1081 change_cur_input(codec, spec->cur_input, 1); 1086 change_cur_input(codec, spec->cur_input, 1);
@@ -1273,6 +1278,7 @@ static const char * const cs420x_models[CS420X_MODELS] = {
1273 [CS420X_MBP53] = "mbp53", 1278 [CS420X_MBP53] = "mbp53",
1274 [CS420X_MBP55] = "mbp55", 1279 [CS420X_MBP55] = "mbp55",
1275 [CS420X_IMAC27] = "imac27", 1280 [CS420X_IMAC27] = "imac27",
1281 [CS420X_IMAC27] = "apple",
1276 [CS420X_AUTO] = "auto", 1282 [CS420X_AUTO] = "auto",
1277}; 1283};
1278 1284
@@ -1282,7 +1288,13 @@ static const struct snd_pci_quirk cs420x_cfg_tbl[] = {
1282 SND_PCI_QUIRK(0x10de, 0x0d94, "MacBookAir 3,1(2)", CS420X_MBP55), 1288 SND_PCI_QUIRK(0x10de, 0x0d94, "MacBookAir 3,1(2)", CS420X_MBP55),
1283 SND_PCI_QUIRK(0x10de, 0xcb79, "MacBookPro 5,5", CS420X_MBP55), 1289 SND_PCI_QUIRK(0x10de, 0xcb79, "MacBookPro 5,5", CS420X_MBP55),
1284 SND_PCI_QUIRK(0x10de, 0xcb89, "MacBookPro 7,1", CS420X_MBP55), 1290 SND_PCI_QUIRK(0x10de, 0xcb89, "MacBookPro 7,1", CS420X_MBP55),
1285 SND_PCI_QUIRK(0x8086, 0x7270, "IMac 27 Inch", CS420X_IMAC27), 1291 /* this conflicts with too many other models */
1292 /*SND_PCI_QUIRK(0x8086, 0x7270, "IMac 27 Inch", CS420X_IMAC27),*/
1293 {} /* terminator */
1294};
1295
1296static const struct snd_pci_quirk cs420x_codec_cfg_tbl[] = {
1297 SND_PCI_QUIRK_VENDOR(0x106b, "Apple", CS420X_APPLE),
1286 {} /* terminator */ 1298 {} /* terminator */
1287}; 1299};
1288 1300
@@ -1364,6 +1376,10 @@ static int patch_cs420x(struct hda_codec *codec)
1364 spec->board_config = 1376 spec->board_config =
1365 snd_hda_check_board_config(codec, CS420X_MODELS, 1377 snd_hda_check_board_config(codec, CS420X_MODELS,
1366 cs420x_models, cs420x_cfg_tbl); 1378 cs420x_models, cs420x_cfg_tbl);
1379 if (spec->board_config < 0)
1380 spec->board_config =
1381 snd_hda_check_board_codec_sid_config(codec,
1382 CS420X_MODELS, NULL, cs420x_codec_cfg_tbl);
1367 if (spec->board_config >= 0) 1383 if (spec->board_config >= 0)
1368 fix_pincfg(codec, spec->board_config, cs_pincfgs); 1384 fix_pincfg(codec, spec->board_config, cs_pincfgs);
1369 1385
@@ -1371,10 +1387,11 @@ static int patch_cs420x(struct hda_codec *codec)
1371 case CS420X_IMAC27: 1387 case CS420X_IMAC27:
1372 case CS420X_MBP53: 1388 case CS420X_MBP53:
1373 case CS420X_MBP55: 1389 case CS420X_MBP55:
1374 /* GPIO1 = headphones */ 1390 case CS420X_APPLE:
1375 /* GPIO3 = speakers */ 1391 spec->gpio_eapd_hp = 2; /* GPIO1 = headphones */
1376 spec->gpio_mask = 0x0a; 1392 spec->gpio_eapd_speaker = 8; /* GPIO3 = speakers */
1377 spec->gpio_dir = 0x0a; 1393 spec->gpio_mask = spec->gpio_dir =
1394 spec->gpio_eapd_hp | spec->gpio_eapd_speaker;
1378 break; 1395 break;
1379 } 1396 }
1380 1397
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
index 9850c5b481ea..c505fd5d338c 100644
--- a/sound/pci/hda/patch_hdmi.c
+++ b/sound/pci/hda/patch_hdmi.c
@@ -69,6 +69,7 @@ struct hdmi_spec_per_pin {
69 struct hda_codec *codec; 69 struct hda_codec *codec;
70 struct hdmi_eld sink_eld; 70 struct hdmi_eld sink_eld;
71 struct delayed_work work; 71 struct delayed_work work;
72 int repoll_count;
72}; 73};
73 74
74struct hdmi_spec { 75struct hdmi_spec {
@@ -748,7 +749,7 @@ static void hdmi_setup_audio_infoframe(struct hda_codec *codec, int pin_idx,
748 * Unsolicited events 749 * Unsolicited events
749 */ 750 */
750 751
751static void hdmi_present_sense(struct hdmi_spec_per_pin *per_pin, bool retry); 752static void hdmi_present_sense(struct hdmi_spec_per_pin *per_pin, int repoll);
752 753
753static void hdmi_intrinsic_event(struct hda_codec *codec, unsigned int res) 754static void hdmi_intrinsic_event(struct hda_codec *codec, unsigned int res)
754{ 755{
@@ -766,7 +767,7 @@ static void hdmi_intrinsic_event(struct hda_codec *codec, unsigned int res)
766 if (pin_idx < 0) 767 if (pin_idx < 0)
767 return; 768 return;
768 769
769 hdmi_present_sense(&spec->pins[pin_idx], true); 770 hdmi_present_sense(&spec->pins[pin_idx], 1);
770} 771}
771 772
772static void hdmi_non_intrinsic_event(struct hda_codec *codec, unsigned int res) 773static void hdmi_non_intrinsic_event(struct hda_codec *codec, unsigned int res)
@@ -960,7 +961,7 @@ static int hdmi_read_pin_conn(struct hda_codec *codec, int pin_idx)
960 return 0; 961 return 0;
961} 962}
962 963
963static void hdmi_present_sense(struct hdmi_spec_per_pin *per_pin, bool retry) 964static void hdmi_present_sense(struct hdmi_spec_per_pin *per_pin, int repoll)
964{ 965{
965 struct hda_codec *codec = per_pin->codec; 966 struct hda_codec *codec = per_pin->codec;
966 struct hdmi_eld *eld = &per_pin->sink_eld; 967 struct hdmi_eld *eld = &per_pin->sink_eld;
@@ -989,7 +990,7 @@ static void hdmi_present_sense(struct hdmi_spec_per_pin *per_pin, bool retry)
989 if (eld_valid) { 990 if (eld_valid) {
990 if (!snd_hdmi_get_eld(eld, codec, pin_nid)) 991 if (!snd_hdmi_get_eld(eld, codec, pin_nid))
991 snd_hdmi_show_eld(eld); 992 snd_hdmi_show_eld(eld);
992 else if (retry) { 993 else if (repoll) {
993 queue_delayed_work(codec->bus->workq, 994 queue_delayed_work(codec->bus->workq,
994 &per_pin->work, 995 &per_pin->work,
995 msecs_to_jiffies(300)); 996 msecs_to_jiffies(300));
@@ -1004,7 +1005,10 @@ static void hdmi_repoll_eld(struct work_struct *work)
1004 struct hdmi_spec_per_pin *per_pin = 1005 struct hdmi_spec_per_pin *per_pin =
1005 container_of(to_delayed_work(work), struct hdmi_spec_per_pin, work); 1006 container_of(to_delayed_work(work), struct hdmi_spec_per_pin, work);
1006 1007
1007 hdmi_present_sense(per_pin, false); 1008 if (per_pin->repoll_count++ > 6)
1009 per_pin->repoll_count = 0;
1010
1011 hdmi_present_sense(per_pin, per_pin->repoll_count);
1008} 1012}
1009 1013
1010static int hdmi_add_pin(struct hda_codec *codec, hda_nid_t pin_nid) 1014static int hdmi_add_pin(struct hda_codec *codec, hda_nid_t pin_nid)
@@ -1235,7 +1239,7 @@ static int generic_hdmi_build_jack(struct hda_codec *codec, int pin_idx)
1235 if (err < 0) 1239 if (err < 0)
1236 return err; 1240 return err;
1237 1241
1238 hdmi_present_sense(per_pin, false); 1242 hdmi_present_sense(per_pin, 0);
1239 return 0; 1243 return 0;
1240} 1244}
1241 1245
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 14feecf2d802..63186d7d18a9 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -278,6 +278,12 @@ static bool alc_dyn_adc_pcm_resetup(struct hda_codec *codec, int cur)
278 return false; 278 return false;
279} 279}
280 280
281static inline hda_nid_t get_capsrc(struct alc_spec *spec, int idx)
282{
283 return spec->capsrc_nids ?
284 spec->capsrc_nids[idx] : spec->adc_nids[idx];
285}
286
281static void call_update_outputs(struct hda_codec *codec); 287static void call_update_outputs(struct hda_codec *codec);
282 288
283/* select the given imux item; either unmute exclusively or select the route */ 289/* select the given imux item; either unmute exclusively or select the route */
@@ -319,8 +325,7 @@ static int alc_mux_select(struct hda_codec *codec, unsigned int adc_idx,
319 adc_idx = spec->dyn_adc_idx[idx]; 325 adc_idx = spec->dyn_adc_idx[idx];
320 } 326 }
321 327
322 nid = spec->capsrc_nids ? 328 nid = get_capsrc(spec, adc_idx);
323 spec->capsrc_nids[adc_idx] : spec->adc_nids[adc_idx];
324 329
325 /* no selection? */ 330 /* no selection? */
326 num_conns = snd_hda_get_conn_list(codec, nid, NULL); 331 num_conns = snd_hda_get_conn_list(codec, nid, NULL);
@@ -1071,8 +1076,19 @@ static bool alc_rebuild_imux_for_auto_mic(struct hda_codec *codec)
1071 spec->imux_pins[2] = spec->dock_mic_pin; 1076 spec->imux_pins[2] = spec->dock_mic_pin;
1072 for (i = 0; i < 3; i++) { 1077 for (i = 0; i < 3; i++) {
1073 strcpy(imux->items[i].label, texts[i]); 1078 strcpy(imux->items[i].label, texts[i]);
1074 if (spec->imux_pins[i]) 1079 if (spec->imux_pins[i]) {
1080 hda_nid_t pin = spec->imux_pins[i];
1081 int c;
1082 for (c = 0; c < spec->num_adc_nids; c++) {
1083 hda_nid_t cap = get_capsrc(spec, c);
1084 int idx = get_connection_index(codec, cap, pin);
1085 if (idx >= 0) {
1086 imux->items[i].index = idx;
1087 break;
1088 }
1089 }
1075 imux->num_items = i + 1; 1090 imux->num_items = i + 1;
1091 }
1076 } 1092 }
1077 spec->num_mux_defs = 1; 1093 spec->num_mux_defs = 1;
1078 spec->input_mux = imux; 1094 spec->input_mux = imux;
@@ -1991,10 +2007,8 @@ static int alc_build_controls(struct hda_codec *codec)
1991 if (!kctl) 2007 if (!kctl)
1992 kctl = snd_hda_find_mixer_ctl(codec, "Input Source"); 2008 kctl = snd_hda_find_mixer_ctl(codec, "Input Source");
1993 for (i = 0; kctl && i < kctl->count; i++) { 2009 for (i = 0; kctl && i < kctl->count; i++) {
1994 const hda_nid_t *nids = spec->capsrc_nids; 2010 err = snd_hda_add_nid(codec, kctl, i,
1995 if (!nids) 2011 get_capsrc(spec, i));
1996 nids = spec->adc_nids;
1997 err = snd_hda_add_nid(codec, kctl, i, nids[i]);
1998 if (err < 0) 2012 if (err < 0)
1999 return err; 2013 return err;
2000 } 2014 }
@@ -2786,8 +2800,7 @@ static int alc_auto_create_input_ctls(struct hda_codec *codec)
2786 } 2800 }
2787 2801
2788 for (c = 0; c < num_adcs; c++) { 2802 for (c = 0; c < num_adcs; c++) {
2789 hda_nid_t cap = spec->capsrc_nids ? 2803 hda_nid_t cap = get_capsrc(spec, c);
2790 spec->capsrc_nids[c] : spec->adc_nids[c];
2791 idx = get_connection_index(codec, cap, pin); 2804 idx = get_connection_index(codec, cap, pin);
2792 if (idx >= 0) { 2805 if (idx >= 0) {
2793 spec->imux_pins[imux->num_items] = pin; 2806 spec->imux_pins[imux->num_items] = pin;
@@ -3820,8 +3833,7 @@ static int init_capsrc_for_pin(struct hda_codec *codec, hda_nid_t pin)
3820 if (!pin) 3833 if (!pin)
3821 return 0; 3834 return 0;
3822 for (i = 0; i < spec->num_adc_nids; i++) { 3835 for (i = 0; i < spec->num_adc_nids; i++) {
3823 hda_nid_t cap = spec->capsrc_nids ? 3836 hda_nid_t cap = get_capsrc(spec, i);
3824 spec->capsrc_nids[i] : spec->adc_nids[i];
3825 int idx; 3837 int idx;
3826 3838
3827 idx = get_connection_index(codec, cap, pin); 3839 idx = get_connection_index(codec, cap, pin);
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index 470f6f286e81..f3658658548e 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -1641,6 +1641,8 @@ static const struct snd_pci_quirk stac92hd73xx_codec_id_cfg_tbl[] = {
1641 "Alienware M17x", STAC_ALIENWARE_M17X), 1641 "Alienware M17x", STAC_ALIENWARE_M17X),
1642 SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x043a, 1642 SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x043a,
1643 "Alienware M17x", STAC_ALIENWARE_M17X), 1643 "Alienware M17x", STAC_ALIENWARE_M17X),
1644 SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0490,
1645 "Alienware M17x", STAC_ALIENWARE_M17X),
1644 {} /* terminator */ 1646 {} /* terminator */
1645}; 1647};
1646 1648
diff --git a/sound/pci/lx6464es/lx_core.c b/sound/pci/lx6464es/lx_core.c
index 5c8717e29eeb..8c3e7fcefd99 100644
--- a/sound/pci/lx6464es/lx_core.c
+++ b/sound/pci/lx6464es/lx_core.c
@@ -78,10 +78,15 @@ unsigned long lx_dsp_reg_read(struct lx6464es *chip, int port)
78 return ioread32(address); 78 return ioread32(address);
79} 79}
80 80
81void lx_dsp_reg_readbuf(struct lx6464es *chip, int port, u32 *data, u32 len) 81static void lx_dsp_reg_readbuf(struct lx6464es *chip, int port, u32 *data,
82 u32 len)
82{ 83{
83 void __iomem *address = lx_dsp_register(chip, port); 84 u32 __iomem *address = lx_dsp_register(chip, port);
84 memcpy_fromio(data, address, len*sizeof(u32)); 85 int i;
86
87 /* we cannot use memcpy_fromio */
88 for (i = 0; i != len; ++i)
89 data[i] = ioread32(address + i);
85} 90}
86 91
87 92
@@ -91,11 +96,15 @@ void lx_dsp_reg_write(struct lx6464es *chip, int port, unsigned data)
91 iowrite32(data, address); 96 iowrite32(data, address);
92} 97}
93 98
94void lx_dsp_reg_writebuf(struct lx6464es *chip, int port, const u32 *data, 99static void lx_dsp_reg_writebuf(struct lx6464es *chip, int port,
95 u32 len) 100 const u32 *data, u32 len)
96{ 101{
97 void __iomem *address = lx_dsp_register(chip, port); 102 u32 __iomem *address = lx_dsp_register(chip, port);
98 memcpy_toio(address, data, len*sizeof(u32)); 103 int i;
104
105 /* we cannot use memcpy_to */
106 for (i = 0; i != len; ++i)
107 iowrite32(data[i], address + i);
99} 108}
100 109
101 110
diff --git a/sound/pci/lx6464es/lx_core.h b/sound/pci/lx6464es/lx_core.h
index 1dd562980b6c..4d7ff797a646 100644
--- a/sound/pci/lx6464es/lx_core.h
+++ b/sound/pci/lx6464es/lx_core.h
@@ -72,10 +72,7 @@ enum {
72}; 72};
73 73
74unsigned long lx_dsp_reg_read(struct lx6464es *chip, int port); 74unsigned long lx_dsp_reg_read(struct lx6464es *chip, int port);
75void lx_dsp_reg_readbuf(struct lx6464es *chip, int port, u32 *data, u32 len);
76void lx_dsp_reg_write(struct lx6464es *chip, int port, unsigned data); 75void lx_dsp_reg_write(struct lx6464es *chip, int port, unsigned data);
77void lx_dsp_reg_writebuf(struct lx6464es *chip, int port, const u32 *data,
78 u32 len);
79 76
80/* plx register access */ 77/* plx register access */
81enum { 78enum {
diff --git a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c
index e760adad9523..19ee2203cbb5 100644
--- a/sound/pci/rme9652/hdspm.c
+++ b/sound/pci/rme9652/hdspm.c
@@ -6518,7 +6518,7 @@ static int __devinit snd_hdspm_create(struct snd_card *card,
6518 hdspm->io_type = AES32; 6518 hdspm->io_type = AES32;
6519 hdspm->card_name = "RME AES32"; 6519 hdspm->card_name = "RME AES32";
6520 hdspm->midiPorts = 2; 6520 hdspm->midiPorts = 2;
6521 } else if ((hdspm->firmware_rev == 0xd5) || 6521 } else if ((hdspm->firmware_rev == 0xd2) ||
6522 ((hdspm->firmware_rev >= 0xc8) && 6522 ((hdspm->firmware_rev >= 0xc8) &&
6523 (hdspm->firmware_rev <= 0xcf))) { 6523 (hdspm->firmware_rev <= 0xcf))) {
6524 hdspm->io_type = MADI; 6524 hdspm->io_type = MADI;