xref: /openbmc/linux/arch/arm64/include/asm/stat.h (revision 6c33a6f4)
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3  * Copyright (C) 2012 ARM Ltd.
4  */
5 #ifndef __ASM_STAT_H
6 #define __ASM_STAT_H
7 
8 #include <uapi/asm/stat.h>
9 
10 #ifdef CONFIG_COMPAT
11 
12 #include <linux/time.h>
13 #include <asm/compat.h>
14 
15 /*
16  * struct stat64 is needed for compat tasks only. Its definition is different
17  * from the generic struct stat64.
18  */
19 struct stat64 {
20 	compat_u64	st_dev;
21 	unsigned char   __pad0[4];
22 
23 #define STAT64_HAS_BROKEN_ST_INO	1
24 	compat_ulong_t	__st_ino;
25 	compat_uint_t	st_mode;
26 	compat_uint_t	st_nlink;
27 
28 	compat_ulong_t	st_uid;
29 	compat_ulong_t	st_gid;
30 
31 	compat_u64	st_rdev;
32 	unsigned char   __pad3[4];
33 
34 	compat_s64	st_size;
35 	compat_ulong_t	st_blksize;
36 	compat_u64	st_blocks;	/* Number of 512-byte blocks allocated. */
37 
38 	compat_ulong_t	st_atime;
39 	compat_ulong_t	st_atime_nsec;
40 
41 	compat_ulong_t	st_mtime;
42 	compat_ulong_t	st_mtime_nsec;
43 
44 	compat_ulong_t	st_ctime;
45 	compat_ulong_t	st_ctime_nsec;
46 
47 	compat_u64	st_ino;
48 };
49 
50 #endif
51 #endif
52