RE: [PATCH v8 6/7] apei/ghes: Use unrcu_pointer for cmpxchg

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

 



Hi Borislav

> -----Original Message-----
> From: Borislav Petkov <bp@xxxxxxxxx>
> Sent: Tuesday, October 11, 2022 6:34 PM
> To: Justin He <Justin.He@xxxxxxx>
> Cc: Len Brown <lenb@xxxxxxxxxx>; James Morse <James.Morse@xxxxxxx>;
> Tony Luck <tony.luck@xxxxxxxxx>; Mauro Carvalho Chehab
> <mchehab@xxxxxxxxxx>; Robert Richter <rric@xxxxxxxxxx>; Robert Moore
> <robert.moore@xxxxxxxxx>; Qiuxu Zhuo <qiuxu.zhuo@xxxxxxxxx>; Yazen
> Ghannam <yazen.ghannam@xxxxxxx>; Jan Luebbe <jlu@xxxxxxxxxxxxxx>;
> Khuong Dinh <khuong@xxxxxxxxxxxxxxxxxxxxxx>; Kani Toshi
> <toshi.kani@xxxxxxx>; Ard Biesheuvel <ardb@xxxxxxxxxx>;
> linux-acpi@xxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx;
> linux-edac@xxxxxxxxxxxxxxx; devel@xxxxxxxxxx; Rafael J . Wysocki
> <rafael@xxxxxxxxxx>; Shuai Xue <xueshuai@xxxxxxxxxxxxxxxxx>; Jarkko
> Sakkinen <jarkko@xxxxxxxxxx>; linux-efi@xxxxxxxxxxxxxxx; nd <nd@xxxxxxx>;
> kernel test robot <lkp@xxxxxxxxx>
> Subject: Re: [PATCH v8 6/7] apei/ghes: Use unrcu_pointer for cmpxchg
> 
> On Mon, Oct 10, 2022 at 02:35:58AM +0000, Jia He wrote:
> > ghes_estatus_caches should be add rcu annotation to avoid sparse warnings.
> >    drivers/acpi/apei/ghes.c:733:25: sparse: sparse: incompatible types in
> comparison expression (different address spaces):
> >    drivers/acpi/apei/ghes.c:733:25: sparse:    struct ghes_estatus_cache
> [noderef] __rcu *
> >    drivers/acpi/apei/ghes.c:733:25: sparse:    struct ghes_estatus_cache *
> >    drivers/acpi/apei/ghes.c:813:25: sparse: sparse: incompatible types in
> comparison expression (different address spaces):
> >    drivers/acpi/apei/ghes.c:813:25: sparse:    struct ghes_estatus_cache
> [noderef] __rcu *
> >    drivers/acpi/apei/ghes.c:813:25: sparse:    struct ghes_estatus_cache *
> >
> > unrcu_pointer is to strip the __rcu in cmpxchg.
> 
> Is this only to shut up sparse or actually fixing anything?

My original purpose is to make it pass the sparse checking. 

--
Cheers,
Justin (Jia He)






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

  Powered by Linux