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: <202410200325.SaEJmyZS-lkp@intel.com>
Date: Sun, 20 Oct 2024 04:03:55 +0800
From: kernel test robot <lkp@...el.com>
To: Kuniyuki Iwashima <kuniyu@...zon.com>,
	"David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	David Ahern <dsahern@...nel.org>
Cc: oe-kbuild-all@...ts.linux.dev, netdev@...r.kernel.org,
	Kuniyuki Iwashima <kuniyu@...zon.com>
Subject: Re: [PATCH v1 net-next 05/11] ipv4: Use per-netns RTNL helpers in
 inet_rtm_newaddr().

Hi Kuniyuki,

kernel test robot noticed the following build warnings:

[auto build test WARNING on net-next/main]

url:    https://github.com/intel-lab-lkp/linux/commits/Kuniyuki-Iwashima/rtnetlink-Define-RTNL_FLAG_DOIT_PERNET-for-per-netns-RTNL-doit/20241018-092802
base:   net-next/main
patch link:    https://lore.kernel.org/r/20241018012225.90409-6-kuniyu%40amazon.com
patch subject: [PATCH v1 net-next 05/11] ipv4: Use per-netns RTNL helpers in inet_rtm_newaddr().
config: x86_64-randconfig-122-20241019 (https://download.01.org/0day-ci/archive/20241020/202410200325.SaEJmyZS-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241020/202410200325.SaEJmyZS-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/202410200325.SaEJmyZS-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> net/ipv4/devinet.c:941:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@     expected void *p @@     got struct in_ifaddr [noderef] __rcu *ifa_list @@
   net/ipv4/devinet.c:941:9: sparse:     expected void *p
   net/ipv4/devinet.c:941:9: sparse:     got struct in_ifaddr [noderef] __rcu *ifa_list
>> net/ipv4/devinet.c:941:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@     expected void *p @@     got struct in_ifaddr [noderef] __rcu *ifa_next @@
   net/ipv4/devinet.c:941:9: sparse:     expected void *p
   net/ipv4/devinet.c:941:9: sparse:     got struct in_ifaddr [noderef] __rcu *ifa_next
   net/ipv4/devinet.c: note: in included file:
>> include/linux/inetdevice.h:261:54: sparse: sparse: incorrect type in argument 2 (different address spaces) @@     expected void *p @@     got struct in_device [noderef] __rcu *const ip_ptr @@
   include/linux/inetdevice.h:261:54: sparse:     expected void *p
   include/linux/inetdevice.h:261:54: sparse:     got struct in_device [noderef] __rcu *const ip_ptr
   net/ipv4/devinet.c: note: in included file (through include/linux/inetdevice.h):
>> include/linux/rtnetlink.h:147:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
   include/linux/rtnetlink.h:147:16: sparse:    void [noderef] __rcu *
   include/linux/rtnetlink.h:147:16: sparse:    void *
>> include/linux/rtnetlink.h:147:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
   include/linux/rtnetlink.h:147:16: sparse:    void [noderef] __rcu *
   include/linux/rtnetlink.h:147:16: sparse:    void *
>> include/linux/rtnetlink.h:147:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
   include/linux/rtnetlink.h:147:16: sparse:    void [noderef] __rcu *
   include/linux/rtnetlink.h:147:16: sparse:    void *

vim +941 net/ipv4/devinet.c

   935	
   936	static struct in_ifaddr *find_matching_ifa(struct net *net, struct in_ifaddr *ifa)
   937	{
   938		struct in_device *in_dev = ifa->ifa_dev;
   939		struct in_ifaddr *ifa1;
   940	
 > 941		in_dev_for_each_ifa_rtnl_net(net, ifa1, in_dev) {
   942			if (ifa1->ifa_mask == ifa->ifa_mask &&
   943			    inet_ifa_match(ifa1->ifa_address, ifa) &&
   944			    ifa1->ifa_local == ifa->ifa_local)
   945				return ifa1;
   946		}
   947	
   948		return NULL;
   949	}
   950	

-- 
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