Re: [PATCH v3 3/3] fat: report creation time in statx

From: OGAWA Hirofumi
Date: Fri Apr 15 2022 - 09:17:45 EST


Chung-Chiang Cheng <cccheng@xxxxxxxxxxxx> writes:

> @@ -568,10 +568,14 @@ int fat_fill_inode(struct inode *inode, struct msdos_dir_entry *de)
>
> fat_time_fat2unix(sbi, &inode->i_mtime, de->time, de->date, 0);
> inode->i_ctime = inode->i_mtime;
> - if (sbi->options.isvfat)
> + if (sbi->options.isvfat) {
> fat_time_fat2unix(sbi, &inode->i_atime, 0, de->adate, 0);
> - else
> + fat_time_fat2unix(sbi, &MSDOS_I(inode)->i_crtime, de->ctime,
> + de->cdate, de->ctime_cs);
> + } else {
> fat_truncate_atime(sbi, &inode->i_mtime, &inode->i_atime);
> + fat_truncate_crtime(sbi, &inode->i_mtime, &MSDOS_I(inode)->i_crtime);
> + }

Probably, nothing worth to update i_crtime here, right?

Thanks.
--
OGAWA Hirofumi <hirofumi@xxxxxxxxxxxxxxxxxx>