Re: [PATCH] f2fs: opt in to multigrain timestamps

From: Chao Yu

Date: Wed Oct 14 2026 - 08:17:01 EST


On 10/12/26 23:46, Jeff Layton wrote:
> Set FS_MGTIME on f2fs_fs_type.
>
> f2fs meets the multigrain requirements:
> - ctime updates use inode_set_ctime_current()
> - f2fs_getattr() calls generic_fillattr()
> - f2fs_setattr() calls setattr_copy()
> - s_time_gran is 1ns
>
> Exception: with CONFIG_F2FS_FS_POSIX_ACL, f2fs_setattr() uses a local
> __setattr_copy() that sets timestamps directly, bypassing
> setattr_copy_mgtime(). Make it call setattr_copy() with ATTR_MODE
> cleared, then do the f2fs mode/ACL handling as before. ACL builds now
> also honor ATTR_CTIME_SET via inode_set_ctime_deleg(), as non-ACL
> builds already do.
>
> Assisted-by: LLM
> Signed-off-by: Jeff Layton <jlayton@xxxxxxxxxx>
Reviewed-by: Chao Yu <chao@xxxxxxxxxx>

Thanks,