From: Ye Bin <yebin@huaweicloud.com>
To: tytso@mit.edu, adilger.kernel@dilger.ca, linux-ext4@vger.kernel.org
Cc: jack@suse.cz
Subject: [PATCH v2 2/8] ext4: introduce EXPORT_SYMBOL_FOR_EXT4_TEST() helper
Date: Thu, 12 Mar 2026 21:12:47 +0800 [thread overview]
Message-ID: <20260312131253.366296-3-yebin@huaweicloud.com> (raw)
In-Reply-To: <20260312131253.366296-1-yebin@huaweicloud.com>
From: Ye Bin <yebin10@huawei.com>
Introduce EXPORT_SYMBOL_FOR_EXT4_TEST() helper for kuint test.
Signed-off-by: Ye Bin <yebin10@huawei.com>
---
fs/ext4/ext4.h | 5 +++++
fs/ext4/mballoc.c | 3 ---
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h
index 4cb2345339ba..8bf2a2ac4787 100644
--- a/fs/ext4/ext4.h
+++ b/fs/ext4/ext4.h
@@ -3945,6 +3945,11 @@ static inline bool ext4_inode_can_atomic_write(struct inode *inode)
extern int ext4_block_write_begin(handle_t *handle, struct folio *folio,
loff_t pos, unsigned len,
get_block_t *get_block);
+
+#if IS_ENABLED(CONFIG_EXT4_KUNIT_TESTS)
+#define EXPORT_SYMBOL_FOR_EXT4_TEST(sym) \
+ EXPORT_SYMBOL_FOR_MODULES(sym, "ext4-test")
+#endif
#endif /* __KERNEL__ */
#endif /* _EXT4_H */
diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c
index 842a604ae5db..97b3f0e4c80b 100644
--- a/fs/ext4/mballoc.c
+++ b/fs/ext4/mballoc.c
@@ -7193,9 +7193,6 @@ ext4_mballoc_query_range(
}
#if IS_ENABLED(CONFIG_EXT4_KUNIT_TESTS)
-#define EXPORT_SYMBOL_FOR_EXT4_TEST(sym) \
- EXPORT_SYMBOL_FOR_MODULES(sym, "ext4-test")
-
void mb_clear_bits_test(void *bm, int cur, int len)
{
mb_clear_bits(bm, cur, len);
--
2.34.1
next prev parent reply other threads:[~2026-03-12 13:14 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-12 13:12 [PATCH v2 0/8] Fix some issues about ext4-test Ye Bin
2026-03-12 13:12 ` [PATCH v2 1/8] ext4: fix mballoc-test.c is not compiled when EXT4_KUNIT_TESTS=M Ye Bin
2026-03-12 13:12 ` Ye Bin [this message]
2026-03-12 13:12 ` [PATCH v2 3/8] ext4: fix extents-test.c " Ye Bin
2026-03-12 13:12 ` [PATCH v2 4/8] ext4: fix miss unlock 'sb->s_umount' in extents_kunit_init() Ye Bin
2026-03-12 13:12 ` [PATCH v2 5/8] ext4: fix miss free super_block in extents_kunit_exit() Ye Bin
2026-03-12 13:12 ` [PATCH v2 6/8] ext4: fix the error handling process in extents_kunit_init) Ye Bin
2026-03-12 13:12 ` [PATCH v2 7/8] ext4: fix possible null-ptr-deref in extents_kunit_exit() Ye Bin
2026-03-12 13:12 ` [PATCH v2 8/8] ext4: fix possible null-ptr-deref in mbt_kunit_exit() Ye Bin
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=20260312131253.366296-3-yebin@huaweicloud.com \
--to=yebin@huaweicloud.com \
--cc=adilger.kernel@dilger.ca \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox