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=1796384480; b=4EgwBA6W3oh4g+214SzyOeA5QpPpo7a8QhZ5AadkgxpdVvM1iptLiFZ4eKhwbNgkttYE FEWE6bFYKxcAEGUiuL2m7HsnsrEkCKHiCS04l7aqmweLPsCv4TJyJpappCzu3H6RQstQM yh4FUdD1gbSsdT7avRVoLimAANTddHpzCk8INK9izNDQ4HtFuOA51YEXqJ+pLkjvl7ZD2 S31110ndRKibVdf0YbYqKqj+2Gge7f3pxHg8uVS77cuPcYttTwn+3IDh+2EbosPIaDYHV tCSCagSRaedFmXrJtMLcgpTqbpIbgjq4hSbldnBzZy5Al8tuN4K4V45z3YsIdnlkmcw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796384480; 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=B/QvPTOXT0qWtI31wrIfAvUDcjOjbMYWB1mtBT4LAhI=; b=nn0GdJlf0uEceWlaASGmL+HmWIxu9PHu/WzPeyG178gJFN3EScck0rLpn3IiGwiSTMkX +yMFdAnLZuftVtDFiUEkvf8V7Ad5OvJEV5u0SMjZboH3mzLq9nXK0QSM5cdhgWVKOIPLq DFtzHDLF2Vq6wwlkTz/GUGQvbJzJ1xeopYtRunYYOaTBNXXG6P5I0rOhactLZTThSzkna MtdDq7xri+5MshP8kNnEJdkfYha97E9QhUxpswO3sRyjeMC5wJlfmp4r7YPHVQx7bxGbz JC1fa/yhbsa9xboaTPu7ZyeM7thjGWEIPp45bIu7kRAT/jx8Cke48ChfBzO9w5PNt2A== 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=Bw8rtcHU; 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 C858C606A32D; Fri, 4 Dec 2026 11:41:20 +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=Bw8rtcHU Received: by smtp.kernel.org (Postfix) with ESMTPSA id 412931F00897; Fri, 4 Dec 2026 11:41:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796384480; bh=B/QvPTOXT0qWtI31wrIfAvUDcjOjbMYWB1mtBT4LAhI=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=Bw8rtcHUvXJ8oBJ0vGyGH9azp8KmCgFbj9oXPyS9lna5zA/VDWieDuKGCDCIUkrMr tVcLOC14ngI+FJPGvOP4YHonXMCTQH/PMZXKUL4thrBv9y0OL+Zj1CaYEQbv1g0dN+ K7IZp0wD6wdeuCNiKur387XZ7r0B9GK6KLr8Kvs4= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Munique Feitoza , Dave Airlie , Sasha Levin Subject: [PATCH 6.6 0168/1167] drm/nouveau: Fix CE channel creation on pre-Kepler GPUs Date: Fri, 4 Dec 2026 18:53:15 +0900 Message-ID: <20261204100706.454472095@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100702.047403948@linuxfoundation.org> References: <20261204100702.047403948@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.6-stable review patch. If anyone has any objections, please let me know. ------------------ From: Munique Feitoza [ Upstream commit a2b7b707d75e605d31fb3d85a6b27f8bb2a01413 ] Commit 04e0481526e3 ("nouveau/dmem: Fix privileged error in copy engine channel") changed nouveau_accel_ce_init() to unconditionally request a privileged channel (priv = true) when calling nouveau_channel_new(). However, privileged channels (func->ramfc->priv) are only supported on Kepler (gk104_chan_ramfc) and newer FIFO implementations. On pre-Kepler GPUs that expose a Copy Engine runlist, func->ramfc->priv is false, which causes nvkm_chan_new_() to reject the channel creation with -EINVAL: nouveau 0000:01:00.0: DRM: failed to create ce channel, -22 Only request a privileged CE channel when device->info.family >= NV_DEVICE_INFO_V0_KEPLER. Fixes: 04e0481526e3 ("nouveau/dmem: Fix privileged error in copy engine channel") Signed-off-by: Munique Feitoza Reviewed-by: Dave Airlie Signed-off-by: Dave Airlie Link: https://patch.msgid.link/20261030202809.28723-1-muniquefeitoz4@gmail.com Signed-off-by: Sasha Levin --- drivers/gpu/drm/nouveau/nouveau_drm.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c b/drivers/gpu/drm/nouveau/nouveau_drm.c index 66142db74e5cd..04e26aff2a884 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drm.c +++ b/drivers/gpu/drm/nouveau/nouveau_drm.c @@ -331,6 +331,7 @@ static void nouveau_accel_ce_init(struct nouveau_drm *drm) { struct nvif_device *device = &drm->client.device; + bool priv; u64 runm; int ret = 0; @@ -343,7 +344,11 @@ nouveau_accel_ce_init(struct nouveau_drm *drm) return; } - ret = nouveau_channel_new(&drm->client, true, runm, NvDmaFB, NvDmaTT, &drm->cechan); + /* priv copy engine only works on kepler and newer. */ + priv = device->info.family >= NV_DEVICE_INFO_V0_KEPLER; + + ret = nouveau_channel_new(&drm->client, priv, runm, NvDmaFB, NvDmaTT, + &drm->cechan); if (ret) NV_ERROR(drm, "failed to create ce channel, %d\n", ret); } -- 2.53.0