All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hao Ge <hao.ge@linux.dev>
To: kernel test robot <lkp@intel.com>
Cc: oe-kbuild-all@lists.linux.dev,
	David Hildenbrand <david@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linux Memory Management List <linux-mm@kvack.org>
Subject: Re: [akpm-mm:mm-new 193/194] lib/alloc_tag.c:815:25: sparse: sparse: cast removes address space '__rcu' of expression
Date: Tue, 31 Mar 2026 16:48:58 +0800	[thread overview]
Message-ID: <f1973455-6af0-448f-b657-274bbf64146b@linux.dev> (raw)
In-Reply-To: <202603291211.YhY0R0se-lkp@intel.com>

Hi


On 2026/3/29 12:36, kernel test robot wrote:
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-new
> head:   df2267b6380964f1305128001f05bc043ddf1f37
> commit: 8bee7b4b574f880ff2c7491212e2ef01cd82f2fd [193/194] mm/alloc_tag: clear codetag for pages allocated before page_ext initialization
> config: openrisc-randconfig-r121-20260329 (https://download.01.org/0day-ci/archive/20260329/202603291211.YhY0R0se-lkp@intel.com/config)
> compiler: or1k-linux-gcc (GCC) 10.5.0
> sparse: v0.6.5-rc1
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260329/202603291211.YhY0R0se-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/202603291211.YhY0R0se-lkp@intel.com/
>
> sparse warnings: (new ones prefixed by >>)
>>> lib/alloc_tag.c:815:25: sparse: sparse: cast removes address space '__rcu' of expression
>>> lib/alloc_tag.c:815:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
>     lib/alloc_tag.c:815:25: sparse:    void ( [noderef] __rcu * )( ... )
>     lib/alloc_tag.c:815:25: sparse:    void ( * )( ... )
>     lib/alloc_tag.c:828:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
>     lib/alloc_tag.c:828:9: sparse:    void ( [noderef] __rcu * )( ... )
>     lib/alloc_tag.c:828:9: sparse:    void ( * )( ... )
>
> vim +/__rcu +815 lib/alloc_tag.c
>
>     802	
>     803	typedef void (*alloc_tag_add_func)(unsigned long pfn);
>     804	static alloc_tag_add_func __rcu alloc_tag_add_early_pfn_ptr __refdata =
>     805			__alloc_tag_add_early_pfn;
>     806	
>     807	void alloc_tag_add_early_pfn(unsigned long pfn)
>     808	{
>     809		alloc_tag_add_func alloc_tag_add;
>     810	
>     811		if (static_key_enabled(&mem_profiling_compressed))
>     812			return;
>     813	
>     814		rcu_read_lock();
>   > 815		alloc_tag_add = rcu_dereference(alloc_tag_add_early_pfn_ptr);
>     816		if (alloc_tag_add)
>     817			alloc_tag_add(pfn);
>     818		rcu_read_unlock();
>     819	}
>     820	
>
Thanks.

The v4 patch I've just posted has fixed the issue. Thanks for your report.


Thanks

Hao




      reply	other threads:[~2026-03-31  8:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-29  4:36 [akpm-mm:mm-new 193/194] lib/alloc_tag.c:815:25: sparse: sparse: cast removes address space '__rcu' of expression kernel test robot
2026-03-31  8:48 ` Hao Ge [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=f1973455-6af0-448f-b657-274bbf64146b@linux.dev \
    --to=hao.ge@linux.dev \
    --cc=akpm@linux-foundation.org \
    --cc=david@kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=lkp@intel.com \
    --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.