From: Michal Wajdeczko <michal.wajdeczko@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>,
Jonathan Cavitt <jonathan.cavitt@intel.com>,
Lucas De Marchi <lucas.demarchi@intel.com>
Subject: [PATCH v3 6/7] drm/xe/tests: Convert xe_mocs live tests
Date: Sat, 20 Jul 2024 16:25:27 +0200 [thread overview]
Message-ID: <20240720142528.530-7-michal.wajdeczko@intel.com> (raw)
In-Reply-To: <20240720142528.530-1-michal.wajdeczko@intel.com>
Convert xe_mocs live tests to parameterized style.
Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Reviewed-by: Jonathan Cavitt <jonathan.cavitt@intel.com>
Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
---
drivers/gpu/drm/xe/tests/xe_mocs.c | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/xe/tests/xe_mocs.c b/drivers/gpu/drm/xe/tests/xe_mocs.c
index febc1d967850..19554019b255 100644
--- a/drivers/gpu/drm/xe/tests/xe_mocs.c
+++ b/drivers/gpu/drm/xe/tests/xe_mocs.c
@@ -6,6 +6,7 @@
#include <kunit/test.h>
#include <kunit/visibility.h>
+#include "tests/xe_kunit_helpers.h"
#include "tests/xe_pci_test.h"
#include "tests/xe_test.h"
@@ -135,7 +136,9 @@ static int mocs_kernel_test_run_device(struct xe_device *xe)
static void xe_live_mocs_kernel_kunit(struct kunit *test)
{
- xe_call_for_each_device(mocs_kernel_test_run_device);
+ struct xe_device *xe = test->priv;
+
+ mocs_kernel_test_run_device(xe);
}
static int mocs_reset_test_run_device(struct xe_device *xe)
@@ -175,12 +178,14 @@ static int mocs_reset_test_run_device(struct xe_device *xe)
static void xe_live_mocs_reset_kunit(struct kunit *test)
{
- xe_call_for_each_device(mocs_reset_test_run_device);
+ struct xe_device *xe = test->priv;
+
+ mocs_reset_test_run_device(xe);
}
static struct kunit_case xe_mocs_tests[] = {
- KUNIT_CASE(xe_live_mocs_kernel_kunit),
- KUNIT_CASE(xe_live_mocs_reset_kunit),
+ KUNIT_CASE_PARAM(xe_live_mocs_kernel_kunit, xe_pci_live_device_gen_param),
+ KUNIT_CASE_PARAM(xe_live_mocs_reset_kunit, xe_pci_live_device_gen_param),
{}
};
@@ -188,5 +193,6 @@ VISIBLE_IF_KUNIT
struct kunit_suite xe_mocs_test_suite = {
.name = "xe_mocs",
.test_cases = xe_mocs_tests,
+ .init = xe_kunit_helper_xe_device_live_test_init,
};
EXPORT_SYMBOL_IF_KUNIT(xe_mocs_test_suite);
--
2.43.0
next prev parent reply other threads:[~2024-07-20 14:25 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-20 14:25 [PATCH v3 0/7] Convert live tests to parameterized style Michal Wajdeczko
2024-07-20 14:25 ` [PATCH v3 1/7] drm/xe: Introduce const cast helper Michal Wajdeczko
2024-07-21 2:46 ` Lucas De Marchi
2024-07-20 14:25 ` [PATCH v3 2/7] drm/xe/tests: Add helpers for use in live tests Michal Wajdeczko
2024-07-20 14:25 ` [PATCH v3 3/7] drm/xe/tests: Convert xe_bo " Michal Wajdeczko
2024-07-20 14:25 ` [PATCH v3 4/7] drm/xe/tests: Convert xe_dma_buf " Michal Wajdeczko
2024-07-20 14:25 ` [PATCH v3 5/7] drm/xe/tests: Convert xe_migrate " Michal Wajdeczko
2024-07-20 14:25 ` Michal Wajdeczko [this message]
2024-07-20 14:25 ` [PATCH v3 7/7] drm/xe/tests: Skip xe_mocs live tests on VF device Michal Wajdeczko
2024-07-20 14:31 ` ✓ CI.Patch_applied: success for Convert live tests to parameterized style (rev3) Patchwork
2024-07-20 14:31 ` ✓ CI.checkpatch: " Patchwork
2024-07-20 14:32 ` ✓ CI.KUnit: " Patchwork
2024-07-20 14:44 ` ✓ CI.Build: " Patchwork
2024-07-20 14:46 ` ✓ CI.Hooks: " Patchwork
2024-07-20 14:48 ` ✓ CI.checksparse: " Patchwork
2024-07-20 15:09 ` ✗ CI.BAT: failure " Patchwork
2024-07-22 9:58 ` Michal Wajdeczko
2024-07-20 16:13 ` ✗ CI.FULL: " Patchwork
2024-07-22 10:05 ` Michal Wajdeczko
2024-07-23 4:27 ` ✓ CI.BAT: success " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240720142528.530-7-michal.wajdeczko@intel.com \
--to=michal.wajdeczko@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=jonathan.cavitt@intel.com \
--cc=lucas.demarchi@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox