Re: [linux-next:master 9279/9689] kernel/exit.c:451:17: sparse: sparse: incorrect type in assignment (different address spaces)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 30 Jun 2024 04:27:24 +0800 kernel test robot <lkp@xxxxxxxxx> wrote:

> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
> head:   1eb586a9782cde8e5091b9de74603e0a8386b09e
> commit: acb1a1ec810808c964c21524c1c521c3f75d2f2d [9279/9689] memcg: mm_update_next_owner: kill the "retry" logic
> config: i386-randconfig-061-20240629
> compiler: gcc-9 (Ubuntu 9.5.0-4ubuntu2) 9.5.0
> reproduce (this is a W=1 build):
> 
> 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/202406300417.JH4krMMP-lkp@xxxxxxxxx/
> 
> >> kernel/exit.c:451:17: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected struct task_struct [noderef] __rcu *volatile @@     got struct task_struct *tsk @@

That's

		WRITE_ONCE(mm->owner, tsk);

and mm->owner indeed has __rcu.  This is a cut-n-paste of existing
code, so things didn't get worse.

We should use rcu_assign_pointer(), but how that interacts with the
requirement to use WRITE_ONCE() needs some thought.




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux