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=1796220831; b=XFInsB+lfvog3FxuuX7hTCVwL+g6fGmAnzvLnv12syEOya5G7OmPcGjertNZZyasmm4w QP5ntGr0RgL9lV9586yQ6CId8UUWMK/gY7t1Xni7cy5yIRBPS0bah5YJ6OQyoSj7Vf6y0 pqBwicTMOWVlE1fgOlS8hJ3fX7mtvJ7OvG/Lig3w0ZoMZYrOwl+jmM6Wq27uvpP2vOwAO NO1VZsQc0Yw45h2ZUA2PRb7KU6nGTepfi2aeBAcnmIgcS174A8tBk6SULG400djSuGoLL T0L4VKTqH3NxcgW4kaJCh1AaEfWfemjxKeZDrPC3xdHVVaPl76J5MkQX1CrfuwEQz5w== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796220831; h=Received:DKIM-Signature:Subject:To:Cc:From:Date:Message-ID: MIME-Version:Content-Type:Content-Transfer-Encoding; bh=Unah/N5RQwIdt0Zz5s0o0U0D1f3JRogl91G3ZgA2cro=; b=gKi7Pfl5cB3bhEqsy0XFOvhG2Uqv6vvZFmaV7hgFV1fCsfQukj8MURkAs3xGpYGFCfPO HQIoO6KzjtnyaNi3G2YKEiwF0S9xr19L8XHaMKXZ8sT4mkwhvvNC8UlyINSCPb/VWjO9C SsE+yt+Zad//ydKg7VFMmWXRNos8qPBR5lzSBrFM/h1wgfwsU0Ld45O543Ka9O+HvgcbD hYHQVq0TUmfpHhMVb1R0u4LtOlf1sg0dR7z3XPMdnjoXNT+0jwFF0Bwf/cpDPSXpoFJC4 c3QVjAiyh/i5pOAdDkXKneYrEI3no+0XSWaQmIEX9e+J3GhbZCI2RfnINyDjCJyRFSA== 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=a63xIc6Y; 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 6352B606A322 for ; Wed, 2 Dec 2026 14:13:51 +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=a63xIc6Y Received: by smtp.kernel.org (Postfix) with ESMTPSA id 12DF31F00896; Wed, 2 Dec 2026 14:13:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796220830; bh=Unah/N5RQwIdt0Zz5s0o0U0D1f3JRogl91G3ZgA2cro=; h=Subject:To:Cc:From:Date; b=a63xIc6YhB+wDNO3tBZcL0R6MDEk13K0ZMv7G5I5eEdsKe92mupUmgfGgKpBvzBrX SEqY4Jzs5qfsHN3yFecZMUK4kgpjwBtUKtsbemB6rfc0D4uh90t+K6Ic4h59xIVgLz ms3VxcdoLwLubVX86oVqCijoUO8nNhY9ZmtK/Z5I= Subject: FAILED: patch "[PATCH] drm/vc4: Hold a runtime PM reference while allocating the" failed to apply to 6.6-stable tree To: mcanal@igalia.com,itoral@igalia.com Cc: From: Date: Wed, 02 Dec 2026 13:42:33 +0100 Message-ID: <2026120232-yapping-carded-0f91@gregkh> 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-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The patch below does not apply to the 6.6-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.6.y git checkout FETCH_HEAD git cherry-pick -x a7d7a25b566635ac1ee6af1c3ef06484cf752c3f # git commit -s git send-email --to '' --in-reply-to '2026120232-yapping-carded-0f91@gregkh' --subject-prefix 'PATCH 6.6.y' 'HEAD^..' Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From a7d7a25b566635ac1ee6af1c3ef06484cf752c3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ma=C3=ADra=20Canal?= Date: Wed, 11 Nov 2026 12:05:19 -0300 Subject: [PATCH] drm/vc4: Hold a runtime PM reference while allocating the binner BO MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit bin_bo_alloc() arms the out-of-memory interrupt once it has allocated the binner BO, and accessing a V3D register requires the block to be powered. vc4_submit_cl_ioctl() already holds a runtime PM reference by the time it reaches vc4_get_bcl(), but vc4_create_bo_ioctl() reaches vc4_grab_bin_bo() without one, so the write can land on a suspended device. Take the reference in vc4_v3d_bin_bo_get(), which covers both callers, and take it before bin_bo_lock so that runtime PM is never waited for with the mutex held. Cc: stable@vger.kernel.org Fixes: 35c8b4b2c0fe ("drm/vc4: Allocate binner bo when starting to use the V3D") Reviewed-by: Iago Toral Quiroga Link: https://patch.msgid.link/20261111-vc4-irq-cleanup-v2-1-aa757bb742f2@igalia.com Signed-off-by: MaĆ­ra Canal diff --git a/drivers/gpu/drm/vc4/vc4_v3d.c b/drivers/gpu/drm/vc4/vc4_v3d.c index ed3bab119979..2bfb8766d1b6 100644 --- a/drivers/gpu/drm/vc4/vc4_v3d.c +++ b/drivers/gpu/drm/vc4/vc4_v3d.c @@ -302,11 +302,15 @@ static int bin_bo_alloc(struct vc4_dev *vc4) int vc4_v3d_bin_bo_get(struct vc4_dev *vc4, bool *used) { - int ret = 0; + int ret; if (WARN_ON_ONCE(vc4->gen > VC4_GEN_4)) return -ENODEV; + ret = vc4_v3d_pm_get(vc4); + if (ret) + return ret; + mutex_lock(&vc4->bin_bo_lock); if (used && *used) @@ -322,6 +326,7 @@ int vc4_v3d_bin_bo_get(struct vc4_dev *vc4, bool *used) complete: mutex_unlock(&vc4->bin_bo_lock); + vc4_v3d_pm_put(vc4); return ret; }