lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202507060106.A5xgr1Rs-lkp@intel.com>
Date: Sun, 6 Jul 2025 01:33:21 +0800
From: kernel test robot <lkp@...el.com>
To: Eric Woudstra <ericwouds@...il.com>,
	Pablo Neira Ayuso <pablo@...filter.org>,
	Jozsef Kadlecsik <kadlec@...filter.org>,
	Nikolay Aleksandrov <razor@...ckwall.org>,
	Ido Schimmel <idosch@...dia.com>,
	"David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	Simon Horman <horms@...nel.org>
Cc: oe-kbuild-all@...ts.linux.dev, netdev@...r.kernel.org,
	netfilter-devel@...r.kernel.org, bridge@...ts.linux.dev,
	Eric Woudstra <ericwouds@...il.com>
Subject: Re: [PATCH v13 nf-next 1/3] netfilter: utils: nf_checksum(_partial)
 correct data!=networkheader

Hi Eric,

kernel test robot noticed the following build warnings:

[auto build test WARNING on netfilter-nf/main]
[also build test WARNING on horms-ipvs/master linus/master v6.16-rc4 next-20250704]
[cannot apply to nf-next/master]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Eric-Woudstra/netfilter-utils-nf_checksum-_partial-correct-data-networkheader/20250705-031418
base:   https://git.kernel.org/pub/scm/linux/kernel/git/netfilter/nf.git main
patch link:    https://lore.kernel.org/r/20250704191135.1815969-2-ericwouds%40gmail.com
patch subject: [PATCH v13 nf-next 1/3] netfilter: utils: nf_checksum(_partial) correct data!=networkheader
config: x86_64-randconfig-121-20250705 (https://download.01.org/0day-ci/archive/20250706/202507060106.A5xgr1Rs-lkp@intel.com/config)
compiler: clang version 20.1.7 (https://github.com/llvm/llvm-project 6146a88f60492b520a36f8f8f3231e15f3cc6082)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250706/202507060106.A5xgr1Rs-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202507060106.A5xgr1Rs-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> net/netfilter/utils.c:131:24: sparse: sparse: incorrect type in return expression (different base types) @@     expected restricted __sum16 @@     got int @@
   net/netfilter/utils.c:131:24: sparse:     expected restricted __sum16
   net/netfilter/utils.c:131:24: sparse:     got int
   net/netfilter/utils.c:155:24: sparse: sparse: incorrect type in return expression (different base types) @@     expected restricted __sum16 @@     got int @@
   net/netfilter/utils.c:155:24: sparse:     expected restricted __sum16
   net/netfilter/utils.c:155:24: sparse:     got int

vim +131 net/netfilter/utils.c

   122	
   123	__sum16 nf_checksum(struct sk_buff *skb, unsigned int hook,
   124			    unsigned int dataoff, u8 protocol,
   125			    unsigned short family)
   126	{
   127		unsigned int nhpull = skb_network_header(skb) - skb->data;
   128		__sum16 csum = 0;
   129	
   130		if (!pskb_may_pull(skb, nhpull))
 > 131			return -ENOMEM;
   132		__skb_pull(skb, nhpull);
   133		switch (family) {
   134		case AF_INET:
   135			csum = nf_ip_checksum(skb, hook, dataoff - nhpull, protocol);
   136			break;
   137		case AF_INET6:
   138			csum = nf_ip6_checksum(skb, hook, dataoff - nhpull, protocol);
   139			break;
   140		}
   141		__skb_push(skb, nhpull);
   142	
   143		return csum;
   144	}
   145	EXPORT_SYMBOL_GPL(nf_checksum);
   146	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ