kernel_stat.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /* Ripped from linux/include/asm-x86_64/stat.h
  2. * and renamed 'struct stat' to 'struct kernel_stat' */
  3. #ifndef _ASM_X86_64_STAT_H
  4. #define _ASM_X86_64_STAT_H
  5. #ifndef _LIBC
  6. #error bits/kernel_stat.h is for internal uClibc use only!
  7. #endif
  8. #define STAT_HAVE_NSEC 1
  9. struct kernel_stat {
  10. unsigned long st_dev;
  11. unsigned long st_ino;
  12. unsigned long st_nlink;
  13. unsigned int st_mode;
  14. unsigned int st_uid;
  15. unsigned int st_gid;
  16. unsigned int __pad0;
  17. unsigned long st_rdev;
  18. long st_size;
  19. long st_blksize;
  20. long st_blocks; /* Number 512-byte blocks allocated. */
  21. unsigned long st_atime;
  22. unsigned long st_atime_nsec;
  23. unsigned long st_mtime;
  24. unsigned long st_mtime_nsec;
  25. unsigned long st_ctime;
  26. unsigned long st_ctime_nsec;
  27. long __unused[3];
  28. };
  29. /* For 32bit emulation */
  30. struct __old_kernel_stat {
  31. unsigned short st_dev;
  32. unsigned short st_ino;
  33. unsigned short st_mode;
  34. unsigned short st_nlink;
  35. unsigned short st_uid;
  36. unsigned short st_gid;
  37. unsigned short st_rdev;
  38. unsigned int st_size;
  39. unsigned int st_atime;
  40. unsigned int st_mtime;
  41. unsigned int st_ctime;
  42. };
  43. /* x86-64 stat64 is same as stat */
  44. #define kernel_stat64 kernel_stat
  45. #endif