linux-kbuild.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 RESEND] checksyscalls: Ignore fstat to silence build warning on LoongArch
@ 2023-03-07  7:59 Tiezhu Yang
  2023-03-07  8:15 ` Arnd Bergmann
  0 siblings, 1 reply; 2+ messages in thread
From: Tiezhu Yang @ 2023-03-07  7:59 UTC (permalink / raw)
  To: Huacai Chen, WANG Xuerui, Arnd Bergmann, Andrew Morton, Masahiro Yamada
  Cc: linux-kbuild, loongarch, linux-kernel, loongson-kernel

fstat is replaced by statx on the new architecture, so an exception
is added to the checksyscalls script to silence the following build
warning on LoongArch:

  CALL    scripts/checksyscalls.sh
<stdin>:569:2: warning: #warning syscall fstat not implemented [-Wcpp]

Suggested-by: WANG Xuerui <kernel@xen0n.name>
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
---

This warning still exists when build 6.3-rc1, it looks like
not so good, just resend the patch (2022-08-30):

https://lore.kernel.org/lkml/1661830021-8643-1-git-send-email-yangtiezhu@loongson.cn/

 scripts/checksyscalls.sh | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/scripts/checksyscalls.sh b/scripts/checksyscalls.sh
index f33e61a..1e5d2ee 100755
--- a/scripts/checksyscalls.sh
+++ b/scripts/checksyscalls.sh
@@ -114,7 +114,6 @@ cat << EOF
 #define __IGNORE_truncate
 #define __IGNORE_stat
 #define __IGNORE_lstat
-#define __IGNORE_fstat
 #define __IGNORE_fcntl
 #define __IGNORE_fadvise64
 #define __IGNORE_newfstatat
@@ -255,6 +254,9 @@ cat << EOF
 /* 64-bit ports never needed these, and new 32-bit ports can use statx */
 #define __IGNORE_fstat64
 #define __IGNORE_fstatat64
+
+/* Newer ports are not required to provide fstat in favor of statx */
+#define __IGNORE_fstat
 EOF
 }
 
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v3 RESEND] checksyscalls: Ignore fstat to silence build warning on LoongArch
  2023-03-07  7:59 [PATCH v3 RESEND] checksyscalls: Ignore fstat to silence build warning on LoongArch Tiezhu Yang
@ 2023-03-07  8:15 ` Arnd Bergmann
  0 siblings, 0 replies; 2+ messages in thread
From: Arnd Bergmann @ 2023-03-07  8:15 UTC (permalink / raw)
  To: Tiezhu Yang, Huacai Chen, WANG Xuerui, Andrew Morton, Masahiro Yamada
  Cc: linux-kbuild, loongarch, linux-kernel, loongson-kernel

On Tue, Mar 7, 2023, at 08:59, Tiezhu Yang wrote:
> fstat is replaced by statx on the new architecture, so an exception
> is added to the checksyscalls script to silence the following build
> warning on LoongArch:
>
>   CALL    scripts/checksyscalls.sh
> <stdin>:569:2: warning: #warning syscall fstat not implemented [-Wcpp]
>
> Suggested-by: WANG Xuerui <kernel@xen0n.name>
> Suggested-by: Arnd Bergmann <arnd@arndb.de>
> Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>

Reviewed-by: Arnd Bergmann <arnd@arndb.de>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-03-07  8:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-07  7:59 [PATCH v3 RESEND] checksyscalls: Ignore fstat to silence build warning on LoongArch Tiezhu Yang
2023-03-07  8:15 ` Arnd Bergmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).