[dhowells-fs:fscache-iter-2 53/67] fs/fscache/io.c:306: warning: expecting prototype for fscache_clear_page_bits(). Prototype was for __fscache_clear_page_bits() instead

From: kernel test robot
Date: Tue Sep 28 2021 - 18:11:42 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git fscache-iter-2
head: 23676c28d1a9add6ea09f19ca89b71be994a4b79
commit: 1d11750d6c025faf5867ecb731a0f4a36b79ddf2 [53/67] fscache: Add support for writing to the cache
config: x86_64-randconfig-a002-20210928 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project dc6e8dfdfe7efecfda318d43a06fae18b40eb498)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git/commit/?id=1d11750d6c025faf5867ecb731a0f4a36b79ddf2
git remote add dhowells-fs https://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git
git fetch --no-tags dhowells-fs fscache-iter-2
git checkout 1d11750d6c025faf5867ecb731a0f4a36b79ddf2
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash fs/fscache/

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All warnings (new ones prefixed by >>):

fs/fscache/io.c:26: warning: Function parameter or member 'cres' not described in 'fscache_wait_for_operation'
fs/fscache/io.c:26: warning: Excess function parameter 'cookie' description in 'fscache_wait_for_operation'
>> fs/fscache/io.c:306: warning: expecting prototype for fscache_clear_page_bits(). Prototype was for __fscache_clear_page_bits() instead
>> fs/fscache/io.c:367: warning: expecting prototype for fscache_write_to_cache(). Prototype was for __fscache_write_to_cache() instead


vim +306 fs/fscache/io.c

294
295 /**
296 * fscache_clear_page_bits - Clear the PG_fscache bits from a set of pages
297 * @mapping: The netfs inode to use as the source
298 * @start: The start position in @mapping
299 * @len: The amount of data to unlock
300 *
301 * Clear the PG_fscache flag from a sequence of pages and wake up anyone who's
302 * waiting.
303 */
304 void __fscache_clear_page_bits(struct address_space *mapping,
305 loff_t start, size_t len)
> 306 {
307 pgoff_t first = start / PAGE_SIZE;
308 pgoff_t last = (start + len - 1) / PAGE_SIZE;
309 struct page *page;
310
311 if (len) {
312 XA_STATE(xas, &mapping->i_pages, first);
313
314 rcu_read_lock();
315 xas_for_each(&xas, page, last) {
316 end_page_fscache(page);
317 }
318 rcu_read_unlock();
319 }
320 }
321 EXPORT_SYMBOL(__fscache_clear_page_bits);
322
323 /*
324 * Deal with the completion of writing the data to the cache.
325 */
326 static void fscache_wreq_done(void *priv, ssize_t transferred_or_error,
327 bool was_async)
328 {
329 struct fscache_write_request *wreq = priv;
330
331 fscache_clear_page_bits(wreq->mapping, wreq->start, wreq->len);
332
333 if (wreq->term_func)
334 wreq->term_func(wreq->term_func_priv, transferred_or_error,
335 was_async);
336 fscache_end_operation(&wreq->cache_resources);
337 kfree(wreq);
338 }
339
340 /**
341 * fscache_write_to_cache - Save a write to the cache and clear PG_fscache
342 * @cookie: The cookie representing the cache object
343 * @mapping: The netfs inode to use as the source
344 * @start: The start position in @mapping
345 * @len: The amount of data to write back
346 * @i_size: The new size of the inode
347 * @term_func: The function to call upon completion
348 * @term_func_priv: The private data for @term_func
349 *
350 * Helper function for a netfs to write dirty data from an inode into the cache
351 * object that's backing it.
352 *
353 * @start and @len describe the range of the data. This does not need to be
354 * page-aligned, but to satisfy DIO requirements, the cache may expand it up to
355 * the page boundaries on either end. All the pages covering the range must be
356 * marked with PG_fscache.
357 *
358 * If given, @term_func will be called upon completion and supplied with
359 * @term_func_priv. Note that the PG_fscache flags will have been cleared by
360 * this point, so the netfs must retain its own pin on the mapping.
361 */
362 void __fscache_write_to_cache(struct fscache_cookie *cookie,
363 struct address_space *mapping,
364 loff_t start, size_t len, loff_t i_size,
365 netfs_io_terminated_t term_func,
366 void *term_func_priv)
> 367 {

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip