Linux Sound subsystem development
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: linux-sound@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] ALSA: hda/intel: Power down GPU at error on azx_probe_continue()
Date: Tue, 13 Oct 2026 18:44:53 +0200	[thread overview]
Message-ID: <87pkxdft2y.wl-tiwai@suse.de> (raw)
In-Reply-To: <20261013133153.78225-1-tiwai@suse.de>

On Tue, 13 Oct 2026 15:31:50 +0200,
Takashi Iwai wrote:
> 
> Since the recent fix commit fbaccb1b19c7 ("ALSA: hda: intel: Don't
> free card in the probe work"), we don't release the card but just
> toggles the init_failed flag to stop the operation in the case of
> error at probing in azx_probe_continue().  This leaves, however,
> display_power() true, which may block powering down the GPU.
> 
> Put display_power(false) at the error path for avoiding the potential
> blockage.
> 
> Fixes: fbaccb1b19c7 ("ALSA: hda: intel: Don't free card in the probe work")
> Signed-off-by: Takashi Iwai <tiwai@suse.de>
> ---
>  sound/hda/controllers/intel.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/sound/hda/controllers/intel.c b/sound/hda/controllers/intel.c
> index 6b80b59b8743..b67d569fc859 100644
> --- a/sound/hda/controllers/intel.c
> +++ b/sound/hda/controllers/intel.c
> @@ -2453,6 +2453,7 @@ static int azx_probe_continue(struct azx *chip, bool free_on_error)
>  	if (err < 0) {
>  		if (hda->vga_switcheroo_registered)
>  			dev_warn(&pci->dev, "GPU sound probed, but not operational: please add a quirk to driver_denylist\n");
> +		display_power(chip, false);
>  		if (free_on_error) {
>  			pci_set_drvdata(pci, NULL);
>  			snd_card_free(chip->card);

On the second thought, turning off the display power here alone would
be problematic; the rest hardware cleanup procedure will run anyway in
azx_free() and with the display_power() off, it may lead to something
unexpected.

We can power up again temporarily in azx_free(), too.  But I'm not
sure whether it's a good idea.  Going back to calling azx_free() can
still work, but then we'll hit the old issue again about the already
bound codecs (that aren't detached by azx_free() itself).

Hmm.  Maybe better to leave in the current state for now until someone
sees a real problem on an actual hardware.


Takashi

      parent reply	other threads:[~2026-10-13 16:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-13 13:31 [PATCH 1/2] ALSA: hda/intel: Power down GPU at error on azx_probe_continue() Takashi Iwai
2026-10-13 13:31 ` [PATCH 2/2] ALSA: hda/intel: Clean up error handling in azx_probe_continue() Takashi Iwai
2026-10-13 16:44 ` Takashi Iwai [this message]

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=87pkxdft2y.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    /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