public inbox for drm-ai-reviews@public-inbox.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH] drm/ttm/tests: Fix build failure on PREEMPT_RT
@ 2026-02-26 15:12 Maarten Lankhorst
  2026-02-27  1:52 ` Claude review: " Claude Code Review Bot
  2026-02-27  1:52 ` Claude Code Review Bot
  0 siblings, 2 replies; 5+ messages in thread
From: Maarten Lankhorst @ 2026-02-26 15:12 UTC (permalink / raw)
  To: dri-devel; +Cc: intel-xe, Maarten Lankhorst, kernel test robot

Fix a compile error in the kunit tests when CONFIG_PREEMPT_RT is
enabled, and the normal mutex is converted into a rtmutex.

Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202602261547.3bM6yVAS-lkp@intel.com/
Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>
---
 drivers/gpu/drm/ttm/tests/ttm_bo_test.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/ttm/tests/ttm_bo_test.c b/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
index d468f83220720..2ba5ddf2b1c9e 100644
--- a/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
+++ b/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
@@ -222,13 +222,13 @@ static void ttm_bo_reserve_interrupted(struct kunit *test)
 		KUNIT_FAIL(test, "Couldn't create ttm bo reserve task\n");
 
 	/* Take a lock so the threaded reserve has to wait */
-	mutex_lock(&bo->base.resv->lock.base);
+	ww_mutex_lock(&bo->base.resv->lock, NULL);
 
 	wake_up_process(task);
 	msleep(20);
 	err = kthread_stop(task);
 
-	mutex_unlock(&bo->base.resv->lock.base);
+	ww_mutex_unlock(&bo->base.resv->lock);
 
 	KUNIT_ASSERT_EQ(test, err, -ERESTARTSYS);
 }
-- 
2.51.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread
* [PATCH v2] drm/ttm/tests: Fix build failure on PREEMPT_RT
@ 2026-03-04  8:56 Maarten Lankhorst
  2026-03-05  3:40 ` Claude review: " Claude Code Review Bot
  2026-03-05  3:40 ` Claude Code Review Bot
  0 siblings, 2 replies; 5+ messages in thread
From: Maarten Lankhorst @ 2026-03-04  8:56 UTC (permalink / raw)
  To: dri-devel
  Cc: intel-xe, Jouni Högander, Maarten Lankhorst,
	kernel test robot

Fix a compile error in the kunit tests when CONFIG_PREEMPT_RT is
enabled, and the normal mutex is converted into a rtmutex.

Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202602261547.3bM6yVAS-lkp@intel.com/
Signed-off-by: Maarten Lankhorst <dev@lankhorst.se>
---
Changes since v1:
- Use the correct locking primitive (Jouni)

 drivers/gpu/drm/ttm/tests/ttm_bo_test.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/ttm/tests/ttm_bo_test.c b/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
index d468f83220720..f3103307b5df9 100644
--- a/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
+++ b/drivers/gpu/drm/ttm/tests/ttm_bo_test.c
@@ -222,13 +222,13 @@ static void ttm_bo_reserve_interrupted(struct kunit *test)
 		KUNIT_FAIL(test, "Couldn't create ttm bo reserve task\n");
 
 	/* Take a lock so the threaded reserve has to wait */
-	mutex_lock(&bo->base.resv->lock.base);
+	dma_resv_lock(bo->base.resv, NULL);
 
 	wake_up_process(task);
 	msleep(20);
 	err = kthread_stop(task);
 
-	mutex_unlock(&bo->base.resv->lock.base);
+	dma_resv_unlock(bo->base.resv);
 
 	KUNIT_ASSERT_EQ(test, err, -ERESTARTSYS);
 }
-- 
2.51.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-03-05  3:40 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-26 15:12 [PATCH] drm/ttm/tests: Fix build failure on PREEMPT_RT Maarten Lankhorst
2026-02-27  1:52 ` Claude review: " Claude Code Review Bot
2026-02-27  1:52 ` Claude Code Review Bot
  -- strict thread matches above, loose matches on Subject: below --
2026-03-04  8:56 [PATCH v2] " Maarten Lankhorst
2026-03-05  3:40 ` Claude review: " Claude Code Review Bot
2026-03-05  3:40 ` Claude Code Review Bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox