Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 257767
b: refs/heads/master
c: 6e969d9
h: refs/heads/master
i:
  257765: 177ed4d
  257763: cefeabe
  257759: 26176bb
v: v3
  • Loading branch information
Takashi Iwai committed Jul 11, 2011
1 parent 07c5bea commit 88d6d8e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 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: 21ce0b65272b85f122455818b0c69740945b451a
refs/heads/master: 6e969d9155a4ee7bce800dfbee02099105ca5b97
21 changes: 11 additions & 10 deletions trunk/sound/pci/hda/patch_via.c
Original file line number Diff line number Diff line change
Expand Up @@ -615,6 +615,7 @@ static void via_auto_init_speaker_out(struct hda_codec *codec)
}

static bool is_smart51_pins(struct hda_codec *codec, hda_nid_t pin);
static void via_hp_automute(struct hda_codec *codec);

static void via_auto_init_analog_input(struct hda_codec *codec)
{
Expand Down Expand Up @@ -801,6 +802,7 @@ static int via_independent_hp_put(struct snd_kcontrol *kcontrol,

/* update jack power state */
set_widgets_power_state(codec);
via_hp_automute(codec);
return 1;
}

Expand Down Expand Up @@ -1532,19 +1534,18 @@ static void via_line_automute(struct hda_codec *codec, int present)
static void via_hp_automute(struct hda_codec *codec)
{
int present = 0;
int nums;
struct via_spec *spec = codec->spec;

if (!spec->hp_independent_mode && spec->autocfg.hp_pins[0]) {
int nums;
if (!spec->hp_independent_mode && spec->autocfg.hp_pins[0])
present = snd_hda_jack_detect(codec, spec->autocfg.hp_pins[0]);
if (spec->smart51_enabled)
nums = spec->autocfg.line_outs + spec->smart51_nums;
else
nums = spec->autocfg.line_outs;
toggle_output_mutes(codec, nums,
spec->autocfg.line_out_pins,
present);
}

if (spec->smart51_enabled)
nums = spec->autocfg.line_outs + spec->smart51_nums;
else
nums = spec->autocfg.line_outs;
toggle_output_mutes(codec, nums, spec->autocfg.line_out_pins, present);

via_line_automute(codec, present);
}

Expand Down

0 comments on commit 88d6d8e

Please sign in to comment.