diff options
author | J. Bruce Fields <bfields@redhat.com> | 2012-07-27 16:18:00 -0400 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2012-07-27 16:18:00 -0400 |
commit | 96d6d59ceaeaacba4088862f3c57fcd011f52832 (patch) | |
tree | fee86db726235ee3aeb0efdc7ae790f299d6de9d /fs/locks.c | |
parent | 3b6e2723f32de42028617f2c99b244ccd72cd959 (diff) |
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.c | 11 |
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) | |||
570 | fl->fl_next = NULL; | 570 | fl->fl_next = NULL; |
571 | list_del_init(&fl->fl_link); | 571 | list_del_init(&fl->fl_link); |
572 | 572 | ||
573 | fasync_helper(0, fl->fl_file, 0, &fl->fl_fasync); | ||
574 | if (fl->fl_fasync != NULL) { | ||
575 | printk(KERN_ERR "locks_delete_lock: fasync == %p\n", fl->fl_fasync); | ||
576 | fl->fl_fasync = NULL; | ||
577 | } | ||
578 | |||
579 | if (fl->fl_nspid) { | 573 | if (fl->fl_nspid) { |
580 | put_pid(fl->fl_nspid); | 574 | put_pid(fl->fl_nspid); |
581 | fl->fl_nspid = NULL; | 575 | fl->fl_nspid = NULL; |
@@ -1150,6 +1144,11 @@ int lease_modify(struct file_lock **before, int arg) | |||
1150 | 1144 | ||
1151 | f_delown(filp); | 1145 | f_delown(filp); |
1152 | filp->f_owner.signum = 0; | 1146 | filp->f_owner.signum = 0; |
1147 | fasync_helper(0, fl->fl_file, 0, &fl->fl_fasync); | ||
1148 | if (fl->fl_fasync != NULL) { | ||
1149 | printk(KERN_ERR "locks_delete_lock: fasync == %p\n", fl->fl_fasync); | ||
1150 | fl->fl_fasync = NULL; | ||
1151 | } | ||
1153 | locks_delete_lock(before); | 1152 | locks_delete_lock(before); |
1154 | } | 1153 | } |
1155 | return 0; | 1154 | return 0; |