Re: net/core/page_pool.c:590:9: sparse: sparse: incorrect type in argument 1 (different address spaces)

From: Yujie Liu
Date: Sun Nov 19 2023 - 21:30:16 EST


Hi Olek,

On Thu, Nov 16, 2023 at 01:06:46PM +0100, Alexander Lobakin wrote:
> From: Kernel Test Robot <lkp@xxxxxxxxx>
> Date: Thu, 16 Nov 2023 03:12:24 +0800
>
> > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> > head: c42d9eeef8e5ba9292eda36fd8e3c11f35ee065c
> > commit: ff4e538c8c3e675a15e1e49509c55951832e0451 page_pool: add a lockdep check for recycling in hardirq
> > date: 3 months ago
> > config: loongarch-randconfig-r133-20231107 (https://download.01.org/0day-ci/archive/20231116/202311160339.DbhaH8LX-lkp@xxxxxxxxx/config)
> > compiler: loongarch64-linux-gcc (GCC) 13.2.0
> > reproduce: (https://download.01.org/0day-ci/archive/20231116/202311160339.DbhaH8LX-lkp@xxxxxxxxx/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@xxxxxxxxx>
> > | Closes: https://lore.kernel.org/oe-kbuild-all/202311160339.DbhaH8LX-lkp@xxxxxxxxx/
> >
> > sparse warnings: (new ones prefixed by >>)
> >>> net/core/page_pool.c:590:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *ptr @@ got unsigned int [noderef] __percpu * @@
> > net/core/page_pool.c:590:9: sparse: expected void *ptr
> > net/core/page_pool.c:590:9: sparse: got unsigned int [noderef] __percpu *
>
> Eeehhh... False-positive?

This is a loongarch-specific warning and should be fixed by [1].
We will configure the bot to avoid sending similar duplicate reports.

[1] https://lore.kernel.org/loongarch/20231113032511.860159-1-chenhuacai@xxxxxxxxxxx/

Thanks,
Yujie