net/ipv4/ipmr.c:312:24: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel test robot
build bottree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: f1a5e78a55ebf2b05777fd5eb738038ddae609d6 commit: b3b6babf47517fde6b6de2493dea28e8831b9347 ipmr: Free mr_table after RCU grace period. date: 5 days ago config: nios2-randconfig-r132-20260502 (https://download.01.org/0day-ci/archive/20260503/[email protected]/config) compiler: nios2-linux-gcc (GCC) 8.5.0 sparse: v0.6.5-rc1 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260503/[email protected]/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
| Fixes: b3b6babf4751 ("ipmr: Free mr_table after RCU grace period.")
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/sparse warnings: (new ones prefixed by >>)
net/ipv4/ipmr.c: note: in included file (through include/uapi/linux/swab.h, include/linux/swab.h, include/uapi/linux/byteorder/little_endian.h, ...):
arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini
>> net/ipv4/ipmr.c:312:24: sparse: sparse: incompatible types in comparison expression (different address spaces):
net/ipv4/ipmr.c:312:24: sparse: struct mr_table [noderef] __rcu *
net/ipv4/ipmr.c:312:24: sparse: struct mr_table *
net/ipv4/ipmr.c:318:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
net/ipv4/ipmr.c:318:16: sparse: struct mr_table [noderef] __rcu *
net/ipv4/ipmr.c:318:16: sparse: struct mr_table *
net/ipv4/ipmr.c:318:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
net/ipv4/ipmr.c:318:16: sparse: struct mr_table [noderef] __rcu *
net/ipv4/ipmr.c:318:16: sparse: struct mr_table *
net/ipv4/ipmr.c:329:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
net/ipv4/ipmr.c:329:16: sparse: struct mr_table [noderef] __rcu *
net/ipv4/ipmr.c:329:16: sparse: struct mr_table *
net/ipv4/ipmr.c:343:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
net/ipv4/ipmr.c:343:9: sparse: struct mr_table [noderef] __rcu *
net/ipv4/ipmr.c:343:9: sparse: struct mr_table *
net/ipv4/ipmr.c:354:32: sparse: sparse: incompatible types in comparison expression (different address spaces):
net/ipv4/ipmr.c:354:32: sparse: struct mr_table [noderef] __rcu *
net/ipv4/ipmr.c:354:32: sparse: struct mr_table *
net/ipv4/ipmr.c:356:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
net/ipv4/ipmr.c:356:9: sparse: struct mr_table [noderef] __rcu *
net/ipv4/ipmr.c:356:9: sparse: struct mr_table *
arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function __builtin_custom_ini
vim +312 net/ipv4/ipmr.c
301
302 bool ipmr_rule_default(const struct fib_rule *rule)
303 {
304 return fib_rule_matchall(rule) && rule->table == RT_TABLE_DEFAULT;
305 }
306 EXPORT_SYMBOL(ipmr_rule_default);
307 #else
308 static struct mr_table *ipmr_mr_table_iter(struct net *net,
309 struct mr_table *mrt)
310 {
311 if (!mrt)
> 312 return rcu_dereference(net->ipv4.mrt);
313 return NULL;
314 }
315
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
Quoted 16 lines · kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: f1a5e78a55ebf2b05777fd5eb738038ddae609d6 commit: b3b6babf47517fde6b6de2493dea28e8831b9347 ipmr: Free mr_table after RCU grace period. date: 5 days ago config: nios2-randconfig-r132-20260502 (https://download.01.org/0day-ci/archive/20260503/[email protected]/config) compiler: nios2-linux-gcc (GCC) 8.5.0 sparse: v0.6.5-rc1 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260503/[email protected]/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
| Fixes: b3b6babf4751 ("ipmr: Free mr_table after RCU grace period.") | Reported-by: kernel test robot <[email protected]> | Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
Quoted 6 lines
sparse warnings: (new ones prefixed by >>)
net/ipv4/ipmr.c: note: in included file (throughinclude/uapi/linux/swab.h,include/linux/swab.h,include/uapi/linux/byteorder/little_endian.h, ...):
arch/nios2/include/asm/swab.h:25:24: sparse: sparse: too many arguments for function__builtin_custom_iniQuoted 1 line
Quoted 1 line
net/ipv4/ipmr.c:312:24: sparse: sparse: incompatible types in comparison expression (different address spaces):net/ipv4/ipmr.c:312:24: sparse: struct mr_table [noderef] __rcu * net/ipv4/ipmr.c:312:24: sparse: struct mr_table *
Will add __rcu to struct mr_table in netns_ipv4.
Thanks