From: kernel test robot <lkp@intel.com>
To: Eric Dumazet <edumazet@google.com>
Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
Jakub Kicinski <kuba@kernel.org>,
Brian Vazquez <brianvv@google.com>
Subject: net/core/dev.c:10290:18: sparse: sparse: cast removes address space '__percpu' of expression
Date: Tue, 19 Dec 2023 21:29:54 +0800 [thread overview]
Message-ID: <202312192120.8ogDR8Em-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 2cf4f94d8e8646803f8fb0facf134b0cd7fb691a
commit: 625788b5844511cf4c30cffa7fa0bc3a69cebc82 net: add per-cpu storage and net->core_stats
date: 1 year, 9 months ago
config: riscv-buildonly-randconfig-r006-20230429 (https://download.01.org/0day-ci/archive/20231219/202312192120.8ogDR8Em-lkp@intel.com/config)
compiler: riscv64-linux-gcc (GCC) 12.3.0
reproduce: (https://download.01.org/0day-ci/archive/20231219/202312192120.8ogDR8Em-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/202312192120.8ogDR8Em-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
net/core/dev.c:3254:23: sparse: sparse: incorrect type in argument 4 (different base types) @@ expected restricted __wsum [usertype] csum @@ got unsigned int @@
net/core/dev.c:3254:23: sparse: expected restricted __wsum [usertype] csum
net/core/dev.c:3254:23: sparse: got unsigned int
net/core/dev.c:3254:23: sparse: sparse: cast from restricted __wsum
>> net/core/dev.c:10290:18: sparse: sparse: cast removes address space '__percpu' of expression
net/core/dev.c:3759:17: sparse: sparse: context imbalance in '__dev_queue_xmit' - different lock contexts for basic block
net/core/dev.c:4961:17: sparse: sparse: context imbalance in 'net_tx_action' - different lock contexts for basic block
vim +/__percpu +10290 net/core/dev.c
10282
10283 struct net_device_core_stats *netdev_core_stats_alloc(struct net_device *dev)
10284 {
10285 struct net_device_core_stats __percpu *p;
10286
10287 p = alloc_percpu_gfp(struct net_device_core_stats,
10288 GFP_ATOMIC | __GFP_NOWARN);
10289
10290 if (p && cmpxchg(&dev->core_stats, NULL, p))
10291 free_percpu(p);
10292
10293 /* This READ_ONCE() pairs with the cmpxchg() above */
10294 p = READ_ONCE(dev->core_stats);
10295 if (!p)
10296 return NULL;
10297
10298 return this_cpu_ptr(p);
10299 }
10300 EXPORT_SYMBOL(netdev_core_stats_alloc);
10301
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2023-12-19 13:30 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-19 13:29 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-07-13 15:48 net/core/dev.c:10290:18: sparse: sparse: cast removes address space '__percpu' of expression kernel test robot
2022-06-05 0:46 kernel test robot
2022-03-28 6:28 kernel test robot
2022-03-28 17:17 ` Jakub Kicinski
2022-03-28 17:17 ` Jakub Kicinski
2022-03-28 17:17 ` Jakub Kicinski
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=202312192120.8ogDR8Em-lkp@intel.com \
--to=lkp@intel.com \
--cc=brianvv@google.com \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
/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.