From: kernel test robot <lkp@intel.com>
To: Pavel Begunkov <asml.silence@gmail.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [isilence:zcrx/next 25/27] net/core/page_pool.c:691:19: warning: variable 'niov' set but not used
Date: Wed, 15 May 2024 15:50:37 +0800 [thread overview]
Message-ID: <202405151524.RBc0Q1A4-lkp@intel.com> (raw)
tree: https://github.com/isilence/linux zcrx/next
head: 8f99f44fc1fabf943cf0d1989f0afdff15e064e8
commit: 26fa2c4456e3c703b1dc7d61ec32180e4e7864d6 [25/27] wip: bnxt
config: riscv-defconfig (https://download.01.org/0day-ci/archive/20240515/202405151524.RBc0Q1A4-lkp@intel.com/config)
compiler: clang version 19.0.0git (https://github.com/llvm/llvm-project b910bebc300dafb30569cecc3017b446ea8eafa0)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240515/202405151524.RBc0Q1A4-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/202405151524.RBc0Q1A4-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from net/core/page_pool.c:13:
In file included from include/net/page_pool/helpers.h:55:
In file included from include/net/page_pool/types.h:7:
In file included from include/linux/ptr_ring.h:26:
In file included from include/linux/mm.h:2208:
include/linux/vmstat.h:522:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
522 | return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
| ~~~~~~~~~~~ ^ ~~~
>> net/core/page_pool.c:691:19: warning: variable 'niov' set but not used [-Wunused-but-set-variable]
691 | struct net_iov *niov;
| ^
2 warnings generated.
vim +/niov +691 net/core/page_pool.c
675
676 /* Only allow direct recycling in special circumstances, into the
677 * alloc side cache. E.g. during RX-NAPI processing for XDP_DROP use-case.
678 *
679 * Caller must provide appropriate safe context.
680 */
681 static bool page_pool_recycle_in_cache(netmem_ref netmem,
682 struct page_pool *pool)
683 {
684 if (unlikely(pool->alloc.count == PP_ALLOC_CACHE_SIZE)) {
685 recycle_stat_inc(pool, cache_full);
686 return false;
687 }
688
689 if (netmem_is_net_iov(netmem)) {
690 // struct io_zc_rx_buf *buf;
> 691 struct net_iov *niov;
692
693 niov = netmem_to_net_iov(netmem);
694 // buf = container_of(niov, struct io_zc_rx_buf, niov);
695 // printk(KERN_INFO "----- page_pool_recycle_in_cache: recycling page, physical address: %#llx\n", (unsigned long long)page_to_phys(buf->page));
696 }
697
698 /* Caller MUST have verified/know (page_ref_count(page) == 1) */
699 pool->alloc.cache[pool->alloc.count++] = netmem;
700 recycle_stat_inc(pool, cached);
701 return true;
702 }
703
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2024-05-15 7:51 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=202405151524.RBc0Q1A4-lkp@intel.com \
--to=lkp@intel.com \
--cc=asml.silence@gmail.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).