* [cilium:pr/bpf-tproxy 8/8] drivers/net/ethernet/intel/fm10k/fm10k_main.c:885:16: warning: division by zero is undefined
@ 2026-04-17 7:41 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-04-17 7:41 UTC (permalink / raw)
To: Daniel Borkmann; +Cc: llvm, oe-kbuild-all
tree: https://github.com/cilium/linux.git pr/bpf-tproxy
head: 27d1eafb8d37f1b272a991077d3bd1bb312118a9
commit: 27d1eafb8d37f1b272a991077d3bd1bb312118a9 [8/8] bpf: Support SOCK_RCU_FREE sockets in bpf_sk_assign on egress
config: powerpc64-randconfig-001-20260417 (https://download.01.org/0day-ci/archive/20260417/202604171545.woUYCIGr-lkp@intel.com/config)
compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project 5bac06718f502014fade905512f1d26d578a18f3)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260417/202604171545.woUYCIGr-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/202604171545.woUYCIGr-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from drivers/net/ethernet/intel/fm10k/fm10k_main.c:6:
In file included from include/net/ipv6.h:12:
In file included from include/linux/ipv6.h:103:
In file included from include/linux/tcp.h:20:
In file included from include/net/inet_connection_sock.h:21:
In file included from include/net/inet_sock.h:24:
include/net/request_sock.h:117:29: error: use of undeclared identifier 'sock_pfree_ref'; did you mean 'sock_kfree_s'?
117 | skb->destructor == sock_pfree_ref;
| ^~~~~~~~~~~~~~
| sock_kfree_s
include/net/sock.h:1901:6: note: 'sock_kfree_s' declared here
1901 | void sock_kfree_s(struct sock *sk, void *mem, int size);
| ^
In file included from drivers/net/ethernet/intel/fm10k/fm10k_main.c:6:
In file included from include/net/ipv6.h:12:
In file included from include/linux/ipv6.h:103:
In file included from include/linux/tcp.h:20:
In file included from include/net/inet_connection_sock.h:21:
In file included from include/net/inet_sock.h:24:
include/net/request_sock.h:117:26: warning: comparison of distinct pointer types ('void (*)(struct sk_buff *)' and 'void (*)(struct sock *, void *, int)') [-Wcompare-distinct-pointer-types]
117 | skb->destructor == sock_pfree_ref;
| ~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~
>> drivers/net/ethernet/intel/fm10k/fm10k_main.c:885:16: warning: division by zero is undefined [-Wdivision-by-zero]
885 | desc_flags |= FM10K_SET_FLAG(tx_flags, FM10K_TX_FLAGS_CSUM,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
886 | FM10K_TXD_FLAG_CSUM);
| ~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/intel/fm10k/fm10k_main.c:877:26: note: expanded from macro 'FM10K_SET_FLAG'
877 | ((u32)(_input & _flag) / (_flag / _result)))
| ^ ~~~~~~~~~~~~~~~~~
2 warnings and 1 error generated.
vim +885 drivers/net/ethernet/intel/fm10k/fm10k_main.c
76a540d4728a379 Alexander Duyck 2014-09-20 873
76a540d4728a379 Alexander Duyck 2014-09-20 874 #define FM10K_SET_FLAG(_input, _flag, _result) \
76a540d4728a379 Alexander Duyck 2014-09-20 875 ((_flag <= _result) ? \
76a540d4728a379 Alexander Duyck 2014-09-20 876 ((u32)(_input & _flag) * (_result / _flag)) : \
76a540d4728a379 Alexander Duyck 2014-09-20 877 ((u32)(_input & _flag) / (_flag / _result)))
76a540d4728a379 Alexander Duyck 2014-09-20 878
76a540d4728a379 Alexander Duyck 2014-09-20 879 static u8 fm10k_tx_desc_flags(struct sk_buff *skb, u32 tx_flags)
76a540d4728a379 Alexander Duyck 2014-09-20 880 {
76a540d4728a379 Alexander Duyck 2014-09-20 881 /* set type for advanced descriptor with frame checksum insertion */
76a540d4728a379 Alexander Duyck 2014-09-20 882 u32 desc_flags = 0;
76a540d4728a379 Alexander Duyck 2014-09-20 883
76a540d4728a379 Alexander Duyck 2014-09-20 884 /* set checksum offload bits */
76a540d4728a379 Alexander Duyck 2014-09-20 @885 desc_flags |= FM10K_SET_FLAG(tx_flags, FM10K_TX_FLAGS_CSUM,
76a540d4728a379 Alexander Duyck 2014-09-20 886 FM10K_TXD_FLAG_CSUM);
76a540d4728a379 Alexander Duyck 2014-09-20 887
76a540d4728a379 Alexander Duyck 2014-09-20 888 return desc_flags;
76a540d4728a379 Alexander Duyck 2014-09-20 889 }
76a540d4728a379 Alexander Duyck 2014-09-20 890
:::::: The code at line 885 was first introduced by commit
:::::: 76a540d4728a379e022fb2e2e8766d502b6d345c fm10k: Add support for netdev offloads
:::::: TO: Alexander Duyck <alexander.h.duyck@intel.com>
:::::: CC: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-04-17 7:42 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-17 7:41 [cilium:pr/bpf-tproxy 8/8] drivers/net/ethernet/intel/fm10k/fm10k_main.c:885:16: warning: division by zero is undefined kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox