1
0

fcntl.h 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #ifndef CYGONCE_ISO_FCNTL_H
  2. #define CYGONCE_ISO_FCNTL_H
  3. /*------------------------------------------------------------------------*/
  4. /* for dfs_jffs2.c */
  5. /*------------------------------------------------------------------------*/
  6. /* File access modes used for open() and fnctl() */
  7. #define JFFS2_O_RDONLY (DFS_O_RDONLY) /* Open for reading only */
  8. #define JFFS2_O_WRONLY (DFS_O_WRONLY) /* Open for writing only */
  9. #define JFFS2_O_RDWR (DFS_O_RDONLY|DFS_O_WRONLY) /* Open for reading and writing */
  10. /* File access mode mask */
  11. #define JFFS2_O_ACCMODE (DFS_O_RDONLY|DFS_O_RDWR|DFS_O_WRONLY)
  12. /* open() mode flags */
  13. #define JFFS2_O_CREAT (DFS_O_CREAT) /* Create file it it does not exist */
  14. #define JFFS2_O_EXCL (DFS_O_EXCL) /* Exclusive use */
  15. #define JFFS2_O_NOCTTY (DFS_O_NOCTTY) /* Do not assign a controlling terminal */
  16. #define JFFS2_O_TRUNC (DFS_O_TRUNC) /* Truncate */
  17. /* File status flags used for open() and fcntl() */
  18. #define JFFS2_O_APPEND (DFS_O_APPEND) /* Set append mode */
  19. #define JFFS2_O_DSYNC (DFS_O_DSYNC) /* Synchronized I/O data integrity writes */
  20. #define JFFS2_O_NONBLOCK (DFS_O_NONBLOCK)/* No delay */
  21. #define JFFS2_O_RSYNC (DFS_O_RSYNC) /* Synchronized read I/O */
  22. #define JFFS2_O_SYNC (DFS_O_SYNC) /* Synchronized I/O file integrity writes */
  23. /*------------------------------------------------------------------------*/
  24. /* for dfs_jffs2.c */
  25. /*------------------------------------------------------------------------*/
  26. #if defined(__CC_ARM) || defined(MSVC)
  27. /* File access modes used for open() and fnctl() */
  28. #define O_RDONLY (1<<0) /* Open for reading only */
  29. #define O_WRONLY (1<<1) /* Open for writing only */
  30. #define O_RDWR (O_RDONLY|O_WRONLY) /* Open for reading and writing */
  31. /* File access mode mask */
  32. #define O_ACCMODE (O_RDONLY|O_RDWR|O_WRONLY)
  33. /* open() mode flags */
  34. #define O_CREAT (1<<3) /* Create file it it does not exist */
  35. #define O_EXCL (1<<4) /* Exclusive use */
  36. #define O_NOCTTY (1<<5) /* Do not assign a controlling terminal */
  37. #define O_TRUNC (1<<6) /* Truncate */
  38. /* File status flags used for open() and fcntl() */
  39. #define O_APPEND (1<<7) /* Set append mode */
  40. #define O_DSYNC (1<<8) /* Synchronized I/O data integrity writes */
  41. #define O_NONBLOCK (1<<9) /* No delay */
  42. #define O_RSYNC (1<<10) /* Synchronized read I/O */
  43. #define O_SYNC (1<<11) /* Synchronized I/O file integrity writes */
  44. #endif /* CYGONCE_ISO_FCNTL_H multiple inclusion protection */
  45. #endif
  46. /* EOF fcntl.h */