Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 284184
b: refs/heads/master
c: e29d377
h: refs/heads/master
v: v3
  • Loading branch information
Takashi Iwai committed Nov 14, 2011
1 parent 0842fe7 commit 3314e6c
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 5 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: c3e837bbcc03e39991da5dd1f791c06cde9f7a45
refs/heads/master: e29d377814b83af816fb8c1857605b9c4196477b
21 changes: 17 additions & 4 deletions trunk/sound/pci/hda/patch_realtek.c
Original file line number Diff line number Diff line change
Expand Up @@ -3144,8 +3144,15 @@ static int alc_auto_add_vol_ctl(struct hda_codec *codec,
val);
}

#define alc_auto_add_stereo_vol(codec, pfx, cidx, nid) \
alc_auto_add_vol_ctl(codec, pfx, cidx, nid, 3)
static int alc_auto_add_stereo_vol(struct hda_codec *codec,
const char *pfx, int cidx,
hda_nid_t nid)
{
int chs = 1;
if (get_wcaps(codec, nid) & AC_WCAP_STEREO)
chs = 3;
return alc_auto_add_vol_ctl(codec, pfx, cidx, nid, chs);
}

/* create a mute-switch for the given mixer widget;
* if it has multiple sources (e.g. DAC and loopback), create a bind-mute
Expand Down Expand Up @@ -3177,8 +3184,14 @@ static int alc_auto_add_sw_ctl(struct hda_codec *codec,
return __add_pb_sw_ctrl(codec->spec, type, pfx, cidx, val);
}

#define alc_auto_add_stereo_sw(codec, pfx, cidx, nid) \
alc_auto_add_sw_ctl(codec, pfx, cidx, nid, 3)
static int alc_auto_add_stereo_sw(struct hda_codec *codec, const char *pfx,
int cidx, hda_nid_t nid)
{
int chs = 1;
if (get_wcaps(codec, nid) & AC_WCAP_STEREO)
chs = 3;
return alc_auto_add_sw_ctl(codec, pfx, cidx, nid, chs);
}

static hda_nid_t alc_look_for_out_mute_nid(struct hda_codec *codec,
hda_nid_t pin, hda_nid_t dac)
Expand Down

0 comments on commit 3314e6c

Please sign in to comment.