On Sat, Apr 30, 2022 at 5:01 PM OGAWA Hirofumi <hirofumi@xxxxxxxxxxxxxxxxxx> wrote: > > They are all in {cdate:16, ctime:16, ctime_cs:8} format, which ensures > > crtime will be kept at the correct granularity (10 ms). The remaining > > timestamps may be copied from the vfs inode, so we need to truncate them > > to fit FAT's format. But crtime doesn't need to do that. > > Hm, maybe right. I'm not checking fully though, then we can remove > fat_truncate_time() in vfat_create/mkdir()? > > (Actually msdos too though, the state of timestamps for msdos is > strange, mean on-disk and in-core timestamps are not sync. So not > including for now) Thanks for your insight! Indeed all the time truncations in these two functions can be removed, because all the timestamps come from fat_time_fat2unix() which ensures the granularity. I'll update this change in the last commit later if there's no additional issues. Thanks.