From: Yuezhang Mo <Yuezhang.Mo@sony.com>
To: linux-erofs@lists.ozlabs.org
Cc: Gao Xiang <xiang@kernel.org>, Chao Yu <chao@kernel.org>,
Yue Hu <zbestahu@gmail.com>,
Jeffle Xu <jefflexu@linux.alibaba.com>,
Sandeep Dhavale <dhavale@google.com>,
Hongbo Li <lihongbo22@huawei.com>,
Chunhai Guo <guochunhai@vivo.com>,
Yuezhang Mo <Yuezhang.Mo@sony.com>,
Friendy Su <friendy.su@sony.com>,
Daniel Palmer <daniel.palmer@sony.com>
Subject: [PATCH v1] erofs: remove the guard of showing domain_id and fsid
Date: Mon, 30 Mar 2026 15:32:36 +0800 [thread overview]
Message-ID: <20260330073235.3328579-2-Yuezhang.Mo@sony.com> (raw)
This change fixes an issue where domain_id was not shown when
CONFIG_EROFS_FS_PAGE_CACHE_SHARE is enabled, as this configuration
is mutually exclusive with CONFIG_EROFS_FS_ONDEMAND.
Both domain_id and fsid fields are present in struct erofs_sb_info
regardless of configuration. They are not set if the configurations
are not enabled, and remain NULL. Therefore, the conditional guard
in erofs_show_options() are unnecessary and can be removed.
Signed-off-by: Yuezhang Mo <Yuezhang.Mo@sony.com>
Reviewed-by: Friendy Su <friendy.su@sony.com>
Reviewed-by: Daniel Palmer <daniel.palmer@sony.com>
---
fs/erofs/super.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/fs/erofs/super.c b/fs/erofs/super.c
index 972a0c82198d..be028cdf902c 100644
--- a/fs/erofs/super.c
+++ b/fs/erofs/super.c
@@ -1095,12 +1095,10 @@ static int erofs_show_options(struct seq_file *seq, struct dentry *root)
seq_puts(seq, ",dax=never");
if (erofs_is_fileio_mode(sbi) && test_opt(opt, DIRECT_IO))
seq_puts(seq, ",directio");
- if (IS_ENABLED(CONFIG_EROFS_FS_ONDEMAND)) {
- if (sbi->fsid)
- seq_printf(seq, ",fsid=%s", sbi->fsid);
- if (sbi->domain_id)
- seq_printf(seq, ",domain_id=%s", sbi->domain_id);
- }
+ if (sbi->fsid)
+ seq_printf(seq, ",fsid=%s", sbi->fsid);
+ if (sbi->domain_id)
+ seq_printf(seq, ",domain_id=%s", sbi->domain_id);
if (sbi->dif0.fsoff)
seq_printf(seq, ",fsoffset=%llu", sbi->dif0.fsoff);
if (test_opt(opt, INODE_SHARE))
--
2.43.0
next reply other threads:[~2026-03-30 7:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-30 7:32 Yuezhang Mo [this message]
2026-03-30 7:47 ` [PATCH v1] erofs: remove the guard of showing domain_id and fsid Gao Xiang
2026-03-30 8:48 ` Yuezhang.Mo
2026-03-30 8:51 ` Gao Xiang
2026-03-30 7:48 ` Hongbo Li
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=20260330073235.3328579-2-Yuezhang.Mo@sony.com \
--to=yuezhang.mo@sony.com \
--cc=chao@kernel.org \
--cc=daniel.palmer@sony.com \
--cc=dhavale@google.com \
--cc=friendy.su@sony.com \
--cc=guochunhai@vivo.com \
--cc=jefflexu@linux.alibaba.com \
--cc=lihongbo22@huawei.com \
--cc=linux-erofs@lists.ozlabs.org \
--cc=xiang@kernel.org \
--cc=zbestahu@gmail.com \
/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