diff options
Diffstat (limited to 'fs/ocfs2/dir.c')
-rw-r--r-- | fs/ocfs2/dir.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/ocfs2/dir.c b/fs/ocfs2/dir.c index fc121350d8cb..f1e1aed8f638 100644 --- a/fs/ocfs2/dir.c +++ b/fs/ocfs2/dir.c | |||
@@ -2014,12 +2014,12 @@ int ocfs2_dir_foreach(struct inode *inode, loff_t *f_pos, void *priv, | |||
2014 | int ocfs2_readdir(struct file * filp, void * dirent, filldir_t filldir) | 2014 | int ocfs2_readdir(struct file * filp, void * dirent, filldir_t filldir) |
2015 | { | 2015 | { |
2016 | int error = 0; | 2016 | int error = 0; |
2017 | struct inode *inode = filp->f_path.dentry->d_inode; | 2017 | struct inode *inode = file_inode(filp); |
2018 | int lock_level = 0; | 2018 | int lock_level = 0; |
2019 | 2019 | ||
2020 | trace_ocfs2_readdir((unsigned long long)OCFS2_I(inode)->ip_blkno); | 2020 | trace_ocfs2_readdir((unsigned long long)OCFS2_I(inode)->ip_blkno); |
2021 | 2021 | ||
2022 | error = ocfs2_inode_lock_atime(inode, filp->f_vfsmnt, &lock_level); | 2022 | error = ocfs2_inode_lock_atime(inode, filp->f_path.mnt, &lock_level); |
2023 | if (lock_level && error >= 0) { | 2023 | if (lock_level && error >= 0) { |
2024 | /* We release EX lock which used to update atime | 2024 | /* We release EX lock which used to update atime |
2025 | * and get PR lock again to reduce contention | 2025 | * and get PR lock again to reduce contention |