diff options
Diffstat (limited to 'fs/nfs/nfs4proc.c')
-rw-r--r-- | fs/nfs/nfs4proc.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 45b35b9b1e36..55e1e3af23a3 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c | |||
@@ -38,6 +38,7 @@ | |||
38 | #include <linux/mm.h> | 38 | #include <linux/mm.h> |
39 | #include <linux/delay.h> | 39 | #include <linux/delay.h> |
40 | #include <linux/errno.h> | 40 | #include <linux/errno.h> |
41 | #include <linux/file.h> | ||
41 | #include <linux/string.h> | 42 | #include <linux/string.h> |
42 | #include <linux/ratelimit.h> | 43 | #include <linux/ratelimit.h> |
43 | #include <linux/printk.h> | 44 | #include <linux/printk.h> |
@@ -5604,6 +5605,7 @@ static struct nfs4_lockdata *nfs4_alloc_lockdata(struct file_lock *fl, | |||
5604 | p->server = server; | 5605 | p->server = server; |
5605 | atomic_inc(&lsp->ls_count); | 5606 | atomic_inc(&lsp->ls_count); |
5606 | p->ctx = get_nfs_open_context(ctx); | 5607 | p->ctx = get_nfs_open_context(ctx); |
5608 | get_file(fl->fl_file); | ||
5607 | memcpy(&p->fl, fl, sizeof(p->fl)); | 5609 | memcpy(&p->fl, fl, sizeof(p->fl)); |
5608 | return p; | 5610 | return p; |
5609 | out_free_seqid: | 5611 | out_free_seqid: |
@@ -5716,6 +5718,7 @@ static void nfs4_lock_release(void *calldata) | |||
5716 | nfs_free_seqid(data->arg.lock_seqid); | 5718 | nfs_free_seqid(data->arg.lock_seqid); |
5717 | nfs4_put_lock_state(data->lsp); | 5719 | nfs4_put_lock_state(data->lsp); |
5718 | put_nfs_open_context(data->ctx); | 5720 | put_nfs_open_context(data->ctx); |
5721 | fput(data->fl.fl_file); | ||
5719 | kfree(data); | 5722 | kfree(data); |
5720 | dprintk("%s: done!\n", __func__); | 5723 | dprintk("%s: done!\n", __func__); |
5721 | } | 5724 | } |