From: Baokun Li <libaokun@linux.alibaba.com>
To: Jan Kara <jack@suse.cz>
Cc: Ted Tso <tytso@mit.edu>,
linux-ext4@vger.kernel.org,
Tigran Aivazian <aivazian.tigran@gmail.com>
Subject: Re: [PATCH] ext4: Fix spurious message about orphan cleanup on RO fs
Date: Tue, 4 Aug 2026 18:53:00 +0800 [thread overview]
Message-ID: <d13a2edd-34eb-42cf-a4c5-626eb750a130@linux.alibaba.com> (raw)
In-Reply-To: <20260803160037.64285-2-jack@suse.cz>
On 2026/8/4 00:00, Jan Kara wrote:
> When orphan_file feature is enabled, ext4_orphan_cleanup() was always
> walking through the orphan file looking for orphan inodes. This is
> mostly harmless but for read-only filesystem it results in spurious
> "orphan cleanup on readonly fs" message and in other cornercases it
> could result in similar somewhat misleading messages. Skip orphan
> cleanup if the orphan file is empty to avoid confusing messages.
>
> Fixes: 02f310fcf47f ("ext4: Speedup ext4 orphan inode handling")
> Reported-by: Tigran Aivazian <aivazian.tigran@gmail.com>
> Signed-off-by: Jan Kara <jack@suse.cz>
Looks good to me.
Reviewed-by: Baokun Li <libaokun@linux.alibaba.com>
> ---
> fs/ext4/orphan.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/ext4/orphan.c b/fs/ext4/orphan.c
> index 64ea47624233..2a44998a6c2e 100644
> --- a/fs/ext4/orphan.c
> +++ b/fs/ext4/orphan.c
> @@ -388,7 +388,7 @@ void ext4_orphan_cleanup(struct super_block *sb, struct ext4_super_block *es)
> struct ext4_orphan_info *oi = &EXT4_SB(sb)->s_orphan_info;
> int inodes_per_ob = ext4_inodes_per_orphan_block(sb);
>
> - if (!es->s_last_orphan && !oi->of_blocks) {
> + if (!es->s_last_orphan && ext4_orphan_file_empty(sb)) {
> ext4_debug("no orphan inodes to clean up\n");
> return;
> }
next prev parent reply other threads:[~2026-08-04 10:53 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-03 16:00 [PATCH] ext4: Fix spurious message about orphan cleanup on RO fs Jan Kara
2026-08-04 7:06 ` Tigran Aivazian
2026-08-04 10:53 ` Baokun Li [this message]
2026-08-06 15:00 ` Theodore Ts'o
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=d13a2edd-34eb-42cf-a4c5-626eb750a130@linux.alibaba.com \
--to=libaokun@linux.alibaba.com \
--cc=aivazian.tigran@gmail.com \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=tytso@mit.edu \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.