kernel_stat.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #ifndef _BITS_STAT_STRUCT_H
  2. #define _BITS_STAT_STRUCT_H
  3. /* This file provides whatever this particular arch's kernel thinks
  4. * struct kernel_stat should look like... It turns out each arch has a
  5. * different opinion on the subject... */
  6. #if __WORDSIZE == 64
  7. #define kernel_stat kernel_stat64
  8. #else
  9. struct kernel_stat {
  10. unsigned short st_dev;
  11. unsigned long st_ino;
  12. unsigned short st_mode;
  13. short st_nlink;
  14. unsigned short st_uid;
  15. unsigned short st_gid;
  16. unsigned short st_rdev;
  17. long st_size;
  18. struct timespec st_atim;
  19. struct timespec st_mtim;
  20. struct timespec st_ctim;
  21. long st_blksize;
  22. long st_blocks;
  23. unsigned long __unused4[2];
  24. };
  25. #endif
  26. struct kernel_stat64 {
  27. unsigned long long st_dev;
  28. unsigned long long st_ino;
  29. unsigned int st_mode;
  30. unsigned int st_nlink;
  31. unsigned int st_uid;
  32. unsigned int st_gid;
  33. unsigned long long st_rdev;
  34. unsigned char __pad3[8];
  35. long long st_size;
  36. unsigned int st_blksize;
  37. unsigned char __pad4[8];
  38. unsigned int st_blocks;
  39. struct timespec st_atim;
  40. struct timespec st_mtim;
  41. struct timespec st_ctim;
  42. unsigned int __unused4;
  43. unsigned int __unused5;
  44. };
  45. #endif /* _BITS_STAT_STRUCT_H */