diff options
Diffstat (limited to 'fs/xfs/xfs_itable.c')
-rw-r--r-- | fs/xfs/xfs_itable.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/fs/xfs/xfs_itable.c b/fs/xfs/xfs_itable.c index f63646ead816..41f50e7d1c32 100644 --- a/fs/xfs/xfs_itable.c +++ b/fs/xfs/xfs_itable.c | |||
@@ -56,6 +56,7 @@ xfs_bulkstat_one_iget( | |||
56 | { | 56 | { |
57 | xfs_dinode_core_t *dic; /* dinode core info pointer */ | 57 | xfs_dinode_core_t *dic; /* dinode core info pointer */ |
58 | xfs_inode_t *ip; /* incore inode pointer */ | 58 | xfs_inode_t *ip; /* incore inode pointer */ |
59 | vnode_t *vp; | ||
59 | int error; | 60 | int error; |
60 | 61 | ||
61 | error = xfs_iget(mp, NULL, ino, 0, XFS_ILOCK_SHARED, &ip, bno); | 62 | error = xfs_iget(mp, NULL, ino, 0, XFS_ILOCK_SHARED, &ip, bno); |
@@ -72,6 +73,7 @@ xfs_bulkstat_one_iget( | |||
72 | goto out_iput; | 73 | goto out_iput; |
73 | } | 74 | } |
74 | 75 | ||
76 | vp = XFS_ITOV(ip); | ||
75 | dic = &ip->i_d; | 77 | dic = &ip->i_d; |
76 | 78 | ||
77 | /* xfs_iget returns the following without needing | 79 | /* xfs_iget returns the following without needing |
@@ -84,8 +86,9 @@ xfs_bulkstat_one_iget( | |||
84 | buf->bs_uid = dic->di_uid; | 86 | buf->bs_uid = dic->di_uid; |
85 | buf->bs_gid = dic->di_gid; | 87 | buf->bs_gid = dic->di_gid; |
86 | buf->bs_size = dic->di_size; | 88 | buf->bs_size = dic->di_size; |
87 | buf->bs_atime.tv_sec = dic->di_atime.t_sec; | 89 | /* atime is only kept uptodate in the Linux inode */ |
88 | buf->bs_atime.tv_nsec = dic->di_atime.t_nsec; | 90 | buf->bs_atime.tv_sec = vp->v_inode.i_atime.tv_sec; |
91 | buf->bs_atime.tv_nsec = vp->v_inode.i_atime.tv_nsec; | ||
89 | buf->bs_mtime.tv_sec = dic->di_mtime.t_sec; | 92 | buf->bs_mtime.tv_sec = dic->di_mtime.t_sec; |
90 | buf->bs_mtime.tv_nsec = dic->di_mtime.t_nsec; | 93 | buf->bs_mtime.tv_nsec = dic->di_mtime.t_nsec; |
91 | buf->bs_ctime.tv_sec = dic->di_ctime.t_sec; | 94 | buf->bs_ctime.tv_sec = dic->di_ctime.t_sec; |