From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796381984; b=S+o2eFCVFy/lomhzA7MWryMOni2zv9kUsUajk3SwaLMEjBmWyufsl4k+oUVx4FYlrYaB Z0P9n4epx2CqDAPnKrkTAuXqGQEcnIvKHiyWghTjJ0IKayRIcJwRVn912tYFJzaBTHP3O 2GNxWTS1CMoppUiRkuc/CeUxBmaZOl5btmWQF4LQv/Zca4fx2sAZjb7ioIR/5UwoWkk60 yUn6wa9FJzWLOGN/XdXW06dMDC/OTI0hbMuOeAG3TFWpbXyQ8bLDLTr4szeB8+j0MLKZu sk8f3wy7Ly9V0EsEt8OjrZAvKRTw8aiVjNRvKQdco0hl4zLxqcWCpODp0UHtGV/9c8Q== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796381984; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: In-Reply-To:References:User-Agent:X-stable:X-Patchwork-Hint: MIME-Version:Content-Transfer-Encoding; bh=dxiZZlr2fftTTbaC0NfuqgntwsNX3hiTaMQq50/H1xc=; b=DRF/IMeJ7Vl4UZXxJLXSP6Ka02361QKTKOQ9veeK1pMgc54zDW2hBBy9gAITa7QiTfka XhKbR3Y2oN32+/B+gkDsh8/8egPQk7Ei2rqzlGOfwZA6RdUV2kMtDd2RxQpQ2bAVZ8aZb VGFA98mZJuccLGAet71SoT1mruJbzi4g3ukcF7faJtEfS0DLzXP0z52DiTXT/Lje2OMdb TL5Cf6UbdYKhUeLw9A74h/APyU9atIk+V2GaXwsM6o3A1GhyMMhh0YnVLrl+qmMhGCGYe hopCKEFtavcnwaVQHCS2PgpQUSkwyxBCUHUV5AqyVQChcNThMWAI7wrER64XY0jYlVQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=0kbFStGD; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3E802606A322; Fri, 4 Dec 2026 10:59:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=0kbFStGD Received: by smtp.kernel.org (Postfix) with ESMTPSA id ABEB11F000C2; Fri, 4 Dec 2026 10:59:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796381984; bh=dxiZZlr2fftTTbaC0NfuqgntwsNX3hiTaMQq50/H1xc=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=0kbFStGD+Zdt5p6mG+DkNXy9Gl4KWQQCsmLEKrupKp2taiAger8h9Vw2DfiVphDJ4 v5eu8aS8G/9DDcaIYfSiM39x4PpNCEaFAChXvsyUc5TP2cPzhzq08p4jVBkuNC6F6O b/VIXgZXhcMC+KlBsdDFJoXX79WQvvY82E8MXGvI= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Michal Grzelak , Kai Vehmanen , Takashi Iwai , Sasha Levin Subject: [PATCH 6.18 231/703] ALSA: hda: intel: Release i915 power also when delayed probe fails Date: Fri, 4 Dec 2026 19:02:10 +0900 Message-ID: <20261204100633.967714223@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100627.522266145@linuxfoundation.org> References: <20261204100627.522266145@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: stable@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Kai Vehmanen [ Upstream commit 0a5550dd94e61852941fb37142f4664ecddef312 ] Commit fbaccb1b19c7 ("ALSA: hda: intel: Don't free card in the probe work") stopped freeing the card from azx_probe_work() when the delayed probe fails, and only disconnects it, leaving the free to azx_remove(). This avoids the double free, but the resources that were released by the card free via azx_free() are now kept until the PCI device is unbound. In particular the display power reference stay held, blocking runtime suspend for i915/xe. Release the display power in the azx_probe_continue() work in all cases. This power reference is only taken for the purpose of the display codec probe. If the display codec probe was successful, it will have taken its own reference. In case of systems with the HDA controller on GPU side (hda->need_i915_power), functionality is same as before - we have to keep power. Fixes: fbaccb1b19c7 ("ALSA: hda: intel: Don't free card in the probe work") Reported-by: Michal Grzelak Link: https://gitlab.freedesktop.org/drm/i915/kernel/-/work_items/17751 Signed-off-by: Kai Vehmanen Link: https://patch.msgid.link/20261120150937.2187228-1-kai.vehmanen@linux.intel.com Signed-off-by: Takashi Iwai Signed-off-by: Sasha Levin --- sound/hda/controllers/intel.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sound/hda/controllers/intel.c b/sound/hda/controllers/intel.c index 6390fc91c0a45..a543580561cf6 100644 --- a/sound/hda/controllers/intel.c +++ b/sound/hda/controllers/intel.c @@ -2385,6 +2385,9 @@ static int azx_probe_continue(struct azx *chip, bool free_on_error) } out_free: + if (!hda->need_i915_power) + display_power(chip, false); + 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"); @@ -2395,8 +2398,6 @@ static int azx_probe_continue(struct azx *chip, bool free_on_error) return err; } - if (!hda->need_i915_power) - display_power(chip, false); complete_all(&hda->probe_wait); to_hda_bus(bus)->bus_probing = 0; hda->probe_retry = 0; -- 2.53.0