mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-04 04:06:26 +00:00
kselftest/arm64: Fix printf() warning in the arm64 MTE prctl() test
While prctl() returns an 'int', the PR_MTE_TCF_MASK is defined as unsigned long which results in the larger type following a bitwise 'and' operation. Cast the printf() argument to 'int'. Cc: Shuah Khan <skhan@linuxfoundation.org> Cc: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20241108134920.1233992-3-catalin.marinas@arm.com Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
This commit is contained in:
parent
b6bd50dd3b
commit
0cc6b94a44
@ -85,7 +85,7 @@ void set_mode_test(const char *name, int hwcap2, int mask)
|
||||
ksft_test_result_pass("%s\n", name);
|
||||
} else {
|
||||
ksft_print_msg("Got %x, expected %x\n",
|
||||
(ret & PR_MTE_TCF_MASK), mask);
|
||||
(ret & (int)PR_MTE_TCF_MASK), mask);
|
||||
ksft_test_result_fail("%s\n", name);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user