summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/Kconfig.debug
diff options
context:
space:
mode:
authorTvrtko Ursulin <tvrtko.ursulin@igalia.com>2025-03-24 09:26:29 +0000
committerPhilipp Stanner <phasta@kernel.org>2025-03-24 10:41:52 +0100
commit5a99350794fec11faaed8a4b36a6931e696f672f (patch)
tree789f6d0d8082211d151d7cb04f5975bde39cc7ec /drivers/gpu/drm/Kconfig.debug
parent8e623137f112eb86ad949e3bcb6c0e5ae11a092a (diff)
drm/sched: Add scheduler unit testing infrastructure and some basic tests
Implement a mock scheduler backend and add some basic test to exercise the core scheduler code paths. Mock backend (kind of like a very simple mock GPU) can either process jobs by tests manually advancing the "timeline" job at a time, or alternatively jobs can be configured with a time duration in which case they get completed asynchronously from the unit test code. Core scheduler classes are subclassed to support this mock implementation. The tests added are just a few simple submission patterns. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com> Suggested-by: Philipp Stanner <phasta@kernel.org> Cc: Christian König <christian.koenig@amd.com> Cc: Danilo Krummrich <dakr@kernel.org> Cc: Matthew Brost <matthew.brost@intel.com> Cc: Philipp Stanner <phasta@kernel.org> Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Philipp Stanner <phasta@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20250324092633.49746-3-tvrtko.ursulin@igalia.com
Diffstat (limited to 'drivers/gpu/drm/Kconfig.debug')
-rw-r--r--drivers/gpu/drm/Kconfig.debug12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/gpu/drm/Kconfig.debug b/drivers/gpu/drm/Kconfig.debug
index ddc080f37850..c493743e8aca 100644
--- a/drivers/gpu/drm/Kconfig.debug
+++ b/drivers/gpu/drm/Kconfig.debug
@@ -100,5 +100,17 @@ config DRM_TTM_KUNIT_TEST
If in doubt, say "N".
+config DRM_SCHED_KUNIT_TEST
+ tristate "KUnit tests for the DRM scheduler" if !KUNIT_ALL_TESTS
+ select DRM_SCHED
+ depends on DRM && KUNIT
+ default KUNIT_ALL_TESTS
+ help
+ Choose this option to build unit tests for the DRM scheduler.
+
+ Recommended for driver developers only.
+
+ If in doubt, say "N".
+
config DRM_EXPORT_FOR_TESTS
bool