From: kernel test robot <lkp@intel.com>
To: Chao Yu <chao@kernel.org>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [chao:feature/test/cache 14/14] fs/f2fs/cache_test.c:280:27: error: implicit declaration of function 'f2fs_cache_test_and_set_referenced'; did you mean 'f2fs_cache_test_and_clear_referenced'?
Date: Wed, 02 Sep 2026 12:02:53 +0800 [thread overview]
Message-ID: <202609021227.BGM2MWwj-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/chao/linux.git feature/test/cache
head: 80184bf033f71e094078e92116db41b8329e136a
commit: 80184bf033f71e094078e92116db41b8329e136a [14/14] f2fs: cache: introduce KUnit test suite
config: sh-randconfig-r062-20260901 (https://download.01.org/0day-ci/archive/20260902/202609021227.BGM2MWwj-lkp@intel.com/config)
compiler: sh4-linux-gcc (GCC) 10.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260902/202609021227.BGM2MWwj-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202609021227.BGM2MWwj-lkp@intel.com/
All errors (new ones prefixed by >>):
In file included from include/linux/err.h:5,
from include/kunit/assert.h:12,
from include/kunit/test.h:12,
from fs/f2fs/cache_test.c:9:
fs/f2fs/cache_test.c: In function 'test_cache_block_states_and_bitlocks':
>> fs/f2fs/cache_test.c:280:27: error: implicit declaration of function 'f2fs_cache_test_and_set_referenced'; did you mean 'f2fs_cache_test_and_clear_referenced'? [-Werror=implicit-function-declaration]
280 | KUNIT_EXPECT_FALSE(test, f2fs_cache_test_and_set_referenced(entry));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:76:40: note: in definition of macro 'likely'
76 | # define likely(x) __builtin_expect(!!(x), 1)
| ^
include/kunit/test.h:810:2: note: in expansion of macro 'KUNIT_UNARY_ASSERTION'
810 | KUNIT_UNARY_ASSERTION(test, \
| ^~~~~~~~~~~~~~~~~~~~~
include/kunit/test.h:1017:2: note: in expansion of macro 'KUNIT_FALSE_MSG_ASSERTION'
1017 | KUNIT_FALSE_MSG_ASSERTION(test, \
| ^~~~~~~~~~~~~~~~~~~~~~~~~
include/kunit/test.h:1014:2: note: in expansion of macro 'KUNIT_EXPECT_FALSE_MSG'
1014 | KUNIT_EXPECT_FALSE_MSG(test, condition, NULL)
| ^~~~~~~~~~~~~~~~~~~~~~
fs/f2fs/cache_test.c:280:2: note: in expansion of macro 'KUNIT_EXPECT_FALSE'
280 | KUNIT_EXPECT_FALSE(test, f2fs_cache_test_and_set_referenced(entry));
| ^~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +280 fs/f2fs/cache_test.c
241
242 /* Module 5: F2FS_BLOCK_* block states and bit-locks */
243 static void test_cache_block_states_and_bitlocks(struct kunit *test)
244 {
245 struct f2fs_cache_test_ctx *ctx = test->priv;
246 struct f2fs_cached_block_list *cache = META_CACHE(&ctx->sbi);
247 struct f2fs_cached_block *entry;
248
249 entry = f2fs_grab_cache(cache, 1, F2FS_CACHE_CREATE);
250 KUNIT_ASSERT_FALSE(test, IS_ERR(entry));
251
252 /* Lock / Trylock / Unlock */
253 KUNIT_EXPECT_TRUE(test, f2fs_trylock_cache(entry));
254 KUNIT_EXPECT_TRUE(test, f2fs_cache_test_locked(entry));
255 KUNIT_EXPECT_FALSE(test, f2fs_trylock_cache(entry));
256 f2fs_unlock_cache(entry);
257 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_locked(entry));
258
259 /* Uptodate */
260 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_uptodate(entry));
261 f2fs_cache_set_uptodate(entry);
262 KUNIT_EXPECT_TRUE(test, f2fs_cache_test_uptodate(entry));
263 f2fs_cache_clear_uptodate(entry);
264 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_uptodate(entry));
265
266 /* Dirty */
267 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_dirty(entry));
268 f2fs_mark_cache_dirty(entry);
269 KUNIT_EXPECT_TRUE(test, f2fs_cache_test_dirty(entry));
270 KUNIT_EXPECT_TRUE(test, f2fs_cache_test_and_clear_dirty(entry));
271 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_dirty(entry));
272
273 /* Inline */
274 f2fs_cache_set_inline(entry);
275 KUNIT_EXPECT_TRUE(test, f2fs_cache_test_inline(entry));
276 f2fs_cache_clear_inline(entry);
277 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_inline(entry));
278
279 /* Referenced */
> 280 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_and_set_referenced(entry));
281 KUNIT_EXPECT_TRUE(test, f2fs_cache_test_and_set_referenced(entry));
282 KUNIT_EXPECT_TRUE(test, f2fs_cache_test_and_clear_referenced(entry));
283 KUNIT_EXPECT_FALSE(test, f2fs_cache_test_and_clear_referenced(entry));
284 }
285
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-09-02 4:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202609021227.BGM2MWwj-lkp@intel.com \
--to=lkp@intel.com \
--cc=chao@kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
/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.