[Intel-gfx] [PATCH i-g-t v3] tests/gem_userptr_blits: Refresh map-fixed-invalidate* subtests

2020-02-26 Thread Janusz Krzysztofik
mmap types to GTT if no MMAP_OFFSET support"). Signed-off-by: Janusz Krzysztofik Cc: Michał Winiarski --- tests/i915/gem_userptr_blits.c | 43 +++--- 1 file changed, 29 insertions(+), 14 deletions(-) diff --git a/tests/i915/gem_userptr_blits.c b/

[Intel-gfx] [RFC PATCH i-g-t v4 0/2] tests/gem_userptr_blits: Enhance invalid mapping exercise

2020-02-28 Thread Janusz Krzysztofik
t set, - actually try to anger lockdep using gem_set_tiling() (Chris). - rebase on top of "lib/i915: Restrict mmap types to GTT if no MMAP_OFFSET support". Janusz Krzysztofik (2): tests/gem_userptr_blits: Exercise new invalid mapping types tests/gem_userptr_blits: Try t

[Intel-gfx] [RFC PATCH i-g-t v4 2/2] tests/gem_userptr_blits: Try to anger lockdep with invalid mappings

2020-02-28 Thread Janusz Krzysztofik
A currently unavoidable lockdep loop related to userptr MMU notifier exists inside the i915 driver. For as long as that issue is not resolved, operations which are believed to potentially result in the loop being triggered are expected to fail early to prevent from that badness to happen. The loc

[Intel-gfx] [RFC PATCH i-g-t v4 1/2] tests/gem_userptr_blits: Exercise new invalid mapping types

2020-02-28 Thread Janusz Krzysztofik
d" section, - rebase on top of "lib/i915: Restrict mmap types to GTT if no MMAP_OFFSET support". Signed-off-by: Janusz Krzysztofik Cc: Antonio Argenziano --- tests/i915/gem_userptr_blits.c | 38 +++--- 1 file changed, 21 insertions(+), 17 deletio

[Intel-gfx] [RFC PATCH i-g-t 2/2] tests/gem_userptr_blits: Refresh other now MMAP_GTT dependent subtests

2020-03-03 Thread Janusz Krzysztofik
type if there are any. Signed-off-by: Janusz Krzysztofik --- tests/i915/gem_userptr_blits.c | 108 - 1 file changed, 79 insertions(+), 29 deletions(-) diff --git a/tests/i915/gem_userptr_blits.c b/tests/i915/gem_userptr_blits.c index efe34c512..3c659db0c 100644

[Intel-gfx] [RFC PATCH i-g-t 1/2] tests/gem_userptr_blits: Refresh readonly-mmap-unsync exercise

2020-03-03 Thread Janusz Krzysztofik
Upgrade the subtest to use MMAP_GTT API v4 (aka MMAP_OFFSET), dynamically examine each mapping type supported by i915 driver. Signed-off-by: Janusz Krzysztofik --- tests/i915/gem_userptr_blits.c | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/tests

[Intel-gfx] [RFC PATCH i-g-t 0/2] tests/gem_userptr_blits: Refresh other now MMAP_GTT dependent subtests

2020-03-03 Thread Janusz Krzysztofik
ise" series, still waiting for someone to provide a review) patches, this series concludes MMAP_OFFSET related changes required for gem_userptr_blits, I believe. Thanks, Janusz Janusz Krzysztofik (2): tests/gem_userptr_blits: Refresh readonly-mmap-unsync exercise tests/gem_userptr_blits: R

[Intel-gfx] [PATCH i-g-t 0/3] tests/gem_userptr_blits: mmap-offset-invalidate enhancements

2020-03-04 Thread Janusz Krzysztofik
Janusz Krzysztofik (3): tests/gem_userptr_blits: More effectively set pages before invalidation tests/gem_userptr_blits: More exact detection of lockdep loop prevention tests/gem_userptr_blits: Add active variant of mmap-offset-invalidate tests/i915/gem_userptr_blits.c | 40

[Intel-gfx] [PATCH i-g-t 2/3] tests/gem_userptr_blits: More exact detection of lockdep loop prevention

2020-03-04 Thread Janusz Krzysztofik
If mmap-offset over userptr fails, skip with respective message about lockdep loop preventive failure occurrence only if ENODEV, fail otherwise. Signed-off-by: Janusz Krzysztofik --- tests/i915/gem_userptr_blits.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests

[Intel-gfx] [PATCH i-g-t 1/3] tests/gem_userptr_blits: More effectively set pages before invalidation

2020-03-04 Thread Janusz Krzysztofik
It has been observed that mmap-offset-invalidate@wb subtest has never triggered a lockdep loop complain. To fix it, don't use the ->domain field of a mapping type being examined, always set read and write domains to I915_GEM_DOMAIN_GTT instead. Signed-off-by: Janusz Krzysztofik --- te

[Intel-gfx] [RFC PATCH i-g-t 3/3] tests/gem_userptr_blits: Add active variant of mmap-offset-invalidate

2020-03-04 Thread Janusz Krzysztofik
Add a variant that also attaches a igt_spin_t to the userptr, waits for it to start executing, call igt_spin_set_timeout and then do the munmap. Suggested-by: Chris Wilson Signed-off-by: Janusz Krzysztofik --- tests/i915/gem_userptr_blits.c | 33 - 1 file

[Intel-gfx] [Fwd: ✓ Fi.CI.IGT: success for gem_userptr_blits: Refresh other now MMAP_GTT dependent subtests]

2020-03-04 Thread Janusz Krzysztofik
Message From: Patchwork Reply-To: intel-gfx-try...@lists.freedesktop.org To: Janusz Krzysztofik Cc: intel-gfx-try...@lists.freedesktop.org Subject: ✓ Fi.CI.IGT: success for gem_userptr_blits: Refresh other now MMAP_GTT dependent subtests Date: Wed, 04 Mar 2020 11:24:45 - == Series

Re: [Intel-gfx] ✗ Fi.CI.IGT: failure for gem_userptr_blits: mmap-offset-invalidate enhancements

2020-03-05 Thread Janusz Krzysztofik
Hi, Here are my comments to CI results from testing the IGT changes on Trybot with kernel change that prevents non-GTT mmap-offset mapping to userptr reverted. On Thu, 2020-03-05 at 06:15 +, Patchwork wrote: > == Series Details == > > Series: gem_userptr_blits: mmap-offset-invalidate enhance

[Intel-gfx] [PATCH i-g-t] tests/gem_exec_gttfill: MMAP_OFFSET related refresh

2020-03-05 Thread Janusz Krzysztofik
The test already tried to use a working mapping by first trying legacy WC, then GTT. Use gem_mmap__device_coherent() helper instead of approaching its implementation locally. Signed-off-by: Janusz Krzysztofik --- tests/i915/gem_exec_gttfill.c | 13 - 1 file changed, 4 insertions

[Intel-gfx] [PATCH i-g-t] tests/core_hotunplug: Wait for device nodes to re-appear

2023-08-22 Thread Janusz Krzysztofik
es: https://gitlab.freedesktop.org/drm/intel/-/issues/8830 Closes: https://gitlab.freedesktop.org/drm/xe/kernel/-/issues/500 Signed-off-by: Janusz Krzysztofik Cc: Petri Latvala --- tests/core_hotunplug.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/core_hotunplug.c b/tests/core_ho

[Intel-gfx] [RFC PATCH] kunit: Fix test log size limit too low for some tests

2023-08-30 Thread Janusz Krzysztofik
tools that rely on parsing of debugfs results can fail. Increase kunit test case log size limit to 4096 bytes. Signed-off-by: Janusz Krzysztofik --- include/kunit/test.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/kunit/test.h b/include/kunit/test.h index

Re: [Intel-gfx] [RFC PATCH] kunit: Fix test log size limit too low for some tests

2023-08-30 Thread Janusz Krzysztofik
On Wednesday, 30 August 2023 11:23:43 CEST David Gow wrote: > On Wed, 30 Aug 2023 at 15:55, Janusz Krzysztofik > wrote: > > > > Now we have memory space available to a kunit test case log exposed via > > debugfs limited to 2048 bytes, while some para

[Intel-gfx] [PATCH i-g-t] tests/gem_reset_stats: Don't allow request watchdog to interfere

2023-04-13 Thread Janusz Krzysztofik
chdog interfers with engine heartbeat and request preemption used by the test for exercising reset statistics. Disable request watchdog during the test execution. Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/8310 Signed-off-by: Janusz Krzysztofik --- tests/i915/gem_reset_stats.c | 7 +

[Intel-gfx] [RFC PATCH] x86/mm: Fix PAT bit missing from page protection modify mask

2023-04-24 Thread Janusz Krzysztofik
and the _PAGE_CHG_MASK symbol, primarly used by pte_modify(), is likely intentionally defined with that bit not set, keep that symbol unchanged. Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/7648 Fixes: 281d4078bec3 ("x86: Make page cache mode a real type") Si

[Intel-gfx] [PATCH i-g-t 00/17] Fix IGT Kunit implementation issues

2023-09-08 Thread Janusz Krzysztofik
Janusz Krzysztofik (17): lib/kunit: Drop unused file stream lib/kunit: Stop loading kunit module explicitly lib/kunit: Fix struct kmod_module kunit_kmod not freed lib/kunit: Optimize calls to igt_success/skip/fail() lib/kunit: Fix illegal igt_fail() calls inside subtest body lib/ktap

[Intel-gfx] [PATCH i-g-t 01/17] lib/kunit: Drop unused file stream

2023-09-08 Thread Janusz Krzysztofik
fileno() and the data is read with read(). Drop the unnecessary conversions and teach functions to accept and process just the file descriptor of /dev/kmsg. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 12 +- lib/igt_ktap.c | 62

[Intel-gfx] [PATCH i-g-t 02/17] lib/kunit: Stop loading kunit module explicitly

2023-09-08 Thread Janusz Krzysztofik
essary operation. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 97667a896f..faf31afabc 100644 --- a/lib/igt_kmod.c +++ b/lib/igt_kmod.c @@ -789,12 +789,6 @@ static void __igt_kunit(const char

[Intel-gfx] [PATCH i-g-t 04/17] lib/kunit: Optimize calls to igt_success/skip/fail()

2023-09-08 Thread Janusz Krzysztofik
makes the code more compact. Go for it. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 14 +++--- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 34ddec3fad..1d1cd51170 100644 --- a/lib/igt_kmod.c +++ b/lib/igt_kmod.c @@ -814,12

[Intel-gfx] [PATCH i-g-t 05/17] lib/kunit: Fix illegal igt_fail() calls inside subtest body

2023-09-08 Thread Janusz Krzysztofik
preceding igt_fixture section. Replace remaining illegal igt_fail() calls with more friendly skips. Let igt_runner decide if abort is needed. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 75 +++--- 1 file changed, 22 insertions(+), 53 deletions

[Intel-gfx] [PATCH i-g-t 03/17] lib/kunit: Fix struct kmod_module kunit_kmod not freed

2023-09-08 Thread Janusz Krzysztofik
We obtain a kmod_module structure for kunit module in order to check if it is modular or built-in, then we never release that structure. Fix it. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index

[Intel-gfx] [PATCH i-g-t 06/17] lib/ktap: Make sure we fail on premature cancel

2023-09-08 Thread Janusz Krzysztofik
by result of KTAP parsing. Signed-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 123a40d183..84fb13218f 100644 --- a/lib/igt_ktap.c +++ b/lib/igt_ktap.c @@ -579,9 +579,7

[Intel-gfx] [PATCH i-g-t 07/17] lib/ktap: Don't ignore interrupt signals

2023-09-08 Thread Janusz Krzysztofik
igt_runner has no problems with killing us promptly on timeout. Signed-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 84fb13218f..3cfb55ec97 100644 --- a/lib/igt_ktap.c +++ b/lib

[Intel-gfx] [PATCH i-g-t 10/17] lib/ktap: Read /dev/kmsg in blocking mode

2023-09-08 Thread Janusz Krzysztofik
high CPU usage can be observed. Simplify reading KTAP reports by first switching the file descriptor back to blocking mode. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 7 - lib/igt_ktap.c | 81 ++ 2 files changed, 28 insertions(+

[Intel-gfx] [PATCH i-g-t 08/17] lib/kunit: Cancel KTP parser on module load failure

2023-09-08 Thread Janusz Krzysztofik
break the test immediately. Cancel the KTAP parser thread right after module load error and before joining it. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 1 + lib/igt_ktap.c | 6 ++ lib/igt_ktap.h | 1 + 3 files changed, 8 insertions(+) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c

[Intel-gfx] [PATCH i-g-t 09/17] lib/ktap: Drop is_running flag

2023-09-08 Thread Janusz Krzysztofik
-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 32 1 file changed, 32 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 1e75b2ec23..fe77b62680 100644 --- a/lib/igt_ktap.c +++ b/lib/igt_ktap.c @@ -18,7 +18,6 @@ struct ktap_parser_args { int

[Intel-gfx] [PATCH i-g-t 11/17] lib/kunit: Fail / skip on kernel taint

2023-09-08 Thread Janusz Krzysztofik
Similar to how igt_kselftest() handles kernel taints, fail current dynamic sub-subtest and skip remaining ones when a kernel taint is detected during execution of kunit test cases. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 12 +++- 1 file changed, 11 insertions(+), 1

[Intel-gfx] [PATCH i-g-t 12/17] lib/ktap: Use IGT linked lists for storing KTAP results

2023-09-08 Thread Janusz Krzysztofik
For code simplicity and clarity, use existing IGT linked lists library instead of open coding a custom implementation of a list of KTAP results. While being at it, flatten the code by inverting a check for pending results. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 28

[Intel-gfx] [PATCH i-g-t 13/17] lib/ktap: Reimplement KTAP parser

2023-09-08 Thread Janusz Krzysztofik
ctness of their parsing is also provided. Signed-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 422 lib/igt_ktap.h | 15 ++ lib/tests/igt_ktap_parser.c | 235 lib/tests/meson.build | 1 + 4 files changed,

[Intel-gfx] [PATCH i-g-t 15/17] lib/kunit: Parse KTAP report from the main process thread

2023-09-08 Thread Janusz Krzysztofik
needed functions from igt_ktap soruces. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 158 +++--- lib/igt_ktap.c | 568 - lib/igt_ktap.h | 22 -- 3 files changed, 123 insertions(+), 625 deletions(-) diff --git a/lib/igt_kmod.c b/lib

[Intel-gfx] [PATCH i-g-t 16/17] lib/kunit: Strip "_test" or "_kunit" suffix from subtest names

2023-09-08 Thread Janusz Krzysztofik
t carry any useful information. Strip those suffixes from IGT subtest names. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 26 ++ tests/drm_mm.c | 42 +- 2 files changed, 43 insertions(+), 25 deletions(-) diff --git a/lib/igt

[Intel-gfx] [PATCH i-g-t 14/17] lib/kunit: Load test modules in background

2023-09-08 Thread Janusz Krzysztofik
parser, without waiting for completion of module loading. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 35 +-- 1 file changed, 33 insertions(+), 2 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index c692954911..bbde3929f2 100644 --- a/lib

[Intel-gfx] [PATCH i-g-t 17/17] lib/kunit: Omit suite name prefix if the same as subtest name

2023-09-08 Thread Janusz Krzysztofik
is into account when composing names for IGT dynamic sub-subtest names and drop the leading test suite name component when it is the same as subtest name. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 11 --- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/

[Intel-gfx] [PATCH i-g-t v2 00/17] Fix IGT Kunit implementation issues

2023-09-08 Thread Janusz Krzysztofik
v2: Fix incorrect and missing includes in the test source file, - add license and copyright clauses to the test source file. Janusz Krzysztofik (17): lib/kunit: Drop unused file stream lib/kunit: Stop loading kunit module explicitly lib/kunit: Fix struct kmod_module kunit_kmod not freed

[Intel-gfx] [PATCH i-g-t v2 01/17] lib/kunit: Drop unused file stream

2023-09-08 Thread Janusz Krzysztofik
fileno() and the data is read with read(). Drop the unnecessary conversions and teach functions to accept and process just the file descriptor of /dev/kmsg. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 12 +- lib/igt_ktap.c | 62

[Intel-gfx] [PATCH i-g-t v2 03/17] lib/kunit: Fix struct kmod_module kunit_kmod not freed

2023-09-08 Thread Janusz Krzysztofik
We obtain a kmod_module structure for kunit module in order to check if it is modular or built-in, then we never release that structure. Fix it. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index

[Intel-gfx] [PATCH i-g-t v2 02/17] lib/kunit: Stop loading kunit module explicitly

2023-09-08 Thread Janusz Krzysztofik
essary operation. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 97667a896f..faf31afabc 100644 --- a/lib/igt_kmod.c +++ b/lib/igt_kmod.c @@ -789,12 +789,6 @@ static void __igt_kunit(const char

[Intel-gfx] [PATCH i-g-t v2 04/17] lib/kunit: Optimize calls to igt_success/skip/fail()

2023-09-08 Thread Janusz Krzysztofik
makes the code more compact. Go for it. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 14 +++--- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 34ddec3fad..1d1cd51170 100644 --- a/lib/igt_kmod.c +++ b/lib/igt_kmod.c @@ -814,12

[Intel-gfx] [PATCH i-g-t v2 05/17] lib/kunit: Fix illegal igt_fail() calls inside subtest body

2023-09-08 Thread Janusz Krzysztofik
preceding igt_fixture section. Replace remaining illegal igt_fail() calls with more friendly skips. Let igt_runner decide if abort is needed. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 75 +++--- 1 file changed, 22 insertions(+), 53 deletions

[Intel-gfx] [PATCH i-g-t v2 06/17] lib/ktap: Make sure we fail on premature cancel

2023-09-08 Thread Janusz Krzysztofik
by result of KTAP parsing. Signed-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 123a40d183..84fb13218f 100644 --- a/lib/igt_ktap.c +++ b/lib/igt_ktap.c @@ -579,9 +579,7

[Intel-gfx] [PATCH i-g-t v2 07/17] lib/ktap: Don't ignore interrupt signals

2023-09-08 Thread Janusz Krzysztofik
igt_runner has no problems with killing us promptly on timeout. Signed-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 84fb13218f..3cfb55ec97 100644 --- a/lib/igt_ktap.c +++ b/lib

[Intel-gfx] [PATCH i-g-t v2 08/17] lib/kunit: Cancel KTP parser on module load failure

2023-09-08 Thread Janusz Krzysztofik
break the test immediately. Cancel the KTAP parser thread right after module load error and before joining it. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 1 + lib/igt_ktap.c | 6 ++ lib/igt_ktap.h | 1 + 3 files changed, 8 insertions(+) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c

[Intel-gfx] [PATCH i-g-t v2 09/17] lib/ktap: Drop is_running flag

2023-09-08 Thread Janusz Krzysztofik
-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 32 1 file changed, 32 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 1e75b2ec23..fe77b62680 100644 --- a/lib/igt_ktap.c +++ b/lib/igt_ktap.c @@ -18,7 +18,6 @@ struct ktap_parser_args { int

[Intel-gfx] [PATCH i-g-t v2 10/17] lib/ktap: Read /dev/kmsg in blocking mode

2023-09-08 Thread Janusz Krzysztofik
high CPU usage can be observed. Simplify reading KTAP reports by first switching the file descriptor back to blocking mode. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 7 - lib/igt_ktap.c | 81 ++ 2 files changed, 28 insertions(+

[Intel-gfx] [PATCH i-g-t v2 12/17] lib/ktap: Use IGT linked lists for storing KTAP results

2023-09-08 Thread Janusz Krzysztofik
For code simplicity and clarity, use existing IGT linked lists library instead of open coding a custom implementation of a list of KTAP results. While being at it, flatten the code by inverting a check for pending results. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 28

[Intel-gfx] [PATCH i-g-t v2 13/17] lib/ktap: Reimplement KTAP parser

2023-09-08 Thread Janusz Krzysztofik
ctness of their parsing is also provided. v2: Fix incorrect and missing includes in the test source file, - add license and copyright clauses to the test source file. Signed-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 422 lib/igt_ktap.h

[Intel-gfx] [PATCH i-g-t v2 14/17] lib/kunit: Load test modules in background

2023-09-08 Thread Janusz Krzysztofik
parser, without waiting for completion of module loading. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 35 +-- 1 file changed, 33 insertions(+), 2 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index c692954911..bbde3929f2 100644 --- a/lib

[Intel-gfx] [PATCH i-g-t v2 15/17] lib/kunit: Parse KTAP report from the main process thread

2023-09-08 Thread Janusz Krzysztofik
needed functions from igt_ktap soruces. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 158 +++--- lib/igt_ktap.c | 568 - lib/igt_ktap.h | 22 -- 3 files changed, 123 insertions(+), 625 deletions(-) diff --git a/lib/igt_kmod.c b/lib

[Intel-gfx] [PATCH i-g-t v2 11/17] lib/kunit: Fail / skip on kernel taint

2023-09-08 Thread Janusz Krzysztofik
Similar to how igt_kselftest() handles kernel taints, fail current dynamic sub-subtest and skip remaining ones when a kernel taint is detected during execution of kunit test cases. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 12 +++- 1 file changed, 11 insertions(+), 1

[Intel-gfx] [PATCH i-g-t v2 16/17] lib/kunit: Strip "_test" or "_kunit" suffix from subtest names

2023-09-08 Thread Janusz Krzysztofik
t carry any useful information. Strip those suffixes from IGT subtest names. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 26 ++ tests/drm_mm.c | 42 +- 2 files changed, 43 insertions(+), 25 deletions(-) diff --git a/lib/igt

[Intel-gfx] [PATCH i-g-t v2 17/17] lib/kunit: Omit suite name prefix if the same as subtest name

2023-09-08 Thread Janusz Krzysztofik
is into account when composing names for IGT dynamic sub-subtest names and drop the leading test suite name component when it is the same as subtest name. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 11 --- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/

Re: [Intel-gfx] [PATCH i-g-t v2 05/17] lib/kunit: Fix illegal igt_fail() calls inside subtest body

2023-09-11 Thread Janusz Krzysztofik
Hi Mauro, Thanks for review. On Monday, 11 September 2023 10:52:51 CEST Mauro Carvalho Chehab wrote: > On Fri, 8 Sep 2023 14:32:39 +0200 > Janusz Krzysztofik wrote: > > > In a body of a subtest with dynamic sub-subtests, it is illegal to call > > igt_fail() and its varia

[Intel-gfx] [PATCH] drm/tests: Fix incorrect argument in drm_test_mm_insert_range

2023-09-11 Thread Janusz Krzysztofik
t;= start) is triggered. Fix it by restoring the original value. Fixes: fc8d29e298cf ("drm: selftest: convert drm_mm selftest to KUnit") Signed-off-by: Janusz Krzysztofik Cc: "Maíra Canal" Cc: Arthur Grillo Cc: Javier Martinez Canillas Cc: Daniel Latypov Cc: sta...@vger.ke

Re: [Intel-gfx] [PATCH i-g-t v2 05/17] lib/kunit: Fix illegal igt_fail() calls inside subtest body

2023-09-13 Thread Janusz Krzysztofik
On Monday, 11 September 2023 13:57:29 CEST Mauro Carvalho Chehab wrote: > On Mon, 11 Sep 2023 11:28:32 +0200 > Janusz Krzysztofik wrote: > > > Hi Mauro, > > > > Thanks for review. > > > > On Monday, 11 September 2023 10:52:51 CEST Mauro Carvalho Chehab wr

Re: [Intel-gfx] [PATCH i-g-t v2 07/17] lib/ktap: Don't ignore interrupt signals

2023-09-13 Thread Janusz Krzysztofik
On Monday, 11 September 2023 11:01:42 CEST Mauro Carvalho Chehab wrote: > On Fri, 8 Sep 2023 14:32:41 +0200 > Janusz Krzysztofik wrote: > > > While reading KTAP data from /dev/kmsg we now ignore interrupt signals > > that may occur during read() and we continue

Re: [Intel-gfx] [PATCH i-g-t v2 07/17] lib/ktap: Don't ignore interrupt signals

2023-09-15 Thread Janusz Krzysztofik
On Friday, 15 September 2023 14:25:24 CEST Mauro Carvalho Chehab wrote: > On Wed, 13 Sep 2023 16:04:10 +0200 > Janusz Krzysztofik wrote: > > > On Monday, 11 September 2023 11:01:42 CEST Mauro Carvalho Chehab wrote: > > > On Fri, 8 Sep 2023 14:32:41 +0200 > &g

Re: [Intel-gfx] [PATCH i-g-t v2 13/17] lib/ktap: Reimplement KTAP parser

2023-09-15 Thread Janusz Krzysztofik
Hi Mauro, On Friday, 15 September 2023 14:28:49 CEST Mauro Carvalho Chehab wrote: > On Fri, 8 Sep 2023 14:32:47 +0200 > Janusz Krzysztofik wrote: > > Forgot to mention on my past review: > > > + &n, &l

Re: [Intel-gfx] [PATCH i-g-t v2 13/17] lib/ktap: Reimplement KTAP parser

2023-09-15 Thread Janusz Krzysztofik
On Friday, 15 September 2023 15:09:58 CEST Janusz Krzysztofik wrote: > Hi Mauro, > > On Friday, 15 September 2023 14:28:49 CEST Mauro Carvalho Chehab wrote: > > On Fri, 8 Sep 2023 14:32:47 +0200 > > Janusz Krzysztofik wrote: > > > > Fo

Re: [Intel-gfx] [PATCH] drm/tests: Fix incorrect argument in drm_test_mm_insert_range

2023-09-15 Thread Janusz Krzysztofik
Hi Maíra, Thanks for review. On Friday, 15 September 2023 16:01:31 CEST Maira Canal wrote: > Hi, > > On 9/11/23 10:03, Janusz Krzysztofik wrote: > > While drm_mm test was converted form igt selftest to kunit, unexpected > > value of "end" argument equal "star

[Intel-gfx] [PATCH i-g-t v3 00/17] Fix IGT Kunit implementation issues

2023-09-18 Thread Janusz Krzysztofik
includes in the test source file, - add license and copyright clauses to the test source file. Janusz Krzysztofik (17): lib/kunit: Drop unused file stream lib/kunit: Stop loading kunit module explicitly lib/kunit: Fix struct kmod_module kunit_kmod not freed lib/kunit: Optimize calls to

[Intel-gfx] [PATCH i-g-t v3 01/17] lib/kunit: Drop unused file stream

2023-09-18 Thread Janusz Krzysztofik
descriptor with fileno() and raw data is read with read(). Drop the unnecessary conversions and teach functions to accept and process just the file descriptor of /dev/kmsg. Signed-off-by: Janusz Krzysztofik Acked-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 12 +- lib/igt_ktap.c | 62

[Intel-gfx] [PATCH i-g-t v3 02/17] lib/kunit: Stop loading kunit module explicitly

2023-09-18 Thread Janusz Krzysztofik
essary operation. Signed-off-by: Janusz Krzysztofik Acked-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 97667a896f..faf31afabc 100644 --- a/lib/igt_kmod.c +++ b/lib/igt_kmod.c @@ -789,12 +789,6 @@ stat

[Intel-gfx] [PATCH i-g-t v3 04/17] lib/kunit: Optimize calls to igt_success/skip/fail()

2023-09-18 Thread Janusz Krzysztofik
makes the code more compact. Go for it. Signed-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 14 +++--- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 34ddec3fad..1d1cd51170 100644 --- a/lib

[Intel-gfx] [PATCH i-g-t v3 03/17] lib/kunit: Fix struct kmod_module kunit_kmod not freed

2023-09-18 Thread Janusz Krzysztofik
We obtain a kmod_module structure for kunit module in order to check if it is modular or built-in, then we never release that structure. Fix it. Signed-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib

[Intel-gfx] [PATCH i-g-t v3 05/17] lib/kunit: Fix illegal igt_fail() calls inside subtest body

2023-09-18 Thread Janusz Krzysztofik
from igt_ktest_fini() when only listing subtests, - call igt_ktest_end() from igt_fixture so it is not unnecessarily called when only listing subtests. Signed-off-by: Janusz Krzysztofik Cc: Mauro Carvalho Chehab --- lib/igt_kmod.c | 76 +++--- 1

[Intel-gfx] [PATCH i-g-t v3 06/17] lib/ktap: Make sure we fail on premature cancel

2023-09-18 Thread Janusz Krzysztofik
by result of KTAP parsing. Signed-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_ktap.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 123a40d183..84fb13218f 100644 --- a/lib/igt_ktap.c +++ b/lib/igt_ktap.c

[Intel-gfx] [PATCH i-g-t v3 07/17] lib/ktap: Drop checks for EINTR on read() failures

2023-09-18 Thread Janusz Krzysztofik
user interrupt, only the whole process should be terminated. Drop checks for errno == EINTR as not applicable. v2: Drop handling of EINTR completely, update commit message and descripion. Signed-off-by: Janusz Krzysztofik Cc: Mauro Carvalho Chehab --- lib/igt_ktap.c | 15 --- 1

[Intel-gfx] [PATCH i-g-t v3 08/17] lib/kunit: Cancel KTP parser on module load failure

2023-09-18 Thread Janusz Krzysztofik
break the test immediately. Cancel the KTAP parser thread right after module load error and before joining it. Signed-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 1 + lib/igt_ktap.c | 6 ++ lib/igt_ktap.h | 1 + 3 files changed, 8 insertions(+) diff

[Intel-gfx] [PATCH i-g-t v3 09/17] lib/ktap: Drop is_running flag

2023-09-18 Thread Janusz Krzysztofik
-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_ktap.c | 32 1 file changed, 32 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index 0db42d1243..5bc5e003d7 100644 --- a/lib/igt_ktap.c +++ b/lib/igt_ktap.c @@ -18,7 +18,6

[Intel-gfx] [PATCH i-g-t v3 10/17] lib/ktap: Read /dev/kmsg in blocking mode

2023-09-18 Thread Janusz Krzysztofik
IGINT default signal handler kills the whole process anyway, - update commit description to also mention read error handling fix. Signed-off-by: Janusz Krzysztofik Acked-by: Mauro Carvalho Chehab # v1 --- lib/igt_kmod.c | 7 +- lib/igt_ktap.c

[Intel-gfx] [PATCH i-g-t v3 11/17] lib/kunit: Fail / skip on kernel taint

2023-09-18 Thread Janusz Krzysztofik
Similar to how igt_kselftest() handles kernel taints, fail current dynamic sub-subtest and skip remaining ones when a kernel taint is detected during execution of kunit test cases. Signed-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 12 +++- 1 file

[Intel-gfx] [PATCH i-g-t v3 14/17] lib/kunit: Load test modules in background

2023-09-18 Thread Janusz Krzysztofik
parser, without waiting for completion of module loading. Signed-off-by: Janusz Krzysztofik Acked-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 35 +-- 1 file changed, 33 insertions(+), 2 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index 2941524bb4

[Intel-gfx] [PATCH i-g-t v3 13/17] lib/ktap: Reimplement KTAP parser

2023-09-18 Thread Janusz Krzysztofik
the test source file, - add license and copyright clauses to the test source file. Signed-off-by: Janusz Krzysztofik Acked-by: Mauro Carvalho Chehab --- lib/igt_ktap.c | 422 lib/igt_ktap.h | 15 ++ lib/tests/igt

[Intel-gfx] [PATCH i-g-t v3 12/17] lib/ktap: Use IGT linked lists for storing KTAP results

2023-09-18 Thread Janusz Krzysztofik
For code simplicity and clarity, use existing IGT linked lists library instead of open coding a custom implementation of a list of KTAP results. While being at it, flatten the code by inverting a check for pending results. Signed-off-by: Janusz Krzysztofik Acked-by: Mauro Carvalho Chehab

[Intel-gfx] [PATCH i-g-t v3 15/17] lib/kunit: Parse KTAP report from the main process thread

2023-09-18 Thread Janusz Krzysztofik
needed functions from igt_ktap soruces. v2: Interrupt blocking read() on modprobe failure. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 208 ++ lib/igt_ktap.c | 568 - lib/igt_ktap.h | 22 -- 3 files changed, 166 insertions

[Intel-gfx] [PATCH i-g-t v3 16/17] lib/kunit: Strip "_test" or "_kunit" suffix from subtest names

2023-09-18 Thread Janusz Krzysztofik
t carry any useful information. Strip those suffixes from IGT subtest names. Signed-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 23 --- tests/drm_mm.c | 42 +- 2 files changed, 41 insertions(+), 24

[Intel-gfx] [PATCH i-g-t v3 17/17] lib/kunit: Omit suite name prefix if the same as subtest name

2023-09-18 Thread Janusz Krzysztofik
is into account when composing names for IGT dynamic sub-subtest names and drop the leading test suite name component when it is the same as subtest name. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 11 --- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/

[Intel-gfx] [PATCH i-g-t 0/9] Kunit fixes and improvements

2023-10-03 Thread Janusz Krzysztofik
Janusz Krzysztofik (9): lib/kunit: Fix handling of potential errors from F_GETFL lib/kunit: Be more verbose on errors lib/kunit: Fix misplaced igt_kunit() doc lib/kunit: Parse KTAP report from the main process thread lib/kunit: Omit suite name prefix if the same as subtest name tests

[Intel-gfx] [PATCH i-g-t 1/9] lib/kunit: Fix handling of potential errors from F_GETFL

2023-10-03 Thread Janusz Krzysztofik
Function fcntl(..., F_GETFL, ...) that returns file status flags may also return a negative error code. Handle that error instead of blindly using the returned value as flags. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

[Intel-gfx] [PATCH i-g-t 2/9] lib/kunit: Be more verbose on errors

2023-10-03 Thread Janusz Krzysztofik
Use a more verbose variant of igt_fail() when failing a dynamic sub- subtest on kernel taint. Also, print a debug message on string duplication failure. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/igt_kmod.c b

[Intel-gfx] [PATCH i-g-t 3/9] lib/kunit: Fix misplaced igt_kunit() doc

2023-10-03 Thread Janusz Krzysztofik
: Janusz Krzysztofik --- lib/igt_kmod.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c index df0e650d49..426ae5b26f 100644 --- a/lib/igt_kmod.c +++ b/lib/igt_kmod.c @@ -762,15 +762,6 @@ static void *modprobe_task(void *arg

[Intel-gfx] [PATCH i-g-t 4/9] lib/kunit: Parse KTAP report from the main process thread

2023-10-03 Thread Janusz Krzysztofik
been processed, - fix trailing newlines missing from error messages, - add more debug statements, - integrate common code around kunit_result_free() into it. v2: Interrupt blocking read() on modprobe failure. Signed-off-by: Janusz Krzysztofik Acked-by: Mauro Carvalho Chehab # v2 --- lib

[Intel-gfx] [PATCH i-g-t 5/9] lib/kunit: Omit suite name prefix if the same as subtest name

2023-10-03 Thread Janusz Krzysztofik
is into account when composing names for IGT dynamic sub-subtest names and drop the leading test suite name component when it is the same as subtest name. Signed-off-by: Janusz Krzysztofik Reviewed-by: Mauro Carvalho Chehab --- lib/igt_kmod.c | 11 --- 1 file changed, 8 insertions(+),

[Intel-gfx] [PATCH i-g-t 8/9] lib/kunit: Fetch a list of test cases in advance

2023-10-03 Thread Janusz Krzysztofik
list of test cases obtained in advance, then we stop parsing KTAP report as soon as we get a result from the last test case from the list. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 217 +++-- 1 file changed, 157 insertions(+), 60 deletions(-)

[Intel-gfx] [PATCH i-g-t 7/9] lib/ktap: Drop workaround for missing top level KTAP headers

2023-10-03 Thread Janusz Krzysztofik
has fixed that issue, that workaround is no longer needed. Drop it. Signed-off-by: Janusz Krzysztofik --- lib/igt_ktap.c | 12 lib/tests/igt_ktap_parser.c | 3 +-- 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/lib/igt_ktap.c b/lib/igt_ktap.c index

[Intel-gfx] [PATCH i-g-t 6/9] tests/kms_selftest: Let subtest names match suite names

2023-10-03 Thread Janusz Krzysztofik
to kunit and the i915 module potentially providing three test suites: mock, live and perf). [1] https://docs.kernel.org/dev-tools/kunit/style.html Signed-off-by: Janusz Krzysztofik --- tests/kms_selftest.c | 37 - 1 file changed, 16 insertions(+), 21 deletions

[Intel-gfx] [PATCH i-g-t 9/9] lib/kunit: Execute kunit test cases only when needed

2023-10-03 Thread Janusz Krzysztofik
of dynamic sub-subtests, and do that only from the first actually executed dynamic sub-subtest. Signed-off-by: Janusz Krzysztofik --- lib/igt_kmod.c | 59 -- 1 file changed, 33 insertions(+), 26 deletions(-) diff --git a/lib/igt_kmod.c b/lib/igt_km

Re: [Intel-gfx] [PATCH i-g-t 8/9] lib/kunit: Fetch a list of test cases in advance

2023-10-06 Thread Janusz Krzysztofik
Hi Kamil, Thanks for review. On Thursday, 5 October 2023 23:28:44 CEST Kamil Konieczny wrote: > Hi Janusz, > > On 2023-10-03 at 11:10:53 +0200, Janusz Krzysztofik wrote: > > Recent improvements to the kernel kunit framework allow us to obtain a > > list of test cases pro

[Intel-gfx] [PATCH v3] x86/mm: Fix PAT bit missing from page protection modify mask

2023-06-09 Thread Janusz Krzysztofik
/7648 Fixes: 281d4078bec3 ("x86: Make page cache mode a real type") Signed-off-by: Janusz Krzysztofik Tested-by: Marek Marczykowski-Górecki Reviewed-by: Andi Shyti Acked-by: Juergen Gross # v1 Cc: Borislav Petkov Cc: Dave Hansen Cc: "Edgecombe, Rick P" Cc: sta...@vger.kernel.or

[Intel-gfx] [PATCH] drm/i915: Fix premature release of request's reusable memory

2023-07-04 Thread Janusz Krzysztofik
previous active i915 requests from being released while still accessing their memory. Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/8211 Fixes: b1e3177bd1d8 ("drm/i915: Coordinate i915_active with its own mutex") Signed-off-by: Janusz Krzysztofik Cc: # v5.5+ --- drivers/g

[Intel-gfx] [PATCH v3 RESEND] x86/mm: Fix PAT bit missing from page protection modify mask

2023-07-10 Thread Janusz Krzysztofik
/7648 Fixes: 281d4078bec3 ("x86: Make page cache mode a real type") Signed-off-by: Janusz Krzysztofik Tested-by: Marek Marczykowski-Górecki Reviewed-by: Andi Shyti Reviewed-by: Juergen Gross Cc: Borislav Petkov Cc: Dave Hansen Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "E

Re: [Intel-gfx] [PATCH v3 RESEND] x86/mm: Fix PAT bit missing from page protection modify mask

2023-07-17 Thread Janusz Krzysztofik
Hi Borislav, On Monday, 10 July 2023 10:05:19 CEST Borislav Petkov wrote: > On Mon, Jul 10, 2023 at 09:36:14AM +0200, Janusz Krzysztofik wrote: > > Assume that adding _PAGE_PAT to _PAGE_CHG_MASK doesn't break pte_modify() > > and its users, and go for it. Also, add _PAGE_PAT_

Re: [Intel-gfx] [PATCH v3 RESEND] x86/mm: Fix PAT bit missing from page protection modify mask

2023-07-17 Thread Janusz Krzysztofik
Hi Rick, On Monday, 10 July 2023 19:58:07 CEST Edgecombe, Rick P wrote: > On Mon, 2023-07-10 at 09:36 +0200, Janusz Krzysztofik wrote: > > The issue needs to be fixed by including _PAGE_PAT bit into a bitmask > > used > > by pgprot_modify() for selecting bits to be preserved

[Intel-gfx] [PATCH v2] drm/i915: Fix premature release of request's reusable memory

2023-07-17 Thread Janusz Krzysztofik
f85d8582e ("drm/i915: Serialise i915_active_fence_set() with itself") Suggested-by: Chris Wilson Signed-off-by: Janusz Krzysztofik Cc: # v5.6+ --- drivers/gpu/drm/i915/i915_active.c | 99 - drivers/gpu/drm/i915/i915_request.c | 11 2 files changed, 81 insertions(+), 29 d

[Intel-gfx] [PATCH v3] drm/i915: Fix premature release of request's reusable memory

2023-07-20 Thread Janusz Krzysztofik
ts release to call_rcu() (Chris) Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/8211 Fixes: df9f85d8582e ("drm/i915: Serialise i915_active_fence_set() with itself") Suggested-by: Chris Wilson Signed-off-by: Janusz Krzysztofik Cc: # v5.6+ ---

Re: [Intel-gfx] [igt-dev] [PATCH i-g-t 0/2] tests/i915/perf: Add stress / race exercises

2023-02-03 Thread Janusz Krzysztofik
Hi Umesh, Thanks for taking a look. On Friday, 3 February 2023 20:21:38 CET Umesh Nerlige Ramappa wrote: > On Tue, Jan 31, 2023 at 10:17:29AM +0100, Janusz Krzysztofik wrote: > >Users reported oopses on list corruptions when using i915 perf with a > >number of concurrently r

<    1   2   3   4   5   6   7   8   9   >