From: kernel test robot <lkp@intel.com>
To: kernel@openeuler.org, Wang Liang <wangliang74@huawei.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [openeuler:OLK-6.6 3098/3098] net/oenetcls/oenetcls_main.c:990:13: warning: 'set_netdev_xps_queue' defined but not used
Date: Tue, 4 Nov 2025 06:01:52 +0800 [thread overview]
Message-ID: <202511040552.16dcWFcA-lkp@intel.com> (raw)
Hi Wang,
First bad commit (maybe != root cause):
tree: https://gitee.com/openeuler/kernel.git OLK-6.6
head: a29fc03bd0ddaf7388cf31604ef5bd9807585109
commit: 22d4075bf5ef29ba4b329f954ac28a7de1d69a65 [3098/3098] net/oenetcls: remove oenetcls trace hook
config: x86_64-randconfig-121-20251104 (https://download.01.org/0day-ci/archive/20251104/202511040552.16dcWFcA-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251104/202511040552.16dcWFcA-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/202511040552.16dcWFcA-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> net/oenetcls/oenetcls_main.c:990:13: warning: 'set_netdev_xps_queue' defined but not used [-Wunused-function]
990 | static void set_netdev_xps_queue(bool enable)
| ^~~~~~~~~~~~~~~~~~~~
In file included from include/linux/string.h:294,
from include/linux/bitmap.h:11,
from include/linux/cpumask.h:12,
from arch/x86/include/asm/cpumask.h:5,
from arch/x86/include/asm/msr.h:11,
from arch/x86/include/asm/processor.h:23,
from arch/x86/include/asm/timex.h:5,
from include/linux/timex.h:67,
from include/linux/time32.h:13,
from include/linux/time.h:60,
from include/linux/stat.h:19,
from include/linux/module.h:13,
from net/oenetcls/oenetcls_main.c:2:
In function 'strncpy',
inlined from 'oecls_filter_restore' at net/oenetcls/oenetcls_main.c:459:2:
include/linux/fortify-string.h:81:33: warning: '__builtin_strncpy' specified bound 16 equals destination size [-Wstringop-truncation]
81 | #define __underlying_strncpy __builtin_strncpy
| ^
include/linux/fortify-string.h:165:16: note: in expansion of macro '__underlying_strncpy'
165 | return __underlying_strncpy(p, q, size);
| ^~~~~~~~~~~~~~~~~~~~
In function 'strncpy',
inlined from 'oecls_filter_enable.constprop' at net/oenetcls/oenetcls_main.c:413:2:
include/linux/fortify-string.h:81:33: warning: '__builtin_strncpy' specified bound 16 equals destination size [-Wstringop-truncation]
81 | #define __underlying_strncpy __builtin_strncpy
| ^
include/linux/fortify-string.h:165:16: note: in expansion of macro '__underlying_strncpy'
165 | return __underlying_strncpy(p, q, size);
| ^~~~~~~~~~~~~~~~~~~~
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for PTP_1588_CLOCK
Depends on [n]: NET [=y] && POSIX_TIMERS [=n]
Selected by [m]:
- SXE [=m] && NETDEVICES [=y] && ETHERNET [=y] && NET_VENDOR_LINKDATA [=y] && (X86 [=y] || ARM64) && PCI [=y]
- SXE_VF [=m] && NETDEVICES [=y] && ETHERNET [=y] && NET_VENDOR_LINKDATA [=y] && (X86 [=y] || ARM64) && PCI [=y]
vim +/set_netdev_xps_queue +990 net/oenetcls/oenetcls_main.c
4bed6ba0e88f50 Wang Liang 2025-08-26 989
4bed6ba0e88f50 Wang Liang 2025-08-26 @990 static void set_netdev_xps_queue(bool enable)
4bed6ba0e88f50 Wang Liang 2025-08-26 991 {
4bed6ba0e88f50 Wang Liang 2025-08-26 992 const struct cpumask clear_mask = { 0 };
4bed6ba0e88f50 Wang Liang 2025-08-26 993 struct oecls_netdev_info *oecls_dev;
4bed6ba0e88f50 Wang Liang 2025-08-26 994 const struct cpumask *cpu_mask;
4bed6ba0e88f50 Wang Liang 2025-08-26 995 int rxq_id, devid, cpu, nid;
4bed6ba0e88f50 Wang Liang 2025-08-26 996
4bed6ba0e88f50 Wang Liang 2025-08-26 997 for_each_oecls_netdev(devid, oecls_dev) {
4bed6ba0e88f50 Wang Liang 2025-08-26 998 for (rxq_id = 0; rxq_id < oecls_dev->rxq_num; rxq_id++) {
4bed6ba0e88f50 Wang Liang 2025-08-26 999 cpu = oecls_dev->rxq[rxq_id].affinity_cpu;
4bed6ba0e88f50 Wang Liang 2025-08-26 1000 nid = cpu_to_node(cpu);
4bed6ba0e88f50 Wang Liang 2025-08-26 1001 if (enable)
4bed6ba0e88f50 Wang Liang 2025-08-26 1002 cpu_mask = cpumask_of_node(nid);
4bed6ba0e88f50 Wang Liang 2025-08-26 1003 else
4bed6ba0e88f50 Wang Liang 2025-08-26 1004 cpu_mask = &clear_mask;
4bed6ba0e88f50 Wang Liang 2025-08-26 1005
4bed6ba0e88f50 Wang Liang 2025-08-26 1006 netif_set_xps_queue_wrapper(oecls_dev->netdev, rxq_id, cpu_mask);
4bed6ba0e88f50 Wang Liang 2025-08-26 1007 }
4bed6ba0e88f50 Wang Liang 2025-08-26 1008 }
4bed6ba0e88f50 Wang Liang 2025-08-26 1009 }
4bed6ba0e88f50 Wang Liang 2025-08-26 1010
:::::: The code at line 990 was first introduced by commit
:::::: 4bed6ba0e88f50484fd5fb06bd993727b981b718 net/oenetcls: introduce oenetcls for network optimization
:::::: TO: Wang Liang <wangliang74@huawei.com>
:::::: CC: Wang Liang <wangliang74@huawei.com>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2025-11-03 22:02 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=202511040552.16dcWFcA-lkp@intel.com \
--to=lkp@intel.com \
--cc=kernel@openeuler.org \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=wangliang74@huawei.com \
/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.