aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2006-08-08 19:36:06 -0700
committerH. Peter Anvin <hpa@zytor.com>2006-08-08 19:36:06 -0700
commit5238d330db74155b42b8944ce60f95a9c6c17346 (patch)
tree6e6d86f618f62a623b0b183a77133536facbeaa7
parent2a4baceb10b1d10dc4d13f14d7080fc5c38abc27 (diff)
parentf96f2943193d1cd5e4728706463904f913a60d08 (diff)
downloadklibc-5238d330db74155b42b8944ce60f95a9c6c17346.tar.gz
Merge with git://charm.itp.tuwien.ac.at/mattems/klibc/.git#maksklibc-1.4.20
-rw-r--r--usr/include/arch/mips/klibc/archconfig.h3
-rw-r--r--usr/include/klibc/sysconfig.h10
-rw-r--r--usr/include/sys/vfs.h17
3 files changed, 30 insertions, 0 deletions
diff --git a/usr/include/arch/mips/klibc/archconfig.h b/usr/include/arch/mips/klibc/archconfig.h
index d9528b8e864be..15b3208cdb7cb 100644
--- a/usr/include/arch/mips/klibc/archconfig.h
+++ b/usr/include/arch/mips/klibc/archconfig.h
@@ -12,4 +12,7 @@
/* MIPS has architecture-specific code for vfork() */
#define _KLIBC_REAL_VFORK 1
+/* MIPS defines it's own statfs */
+#define _KLIBC_STATFS_F_TYPE_32B 1
+
#endif /* _KLIBC_ARCHCONFIG_H */
diff --git a/usr/include/klibc/sysconfig.h b/usr/include/klibc/sysconfig.h
index f3ae9150fc645..f4fb7a944a0df 100644
--- a/usr/include/klibc/sysconfig.h
+++ b/usr/include/klibc/sysconfig.h
@@ -163,4 +163,14 @@
# define _KLIBC_STATFS_F_TYPE_64 (_BITSIZE == 64)
#endif
+/*
+ * _KLIBC_STATFS_F_TYPE_32B:
+ *
+ * mips has it's own definition of statfs, which is
+ * different from any other 32 bit arch.
+ */
+#ifndef _KLIBC_STATFS_F_TYPE_32B
+# define _KLIBC_STATFS_F_TYPE_32B 0
+#endif
+
#endif /* _KLIBC_SYSCONFIG_H */
diff --git a/usr/include/sys/vfs.h b/usr/include/sys/vfs.h
index 33b10264d750d..6fb1eabc80868 100644
--- a/usr/include/sys/vfs.h
+++ b/usr/include/sys/vfs.h
@@ -32,6 +32,23 @@ struct statfs {
uint64_t f_spare[5];
};
+#elif _KLIBC_STATFS_F_TYPE_32B
+
+struct statfs {
+ uint32_t f_type;
+ uint32_t f_bsize;
+ uint32_t f_frsize;
+ uint32_t __pad;
+ uint64_t f_blocks;
+ uint64_t f_bfree;
+ uint64_t f_files;
+ uint64_t f_ffree;
+ uint64_t f_bavail;
+ __kernel_fsid_t f_fsid;
+ uint32_t f_namelen;
+ uint32_t f_spare[6];
+};
+
#else /* not _KLIBC_STATFS_F_TYPE_64 */
struct statfs {