Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 182749
b: refs/heads/master
c: 04b5efe
h: refs/heads/master
i:
  182747: 362ece5
v: v3
  • Loading branch information
Charles Chin authored and Takashi Iwai committed Feb 4, 2010
1 parent 9342436 commit f387542
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 18 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a9694faa287888b4fb10849649b6c94d0a1c9940
refs/heads/master: 04b5efe5fa7f71c37b938053666fac317b67c636
30 changes: 13 additions & 17 deletions trunk/sound/pci/hda/patch_sigmatel.c
Original file line number Diff line number Diff line change
Expand Up @@ -5291,7 +5291,6 @@ static int patch_stac92hd83xxx(struct hda_codec *codec)
hda_nid_t conn[STAC92HD83_DAC_COUNT + 1];
int err;
int num_dacs;
hda_nid_t nid;

spec = kzalloc(sizeof(*spec), GFP_KERNEL);
if (spec == NULL)
Expand Down Expand Up @@ -5387,24 +5386,21 @@ static int patch_stac92hd83xxx(struct hda_codec *codec)
return err;
}

switch (spec->board_config) {
case STAC_DELL_S14:
nid = 0xf;
break;
default:
nid = 0xe;
break;
}

num_dacs = snd_hda_get_connections(codec, nid,
/* docking output support */
num_dacs = snd_hda_get_connections(codec, 0xF,
conn, STAC92HD83_DAC_COUNT + 1) - 1;
if (num_dacs < 0)
num_dacs = STAC92HD83_DAC_COUNT;

/* set port X to select the last DAC
*/
snd_hda_codec_write_cache(codec, nid, 0,
/* skip non-DAC connections */
while (num_dacs >= 0 &&
(get_wcaps_type(get_wcaps(codec, conn[num_dacs]))
!= AC_WID_AUD_OUT))
num_dacs--;
/* set port E and F to select the last DAC */
if (num_dacs >= 0) {
snd_hda_codec_write_cache(codec, 0xE, 0,
AC_VERB_SET_CONNECT_SEL, num_dacs);
snd_hda_codec_write_cache(codec, 0xF, 0,
AC_VERB_SET_CONNECT_SEL, num_dacs);
}

codec->proc_widget_hook = stac92hd_proc_hook;

Expand Down

0 comments on commit f387542

Please sign in to comment.