kernel_stat.h 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. /* taken from linux/include/asm-or1k/stat.h */
  2. #ifndef _BITS_STAT_STRUCT_H
  3. #define _BITS_STAT_STRUCT_H
  4. #ifndef _LIBC
  5. #error bits/kernel_stat.h is for internal uClibc use only!
  6. #endif
  7. struct kernel_stat {
  8. unsigned long st_dev; /* Device. */
  9. unsigned long st_ino; /* File serial number. */
  10. unsigned int st_mode; /* File mode. */
  11. unsigned int st_nlink; /* Link count. */
  12. unsigned int st_uid; /* User ID of the file's owner. */
  13. unsigned int st_gid; /* Group ID of the file's group. */
  14. unsigned long st_rdev; /* Device number, if device. */
  15. unsigned long __pad1;
  16. long st_size; /* Size of file, in bytes. */
  17. int st_blksize; /* Optimal block size for I/O. */
  18. int __pad2;
  19. long st_blocks; /* Number 512-byte blocks allocated. */
  20. struct timespec st_atim;
  21. struct timespec st_mtim;
  22. struct timespec st_ctim;
  23. /*
  24. unsigned long st_atime;
  25. unsigned long __unused1;
  26. unsigned long st_mtime;
  27. unsigned long __unused2;
  28. unsigned long st_ctime;
  29. unsigned long __unused3;
  30. */
  31. unsigned int __unused4;
  32. unsigned int __unused5;
  33. };
  34. /* This matches struct stat64 in glibc2.1.
  35. */
  36. struct kernel_stat64 {
  37. unsigned long long st_dev; /* Device. */
  38. unsigned long long st_ino; /* File serial number. */
  39. unsigned int st_mode; /* File mode. */
  40. unsigned int st_nlink; /* Link count. */
  41. unsigned int st_uid; /* User ID of the file's owner. */
  42. unsigned int st_gid; /* Group ID of the file's group. */
  43. unsigned long long st_rdev; /* Device number, if device. */
  44. unsigned long long __pad1;
  45. long long st_size; /* Size of file, in bytes. */
  46. int st_blksize; /* Optimal block size for I/O. */
  47. int __pad2;
  48. long long st_blocks; /* Number 512-byte blocks allocated. */
  49. struct timespec st_atim;
  50. struct timespec st_mtim;
  51. struct timespec st_ctim;
  52. unsigned int __unused4;
  53. unsigned int __unused5;
  54. };
  55. #endif