[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <feb773a8df5d30b8d9347d1c922997c9da1fd06a.camel@xry111.site>
Date: Wed, 31 Aug 2022 14:50:07 +0800
From: Xi Ruoyao <xry111@...111.site>
To: Yupeng Li <liyupeng@...los.com>, chenhuacai@...nel.org,
kernel@...0n.name, jiaxun.yang@...goat.com
Cc: loongarch@...ts.linux.dev, linux-kernel@...r.kernel.org,
caizp2008@....com
Subject: Re: [PATCH 1/1] LoongArch: Fixed loongarch kernel csr_xxx implicit
declaration.
On Wed, 2022-08-31 at 14:14 +0800, Yupeng Li wrote:
> Loongarch CSR register operation related interface, use the
> interface defined __builtin_loongarch_xxx instead.
> Build kernel error messages like:
It's likely because you are using a draft version of LoongArch GCC port.
Wrapper functions like __csrrd_w has been there in larchintrin.h since
the first day GCC port was merged upstream
(https://gcc.gnu.org/r12-7881).
A quick search shows IA64 and PowerPC also use GCC ia64intrin.h and
spu_intrinsics.h, so the use of these wrappers are not forbidden in
kernel source.
Unless there is some new good reason for the change,
Nacked-by: Xi Ruoyao <xry111@...111.site>
>
> CALL scripts/atomic/check-atomics.sh
> CC arch/loongarch/kernel/asm-offsets.s
> In file included from ./arch/loongarch/include/asm/cpu-info.h:11,
> from ./arch/loongarch/include/asm/processor.h:13,
> from ./arch/loongarch/include/asm/thread_info.h:15,
> from ./include/linux/thread_info.h:60,
> from ./include/asm-generic/current.h:5,
> from
> ./arch/loongarch/include/generated/asm/current.h:1,
> from ./include/linux/sched.h:12,
> from arch/loongarch/kernel/asm-offsets.c:8:
> ./arch/loongarch/include/asm/loongarch.h: In function 'csr_read32':
> ./arch/loongarch/include/asm/loongarch.h:232:9: error: implicit
> declaration of function '__csrrd_w'; did you mean '__iocsrrd_w'? [-
> Werror=implicit-function-declaration]
> return __csrrd_w(reg);
> ^~~~~~~~~
> __iocsrrd_w
--
Xi Ruoyao <xry111@...111.site>
School of Aerospace Science and Technology, Xidian University
Powered by blists - more mailing lists