riscv: kselftests: Fix mm build by removing testcases subdirectory
authorAlexandre Ghiti <alexghiti@rivosinc.com>
Fri, 15 Sep 2023 10:01:13 +0000 (12:01 +0200)
committerPalmer Dabbelt <palmer@rivosinc.com>
Wed, 20 Sep 2023 09:29:26 +0000 (02:29 -0700)
kselftests fails to build because the mm/testcases subdirectory is not
created and then the compiler fails to output the binary there.

So fix this by simply removing this subdirectory which is not very
useful.

Signed-off-by: Alexandre Ghiti <alexghiti@rivosinc.com>
Reviewed-by: Charlie Jenkins <charlie@rivosinc.com>
Link: https://lore.kernel.org/r/20230915100113.13131-1-alexghiti@rivosinc.com
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
tools/testing/selftests/riscv/mm/Makefile
tools/testing/selftests/riscv/mm/mmap_bottomup.c [moved from tools/testing/selftests/riscv/mm/testcases/mmap_bottomup.c with 97% similarity]
tools/testing/selftests/riscv/mm/mmap_default.c [moved from tools/testing/selftests/riscv/mm/testcases/mmap_default.c with 97% similarity]
tools/testing/selftests/riscv/mm/mmap_test.h [moved from tools/testing/selftests/riscv/mm/testcases/mmap_test.h with 100% similarity]
tools/testing/selftests/riscv/mm/run_mmap.sh [moved from tools/testing/selftests/riscv/mm/testcases/run_mmap.sh with 100% similarity]

index 11e0f05..c333263 100644 (file)
@@ -5,11 +5,11 @@
 # Additional include paths needed by kselftest.h and local headers
 CFLAGS += -D_GNU_SOURCE -std=gnu99 -I.
 
-TEST_GEN_FILES := testcases/mmap_default testcases/mmap_bottomup
+TEST_GEN_FILES := mmap_default mmap_bottomup
 
-TEST_PROGS := testcases/run_mmap.sh
+TEST_PROGS := run_mmap.sh
 
 include ../../lib.mk
 
-$(OUTPUT)/mm: testcases/mmap_default.c testcases/mmap_bottomup.c testcases/mmap_tests.h
+$(OUTPUT)/mm: mmap_default.c mmap_bottomup.c mmap_tests.h
        $(CC) -o$@ $(CFLAGS) $(LDFLAGS) $^
@@ -1,6 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0-only
 #include <sys/mman.h>
-#include <testcases/mmap_test.h>
+#include <mmap_test.h>
 
 #include "../../kselftest_harness.h"
 
@@ -1,6 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0-only
 #include <sys/mman.h>
-#include <testcases/mmap_test.h>
+#include <mmap_test.h>
 
 #include "../../kselftest_harness.h"