From: kernel test robot <lkp@intel.com>
To: Kuniyuki Iwashima <kuniyu@amazon.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
David Ahern <dsahern@kernel.org>
Cc: oe-kbuild-all@lists.linux.dev, netdev@vger.kernel.org,
Kuniyuki Iwashima <kuniyu@amazon.com>
Subject: Re: [PATCH v1 net-next 11/11] ipv4: Convert devinet_ioctl to per-netns RTNL.
Date: Sun, 20 Oct 2024 11:07:43 +0800 [thread overview]
Message-ID: <202410201022.bZkEgzK5-lkp@intel.com> (raw)
In-Reply-To: <20241018012225.90409-12-kuniyu@amazon.com>
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-12-kuniyu%40amazon.com
patch subject: [PATCH v1 net-next 11/11] ipv4: Convert devinet_ioctl to per-netns RTNL.
config: x86_64-randconfig-122-20241019 (https://download.01.org/0day-ci/archive/20241020/202410201022.bZkEgzK5-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/202410201022.bZkEgzK5-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/202410201022.bZkEgzK5-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
net/ipv4/devinet.c:674:47: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void *p @@ got struct in_ifaddr [noderef] __rcu * @@
net/ipv4/devinet.c:674:47: sparse: expected void *p
net/ipv4/devinet.c:674:47: sparse: got struct in_ifaddr [noderef] __rcu *
net/ipv4/devinet.c:775:65: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void *p @@ got struct in_ifaddr [noderef] __rcu * @@
net/ipv4/devinet.c:775:65: sparse: expected void *p
net/ipv4/devinet.c:775:65: sparse: got struct in_ifaddr [noderef] __rcu *
net/ipv4/devinet.c:783:73: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void *p @@ got struct in_ifaddr [noderef] __rcu * @@
net/ipv4/devinet.c:783:73: sparse: expected void *p
net/ipv4/devinet.c:783:73: sparse: got struct in_ifaddr [noderef] __rcu *
net/ipv4/devinet.c:945: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:945:9: sparse: expected void *p
net/ipv4/devinet.c:945:9: sparse: got struct in_ifaddr [noderef] __rcu *ifa_list
net/ipv4/devinet.c:945: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:945:9: sparse: expected void *p
net/ipv4/devinet.c:945:9: sparse: got struct in_ifaddr [noderef] __rcu *ifa_next
net/ipv4/devinet.c:1135:63: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void *p @@ got struct in_ifaddr [noderef] __rcu * @@
net/ipv4/devinet.c:1135:63: sparse: expected void *p
net/ipv4/devinet.c:1135:63: sparse: got struct in_ifaddr [noderef] __rcu *
net/ipv4/devinet.c:1149:63: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void *p @@ got struct in_ifaddr [noderef] __rcu * @@
net/ipv4/devinet.c:1149:63: sparse: expected void *p
net/ipv4/devinet.c:1149:63: sparse: got struct in_ifaddr [noderef] __rcu *
net/ipv4/devinet.c:1313: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:1313:9: sparse: expected void *p
net/ipv4/devinet.c:1313:9: sparse: got struct in_ifaddr [noderef] __rcu *ifa_list
>> net/ipv4/devinet.c:1313:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void *p @@ got struct in_ifaddr [noderef] __rcu *const ifa_next @@
net/ipv4/devinet.c:1313:9: sparse: expected void *p
net/ipv4/devinet.c:1313:9: sparse: got struct in_ifaddr [noderef] __rcu *const 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:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
include/linux/rtnetlink.h:153:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
include/linux/rtnetlink.h:153:16: sparse: void [noderef] __rcu *
include/linux/rtnetlink.h:153:16: sparse: void *
vim +1313 net/ipv4/devinet.c
1299
1300 int inet_gifconf(struct net_device *dev, char __user *buf, int len, int size)
1301 {
1302 struct in_device *in_dev = __in_dev_get_rtnl_net(dev);
1303 const struct in_ifaddr *ifa;
1304 struct ifreq ifr;
1305 int done = 0;
1306
1307 if (WARN_ON(size > sizeof(struct ifreq)))
1308 goto out;
1309
1310 if (!in_dev)
1311 goto out;
1312
> 1313 in_dev_for_each_ifa_rtnl_net(dev_net(dev), ifa, in_dev) {
1314 if (!buf) {
1315 done += size;
1316 continue;
1317 }
1318 if (len < size)
1319 break;
1320 memset(&ifr, 0, sizeof(struct ifreq));
1321 strcpy(ifr.ifr_name, ifa->ifa_label);
1322
1323 (*(struct sockaddr_in *)&ifr.ifr_addr).sin_family = AF_INET;
1324 (*(struct sockaddr_in *)&ifr.ifr_addr).sin_addr.s_addr =
1325 ifa->ifa_local;
1326
1327 if (copy_to_user(buf + done, &ifr, size)) {
1328 done = -EFAULT;
1329 break;
1330 }
1331 len -= size;
1332 done += size;
1333 }
1334 out:
1335 return done;
1336 }
1337
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
prev parent reply other threads:[~2024-10-20 3:08 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-18 1:22 [PATCH v1 net-next 00/11] ipv4: Convert RTM_{NEW,DEL}ADDR and more to per-netns RTNL Kuniyuki Iwashima
2024-10-18 1:22 ` [PATCH v1 net-next 01/11] rtnetlink: Define RTNL_FLAG_DOIT_PERNET for per-netns RTNL doit() Kuniyuki Iwashima
2024-10-18 13:48 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 02/11] ipv4: Factorise RTM_NEWADDR validation to inet_validate_rtm() Kuniyuki Iwashima
2024-10-18 13:50 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 03/11] ipv4: Don't allocate ifa for 0.0.0.0 in inet_rtm_newaddr() Kuniyuki Iwashima
2024-10-18 13:51 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 04/11] ipv4: Convert RTM_NEWADDR to per-netns RTNL Kuniyuki Iwashima
2024-10-18 13:51 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 05/11] ipv4: Use per-netns RTNL helpers in inet_rtm_newaddr() Kuniyuki Iwashima
2024-10-18 13:52 ` Eric Dumazet
2024-10-19 20:03 ` kernel test robot
2024-10-19 20:59 ` Kuniyuki Iwashima
2024-10-18 1:22 ` [PATCH v1 net-next 06/11] ipv4: Convert RTM_DELADDR to per-netns RTNL Kuniyuki Iwashima
2024-10-18 13:53 ` Eric Dumazet
2024-10-19 22:59 ` kernel test robot
2024-10-18 1:22 ` [PATCH v1 net-next 07/11] ipv4: Convert check_lifetime() " Kuniyuki Iwashima
2024-10-18 13:54 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 08/11] rtnetlink: Define rtnl_net_lock() Kuniyuki Iwashima
2024-10-18 13:55 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 09/11] ipv4: Convert devinet_sysctl_forward() to per-netns RTNL Kuniyuki Iwashima
2024-10-18 13:56 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 10/11] ipv4: Convert devinet_ioctl() to per-netns RTNL except for SIOCSIFFLAGS Kuniyuki Iwashima
2024-10-18 13:56 ` Eric Dumazet
2024-10-18 1:22 ` [PATCH v1 net-next 11/11] ipv4: Convert devinet_ioctl to per-netns RTNL Kuniyuki Iwashima
2024-10-18 13:57 ` Eric Dumazet
2024-10-20 3:07 ` kernel test robot [this message]
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=202410201022.bZkEgzK5-lkp@intel.com \
--to=lkp@intel.com \
--cc=davem@davemloft.net \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=kuniyu@amazon.com \
--cc=netdev@vger.kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=pabeni@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).