From: kernel test robot <lkp@intel.com>
To: aubrey.li@linux.intel.com
Cc: oe-kbuild-all@lists.linux.dev
Subject: [anolis-intel-cloud:devel-5.10 1/1] drivers/net/ethernet/3snic/sssnic/nic/sss_nic_rx.c:718:13: error: variable '_wqe_num' set but not used
Date: Tue, 25 Nov 2025 21:53:10 +0800 [thread overview]
Message-ID: <202511252130.W71CwEGz-lkp@intel.com> (raw)
Hi Steven,
FYI, the error/warning still remains.
tree: https://gitee.com/anolis/intel-cloud-kernel.git devel-5.10
head: b17ac1b8b619f685007233e0a43f915bbd5d194c
commit: 3f63e55de387ff1ef9405747ecd67ea49dd18ed9 [1/1] Net: ethernet: Support 3snic 3s9xx network card
config: x86_64-anolis-intel-cloud-devel-5.10 (https://download.01.org/0day-ci/archive/20251125/202511252130.W71CwEGz-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.4.0-5) 12.4.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251125/202511252130.W71CwEGz-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/202511252130.W71CwEGz-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/net/ethernet/3snic/sssnic/nic/sss_nic_rx.c: In function 'sss_nic_recv_one_packet':
>> drivers/net/ethernet/3snic/sssnic/nic/sss_nic_rx.c:718:13: error: variable '_wqe_num' set but not used [-Werror=unused-but-set-variable]
718 | u16 _wqe_num = 1; \
| ^~~~~~~~
drivers/net/ethernet/3snic/sssnic/nic/sss_nic_rx.c:805:9: note: in expansion of macro 'sss_nic_bpf_prog_run_xdp'
805 | sss_nic_bpf_prog_run_xdp(rq_desc, pkt_len, &xdp_result);
| ^~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +/_wqe_num +718 drivers/net/ethernet/3snic/sssnic/nic/sss_nic_rx.c
712
713 #define sss_nic_bpf_prog_run_xdp(rq_desc, pkt_size, result) \
714 do { \
715 struct bpf_prog *xdp_prog = NULL; \
716 struct sss_nic_rx_desc *rx_desc = NULL; \
717 struct xdp_buff xdp; \
> 718 u16 _wqe_num = 1; \
719 u8 *_data = NULL; \
720 u32 _ret; \
721 \
722 rcu_read_lock(); \
723 \
724 xdp_prog = READ_ONCE((rq_desc)->xdp_prog); \
725 if (!xdp_prog) { \
726 *(result) = SSSNIC_XDP_PKT_PASS; \
727 } else if (unlikely((pkt_size) > (rq_desc)->buf_len)) { \
728 SSSNIC_RQ_STATS_INC((rq_desc), large_xdp_pkts); \
729 _wqe_num = (u16)((pkt_size) >> (rq_desc)->buff_size_shift) + \
730 (((pkt_size) & ((rq_desc)->buf_len - 1)) ? 1 : 0); \
731 SSSNIC_RQ_STATS_INC((rq_desc), xdp_dropped); \
732 sss_nic_xdp_update_rx_info((rq_desc), _wqe_num); \
733 *(result) = SSSNIC_XDP_PKT_DROP; \
734 } else { \
735 rx_desc = &(rq_desc)->rx_desc_group[(rq_desc)->ci & (rq_desc)->qid_mask]; \
736 _data = (u8 *)page_address(rx_desc->page) + rx_desc->page_offset; \
737 prefetch(_data); \
738 dma_sync_single_range_for_cpu((rq_desc)->dev, rx_desc->buf_daddr, \
739 rx_desc->page_offset, (rq_desc)->buf_len, \
740 DMA_FROM_DEVICE); \
741 xdp.data = _data; \
742 xdp.data_hard_start = xdp.data; \
743 xdp.data_end = xdp.data + (pkt_size); \
744 SSSNIC_SET_XDP_FRAME_SZ(&xdp, (rq_desc)->buf_len); \
745 SSSNIC_XDP_SET_DATA_META_INVALID(&xdp); \
746 prefetchw(xdp.data_hard_start); \
747 \
748 _ret = bpf_prog_run_xdp(xdp_prog, &xdp); \
749 if (_ret == XDP_PASS) { \
750 *(result) = SSSNIC_XDP_PKT_PASS; \
751 } else { \
752 *(result) = SSSNIC_XDP_PKT_DROP; \
753 if (_ret != XDP_DROP) { \
754 SSSNIC_BDF_WARN_INVALID_XDP_ACTION((rq_desc)->netdev, \
755 xdp_prog, _ret); \
756 } \
757 SSSNIC_RQ_STATS_INC((rq_desc), xdp_dropped); \
758 sss_nic_xdp_update_rx_info((rq_desc), _wqe_num); \
759 } \
760 } \
761 \
762 rcu_read_unlock(); \
763 } while (0)
764 #endif
765
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2025-11-25 13:53 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=202511252130.W71CwEGz-lkp@intel.com \
--to=lkp@intel.com \
--cc=aubrey.li@linux.intel.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 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.