From: Abdalla Eldoumani <[email protected]>

vec-syscfg ends with ksft_exit_pass() whatever its tests reported, so it
exits 0 even when tests fail. The kselftest runner decides whether a
program passed from its exit status, so failures in vec-syscfg are only
visible in its TAP output and the run as a whole is reported as passing.

Use ksft_finished() so the exit status reflects the results. Unsupported
vector types are reported as skips, which ksft_finished() treats as
passing, so systems without SVE or SME are unaffected.

Fixes: 95cf3f23877b ("kselftest/arm64: Add tests for SVE vector configuration")
Assisted-by: LLM
Signed-off-by: Abdalla Eldoumani <[email protected]>
---
 tools/testing/selftests/arm64/fp/vec-syscfg.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/testing/selftests/arm64/fp/vec-syscfg.c 
b/tools/testing/selftests/arm64/fp/vec-syscfg.c
index 8dd932f..2c8ccbe 100644
--- a/tools/testing/selftests/arm64/fp/vec-syscfg.c
+++ b/tools/testing/selftests/arm64/fp/vec-syscfg.c
@@ -792,5 +792,5 @@ int main(void)
                        ksft_test_result_skip("%s\n", all_types_tests[i].name);
        }
 
-       ksft_exit_pass();
+       ksft_finished();
 }
-- 
2.49.0.windows.1


Reply via email to