Skip to content

Commit c2a86d8

Browse files
committed
drm/xe/tests: Move shrink test out of xe_bo
The subtest typically has an execution time long enough to motivate a separate test so that it can be easily excluded if needed. v2: reword commit message(Thomas) Cc: Matthew Auld <[email protected]> Cc: Thomas Hellström <[email protected]> Reviewed-by: Thomas Hellström <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Nirmoy Das <[email protected]>
1 parent 64546cf commit c2a86d8

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

drivers/gpu/drm/xe/tests/xe_bo.c

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -606,8 +606,6 @@ static void xe_bo_shrink_kunit(struct kunit *test)
606606
static struct kunit_case xe_bo_tests[] = {
607607
KUNIT_CASE_PARAM(xe_ccs_migrate_kunit, xe_pci_live_device_gen_param),
608608
KUNIT_CASE_PARAM(xe_bo_evict_kunit, xe_pci_live_device_gen_param),
609-
KUNIT_CASE_PARAM_ATTR(xe_bo_shrink_kunit, xe_pci_live_device_gen_param,
610-
{.speed = KUNIT_SPEED_SLOW}),
611609
{}
612610
};
613611

@@ -618,3 +616,17 @@ struct kunit_suite xe_bo_test_suite = {
618616
.init = xe_kunit_helper_xe_device_live_test_init,
619617
};
620618
EXPORT_SYMBOL_IF_KUNIT(xe_bo_test_suite);
619+
620+
static struct kunit_case xe_bo_shrink_test[] = {
621+
KUNIT_CASE_PARAM_ATTR(xe_bo_shrink_kunit, xe_pci_live_device_gen_param,
622+
{.speed = KUNIT_SPEED_SLOW}),
623+
{}
624+
};
625+
626+
VISIBLE_IF_KUNIT
627+
struct kunit_suite xe_bo_shrink_test_suite = {
628+
.name = "xe_bo_shrink",
629+
.test_cases = xe_bo_shrink_test,
630+
.init = xe_kunit_helper_xe_device_live_test_init,
631+
};
632+
EXPORT_SYMBOL_IF_KUNIT(xe_bo_shrink_test_suite);

drivers/gpu/drm/xe/tests/xe_live_test_mod.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,13 @@
66
#include <kunit/test.h>
77

88
extern struct kunit_suite xe_bo_test_suite;
9+
extern struct kunit_suite xe_bo_shrink_test_suite;
910
extern struct kunit_suite xe_dma_buf_test_suite;
1011
extern struct kunit_suite xe_migrate_test_suite;
1112
extern struct kunit_suite xe_mocs_test_suite;
1213

1314
kunit_test_suite(xe_bo_test_suite);
15+
kunit_test_suite(xe_bo_shrink_test_suite);
1416
kunit_test_suite(xe_dma_buf_test_suite);
1517
kunit_test_suite(xe_migrate_test_suite);
1618
kunit_test_suite(xe_mocs_test_suite);

0 commit comments

Comments
 (0)