• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/fs/

Lines Matching defs:file_lock

35 static struct file_lock *locks_alloc_lock(void)
40 void locks_release_private(struct file_lock *fl)
57 static void locks_free_lock(struct file_lock *fl)
67 void locks_init_lock(struct file_lock *fl)
93 struct file_lock *lock = (struct file_lock *) foo;
98 static void locks_copy_private(struct file_lock *new, struct file_lock *fl)
113 * Initialize a new lock from an existing file_lock structure.
115 void __locks_copy_lock(struct file_lock *new, const struct file_lock *fl)
129 void locks_copy_lock(struct file_lock *new, struct file_lock *fl)
157 /* Fill in a file_lock structure with an appropriate FLOCK lock. */
158 static int flock_make_lock(struct file *filp, struct file_lock **lock,
161 struct file_lock *fl;
180 static int assign_type(struct file_lock *fl, int type)
194 /* Verify a "struct flock" and copy it to a "struct file_lock" as a POSIX
197 static int flock_to_posix_lock(struct file *filp, struct file_lock *fl,
247 static int flock64_to_posix_lock(struct file *filp, struct file_lock *fl,
304 static void lease_break_callback(struct file_lock *fl)
309 static void lease_release_private_callback(struct file_lock *fl)
318 static int lease_mylease_callback(struct file_lock *fl, struct file_lock *try)
333 static int lease_init(struct file *filp, int type, struct file_lock *fl)
350 /* Allocate a file_lock initialised to this type of lease */
351 static struct file_lock *lease_alloc(struct file *filp, int type)
353 struct file_lock *fl = locks_alloc_lock();
369 static inline int locks_overlap(struct file_lock *fl1, struct file_lock *fl2)
378 static int posix_same_owner(struct file_lock *fl1, struct file_lock *fl2)
389 static void __locks_delete_block(struct file_lock *waiter)
398 static void locks_delete_block(struct file_lock *waiter)
410 static void locks_insert_block(struct file_lock *blocker,
411 struct file_lock *waiter)
424 static void locks_wake_up_blocks(struct file_lock *blocker)
427 struct file_lock *waiter;
430 struct file_lock, fl_block);
442 static void locks_insert_lock(struct file_lock **pos, struct file_lock *fl)
459 static void locks_delete_lock(struct file_lock **thisfl_p)
461 struct file_lock *fl = *thisfl_p;
485 static int locks_conflict(struct file_lock *caller_fl, struct file_lock *sys_fl)
497 static int posix_locks_conflict(struct file_lock *caller_fl, struct file_lock *sys_fl)
515 static int flock_locks_conflict(struct file_lock *caller_fl, struct file_lock *sys_fl)
529 posix_test_lock(struct file *filp, struct file_lock *fl)
531 struct file_lock *cfl;
579 static struct file_lock *what_owner_is_waiting_for(struct file_lock *block_fl)
581 struct file_lock *fl;
590 static int posix_locks_deadlock(struct file_lock *caller_fl,
591 struct file_lock *block_fl)
611 static int flock_lock_file(struct file *filp, struct file_lock *request)
613 struct file_lock *new_fl = NULL;
614 struct file_lock **before;
632 struct file_lock *fl = *before;
661 struct file_lock *fl = *before;
689 static int __posix_lock_file(struct inode *inode, struct file_lock *request, struct file_lock *conflock)
691 struct file_lock *fl;
692 struct file_lock *new_fl = NULL;
693 struct file_lock *new_fl2 = NULL;
694 struct file_lock *left = NULL;
695 struct file_lock *right = NULL;
696 struct file_lock **before;
700 * We may need two file_lock structures for this operation,
905 int posix_lock_file(struct file *filp, struct file_lock *fl,
906 struct file_lock *conflock)
921 int posix_lock_file_wait(struct file *filp, struct file_lock *fl)
950 struct file_lock *fl;
983 struct file_lock fl;
1021 int lease_modify(struct file_lock **before, int arg)
1023 struct file_lock *fl = *before;
1038 struct file_lock **before;
1039 struct file_lock *fl;
1067 struct file_lock *new_fl, *flock;
1068 struct file_lock *fl;
1171 struct file_lock *flock = inode->i_flock;
1182 struct file_lock *fl;
1202 * @flp: input - file_lock to use, output - file_lock inserted
1209 int generic_setlease(struct file *filp, long arg, struct file_lock **flp)
1211 struct file_lock *fl, **before, **my_before = NULL, *lease;
1212 struct file_lock *new_fl = NULL;
1306 * @lease: file_lock to use
1329 int vfs_setlease(struct file *filp, long arg, struct file_lock **lease)
1356 struct file_lock fl, *flp = &fl;
1393 int flock_lock_file_wait(struct file *filp, struct file_lock *fl)
1435 struct file_lock *lock;
1486 int vfs_test_lock(struct file *filp, struct file_lock *fl)
1495 static int posix_lock_to_flock(struct flock *flock, struct file_lock *fl)
1517 static void posix_lock_to_flock64(struct flock64 *flock, struct file_lock *fl)
1533 struct file_lock file_lock;
1544 error = flock_to_posix_lock(filp, &file_lock, &flock);
1548 error = vfs_test_lock(filp, &file_lock);
1552 flock.l_type = file_lock.fl_type;
1553 if (file_lock.fl_type != F_UNLCK) {
1554 error = posix_lock_to_flock(&flock, &file_lock);
1598 int vfs_lock_file(struct file *filp, unsigned int cmd, struct file_lock *fl, struct file_lock *conf)
1608 struct file_lock *fl)
1637 struct file_lock *file_lock = locks_alloc_lock();
1643 if (file_lock == NULL)
1664 error = flock_to_posix_lock(filp, file_lock, &flock);
1668 file_lock->fl_flags |= FL_SLEEP;
1688 error = do_lock_file_wait(filp, cmd, file_lock);
1699 spin_lock(&current->files->file_lock);
1701 spin_unlock(&current->files->file_lock);
1708 locks_free_lock(file_lock);
1718 struct file_lock file_lock;
1729 error = flock64_to_posix_lock(filp, &file_lock, &flock);
1733 error = vfs_test_lock(filp, &file_lock);
1737 flock.l_type = file_lock.fl_type;
1738 if (file_lock.fl_type != F_UNLCK)
1739 posix_lock_to_flock64(&flock, &file_lock);
1755 struct file_lock *file_lock = locks_alloc_lock();
1761 if (file_lock == NULL)
1782 error = flock64_to_posix_lock(filp, file_lock, &flock);
1786 file_lock->fl_flags |= FL_SLEEP;
1806 error = do_lock_file_wait(filp, cmd, file_lock);
1812 spin_lock(&current->files->file_lock);
1814 spin_unlock(&current->files->file_lock);
1821 locks_free_lock(file_lock);
1833 struct file_lock lock;
1867 struct file_lock *fl;
1868 struct file_lock **before;
1874 struct file_lock fl = {
1915 posix_unblock_lock(struct file *filp, struct file_lock *waiter)
1937 int vfs_cancel_lock(struct file *filp, struct file_lock *fl)
1950 static void lock_get_status(struct seq_file *f, struct file_lock *fl,
2023 struct file_lock *fl, *bfl;
2025 fl = list_entry(v, struct file_lock, fl_link);
2095 struct file_lock *fl;
2135 struct file_lock *fl;
2161 sizeof(struct file_lock), 0, SLAB_PANIC,