2
0

target_fcntl.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. /*
  2. * This program is free software; you can redistribute it and/or modify
  3. * it under the terms of the GNU General Public License version 2 as
  4. * published by the Free Software Foundation, or (at your option) any
  5. * later version. See the COPYING file in the top-level directory.
  6. */
  7. #ifndef MIPS_TARGET_FCNTL_H
  8. #define MIPS_TARGET_FCNTL_H
  9. #define TARGET_O_APPEND 0x0008
  10. #define TARGET_O_DSYNC 0x0010
  11. #define TARGET_O_NONBLOCK 0x0080
  12. #define TARGET_O_CREAT 0x0100 /* not fcntl */
  13. #define TARGET_O_TRUNC 0x0200 /* not fcntl */
  14. #define TARGET_O_EXCL 0x0400 /* not fcntl */
  15. #define TARGET_O_NOCTTY 0x0800 /* not fcntl */
  16. #define TARGET_FASYNC 0x1000 /* fcntl, for BSD compatibility */
  17. #define TARGET_O_LARGEFILE 0x2000 /* allow large file opens */
  18. #define TARGET___O_SYNC 0x4000
  19. #define TARGET_O_DIRECT 0x8000 /* direct disk access hint */
  20. #define TARGET_F_GETLK 14
  21. #define TARGET_F_SETLK 6
  22. #define TARGET_F_SETLKW 7
  23. #define TARGET_F_SETOWN 24 /* for sockets. */
  24. #define TARGET_F_GETOWN 23 /* for sockets. */
  25. #if (TARGET_ABI_BITS == 32)
  26. struct target_flock {
  27. short l_type;
  28. short l_whence;
  29. abi_long l_start;
  30. abi_long l_len;
  31. abi_long l_sysid;
  32. int l_pid;
  33. abi_long pad[4];
  34. };
  35. #define TARGET_HAVE_ARCH_STRUCT_FLOCK
  36. #endif
  37. #define TARGET_F_GETLK64 33 /* using 'struct flock64' */
  38. #define TARGET_F_SETLK64 34
  39. #define TARGET_F_SETLKW64 35
  40. #include "../generic/fcntl.h"
  41. #endif