aboutsummaryrefslogtreecommitdiffstats
path: root/module/zfs/zpl_ctldir.c
diff options
context:
space:
mode:
Diffstat (limited to 'module/zfs/zpl_ctldir.c')
-rw-r--r--module/zfs/zpl_ctldir.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/module/zfs/zpl_ctldir.c b/module/zfs/zpl_ctldir.c
index bd8af3928..1c5fb34e6 100644
--- a/module/zfs/zpl_ctldir.c
+++ b/module/zfs/zpl_ctldir.c
@@ -103,8 +103,10 @@ static int
zpl_root_getattr_impl(const struct path *path, struct kstat *stat,
u32 request_mask, unsigned int query_flags)
{
- generic_fillattr(path->dentry->d_inode, stat);
- stat->atime = CURRENT_TIME;
+ struct inode *ip = path->dentry->d_inode;
+
+ generic_fillattr(ip, stat);
+ stat->atime = current_time(ip);
return (0);
}
@@ -377,14 +379,15 @@ static int
zpl_snapdir_getattr_impl(const struct path *path, struct kstat *stat,
u32 request_mask, unsigned int query_flags)
{
- zfsvfs_t *zfsvfs = ITOZSB(path->dentry->d_inode);
+ struct inode *ip = path->dentry->d_inode;
+ zfsvfs_t *zfsvfs = ITOZSB(ip);
ZFS_ENTER(zfsvfs);
- generic_fillattr(path->dentry->d_inode, stat);
+ generic_fillattr(ip, stat);
stat->nlink = stat->size = 2;
stat->ctime = stat->mtime = dmu_objset_snap_cmtime(zfsvfs->z_os);
- stat->atime = CURRENT_TIME;
+ stat->atime = current_time(ip);
ZFS_EXIT(zfsvfs);
return (0);
@@ -522,7 +525,7 @@ zpl_shares_getattr_impl(const struct path *path, struct kstat *stat,
if (zfsvfs->z_shares_dir == 0) {
generic_fillattr(path->dentry->d_inode, stat);
stat->nlink = stat->size = 2;
- stat->atime = CURRENT_TIME;
+ stat->atime = current_time(ip);
ZFS_EXIT(zfsvfs);
return (0);
}