lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon,  4 Apr 2022 15:19:46 +0900
From:   Masahiro Yamada <masahiroy@...nel.org>
To:     Arnd Bergmann <arnd@...db.de>, linux-kernel@...r.kernel.org
Cc:     linux-kbuild@...r.kernel.org, linux-arch@...r.kernel.org,
        Masahiro Yamada <masahiroy@...nel.org>
Subject: [PATCH 6/8] sparc: add asm/stat.h to UAPI compile-test coverage

asm/stat.h is currently excluded from the UAPI compile-test for
ARCH=sparc because of the errors like follows:

  In file included from <command-line>:
  ./usr/include/asm/stat.h:11:2: error: unknown type name 'ino_t'
     11 |  ino_t   st_ino;
        |  ^~~~~
    HDRTEST usr/include/asm/param.h
  ./usr/include/asm/stat.h:12:2: error: unknown type name 'mode_t'
     12 |  mode_t  st_mode;
        |  ^~~~~~
  ./usr/include/asm/stat.h:14:2: error: unknown type name 'uid_t'
     14 |  uid_t   st_uid;
        |  ^~~~~
  ./usr/include/asm/stat.h:15:2: error: unknown type name 'gid_t'
     15 |  gid_t   st_gid;
        |  ^~~~~

The errors can be fixed by prefixing the types with __kernel_.

Then, remove the no-header-test entry from user/include/Makefile.

Signed-off-by: Masahiro Yamada <masahiroy@...nel.org>
---

 arch/sparc/include/uapi/asm/stat.h | 12 ++++++------
 usr/include/Makefile               |  1 -
 2 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/arch/sparc/include/uapi/asm/stat.h b/arch/sparc/include/uapi/asm/stat.h
index 732c41720e24..e03d6f8ec301 100644
--- a/arch/sparc/include/uapi/asm/stat.h
+++ b/arch/sparc/include/uapi/asm/stat.h
@@ -8,11 +8,11 @@
 /* 64 bit sparc */
 struct stat {
 	unsigned int st_dev;
-	ino_t   st_ino;
-	mode_t  st_mode;
+	__kernel_ino_t st_ino;
+	__kernel_mode_t st_mode;
 	short   st_nlink;
-	uid_t   st_uid;
-	gid_t   st_gid;
+	__kernel_uid_t st_uid;
+	__kernel_gid_t st_gid;
 	unsigned int st_rdev;
 	long    st_size;
 	long    st_atime;
@@ -51,8 +51,8 @@ struct stat64 {
 /* 32 bit sparc */
 struct stat {
 	unsigned short	st_dev;
-	ino_t		st_ino;
-	mode_t		st_mode;
+	__kernel_ino_t	st_ino;
+	__kernel_mode_t	st_mode;
 	short		st_nlink;
 	unsigned short	st_uid;
 	unsigned short	st_gid;
diff --git a/usr/include/Makefile b/usr/include/Makefile
index 9d9dea32e3a0..e2615b9b0402 100644
--- a/usr/include/Makefile
+++ b/usr/include/Makefile
@@ -70,7 +70,6 @@ no-header-test += linux/bpf_perf_event.h
 endif
 
 ifeq ($(SRCARCH),sparc)
-no-header-test += asm/stat.h
 no-header-test += asm/uctx.h
 no-header-test += asm/fbio.h
 endif
-- 
2.32.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ