|
|
076f82 |
commit b87b697f15d6bf7e576a2eeadc1f740172f9d013
|
|
|
076f82 |
Author: =Joshua Kinard <kumba@gentoo.org>
|
|
|
076f82 |
Date: Mon Apr 18 09:55:08 2022 -0300
|
|
|
076f82 |
|
|
|
076f82 |
mips: Fix mips64n32 64 bit time_t stat support (BZ#29069)
|
|
|
076f82 |
|
|
|
076f82 |
Add missing support initially added by 4e8521333bea6e89fcef1020
|
|
|
076f82 |
(which missed n32 stat).
|
|
|
076f82 |
|
|
|
076f82 |
(cherry picked from commit 78fb88827362fbd2cc8aa32892ae5b015106e25c)
|
|
|
076f82 |
|
|
|
076f82 |
diff --git a/sysdeps/unix/sysv/linux/mips/bits/struct_stat.h b/sysdeps/unix/sysv/linux/mips/bits/struct_stat.h
|
|
|
076f82 |
index ab9f474cbc271b7c..ed5b1bc00ba52406 100644
|
|
|
076f82 |
--- a/sysdeps/unix/sysv/linux/mips/bits/struct_stat.h
|
|
|
076f82 |
+++ b/sysdeps/unix/sysv/linux/mips/bits/struct_stat.h
|
|
|
076f82 |
@@ -131,27 +131,30 @@ struct stat64
|
|
|
076f82 |
|
|
|
076f82 |
struct stat
|
|
|
076f82 |
{
|
|
|
076f82 |
+# ifdef __USE_TIME_BITS64
|
|
|
076f82 |
+# include <bits/struct_stat_time64_helper.h>
|
|
|
076f82 |
+# else
|
|
|
076f82 |
__dev_t st_dev;
|
|
|
076f82 |
int st_pad1[3]; /* Reserved for st_dev expansion */
|
|
|
076f82 |
-# ifndef __USE_FILE_OFFSET64
|
|
|
076f82 |
+# ifndef __USE_FILE_OFFSET64
|
|
|
076f82 |
__ino_t st_ino;
|
|
|
076f82 |
-# else
|
|
|
076f82 |
+# else
|
|
|
076f82 |
__ino64_t st_ino;
|
|
|
076f82 |
-# endif
|
|
|
076f82 |
+# endif
|
|
|
076f82 |
__mode_t st_mode;
|
|
|
076f82 |
__nlink_t st_nlink;
|
|
|
076f82 |
__uid_t st_uid;
|
|
|
076f82 |
__gid_t st_gid;
|
|
|
076f82 |
__dev_t st_rdev;
|
|
|
076f82 |
-# if !defined __USE_FILE_OFFSET64
|
|
|
076f82 |
+# if !defined __USE_FILE_OFFSET64
|
|
|
076f82 |
unsigned int st_pad2[2]; /* Reserved for st_rdev expansion */
|
|
|
076f82 |
__off_t st_size;
|
|
|
076f82 |
int st_pad3;
|
|
|
076f82 |
-# else
|
|
|
076f82 |
+# else
|
|
|
076f82 |
unsigned int st_pad2[3]; /* Reserved for st_rdev expansion */
|
|
|
076f82 |
__off64_t st_size;
|
|
|
076f82 |
-# endif
|
|
|
076f82 |
-# ifdef __USE_XOPEN2K8
|
|
|
076f82 |
+# endif
|
|
|
076f82 |
+# ifdef __USE_XOPEN2K8
|
|
|
076f82 |
/* Nanosecond resolution timestamps are stored in a format
|
|
|
076f82 |
equivalent to 'struct timespec'. This is the type used
|
|
|
076f82 |
whenever possible but the Unix namespace rules do not allow the
|
|
|
076f82 |
@@ -161,30 +164,34 @@ struct stat
|
|
|
076f82 |
struct timespec st_atim; /* Time of last access. */
|
|
|
076f82 |
struct timespec st_mtim; /* Time of last modification. */
|
|
|
076f82 |
struct timespec st_ctim; /* Time of last status change. */
|
|
|
076f82 |
-# define st_atime st_atim.tv_sec /* Backward compatibility. */
|
|
|
076f82 |
-# define st_mtime st_mtim.tv_sec
|
|
|
076f82 |
-# define st_ctime st_ctim.tv_sec
|
|
|
076f82 |
-# else
|
|
|
076f82 |
+# define st_atime st_atim.tv_sec /* Backward compatibility. */
|
|
|
076f82 |
+# define st_mtime st_mtim.tv_sec
|
|
|
076f82 |
+# define st_ctime st_ctim.tv_sec
|
|
|
076f82 |
+# else
|
|
|
076f82 |
__time_t st_atime; /* Time of last access. */
|
|
|
076f82 |
unsigned long int st_atimensec; /* Nscecs of last access. */
|
|
|
076f82 |
__time_t st_mtime; /* Time of last modification. */
|
|
|
076f82 |
unsigned long int st_mtimensec; /* Nsecs of last modification. */
|
|
|
076f82 |
__time_t st_ctime; /* Time of last status change. */
|
|
|
076f82 |
unsigned long int st_ctimensec; /* Nsecs of last status change. */
|
|
|
076f82 |
-# endif
|
|
|
076f82 |
+# endif
|
|
|
076f82 |
__blksize_t st_blksize;
|
|
|
076f82 |
unsigned int st_pad4;
|
|
|
076f82 |
-# ifndef __USE_FILE_OFFSET64
|
|
|
076f82 |
+# ifndef __USE_FILE_OFFSET64
|
|
|
076f82 |
__blkcnt_t st_blocks;
|
|
|
076f82 |
-# else
|
|
|
076f82 |
+# else
|
|
|
076f82 |
__blkcnt64_t st_blocks;
|
|
|
076f82 |
-# endif
|
|
|
076f82 |
+# endif
|
|
|
076f82 |
int st_pad5[14];
|
|
|
076f82 |
+# endif
|
|
|
076f82 |
};
|
|
|
076f82 |
|
|
|
076f82 |
#ifdef __USE_LARGEFILE64
|
|
|
076f82 |
struct stat64
|
|
|
076f82 |
{
|
|
|
076f82 |
+# ifdef __USE_TIME_BITS64
|
|
|
076f82 |
+# include <bits/struct_stat_time64_helper.h>
|
|
|
076f82 |
+# else
|
|
|
076f82 |
__dev_t st_dev;
|
|
|
076f82 |
unsigned int st_pad1[3]; /* Reserved for st_dev expansion */
|
|
|
076f82 |
__ino64_t st_ino;
|
|
|
076f82 |
@@ -217,6 +224,7 @@ struct stat64
|
|
|
076f82 |
unsigned int st_pad3;
|
|
|
076f82 |
__blkcnt64_t st_blocks;
|
|
|
076f82 |
int st_pad4[14];
|
|
|
076f82 |
+# endif /* __USE_TIME_BITS64 */
|
|
|
076f82 |
};
|
|
|
076f82 |
#endif
|
|
|
076f82 |
|