[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251109160419.5a16411a@pumpkin>
Date: Sun, 9 Nov 2025 16:04:19 +0000
From: David Laight <david.laight.linux@...il.com>
To: Masaharu Noguchi <nogunix@...il.com>
Cc: jesperjuhl76@...il.com, Jeff Layton <jlayton@...nel.org>, Chuck Lever
<chuck.lever@...cle.com>, Alexander Aring <alex.aring@...il.com>,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] samples: vfs: avoid libc AT_RENAME_* redefinitions
On Sun, 9 Nov 2025 16:13:04 +0900
Masaharu Noguchi <nogunix@...il.com> wrote:
> Signed-off-by: Masaharu Noguchi <nogunix@...il.com>
> ---
> samples/vfs/test-statx.c | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
> diff --git a/samples/vfs/test-statx.c b/samples/vfs/test-statx.c
> index 49c7a46cee07..eabea80e9db8 100644
> --- a/samples/vfs/test-statx.c
> +++ b/samples/vfs/test-statx.c
> @@ -20,6 +20,15 @@
> #include <sys/syscall.h>
> #include <sys/types.h>
> #include <linux/stat.h>
> +#ifdef AT_RENAME_NOREPLACE
> +#undef AT_RENAME_NOREPLACE
> +#endif
> +#ifdef AT_RENAME_EXCHANGE
> +#undef AT_RENAME_EXCHANGE
> +#endif
> +#ifdef AT_RENAME_WHITEOUT
> +#undef AT_RENAME_WHITEOUT
> +#endif
There is no need for the #if, just #undef the symbols.
It is probably worthy of a short comment.
David
> #include <linux/fcntl.h>
> #define statx foo
> #define statx_timestamp foo_timestamp
Powered by blists - more mailing lists