GCC 13.2.0 reported a format string warning:

step_after_suspend_test.c: In function ‘run_test’:
step_after_suspend_test.c:92:32: warning: too many arguments for format 
[-Wformat-extra-args]
   92 |                 ksft_print_msg("waitpid() failed: $s\n", 
strerror(errno));
      |                                ^~~~~~~~~~~~~~~~~~~~~~~~

Fixing the typo $s into %s resolves the issue.

Fixes: 3fa72f2c784b5 ("selftests: breakpoints: step_after_suspend_test use 
ksft_* var arg msg api")
Cc: Shuah Khan <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Mirsad Todorovac <[email protected]>
---
 tools/testing/selftests/breakpoints/step_after_suspend_test.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/testing/selftests/breakpoints/step_after_suspend_test.c 
b/tools/testing/selftests/breakpoints/step_after_suspend_test.c
index 2cf6f10ab7c4..b8703c499d28 100644
--- a/tools/testing/selftests/breakpoints/step_after_suspend_test.c
+++ b/tools/testing/selftests/breakpoints/step_after_suspend_test.c
@@ -89,7 +89,7 @@ int run_test(int cpu)
 
        wpid = waitpid(pid, &status, __WALL);
        if (wpid != pid) {
-               ksft_print_msg("waitpid() failed: $s\n", strerror(errno));
+               ksft_print_msg("waitpid() failed: %s\n", strerror(errno));
                return KSFT_FAIL;
        }
        if (WIFEXITED(status)) {
-- 
2.40.1


Reply via email to