summaryrefslogtreecommitdiffstats
path: root/fs/locks.c
diff options
context:
space:
mode:
authorJ. Bruce Fields <bfields@redhat.com>2012-07-27 16:18:00 -0400
committerJ. Bruce Fields <bfields@redhat.com>2012-07-27 16:18:00 -0400
commit96d6d59ceaeaacba4088862f3c57fcd011f52832 (patch)
treefee86db726235ee3aeb0efdc7ae790f299d6de9d /fs/locks.c
parent3b6e2723f32de42028617f2c99b244ccd72cd959 (diff)
downloadlinux-96d6d59ceaeaacba4088862f3c57fcd011f52832.tar.gz
linux-96d6d59ceaeaacba4088862f3c57fcd011f52832.tar.bz2
linux-96d6d59ceaeaacba4088862f3c57fcd011f52832.zip
locks: move lease-specific code out of locks_delete_lock
No point putting something only used by one caller into common code. Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/locks.c')
-rw-r--r--fs/locks.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/fs/locks.c b/fs/locks.c
index 86668dd211ae..541075a41527 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -570,12 +570,6 @@ static void locks_delete_lock(struct file_lock **thisfl_p)
fl->fl_next = NULL;
list_del_init(&fl->fl_link);
- fasync_helper(0, fl->fl_file, 0, &fl->fl_fasync);
- if (fl->fl_fasync != NULL) {
- printk(KERN_ERR "locks_delete_lock: fasync == %p\n", fl->fl_fasync);
- fl->fl_fasync = NULL;
- }
-
if (fl->fl_nspid) {
put_pid(fl->fl_nspid);
fl->fl_nspid = NULL;
@@ -1150,6 +1144,11 @@ int lease_modify(struct file_lock **before, int arg)
f_delown(filp);
filp->f_owner.signum = 0;
+ fasync_helper(0, fl->fl_file, 0, &fl->fl_fasync);
+ if (fl->fl_fasync != NULL) {
+ printk(KERN_ERR "locks_delete_lock: fasync == %p\n", fl->fl_fasync);
+ fl->fl_fasync = NULL;
+ }
locks_delete_lock(before);
}
return 0;