All of lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Cc: cujomalainey@chromium.org, alsa-devel@alsa-project.org,
	broonie@kernel.org, pierre-louis.bossart@linux.intel.com
Subject: Re: [alsa-devel] [PATCH v2 3/3] ALSA: hda/hdmi - add retry logic to parse_intel_hdmi()
Date: Mon, 20 Jan 2020 17:49:12 +0100	[thread overview]
Message-ID: <s5hpnfe2hvb.wl-tiwai@suse.de> (raw)
In-Reply-To: <20200120160117.29130-4-kai.vehmanen@linux.intel.com>

On Mon, 20 Jan 2020 17:01:17 +0100,
Kai Vehmanen wrote:
> 
> The initial snd_hda_get_sub_node() can fail on certain
> devices (e.g. some Chromebook models using Intel GLK).
> The failure rate is very low, but as this is is part of
> the probe process, end-user impact is high.
> 
> In observed cases, related hardware status registers have
> expected values, but the node query still fails. Retrying
> the node query does seem to help, so fix the problem by
> adding retry logic to the query. This does not impact
> non-Intel platforms.
> 
> BugLink: https://github.com/thesofproject/linux/issues/1642
> Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
> Reviewed-by: Takashi Iwai <tiwai@suse.de>

It seems that this felt out of Mark's hands, so I picked up now to my
tree, as this doesn't seem depending on other changes.

Now applied to for-next branch.


thanks,

Takashi

> ---
>  sound/pci/hda/patch_hdmi.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
> index 630b1f5c276d..a4b75a9dfe3b 100644
> --- a/sound/pci/hda/patch_hdmi.c
> +++ b/sound/pci/hda/patch_hdmi.c
> @@ -2830,9 +2830,12 @@ static int alloc_intel_hdmi(struct hda_codec *codec)
>  /* parse and post-process for Intel codecs */
>  static int parse_intel_hdmi(struct hda_codec *codec)
>  {
> -	int err;
> +	int err, retries = 3;
> +
> +	do {
> +		err = hdmi_parse_codec(codec);
> +	} while (err < 0 && retries--);
>  
> -	err = hdmi_parse_codec(codec);
>  	if (err < 0) {
>  		generic_spec_free(codec);
>  		return err;
> -- 
> 2.17.1
> 
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel

  reply	other threads:[~2020-01-20 16:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-20 16:01 [alsa-devel] [PATCH v2 0/3] SOF: Fix HDMI probe errors on GLK devices Kai Vehmanen
2020-01-20 16:01 ` [alsa-devel] [PATCH v2 1/3] ASoC: SOF: Intel: refactor i915_get/put functions Kai Vehmanen
2020-01-20 16:01 ` [alsa-devel] [PATCH v2 2/3] ASoC: SOF: Intel: do not disable i915 power during probe Kai Vehmanen
2020-01-20 16:01 ` [alsa-devel] [PATCH v2 3/3] ALSA: hda/hdmi - add retry logic to parse_intel_hdmi() Kai Vehmanen
2020-01-20 16:49   ` Takashi Iwai [this message]
2020-01-20 17:17     ` Mark Brown
2020-01-20 17:43       ` Kai Vehmanen
2020-01-20 17:55         ` Mark Brown
2020-01-27 15:38         ` Pierre-Louis Bossart
2020-01-20 18:10       ` Takashi Iwai
2020-01-20 18:37         ` Mark Brown

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=s5hpnfe2hvb.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=cujomalainey@chromium.org \
    --cc=kai.vehmanen@linux.intel.com \
    --cc=pierre-louis.bossart@linux.intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.