Re: [PATCH] checksyscalls: ignore -Wunused-macros

From: Masahiro Yamada
Date: Fri Apr 29 2022 - 13:03:53 EST


On Sat, Apr 23, 2022 at 12:18 AM Vincent Mailhol
<mailhol.vincent@xxxxxxxxxx> wrote:
>
> The macros defined in this file are for testing only and are purposely
> not used. When compiled with W=2, both gcc and clang yield some
> -Wunused-macros warnings. Ignore them.
>
> Signed-off-by: Vincent Mailhol <mailhol.vincent@xxxxxxxxxx>
> ---

Applied to linux-kbuild (only the second hunk)
Thanks.

The current check is not nice,
but this does not hurt.



> scripts/checksyscalls.sh | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/scripts/checksyscalls.sh b/scripts/checksyscalls.sh
> index 9dbab13329fa..cde15f22ec98 100755
> --- a/scripts/checksyscalls.sh
> +++ b/scripts/checksyscalls.sh
> @@ -255,6 +255,7 @@ cat << EOF
> /* 64-bit ports never needed these, and new 32-bit ports can use statx */
> #define __IGNORE_fstat64
> #define __IGNORE_fstatat64
> +
> EOF
> }

Noise.
I dropped it.



>
> @@ -268,4 +269,4 @@ syscall_list() {
> }
>
> (ignore_list && syscall_list $(dirname $0)/../arch/x86/entry/syscalls/syscall_32.tbl) | \
> -$* -Wno-error -E -x c - > /dev/null
> +$* -Wno-error -Wno-unused-macros -E -x c - > /dev/null
> --
> 2.35.1
>


--
Best Regards
Masahiro Yamada