mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-11 21:38:32 +08:00
xfs: sync up xfs_trans_inode with userspace
Add an XFS_ICHGTIME_CREATE case to xfs_trans_ichgtime() to keep in sync with userspace. (Currently no kernel caller sends this flag.) Signed-off-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
This commit is contained in:
parent
3f6d70e885
commit
79ba2a2185
@ -66,6 +66,10 @@ xfs_trans_ichgtime(
|
||||
inode->i_mtime = tv;
|
||||
if (flags & XFS_ICHGTIME_CHG)
|
||||
inode->i_ctime = tv;
|
||||
if (flags & XFS_ICHGTIME_CREATE) {
|
||||
ip->i_d.di_crtime.t_sec = (int32_t)tv.tv_sec;
|
||||
ip->i_d.di_crtime.t_nsec = (int32_t)tv.tv_nsec;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user