This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch master updated. glibc-2.24-395-g510abe7


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  510abe7b945ddab6f4497e7c097cff677286bb4d (commit)
      from  65a77b558513ab54018b237f6570d27d12b6ee97 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=510abe7b945ddab6f4497e7c097cff677286bb4d

commit 510abe7b945ddab6f4497e7c097cff677286bb4d
Author: Steve Ellcey <sellcey@caviumnetworks.com>
Date:   Tue Nov 22 09:59:12 2016 -0800

    Allow [f]statfs64 to alias [f]statfs
    
    	* sysdeps/unix/sysv/linux/fstatfs64.c: Hide prototypes for fstatfs
    	and __fstatfs.  Make them aliases of __fstatfs64 if
    	STATFS_IS_STATFS64 is set to non-zero.
    	* sysdeps/unix/sysv/linux/statfs64.c: Ditto for __statfs, statfs,
    	and __statfs64.
    	* sysdeps/unix/sysv/linux/generic/wordsize-32/fstatfs.c: Do not
    	define __fstatfs and fstatfs if STATFS_IS_STATFS64 is non-zero.
    	* sysdeps/unix/sysv/linux/generic/wordsize-32/statfs.c: Ditto
    	for __statfs and statfs.
    	* sysdeps/unix/sysv/linux/alpha/kernel_stat.h: Set STATFS_IS_STATFS64
    	to 0.
    	* sysdeps/unix/sysv/linux/generic/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/hppa/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/ia64/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/microblaze/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/mips/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/powerpc/powerpc32/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/powerpc/powerpc64/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/s390/s390-64/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/sparc/sparc32/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/sparc/sparc64/kernel_stat.h: Ditto.
    	* sysdeps/unix/sysv/linux/x86_64/kernel_stat.h: Ditto.

diff --git a/ChangeLog b/ChangeLog
index 6053109..a475194 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,29 @@
+2016-11-22  Steve Ellcey  <sellcey@caviumnetworks.com>
+
+	* sysdeps/unix/sysv/linux/fstatfs64.c: Hide prototypes for fstatfs
+	and __fstatfs.  Make them aliases of __fstatfs64 if
+	STATFS_IS_STATFS64 is set to non-zero.
+	* sysdeps/unix/sysv/linux/statfs64.c: Ditto for __statfs, statfs,
+	and __statfs64.
+	* sysdeps/unix/sysv/linux/generic/wordsize-32/fstatfs.c: Do not
+	define __fstatfs and fstatfs if STATFS_IS_STATFS64 is non-zero.
+	* sysdeps/unix/sysv/linux/generic/wordsize-32/statfs.c: Ditto
+	for __statfs and statfs.
+	* sysdeps/unix/sysv/linux/alpha/kernel_stat.h: Set STATFS_IS_STATFS64
+	to 0.
+	* sysdeps/unix/sysv/linux/generic/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/hppa/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/ia64/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/microblaze/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/mips/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/powerpc/powerpc32/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/powerpc/powerpc64/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/s390/s390-64/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/sparc/sparc32/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/sparc/sparc64/kernel_stat.h: Ditto.
+	* sysdeps/unix/sysv/linux/x86_64/kernel_stat.h: Ditto.
+
 2016-11-22  Andreas Schwab  <schwab@suse.de>
 
 	* misc/mkstemp.c: Include <fcntl.h>.
diff --git a/sysdeps/unix/sysv/linux/alpha/kernel_stat.h b/sysdeps/unix/sysv/linux/alpha/kernel_stat.h
index 6708411..d637e09 100644
--- a/sysdeps/unix/sysv/linux/alpha/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/alpha/kernel_stat.h
@@ -86,3 +86,4 @@ struct glibc21_stat
   };
 
 #define XSTAT_IS_XSTAT64 1
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/fstatfs64.c b/sysdeps/unix/sysv/linux/fstatfs64.c
index a624de6..a95fe18 100644
--- a/sysdeps/unix/sysv/linux/fstatfs64.c
+++ b/sysdeps/unix/sysv/linux/fstatfs64.c
@@ -16,9 +16,18 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+/* Hide the prototypes for __fstatfs and fstatfs so that GCC will not
+   complain about the different function signatures if they are aliased
+   to  __fstat64.  If STATFS_IS_STATFS64 is not zero then the statfs and
+   statfs64 structures have an identical layout but different type names.  */
+
+#define __fstatfs __fstatfs_disable
+#define fstatfs fstatfs_disable
+
 #include <errno.h>
 #include <string.h>
 #include <sys/statfs.h>
+#include <kernel_stat.h>
 #include <stddef.h>
 #include <sysdep.h>
 #include <kernel-features.h>
@@ -70,3 +79,11 @@ __fstatfs64 (int fd, struct statfs64 *buf)
 #endif
 }
 weak_alias (__fstatfs64, fstatfs64)
+
+#undef __fstatfs
+#undef fstatfs
+
+#if STATFS_IS_STATFS64
+weak_alias (__fstatfs64, __fstatfs)
+weak_alias (__fstatfs64, fstatfs)
+#endif
diff --git a/sysdeps/unix/sysv/linux/generic/kernel_stat.h b/sysdeps/unix/sysv/linux/generic/kernel_stat.h
index 5d5f04b..ee9ff03 100644
--- a/sysdeps/unix/sysv/linux/generic/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/generic/kernel_stat.h
@@ -26,3 +26,5 @@
 #else
 # define XSTAT_IS_XSTAT64 0
 #endif
+
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/generic/wordsize-32/fstatfs.c b/sysdeps/unix/sysv/linux/generic/wordsize-32/fstatfs.c
index be9599a..c199938 100644
--- a/sysdeps/unix/sysv/linux/generic/wordsize-32/fstatfs.c
+++ b/sysdeps/unix/sysv/linux/generic/wordsize-32/fstatfs.c
@@ -18,8 +18,10 @@
 
 #include <errno.h>
 #include <sys/statfs.h>
+#include <kernel_stat.h>
 #include <stddef.h>
 
+#if !STATFS_IS_STATFS64
 #include "overflow.h"
 
 /* Return information about the filesystem on which FD resides.  */
@@ -30,3 +32,4 @@ __fstatfs (int fd, struct statfs *buf)
   return rc ?: statfs_overflow (buf);
 }
 weak_alias (__fstatfs, fstatfs)
+#endif
diff --git a/sysdeps/unix/sysv/linux/generic/wordsize-32/statfs.c b/sysdeps/unix/sysv/linux/generic/wordsize-32/statfs.c
index 1937f05..6413a54 100644
--- a/sysdeps/unix/sysv/linux/generic/wordsize-32/statfs.c
+++ b/sysdeps/unix/sysv/linux/generic/wordsize-32/statfs.c
@@ -18,8 +18,10 @@
 
 #include <errno.h>
 #include <sys/statfs.h>
+#include <kernel_stat.h>
 #include <stddef.h>
 
+#if !STATFS_IS_STATFS64
 #include "overflow.h"
 
 /* Return information about the filesystem on which FILE resides.  */
@@ -31,3 +33,4 @@ __statfs (const char *file, struct statfs *buf)
 }
 libc_hidden_def (__statfs)
 weak_alias (__statfs, statfs)
+#endif
diff --git a/sysdeps/unix/sysv/linux/hppa/kernel_stat.h b/sysdeps/unix/sysv/linux/hppa/kernel_stat.h
index 9ffa3ba..a3ac53a 100644
--- a/sysdeps/unix/sysv/linux/hppa/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/hppa/kernel_stat.h
@@ -31,3 +31,4 @@ struct kernel_stat {
 #define _HAVE_STAT64_NSEC
 
 #define XSTAT_IS_XSTAT64 0
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/ia64/kernel_stat.h b/sysdeps/unix/sysv/linux/ia64/kernel_stat.h
index 2f6fbb2..9541bb5 100644
--- a/sysdeps/unix/sysv/linux/ia64/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/ia64/kernel_stat.h
@@ -18,3 +18,4 @@
 
 #define STAT_IS_KERNEL_STAT 1
 #define XSTAT_IS_XSTAT64 1
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/kernel_stat.h b/sysdeps/unix/sysv/linux/kernel_stat.h
index 4354d14..eecc962 100644
--- a/sysdeps/unix/sysv/linux/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/kernel_stat.h
@@ -35,3 +35,4 @@ struct kernel_stat
 #define _HAVE_STAT64_NSEC
 
 #define XSTAT_IS_XSTAT64 0
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/microblaze/kernel_stat.h b/sysdeps/unix/sysv/linux/microblaze/kernel_stat.h
index b6ae8c3..3ce58df 100644
--- a/sysdeps/unix/sysv/linux/microblaze/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/microblaze/kernel_stat.h
@@ -49,3 +49,4 @@ struct kernel_stat
 };
 
 #define XSTAT_IS_XSTAT64 0
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/mips/kernel_stat.h b/sysdeps/unix/sysv/linux/mips/kernel_stat.h
index a41d15f..388df1b 100644
--- a/sysdeps/unix/sysv/linux/mips/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/mips/kernel_stat.h
@@ -57,3 +57,4 @@ struct kernel_stat
 #endif
 
 #define XSTAT_IS_XSTAT64 0
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/kernel_stat.h b/sysdeps/unix/sysv/linux/powerpc/powerpc32/kernel_stat.h
index 0fbde98..5b76f67 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/kernel_stat.h
@@ -48,3 +48,4 @@ struct kernel_stat
 #define _HAVE_STAT64_NSEC
 
 #define XSTAT_IS_XSTAT64 0
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/kernel_stat.h b/sysdeps/unix/sysv/linux/powerpc/powerpc64/kernel_stat.h
index fce8fba..eec1ab1 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/kernel_stat.h
@@ -18,3 +18,4 @@
 
 #define STAT_IS_KERNEL_STAT 1
 #define XSTAT_IS_XSTAT64 1
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/s390/s390-64/kernel_stat.h b/sysdeps/unix/sysv/linux/s390/s390-64/kernel_stat.h
index 2f6fbb2..9541bb5 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-64/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/s390/s390-64/kernel_stat.h
@@ -18,3 +18,4 @@
 
 #define STAT_IS_KERNEL_STAT 1
 #define XSTAT_IS_XSTAT64 1
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/kernel_stat.h b/sysdeps/unix/sysv/linux/sparc/sparc32/kernel_stat.h
index eb60236..a441600 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc32/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/sparc/sparc32/kernel_stat.h
@@ -32,3 +32,4 @@ struct kernel_stat
 #define _HAVE_STAT64_NSEC
 
 #define XSTAT_IS_XSTAT64 0
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/kernel_stat.h b/sysdeps/unix/sysv/linux/sparc/sparc64/kernel_stat.h
index 2a26a78..30afb55 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc64/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/sparc/sparc64/kernel_stat.h
@@ -45,3 +45,4 @@ struct kernel_stat64
   };
 
 #define XSTAT_IS_XSTAT64 1
+#define STATFS_IS_STATFS64 0
diff --git a/sysdeps/unix/sysv/linux/statfs64.c b/sysdeps/unix/sysv/linux/statfs64.c
index de42261..4315fe5 100644
--- a/sysdeps/unix/sysv/linux/statfs64.c
+++ b/sysdeps/unix/sysv/linux/statfs64.c
@@ -16,9 +16,18 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+/* Hide the prototypes for __statfs and statfs so that GCC will not
+   complain about the different function signatures if they are aliased
+   to  __stat64.  If STATFS_IS_STATFS64 is not zero then the statfs and
+   statfs64 structures have an identical layout but different type names.  */
+
+#define __statfs __statfs_disable
+#define statfs statfs_disable
+
 #include <errno.h>
 #include <string.h>
 #include <sys/statfs.h>
+#include <kernel_stat.h>
 #include <stddef.h>
 #include <sysdep.h>
 #include <kernel-features.h>
@@ -72,3 +81,12 @@ __statfs64 (const char *file, struct statfs64 *buf)
 #endif
 }
 weak_alias (__statfs64, statfs64)
+
+#undef __statfs
+#undef statfs
+
+#if STATFS_IS_STATFS64
+weak_alias (__statfs64, __statfs)
+weak_alias (__statfs64, statfs)
+libc_hidden_ver (__statfs64, __statfs)
+#endif
diff --git a/sysdeps/unix/sysv/linux/x86_64/kernel_stat.h b/sysdeps/unix/sysv/linux/x86_64/kernel_stat.h
index 2f6fbb2..9541bb5 100644
--- a/sysdeps/unix/sysv/linux/x86_64/kernel_stat.h
+++ b/sysdeps/unix/sysv/linux/x86_64/kernel_stat.h
@@ -18,3 +18,4 @@
 
 #define STAT_IS_KERNEL_STAT 1
 #define XSTAT_IS_XSTAT64 1
+#define STATFS_IS_STATFS64 0

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                          |   26 ++++++++++++++++++++
 sysdeps/unix/sysv/linux/alpha/kernel_stat.h        |    1 +
 sysdeps/unix/sysv/linux/fstatfs64.c                |   17 +++++++++++++
 sysdeps/unix/sysv/linux/generic/kernel_stat.h      |    2 +
 .../unix/sysv/linux/generic/wordsize-32/fstatfs.c  |    3 ++
 .../unix/sysv/linux/generic/wordsize-32/statfs.c   |    3 ++
 sysdeps/unix/sysv/linux/hppa/kernel_stat.h         |    1 +
 sysdeps/unix/sysv/linux/ia64/kernel_stat.h         |    1 +
 sysdeps/unix/sysv/linux/kernel_stat.h              |    1 +
 sysdeps/unix/sysv/linux/microblaze/kernel_stat.h   |    1 +
 sysdeps/unix/sysv/linux/mips/kernel_stat.h         |    1 +
 .../sysv/linux/powerpc/powerpc32/kernel_stat.h     |    1 +
 .../sysv/linux/powerpc/powerpc64/kernel_stat.h     |    1 +
 sysdeps/unix/sysv/linux/s390/s390-64/kernel_stat.h |    1 +
 .../unix/sysv/linux/sparc/sparc32/kernel_stat.h    |    1 +
 .../unix/sysv/linux/sparc/sparc64/kernel_stat.h    |    1 +
 sysdeps/unix/sysv/linux/statfs64.c                 |   18 +++++++++++++
 sysdeps/unix/sysv/linux/x86_64/kernel_stat.h       |    1 +
 18 files changed, 81 insertions(+), 0 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]