linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Hridesh MG <hridesh699@gmail.com>
Cc: Takashi Iwai <tiwai@suse.de>, Jaroslav Kysela <perex@perex.cz>,
	Takashi Iwai <tiwai@suse.com>, Jonathan Corbet <corbet@lwn.net>,
	Stefan Binding <sbinding@opensource.cirrus.com>,
	Kailang Yang <kailang@realtek.com>,
	Simon Trimmer <simont@opensource.cirrus.com>,
	Joshua Grisham <josh@joshuagrisham.com>,
	Richard Fitzgerald <rf@opensource.cirrus.com>,
	linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-doc@vger.kernel.org
Subject: Re: [PATCH 1/2] ALSA: hda/realtek: Fix headset mic on Acer Nitro 5
Date: Mon, 18 Nov 2024 14:52:37 +0100	[thread overview]
Message-ID: <87ed387ioq.wl-tiwai@suse.de> (raw)
In-Reply-To: <CALiyAo=5aLbYEyRWWw7QscTk6cXy5qckHToiPL6h4fKM9=skLg@mail.gmail.com>

On Sun, 17 Nov 2024 21:24:45 +0100,
Hridesh MG wrote:
> 
> > > +     [ALC_287_FIXUP_ACER_NITRO_HEADSET_MIC_VERBS] = {
> > > +             .type = HDA_FIXUP_VERBS,
> > > +             .v.verbs = (const struct hda_verb[]) {
> > > +                     { 0x20, AC_VERB_SET_COEF_INDEX, 0x45 },
> > > +                     { 0x20, AC_VERB_SET_PROC_COEF, 0xD689 },
> >
> > This is a generic setup for the headset input in CTIA mode.
> > Do you really need this explicity?  Usually it's set up at
> > alc_headset_mode_ctia() when the iPhone type is connected.
> Yeah, the mic wont pick up input without it. I did have a feeling that
> it's supposed to be set up automatically rather than being set as a
> verb but I couldn't figure out which part of the code I'm supposed to
> modify to make that happen. I've tried running it with dynamic
> debugging turned on but I don't see the output of codec_dbg from
> alc_headset_mode_ctia() :(

Is alc_fixup_headset_mode() called by the quirk chain?
When this is set up via quirks, alc_update_headset_mode() gets called
at initialization and this should detect the headset type.  At that
point, alc_headset_mode_ctia() would be called if the proper type gets
detected.

> > >  static const struct snd2_pci_quirk alc269_fixup_tbl[] = {
> > > @@ -10201,6 +10220,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
> > >       SND_PCI_QUIRK(0x1025, 0x1466, "Acer Aspire A515-56", ALC255_FIXUP_ACER_HEADPHONE_AND_MIC),
> > >       SND_PCI_QUIRK(0x1025, 0x1534, "Acer Predator PH315-54", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
> > >       SND_PCI_QUIRK(0x1025, 0x169a, "Acer Swift SFG16", ALC256_FIXUP_ACER_SFG16_MICMUTE_LED),
> > > +     SND_PCI_QUIRK(0x1025, 0x159c, "Acer Nitro 5 AN515-58", ALC_287_FIXUP_ACER_NITRO_HEADSET_MIC_PIN),
> >
> > The table is sorted in PCI SSID order.  Please put at the right
> > place.
> Will do, thanks.
> 
> > > +     {.id = ALC_287_FIXUP_ACER_NITRO_HEADSET_MIC_PIN, .name = "alc287-fixup-acer-nitro-headset-mic"},
> >
> > Nowadays the less need for a new model name string.  You can specify
> > the model with an alias of SSID if any other device needs to apply the
> > same quirk, too.  So, unless it's mandatory, better to drop.
> I added the model name string to make debugging easier for users. When
> troubleshooting this issue, I followed many guides that recommended
> the 'Codec-Specific Models' document, but no entry existed for the
> ALC287. I thought that adding a model name would help users quickly
> identify and apply the correct quirk without needing kernel expertise.
> However, if this goes against the current standards, I’m happy to
> adjust.

We used to add static model names in the past, but since some years ago
the driver can accept a style like model=1025:169a option, so there is
no longer need for the explicit new model name string.


thanks,

Takashi

  reply	other threads:[~2024-11-18 13:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-14 16:41 [PATCH 0/2] Fix headset mic on Acer Nitro 5 Hridesh MG
2024-11-14 16:41 ` [PATCH 1/2] ALSA: hda/realtek: " Hridesh MG
2024-11-17 13:45   ` Takashi Iwai
2024-11-17 20:24     ` Hridesh MG
2024-11-18 13:52       ` Takashi Iwai [this message]
2024-11-20 17:32         ` Hridesh MG
2024-11-30 18:58           ` Hridesh MG
2024-12-01  8:26             ` Takashi Iwai
2024-12-05  2:46               ` Kailang
2024-12-05 17:22                 ` Hridesh MG
2024-11-14 16:41 ` [PATCH 2/2] docs: sound: Add a new hd-audio fixup model Hridesh MG

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ed387ioq.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=corbet@lwn.net \
    --cc=hridesh699@gmail.com \
    --cc=josh@joshuagrisham.com \
    --cc=kailang@realtek.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=rf@opensource.cirrus.com \
    --cc=sbinding@opensource.cirrus.com \
    --cc=simont@opensource.cirrus.com \
    --cc=tiwai@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).