1 #ifndef _ASM_GENERIC_FCNTL_H
2 #define _ASM_GENERIC_FCNTL_H
9 #define F_DUPFD 0 /* dup */
10 #define F_GETFD 1 /* get close_on_exec */
11 #define F_SETFD 2 /* set/clear close_on_exec */
12 #define F_GETFL 3 /* get file->f_flags */
13 #define F_SETFL 4 /* set file->f_flags */
15 /* for F_[GET|SET]FL */
16 #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
18 /* operations for bsd flock(), also used by the kernel implementation */
19 #define LOCK_SH 1 /* shared lock */
20 #define LOCK_EX 2 /* exclusive lock */
21 #define LOCK_NB 4 /* or'd with one of the above to prevent
23 #define LOCK_UN 8 /* remove lock */
25 #define LOCK_MAND 32 /* This is a mandatory flock ... */
26 #define LOCK_READ 64 /* which allows concurrent read operations */
27 #define LOCK_WRITE 128 /* which allows concurrent write operations */
28 #define LOCK_RW 192 /* which allows concurrent read & write ops */
30 #define F_LINUX_SPECIFIC_BASE 1024
32 #endif /* _ASM_GENERIC_FCNTL_H */