Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

checksyscalls: ignore fstat to silence build warning on LoongArch

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]

Link: https://lkml.kernel.org/r/1678175940-20872-1-git-send-email-yangtiezhu@loongson.cn
Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
Suggested-by: WANG Xuerui <kernel@xen0n.name>
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Cc: Huacai Chen <chenhuacai@kernel.org>
Cc: Masahiro Yamada <masahiroy@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>

authored by

Tiezhu Yang and committed by
Andrew Morton
12871a15 00358700

+3 -1
+3 -1
scripts/checksyscalls.sh
··· 114 114 #define __IGNORE_truncate 115 115 #define __IGNORE_stat 116 116 #define __IGNORE_lstat 117 - #define __IGNORE_fstat 118 117 #define __IGNORE_fcntl 119 118 #define __IGNORE_fadvise64 120 119 #define __IGNORE_newfstatat ··· 254 255 /* 64-bit ports never needed these, and new 32-bit ports can use statx */ 255 256 #define __IGNORE_fstat64 256 257 #define __IGNORE_fstatat64 258 + 259 + /* Newer ports are not required to provide fstat in favor of statx */ 260 + #define __IGNORE_fstat 257 261 EOF 258 262 } 259 263