From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C2546606A31A for ; Wed, 2 Dec 2026 10:58:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=sEoKKTA4 Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 880CC10E9DD; Wed, 2 Dec 2026 10:58:23 +0000 (UTC) Received: from tor.source.kernel.org (tor.source.kernel.org [172.105.4.254]) by gabe.freedesktop.org (Postfix) with ESMTPS id 2DD7210E9DD for ; Wed, 2 Dec 2026 10:58:17 +0000 (UTC) Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) by tor.source.kernel.org (Postfix) with ESMTP id A705F61B1F; Wed, 2 Dec 2026 10:58:16 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8C5A01F00924; Wed, 2 Dec 2026 10:58:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796209096; bh=e7+OWkwmSxqZ7h5J+WUW7150kwKvKQ6nGzCw8N2QJqs=; h=Subject:To:Cc:From:Date; b=sEoKKTA48nFnNtVeqLXF+cYavDj0h3DSn5knhZoISShdE9MRe3EVoNP7JCwNqx5e5 APF1xTPldFIqzqKpYFDFfh/JWcOpjtdU1SG9ZCc5TqEi5cXfKTrjcOjwOjPrL2mZEC xVHeMTgDhtPKnpcurPZT5EGqcPhcgCB5FAVIb5D4= Subject: Patch "drm/xe: Don't abort the shrinker walk on -EBUSY" has been added to the 7.3-stable tree To: airlied@redhat.com, christian.koenig@amd.com, gregkh@linuxfoundation.org, intel-xe@lists.freedesktop.org, matthew.brost@intel.com, rodrigo.vivi@intel.com, thomas.hellstrom@linux.intel.com Cc: From: Date: Wed, 02 Dec 2026 11:57:10 +0100 Message-ID: <2026120210-unequal-capacity-593a@gregkh> X-Archived-By: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-stable: commit X-Patchwork-Hint: ignore X-BeenThere: intel-xe@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Xe graphics driver List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Intel-xe" X-Spam-Status: No, score=-13.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 This is a note to let you know that I've just added the patch titled drm/xe: Don't abort the shrinker walk on -EBUSY to the 7.3-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: drm-xe-don-t-abort-the-shrinker-walk-on-ebusy.patch and it can be found in the queue-7.3 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let know about it. >From 9de430b6fbbdfeee1a5eec33edf53f52c13c869b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20Hellstr=C3=B6m?= Date: Mon, 19 Oct 2026 11:56:52 +0200 Subject: drm/xe: Don't abort the shrinker walk on -EBUSY MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Thomas Hellström commit 9de430b6fbbdfeee1a5eec33edf53f52c13c869b upstream. xe_bo_shrink() returns -EBUSY for bos that can't currently be shrunk, for example imported dma-bufs, bos whose vm is currently validating, bos that are still busy after the wait timeout, or bos whose backup fails. The shrinker LRU walk treats any negative return value as fatal and aborts, which also skips the remaining shrinker passes. As a result, a single such bo, like an imported dma-buf on the XE_PL_TT LRU, prevents reclaim of all bos behind it on the LRU. Skip bos for which xe_bo_shrink() returns -EBUSY and continue the walk, like the TTM LRU walk does. v4: - Patch introduced. Fixes: 00c8efc3180f ("drm/xe: Add a shrinker for xe bos") Cc: Christian König Cc: Matthew Brost Cc: Rodrigo Vivi Cc: intel-xe@lists.freedesktop.org Cc: # v6.15+ Assisted-by: LLM Signed-off-by: Thomas Hellström Reviewed-by: Matthew Brost Link: https://patch.msgid.link/20261019095655.3501-2-thomas.hellstrom@linux.intel.com (cherry picked from commit 846f333b3e0b48065f96bee74ffa0b9d390ed05f) Signed-off-by: Matthew Brost Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/xe/xe_shrinker.c | 3 +++ 1 file changed, 3 insertions(+) --- a/drivers/gpu/drm/xe/xe_shrinker.c +++ b/drivers/gpu/drm/xe/xe_shrinker.c @@ -113,6 +113,9 @@ static int __xe_shrinker_walk(struct xe_ continue; lret = xe_bo_shrink(ctx, ttm_bo, flags, scanned); + /* Like the TTM LRU walk, skip bos we can't shrink now. */ + if (lret == -EBUSY) + continue; if (lret < 0) { ret = lret; goto out; Patches currently in stable-queue which might be from thomas.hellstrom@linux.intel.com are queue-7.3/drm-xe-dma-buf-validate-bos-on-export-to-charge-the-exporter.patch queue-7.3/drm-xe-don-t-abort-the-shrinker-walk-on-ebusy.patch