Please limit mic boost on Asus 1015E, X55U and K53BE

Bug #1089795 reported by David Henningsson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Undecided
David Henningsson

Bug Description

 /* The mic boosts on level 2 and 3 are too noisy,
    both on internal and external mic inputs.
    Therefore limit the boost to 0 or 1. */

This bug is for tracking purposes. Please do not triage.

Changed in linux (Ubuntu):
assignee: nobody → David Henningsson (diwic)
status: New → In Progress
Changed in linux (Ubuntu):
status: In Progress → Triaged
Revision history for this message
David Henningsson (diwic) wrote : [PATCH] ALSA: hda - Limit internal mic boost for a few Asus machines
Download full text (3.3 KiB)

These are being reported as being so noisy at high mic boost levels,
so they are unusable in practice.
Therefore artificially limit the boosts.

BugLink: https://bugs.launchpad.net/bugs/1089795
Signed-off-by: David Henningsson <email address hidden>
---
 sound/pci/hda/patch_realtek.c | 42 ++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 41 insertions(+), 1 deletion(-)

diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 28b3f5a..6e5d383 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -3156,6 +3156,38 @@ static void alc271_hp_gate_mic_jack(struct hda_codec *codec,
  }
 }

+static void alc269_fixup_limit_int_mic_boost(struct hda_codec *codec,
+ const struct hda_fixup *fix,
+ int action)
+{
+ struct alc_spec *spec = codec->spec;
+ struct auto_pin_cfg *cfg = &spec->gen.autocfg;
+ int i;
+
+ /* The mic boosts on level 2 and 3 are too noisy
+ on the internal mic input.
+ Therefore limit the boost to 0 or 1. */
+
+ if (action != HDA_FIXUP_ACT_PROBE)
+ return;
+
+ for (i = 0; i < cfg->num_inputs; i++) {
+ hda_nid_t nid = cfg->inputs[i].pin;
+ unsigned int defcfg;
+ if (cfg->inputs[i].type != AUTO_PIN_MIC)
+ continue;
+ defcfg = snd_hda_codec_get_pincfg(codec, nid);
+ if (snd_hda_get_input_pin_attr(defcfg) != INPUT_PIN_ATTR_INT)
+ continue;
+
+ snd_hda_override_amp_caps(codec, nid, HDA_INPUT,
+ (0x00 << AC_AMPCAP_OFFSET_SHIFT) |
+ (0x01 << AC_AMPCAP_NUM_STEPS_SHIFT) |
+ (0x2f << AC_AMPCAP_STEP_SIZE_SHIFT) |
+ (0 << AC_AMPCAP_MUTE_SHIFT));
+ }
+}
+
 enum {
  ALC269_FIXUP_SONY_VAIO,
  ALC275_FIXUP_SONY_VAIO_GPIO2,
@@ -3190,6 +3222,7 @@ enum {
  ALC271_FIXUP_AMIC_MIC2,
  ALC271_FIXUP_HP_GATE_MIC_JACK,
  ALC269_FIXUP_ACER_AC700,
+ ALC269_FIXUP_LIMIT_INT_MIC_BOOST,
 };

 static const struct hda_fixup alc269_fixups[] = {
@@ -3428,6 +3461,10 @@ static const struct hda_fixup alc269_fixups[] = {
   .chained = true,
   .chain_id = ALC271_FIXUP_DMIC,
  },
+ [ALC269_FIXUP_LIMIT_INT_MIC_BOOST] = {
+ .type = HDA_FIXUP_FUNC,
+ .v.func = alc269_fixup_limit_int_mic_boost,
+ },
 };

 static const struct snd_pci_quirk alc269_fixup_tbl[] = {
@@ -3458,11 +3495,14 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
  SND_PCI_QUIRK(0x103c, 0x1973, "HP Pavilion", ALC269_FIXUP_HP_MUTE_LED_MIC1),
  SND_PCI_QUIRK(0x103c, 0x1983, "HP Pavilion", ALC269_FIXUP_HP_MUTE_LED_MIC1),
  SND_PCI_QUIRK_VENDOR(0x103c, "HP", ALC269_FIXUP_HP_MUTE_LED),
+ SND_PCI_QUIRK(0x1043, 0x106d, "Asus K53BE", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
+ SND_PCI_QUIRK(0x1043, 0x115d, "Asus 1015E", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
  SND_PCI_QUIRK(0x1043, 0x1427, "Asus Zenbook UX31E", ALC269VB_FIXUP_DMIC),
  SND_PCI_QUIRK(0x1043, 0x1517, "Asus Zenbook UX31A", ALC269VB_FIXUP_DMIC),
+ SND_PCI_QUIRK(0x1043, 0x16e3, "ASUS UX50", ALC269_FIXUP_STEREO_DMIC),
  SND_PCI_QUIRK(0x1043, 0x1a13, "Asus G73Jw", ALC269_FIXUP_ASUS_G73JW),
  SND_PCI_QUIRK(0x1043, 0x1b13, "Asus U41SV", ALC269_FIXUP_INV_DMIC),
- SND_PCI_QUIRK(0x1043, 0x16e3, "ASUS UX50", ALC269_FIXUP_STEREO_DMIC),
+ SND_PCI_QUIRK(0x1043, 0x1c23, "Asus X55U", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
  SND_PCI_QUIRK(0x...

Read more...

Changed in linux (Ubuntu):
status: Triaged → In Progress
Revision history for this message
Takashi Iwai (tiwai) wrote :
Download full text (3.6 KiB)

At Mon, 22 Apr 2013 14:30:14 +0200,
David Henningsson wrote:
>
> These are being reported as being so noisy at high mic boost levels,
> so they are unusable in practice.
> Therefore artificially limit the boosts.
>
> BugLink: https://bugs.launchpad.net/bugs/1089795
> Signed-off-by: David Henningsson <email address hidden>

Thanks, applied.

Takashi

> ---
> sound/pci/hda/patch_realtek.c | 42 ++++++++++++++++++++++++++++++++++++++++-
> 1 file changed, 41 insertions(+), 1 deletion(-)
>
> diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
> index 28b3f5a..6e5d383 100644
> --- a/sound/pci/hda/patch_realtek.c
> +++ b/sound/pci/hda/patch_realtek.c
> @@ -3156,6 +3156,38 @@ static void alc271_hp_gate_mic_jack(struct hda_codec *codec,
> }
> }
>
> +static void alc269_fixup_limit_int_mic_boost(struct hda_codec *codec,
> + const struct hda_fixup *fix,
> + int action)
> +{
> + struct alc_spec *spec = codec->spec;
> + struct auto_pin_cfg *cfg = &spec->gen.autocfg;
> + int i;
> +
> + /* The mic boosts on level 2 and 3 are too noisy
> + on the internal mic input.
> + Therefore limit the boost to 0 or 1. */
> +
> + if (action != HDA_FIXUP_ACT_PROBE)
> + return;
> +
> + for (i = 0; i < cfg->num_inputs; i++) {
> + hda_nid_t nid = cfg->inputs[i].pin;
> + unsigned int defcfg;
> + if (cfg->inputs[i].type != AUTO_PIN_MIC)
> + continue;
> + defcfg = snd_hda_codec_get_pincfg(codec, nid);
> + if (snd_hda_get_input_pin_attr(defcfg) != INPUT_PIN_ATTR_INT)
> + continue;
> +
> + snd_hda_override_amp_caps(codec, nid, HDA_INPUT,
> + (0x00 << AC_AMPCAP_OFFSET_SHIFT) |
> + (0x01 << AC_AMPCAP_NUM_STEPS_SHIFT) |
> + (0x2f << AC_AMPCAP_STEP_SIZE_SHIFT) |
> + (0 << AC_AMPCAP_MUTE_SHIFT));
> + }
> +}
> +
> enum {
> ALC269_FIXUP_SONY_VAIO,
> ALC275_FIXUP_SONY_VAIO_GPIO2,
> @@ -3190,6 +3222,7 @@ enum {
> ALC271_FIXUP_AMIC_MIC2,
> ALC271_FIXUP_HP_GATE_MIC_JACK,
> ALC269_FIXUP_ACER_AC700,
> + ALC269_FIXUP_LIMIT_INT_MIC_BOOST,
> };
>
> static const struct hda_fixup alc269_fixups[] = {
> @@ -3428,6 +3461,10 @@ static const struct hda_fixup alc269_fixups[] = {
> .chained = true,
> .chain_id = ALC271_FIXUP_DMIC,
> },
> + [ALC269_FIXUP_LIMIT_INT_MIC_BOOST] = {
> + .type = HDA_FIXUP_FUNC,
> + .v.func = alc269_fixup_limit_int_mic_boost,
> + },
> };
>
> static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> @@ -3458,11 +3495,14 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> SND_PCI_QUIRK(0x103c, 0x1973, "HP Pavilion", ALC269_FIXUP_HP_MUTE_LED_MIC1),
> SND_PCI_QUIRK(0x103c, 0x1983, "HP Pavilion", ALC269_FIXUP_HP_MUTE_LED_MIC1),
> SND_PCI_QUIRK_VENDOR(0x103c, "HP", ALC269_FIXUP_HP_MUTE_LED),
> + SND_PCI_QUIRK(0x1043, 0x106d, "Asus K53BE", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> + SND_PCI_QUIRK(0x1043, 0x115d, "Asus 1015E", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
> SND_PCI_QUIRK(0x1043, 0x1427, "Asus Zenbook UX31E", ALC269VB_FIXUP_DMIC),
> SND_PCI_QUIRK(0x1043, 0x1517, "Asus Zenbook UX31A", ALC269VB_FIXUP_DMIC),
> + SND_PCI_QUIRK(0x1043, 0x16e3, "ASUS UX50", ALC269_FIXUP_STEREO_DMIC),
> SND_PCI_QUIRK(0x1043, 0x1a13, "Asus G73Jw", ALC269_FI...

Read more...

Changed in linux (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (3.4 KiB)

This bug was fixed in the package linux - 3.10.0-0.7

---------------
linux (3.10.0-0.7) saucy; urgency=low

  [ Andy Whitcroft ]

  * autopkgtest: switch Depends: to build-essential

linux (3.10.0-0.6) saucy; urgency=low

  [ Andy Whitcroft ]

  * [Config] enable CONFIG_ARCH_TEGRA to fix FTBFS on armhf
  * SAUCE: ubuntu: overlayfs -- ovl_path_open should not take path reference
    - LP: #1098378
  * ubuntu: AUFS -- update to 4f14cef47eb7c23eda7198931fbab1040866b6ee
  * ubuntu: overlayfs -- expose do_splice_direct prototype
  * ubuntu: overlayfs -- follow change to do_splice_direct interface
  * [Config] flip CONFIG_NO_HZ_FULL_ALL off as it is overheating machines
    - LP: #1192691

  [ Stefan Bader ]

  * (d-i) Add dm-snapshot to md-modules
    - LP: #1191726

  [ Tim Gardner ]

  * Release tracker
    - LP: #1194149
  * [Config] CONFIG_WIL6210=n for armhf
  * [Config] d-i: Add calxedaxgmac to nic-modules
    - LP: #1192358
  * [debian] Use dh_strip
    - LP: #1192759
  * [Config] Enable perf for armhf
  * do_tools=false when cross compiling
  * [Config] CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS=y
    - LP: #1108082

  [ Upstream Kernel Changes ]

  * nsp32: switch reset delay to msleep() as it is tooo long
  * alx: add a simple AR816x/AR817x device driver
    Plucked from linux-next. replaces ubuntu/alx in favor of
    'to be merged' version in 3.11.
  * rebase to v3.10-rc7
    - LP: #1189363

linux (3.10.0-0.5) saucy; urgency=low

  [ Andy Whitcroft ]

  * rebase to v3.10-rc6
  * [Config] updateconfigs following rebase to v3.10-rc6

  [ Upstream Kernel Changes ]

  * rebase to v3.10-rc6

linux (3.10.0-0.4) saucy; urgency=low

  [ Andy Whitcroft ]

  * [Config] updateconfigs following rebase to v3.10-rc4

linux (3.10.0-0.3) saucy; urgency=low

  [ Andy Whitcroft ]

  * rebase to v3.10-rc5

  [ Upstream Kernel Changes ]

  * rebase to v3.10-rc5
    - LP: #1186170

linux (3.10.0-0.2) saucy; urgency=low

  [ Andy Whitcroft ]

  * rebase to v3.10-rc4
  * [Config] CONFIG_BINFMT_SCRIPT=y to fix booting initramfs scripts
  * [Config] enable SND_PCM_DEBUG SND_PCM_XRUN_DEBUG
    - LP: #1187744
  * [Config] enforce CONFIG_BINFMT_SCRIPT=y

  [ Dave Chiluk ]

  * SAUCE: ncpfs: fix rmdir returns Device or resource busy
    - LP: #1035226

  [ Tim Gardner ]

  * rebase to v3.10-rc3
  * [Config] sparc be gone
  * [Config] ia64 be gone
  * d-i: block-modules provides nbd-modules

  [ Upstream Kernel Changes ]

  * rebase to v3.10-rc4
  * rebase to v3.10-rc3

linux (3.10.0-0.1) saucy; urgency=low

  [ Tim Gardner ]

  * UBUNTU: Disabled lttng
  * UBUNTU: Disable aufs for FTBS
  * UBUNTU: Disabled alx
  * UBUNTU: alx: rename NETIF_F_HW_VLAN_* feature flags to NETIF_F_HW_VLAN_CTAG_*
  * UBUNTU: rebase to v3.10-rc2
  * UBUNTU: SAUCE: uvcvideo: quirk PROBE_DEF for Alienware X51 OmniVision webcam

  [ Andy Whitcroft ]

  * UBUNTU: [Config] update standards version to 3.9.4.0
  * UBUNTU: [Config] squash duplicate package description (long and short)
  * UBUNTU: [Config] fix up Vcs-git: to point to saucy
  * UBUNTU: [Config] drop depenancy on util-linux as is Essential
  * UBUNTU: [Config] drop redundant Build-Conficts:

  [ Upstream Kernel Changes ]

  * rebase to v...

Read more...

Changed in linux (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.