diff options
-rw-r--r-- | fs/lockd/svclock.c | 2 | ||||
-rw-r--r-- | fs/locks.c | 4 | ||||
-rw-r--r-- | fs/nfsd/nfs4state.c | 3 | ||||
-rw-r--r-- | include/linux/fs.h | 1 |
4 files changed, 4 insertions, 6 deletions
diff --git a/fs/lockd/svclock.c b/fs/lockd/svclock.c index 1f122c1940af..4d81553d2948 100644 --- a/fs/lockd/svclock.c +++ b/fs/lockd/svclock.c | |||
@@ -632,7 +632,7 @@ nlmsvc_update_deferred_block(struct nlm_block *block, struct file_lock *conf, | |||
632 | block->b_flags |= B_TIMED_OUT; | 632 | block->b_flags |= B_TIMED_OUT; |
633 | if (conf) { | 633 | if (conf) { |
634 | if (block->b_fl) | 634 | if (block->b_fl) |
635 | locks_copy_lock(block->b_fl, conf); | 635 | __locks_copy_lock(block->b_fl, conf); |
636 | } | 636 | } |
637 | } | 637 | } |
638 | 638 | ||
diff --git a/fs/locks.c b/fs/locks.c index 2e0fa661e423..e1ea2fe03681 100644 --- a/fs/locks.c +++ b/fs/locks.c | |||
@@ -224,7 +224,7 @@ static void locks_copy_private(struct file_lock *new, struct file_lock *fl) | |||
224 | /* | 224 | /* |
225 | * Initialize a new lock from an existing file_lock structure. | 225 | * Initialize a new lock from an existing file_lock structure. |
226 | */ | 226 | */ |
227 | static void __locks_copy_lock(struct file_lock *new, const struct file_lock *fl) | 227 | void __locks_copy_lock(struct file_lock *new, const struct file_lock *fl) |
228 | { | 228 | { |
229 | new->fl_owner = fl->fl_owner; | 229 | new->fl_owner = fl->fl_owner; |
230 | new->fl_pid = fl->fl_pid; | 230 | new->fl_pid = fl->fl_pid; |
@@ -833,7 +833,7 @@ static int __posix_lock_file(struct inode *inode, struct file_lock *request, str | |||
833 | if (!posix_locks_conflict(request, fl)) | 833 | if (!posix_locks_conflict(request, fl)) |
834 | continue; | 834 | continue; |
835 | if (conflock) | 835 | if (conflock) |
836 | locks_copy_lock(conflock, fl); | 836 | __locks_copy_lock(conflock, fl); |
837 | error = -EAGAIN; | 837 | error = -EAGAIN; |
838 | if (!(request->fl_flags & FL_SLEEP)) | 838 | if (!(request->fl_flags & FL_SLEEP)) |
839 | goto out; | 839 | goto out; |
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index 55dfdd71f1b0..8799b8708188 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c | |||
@@ -2712,9 +2712,6 @@ nfsd4_lock(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, | |||
2712 | * Note: locks.c uses the BKL to protect the inode's lock list. | 2712 | * Note: locks.c uses the BKL to protect the inode's lock list. |
2713 | */ | 2713 | */ |
2714 | 2714 | ||
2715 | /* XXX?: Just to divert the locks_release_private at the start of | ||
2716 | * locks_copy_lock: */ | ||
2717 | locks_init_lock(&conflock); | ||
2718 | err = vfs_lock_file(filp, cmd, &file_lock, &conflock); | 2715 | err = vfs_lock_file(filp, cmd, &file_lock, &conflock); |
2719 | switch (-err) { | 2716 | switch (-err) { |
2720 | case 0: /* success! */ | 2717 | case 0: /* success! */ |
diff --git a/include/linux/fs.h b/include/linux/fs.h index cc2be2cf7d41..6556f2f967e5 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -973,6 +973,7 @@ extern int do_sync_mapping_range(struct address_space *mapping, loff_t offset, | |||
973 | /* fs/locks.c */ | 973 | /* fs/locks.c */ |
974 | extern void locks_init_lock(struct file_lock *); | 974 | extern void locks_init_lock(struct file_lock *); |
975 | extern void locks_copy_lock(struct file_lock *, struct file_lock *); | 975 | extern void locks_copy_lock(struct file_lock *, struct file_lock *); |
976 | extern void __locks_copy_lock(struct file_lock *, const struct file_lock *); | ||
976 | extern void locks_remove_posix(struct file *, fl_owner_t); | 977 | extern void locks_remove_posix(struct file *, fl_owner_t); |
977 | extern void locks_remove_flock(struct file *); | 978 | extern void locks_remove_flock(struct file *); |
978 | extern void posix_test_lock(struct file *, struct file_lock *); | 979 | extern void posix_test_lock(struct file *, struct file_lock *); |