In the linux-4.19.y kernel kcmp_test and compaction_test kselftest fails to compile.
kcmp_test.c: In function ���main���: kcmp_test.c:92:17: warning: implicit declaration of function ���ksft_set_plan��� [-Wimplicit-function-declaration] 92 | ksft_set_plan(3); | ^~~~~~~~~~~~~ and
compaction_test.c: In function ���main���: compaction_test.c:186:9: warning: implicit declaration of function ���ksft_set_plan��� [-Wimplicit-function-declaration] 186 | ksft_set_plan(1); | ^~~~~~~~~~~~~
The function definition for ksft_set_plan() is introduced by commit 5821ba969511 ("selftests: Add test plan API to kselftest.h and adjust callers") which is present from linux-5.2.y onwards.
Samasth Norway Ananda (2): selftests/vm: remove call to ksft_set_plan() selftests/kcmp: remove call to ksft_set_plan()
tools/testing/selftests/kcmp/kcmp_test.c | 1 - tools/testing/selftests/vm/compaction_test.c | 2 -- 2 files changed, 3 deletions(-)
The function definition for ksft_set_plan() is not present in linux-4.19.y. compaction_test selftest fails to compile because of this.
Fixes: 9a21701edc41 ("selftests/mm: conform test to TAP format output") Signed-off-by: Samasth Norway Ananda samasth.norway.ananda@oracle.com Reviewed-by: Saeed Mirzamohammadi saeed.mirzamohammadi@oracle.com --- tools/testing/selftests/vm/compaction_test.c | 2 -- 1 file changed, 2 deletions(-)
diff --git a/tools/testing/selftests/vm/compaction_test.c b/tools/testing/selftests/vm/compaction_test.c index e056cfc487e08..e7044fa7f0b70 100644 --- a/tools/testing/selftests/vm/compaction_test.c +++ b/tools/testing/selftests/vm/compaction_test.c @@ -183,8 +183,6 @@ int main(int argc, char **argv) if (prereq() != 0) return ksft_exit_pass();
- ksft_set_plan(1); - lim.rlim_cur = RLIM_INFINITY; lim.rlim_max = RLIM_INFINITY; if (setrlimit(RLIMIT_MEMLOCK, &lim))
On 9/13/24 14:02, Samasth Norway Ananda wrote:
The function definition for ksft_set_plan() is not present in linux-4.19.y. compaction_test selftest fails to compile because of this.
Fixes: 9a21701edc41 ("selftests/mm: conform test to TAP format output") Signed-off-by: Samasth Norway Ananda samasth.norway.ananda@oracle.com Reviewed-by: Saeed Mirzamohammadi saeed.mirzamohammadi@oracle.com
tools/testing/selftests/vm/compaction_test.c | 2 -- 1 file changed, 2 deletions(-)
diff --git a/tools/testing/selftests/vm/compaction_test.c b/tools/testing/selftests/vm/compaction_test.c index e056cfc487e08..e7044fa7f0b70 100644 --- a/tools/testing/selftests/vm/compaction_test.c +++ b/tools/testing/selftests/vm/compaction_test.c @@ -183,8 +183,6 @@ int main(int argc, char **argv) if (prereq() != 0) return ksft_exit_pass();
- ksft_set_plan(1);
- lim.rlim_cur = RLIM_INFINITY; lim.rlim_max = RLIM_INFINITY; if (setrlimit(RLIMIT_MEMLOCK, &lim))
Thank for for finding and fixing this.
Acked-by: Shuah Khan skhan@linuxfoundation.org
thanks, -- Shuah
The function definition for ksft_set_plan() is not present in linux-4.19.y. kcmp_test selftest fails to compile because of this.
Fixes: 32b0469d13eb ("selftests/kcmp: Make the test output consistent and clear") Signed-off-by: Samasth Norway Ananda samasth.norway.ananda@oracle.com Reviewed-by: Saeed Mirzamohammadi saeed.mirzamohammadi@oracle.com --- tools/testing/selftests/kcmp/kcmp_test.c | 1 - 1 file changed, 1 deletion(-)
diff --git a/tools/testing/selftests/kcmp/kcmp_test.c b/tools/testing/selftests/kcmp/kcmp_test.c index d7a8e321bb16b..60305f858c48d 100644 --- a/tools/testing/selftests/kcmp/kcmp_test.c +++ b/tools/testing/selftests/kcmp/kcmp_test.c @@ -89,7 +89,6 @@ int main(int argc, char **argv) int ret;
ksft_print_header(); - ksft_set_plan(3);
fd2 = open(kpath, O_RDWR); if (fd2 < 0) {
On 9/13/24 14:02, Samasth Norway Ananda wrote:
The function definition for ksft_set_plan() is not present in linux-4.19.y. kcmp_test selftest fails to compile because of this.
Fixes: 32b0469d13eb ("selftests/kcmp: Make the test output consistent and clear") Signed-off-by: Samasth Norway Ananda samasth.norway.ananda@oracle.com Reviewed-by: Saeed Mirzamohammadi saeed.mirzamohammadi@oracle.com
tools/testing/selftests/kcmp/kcmp_test.c | 1 - 1 file changed, 1 deletion(-)
diff --git a/tools/testing/selftests/kcmp/kcmp_test.c b/tools/testing/selftests/kcmp/kcmp_test.c index d7a8e321bb16b..60305f858c48d 100644 --- a/tools/testing/selftests/kcmp/kcmp_test.c +++ b/tools/testing/selftests/kcmp/kcmp_test.c @@ -89,7 +89,6 @@ int main(int argc, char **argv) int ret; ksft_print_header();
ksft_set_plan(3);
fd2 = open(kpath, O_RDWR); if (fd2 < 0) {
Thank for for finding and fixing this.
Acked-by: Shuah Khan skhan@linuxfoundation.org
thanks, -- Shuah
linux-stable-mirror@lists.linaro.org