1POSIX_LOCK_FILE(9)               The Linux VFS              POSIX_LOCK_FILE(9)
2
3
4

NAME

6       posix_lock_file - Apply a POSIX-style lock to a file
7

SYNOPSIS

9       int posix_lock_file(struct file * filp, struct file_lock * fl,
10                           struct file_lock * conflock);
11

ARGUMENTS

13       filp
14           The file to apply the lock to
15
16       fl
17           The lock to be applied
18
19       conflock
20           Place to return a copy of the conflicting lock, if found.
21

DESCRIPTION

23       Add a POSIX style lock to a file. We merge adjacent & overlapping locks
24       whenever possible. POSIX locks are sorted by owner task, then by
25       starting address
26
27       Note that if called with an FL_EXISTS argument, the caller may
28       determine whether or not a lock was successfully freed by testing the
29       return value for -ENOENT.
30
32Kernel Hackers Manual 3.10         June 2019                POSIX_LOCK_FILE(9)
Impressum