summaryrefslogtreecommitdiffstats
path: root/kernel/fs/locks.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/fs/locks.c')
-rw-r--r--kernel/fs/locks.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/fs/locks.c b/kernel/fs/locks.c
index 6333263b7..8eddae23e 100644
--- a/kernel/fs/locks.c
+++ b/kernel/fs/locks.c
@@ -1602,7 +1602,7 @@ generic_add_lease(struct file *filp, long arg, struct file_lock **flp, void **pr
{
struct file_lock *fl, *my_fl = NULL, *lease;
struct dentry *dentry = filp->f_path.dentry;
- struct inode *inode = dentry->d_inode;
+ struct inode *inode = file_inode(filp);
struct file_lock_context *ctx;
bool is_deleg = (*flp)->fl_flags & FL_DELEG;
int error;