aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/hda_codec.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/hda/hda_codec.c')
-rw-r--r--sound/pci/hda/hda_codec.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index 94d848e98716..ec352c6ae49a 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -316,6 +316,8 @@ int snd_hda_get_connections(struct hda_codec *codec, hda_nid_t nid,
316 /* single connection */ 316 /* single connection */
317 parm = snd_hda_codec_read(codec, nid, 0, 317 parm = snd_hda_codec_read(codec, nid, 0,
318 AC_VERB_GET_CONNECT_LIST, 0); 318 AC_VERB_GET_CONNECT_LIST, 0);
319 if (parm == -1 && codec->bus->rirb_error)
320 return -EIO;
319 conn_list[0] = parm & mask; 321 conn_list[0] = parm & mask;
320 return 1; 322 return 1;
321 } 323 }
@@ -327,9 +329,12 @@ int snd_hda_get_connections(struct hda_codec *codec, hda_nid_t nid,
327 int range_val; 329 int range_val;
328 hda_nid_t val, n; 330 hda_nid_t val, n;
329 331
330 if (i % num_elems == 0) 332 if (i % num_elems == 0) {
331 parm = snd_hda_codec_read(codec, nid, 0, 333 parm = snd_hda_codec_read(codec, nid, 0,
332 AC_VERB_GET_CONNECT_LIST, i); 334 AC_VERB_GET_CONNECT_LIST, i);
335 if (parm == -1 && codec->bus->rirb_error)
336 return -EIO;
337 }
333 range_val = !!(parm & (1 << (shift-1))); /* ranges */ 338 range_val = !!(parm & (1 << (shift-1))); /* ranges */
334 val = parm & mask; 339 val = parm & mask;
335 parm >>= shift; 340 parm >>= shift;