/* copied from kernel definition, but with padding replaced * by the corresponding correctly-sized userspace types. */ struct stat { dev_t st_dev; int __st_dev_padding; long __st_ino_truncated; mode_t st_mode; nlink_t st_nlink; uid_t st_uid; gid_t st_gid; dev_t st_rdev; int __st_rdev_padding; off_t st_size; blksize_t st_blksize; blkcnt_t st_blocks; struct { long tv_sec; long tv_nsec; } __st_atim32, __st_mtim32, __st_ctim32; ino_t st_ino; struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; }; struct statx { uint32_t stx_mask; uint32_t stx_blksize; uint64_t stx_attributes; uint32_t stx_nlink; uint32_t stx_uid; uint32_t stx_gid; uint16_t stx_mode; uint16_t pad1; uint64_t stx_ino; uint64_t stx_size; uint64_t stx_blocks; uint64_t stx_attributes_mask; struct { int64_t tv_sec; uint32_t tv_nsec; int32_t pad; } stx_atime, stx_btime, stx_ctime, stx_mtime; uint32_t stx_rdev_major; uint32_t stx_rdev_minor; uint32_t stx_dev_major; uint32_t stx_dev_minor; uint64_t spare[14]; };