The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
To: Yangtao Li <frank.li@vivo.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fat: correct superblock flags
Date: Fri, 30 May 2025 19:23:54 +0900	[thread overview]
Message-ID: <87v7piflc5.fsf@mail.parknet.co.jp> (raw)
In-Reply-To: <20250530084648.2434569-1-frank.li@vivo.com>

Yangtao Li <frank.li@vivo.com> writes:

> SB_NOATIME includes SB_NODIRATIME as a subset. Therefore,
> setting SB_NOATIME is sufficient to disable atime updates
> for all files and directories.

SB_NODIRATIME is set at fat_fill_super(). So always SB_NODIRATIME looks
like it is consistent even if meaningless than removing only if remount.

Thanks.

> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
>  fs/fat/inode.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/fat/inode.c b/fs/fat/inode.c
> index 3852bb66358c..5da96c37386d 100644
> --- a/fs/fat/inode.c
> +++ b/fs/fat/inode.c
> @@ -807,7 +807,7 @@ int fat_reconfigure(struct fs_context *fc)
>  	bool new_rdonly;
>  	struct super_block *sb = fc->root->d_sb;
>  	struct msdos_sb_info *sbi = MSDOS_SB(sb);
> -	fc->sb_flags |= SB_NODIRATIME | (sbi->options.isvfat ? 0 : SB_NOATIME);
> +	fc->sb_flags |= sbi->options.isvfat ? SB_NODIRATIME : SB_NOATIME;
>  
>  	sync_filesystem(sb);

-- 
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>

      reply	other threads:[~2025-05-30 10:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-30  8:46 [PATCH] fat: correct superblock flags Yangtao Li
2025-05-30 10:23 ` OGAWA Hirofumi [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87v7piflc5.fsf@mail.parknet.co.jp \
    --to=hirofumi@mail.parknet.co.jp \
    --cc=frank.li@vivo.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox