diff mbox series

[-fixes] riscv: kselftests: Fix mm build by removing testcases subdirectory

Message ID 20230915100113.13131-1-alexghiti@rivosinc.com (mailing list archive)
State Accepted
Commit b06fab003ae181c6690fe6d1f806636f816f4e50
Headers show
Series [-fixes] riscv: kselftests: Fix mm build by removing testcases subdirectory | expand

Checks

Context Check Description
conchuod/cover_letter success Single patches do not need cover letters
conchuod/tree_selection success Guessed tree name to be for-next at HEAD 0bb80ecc33a8
conchuod/fixes_present success Fixes tag not required for -next series
conchuod/maintainers_pattern success MAINTAINERS pattern errors before the patch: 5 and now 5
conchuod/verify_signedoff success Signed-off-by tag matches author and committer
conchuod/kdoc success Errors and warnings before: 0 this patch: 0
conchuod/build_rv64_clang_allmodconfig success Errors and warnings before: 12 this patch: 12
conchuod/module_param success Was 0 now: 0
conchuod/build_rv64_gcc_allmodconfig success Errors and warnings before: 13 this patch: 13
conchuod/build_rv32_defconfig success Build OK
conchuod/dtb_warn_rv64 success Errors and warnings before: 25 this patch: 25
conchuod/header_inline success No static functions without inline keyword in header files
conchuod/checkpatch warning WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
conchuod/build_rv64_nommu_k210_defconfig success Build OK
conchuod/verify_fixes success No Fixes tag
conchuod/build_rv64_nommu_virt_defconfig success Build OK

Commit Message

Alexandre Ghiti Sept. 15, 2023, 10:01 a.m. UTC
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>
---
 tools/testing/selftests/riscv/mm/Makefile                   | 6 +++---
 .../selftests/riscv/mm/{testcases => }/mmap_bottomup.c      | 2 +-
 .../selftests/riscv/mm/{testcases => }/mmap_default.c       | 2 +-
 .../testing/selftests/riscv/mm/{testcases => }/mmap_test.h  | 0
 .../testing/selftests/riscv/mm/{testcases => }/run_mmap.sh  | 0
 5 files changed, 5 insertions(+), 5 deletions(-)
 rename tools/testing/selftests/riscv/mm/{testcases => }/mmap_bottomup.c (97%)
 rename tools/testing/selftests/riscv/mm/{testcases => }/mmap_default.c (97%)
 rename tools/testing/selftests/riscv/mm/{testcases => }/mmap_test.h (100%)
 rename tools/testing/selftests/riscv/mm/{testcases => }/run_mmap.sh (100%)

Comments

Charlie Jenkins Sept. 15, 2023, 3:23 p.m. UTC | #1
On Fri, Sep 15, 2023 at 12:01:13PM +0200, Alexandre Ghiti wrote:
> 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>
> ---
>  tools/testing/selftests/riscv/mm/Makefile                   | 6 +++---
>  .../selftests/riscv/mm/{testcases => }/mmap_bottomup.c      | 2 +-
>  .../selftests/riscv/mm/{testcases => }/mmap_default.c       | 2 +-
>  .../testing/selftests/riscv/mm/{testcases => }/mmap_test.h  | 0
>  .../testing/selftests/riscv/mm/{testcases => }/run_mmap.sh  | 0
>  5 files changed, 5 insertions(+), 5 deletions(-)
>  rename tools/testing/selftests/riscv/mm/{testcases => }/mmap_bottomup.c (97%)
>  rename tools/testing/selftests/riscv/mm/{testcases => }/mmap_default.c (97%)
>  rename tools/testing/selftests/riscv/mm/{testcases => }/mmap_test.h (100%)
>  rename tools/testing/selftests/riscv/mm/{testcases => }/run_mmap.sh (100%)
> 
> diff --git a/tools/testing/selftests/riscv/mm/Makefile b/tools/testing/selftests/riscv/mm/Makefile
> index 11e0f0568923..c333263f2b27 100644
> --- a/tools/testing/selftests/riscv/mm/Makefile
> +++ b/tools/testing/selftests/riscv/mm/Makefile
> @@ -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) $^
> diff --git a/tools/testing/selftests/riscv/mm/testcases/mmap_bottomup.c b/tools/testing/selftests/riscv/mm/mmap_bottomup.c
> similarity index 97%
> rename from tools/testing/selftests/riscv/mm/testcases/mmap_bottomup.c
> rename to tools/testing/selftests/riscv/mm/mmap_bottomup.c
> index b29379f7e478..1757d19ca89b 100644
> --- a/tools/testing/selftests/riscv/mm/testcases/mmap_bottomup.c
> +++ b/tools/testing/selftests/riscv/mm/mmap_bottomup.c
> @@ -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"
>  
> diff --git a/tools/testing/selftests/riscv/mm/testcases/mmap_default.c b/tools/testing/selftests/riscv/mm/mmap_default.c
> similarity index 97%
> rename from tools/testing/selftests/riscv/mm/testcases/mmap_default.c
> rename to tools/testing/selftests/riscv/mm/mmap_default.c
> index d1accb91b726..c63c60b9397e 100644
> --- a/tools/testing/selftests/riscv/mm/testcases/mmap_default.c
> +++ b/tools/testing/selftests/riscv/mm/mmap_default.c
> @@ -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"
>  
> diff --git a/tools/testing/selftests/riscv/mm/testcases/mmap_test.h b/tools/testing/selftests/riscv/mm/mmap_test.h
> similarity index 100%
> rename from tools/testing/selftests/riscv/mm/testcases/mmap_test.h
> rename to tools/testing/selftests/riscv/mm/mmap_test.h
> diff --git a/tools/testing/selftests/riscv/mm/testcases/run_mmap.sh b/tools/testing/selftests/riscv/mm/run_mmap.sh
> similarity index 100%
> rename from tools/testing/selftests/riscv/mm/testcases/run_mmap.sh
> rename to tools/testing/selftests/riscv/mm/run_mmap.sh
> -- 
> 2.39.2
> 
Fixes the problem.

Reviewed-by: Charlie Jenkins <charlie@rivosinc.com>

- Charlie
patchwork-bot+linux-riscv@kernel.org Sept. 20, 2023, 1:30 p.m. UTC | #2
Hello:

This patch was applied to riscv/linux.git (fixes)
by Palmer Dabbelt <palmer@rivosinc.com>:

On Fri, 15 Sep 2023 12:01:13 +0200 you wrote:
> 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>
> 
> [...]

Here is the summary with links:
  - [-fixes] riscv: kselftests: Fix mm build by removing testcases subdirectory
    https://git.kernel.org/riscv/c/b06fab003ae1

You are awesome, thank you!
diff mbox series

Patch

diff --git a/tools/testing/selftests/riscv/mm/Makefile b/tools/testing/selftests/riscv/mm/Makefile
index 11e0f0568923..c333263f2b27 100644
--- a/tools/testing/selftests/riscv/mm/Makefile
+++ b/tools/testing/selftests/riscv/mm/Makefile
@@ -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) $^
diff --git a/tools/testing/selftests/riscv/mm/testcases/mmap_bottomup.c b/tools/testing/selftests/riscv/mm/mmap_bottomup.c
similarity index 97%
rename from tools/testing/selftests/riscv/mm/testcases/mmap_bottomup.c
rename to tools/testing/selftests/riscv/mm/mmap_bottomup.c
index b29379f7e478..1757d19ca89b 100644
--- a/tools/testing/selftests/riscv/mm/testcases/mmap_bottomup.c
+++ b/tools/testing/selftests/riscv/mm/mmap_bottomup.c
@@ -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"
 
diff --git a/tools/testing/selftests/riscv/mm/testcases/mmap_default.c b/tools/testing/selftests/riscv/mm/mmap_default.c
similarity index 97%
rename from tools/testing/selftests/riscv/mm/testcases/mmap_default.c
rename to tools/testing/selftests/riscv/mm/mmap_default.c
index d1accb91b726..c63c60b9397e 100644
--- a/tools/testing/selftests/riscv/mm/testcases/mmap_default.c
+++ b/tools/testing/selftests/riscv/mm/mmap_default.c
@@ -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"
 
diff --git a/tools/testing/selftests/riscv/mm/testcases/mmap_test.h b/tools/testing/selftests/riscv/mm/mmap_test.h
similarity index 100%
rename from tools/testing/selftests/riscv/mm/testcases/mmap_test.h
rename to tools/testing/selftests/riscv/mm/mmap_test.h
diff --git a/tools/testing/selftests/riscv/mm/testcases/run_mmap.sh b/tools/testing/selftests/riscv/mm/run_mmap.sh
similarity index 100%
rename from tools/testing/selftests/riscv/mm/testcases/run_mmap.sh
rename to tools/testing/selftests/riscv/mm/run_mmap.sh