1
0

statvfs.h 883 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #ifndef _SYS_STATVFS_H
  2. #define _SYS_STATVFS_H
  3. #define __NEED_fsblkcnt_t
  4. #define __NEED_fsfilcnt_t
  5. #include <bits/alltypes.h>
  6. #include <endian.h>
  7. struct statvfs {
  8. unsigned long f_bsize, f_frsize;
  9. fsblkcnt_t f_blocks, f_bfree, f_bavail;
  10. fsfilcnt_t f_files, f_ffree, f_favail;
  11. #if __BYTE_ORDER == __LITTLE_ENDIAN
  12. unsigned long f_fsid;
  13. unsigned :8*(2*sizeof(int)-sizeof(long));
  14. #else
  15. unsigned :8*(2*sizeof(int)-sizeof(long));
  16. unsigned long f_fsid;
  17. #endif
  18. unsigned long f_flag, f_namemax;
  19. int __reserved[6];
  20. };
  21. int statvfs (const char *, struct statvfs *);
  22. int fstatvfs (int, struct statvfs *);
  23. #define ST_RDONLY 1
  24. #define ST_NOSUID 2
  25. #define ST_NODEV 4
  26. #define ST_NOEXEC 8
  27. #define ST_SYNCHRONOUS 16
  28. #define ST_MANDLOCK 64
  29. #define ST_WRITE 128
  30. #define ST_APPEND 256
  31. #define ST_IMMUTABLE 512
  32. #define ST_NOATIME 1024
  33. #define ST_NODIRATIME 2048
  34. #endif