|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH 1/5] xen/arm64: detect the LSE atomic instructions
On Thu, Nov 26, 2026 at 08:58:21AM +0100, Jan Beulich wrote: > On 25.11.2026 18:55, Luca Di Maio wrote: > > Load/store exclusive loops give no forward-progress guarantee, so many > > CPUs contending on one cache line can livelock. Add the > > ARM64_HAS_LSE_ATOMICS capability and system_uses_lse_atomics(), patched > > at boot like Linux's alternative_has_cap_likely(), for the next patches. > > Assemblers older than binutils 2.26 lack .arch_extension, so Xen built > > with one keeps the exclusive loops. > > > > Assisted-by: Claude:claude-opus-5-5 > > Signed-off-by: Luca Di Maio <luca@xxxxxxxxx> > > --- > > xen/arch/arm/arch.mk | 3 +++ > > xen/arch/arm/cpufeature.c | 10 +++++++++ > > xen/arch/arm/include/asm/arm64/lse.h | 31 +++++++++++++++++++++++++++ > > xen/arch/arm/include/asm/cpufeature.h | 3 ++- > > 4 files changed, 46 insertions(+), 1 deletion(-) > > create mode 100644 xen/arch/arm/include/asm/arm64/lse.h > > > > diff --git a/xen/arch/arm/arch.mk b/xen/arch/arm/arch.mk > > index dea8dbd18a..fe8e02229f 100644 > > --- a/xen/arch/arm/arch.mk > > +++ b/xen/arch/arm/arch.mk > > @@ -19,6 +19,9 @@ endif > > CFLAGS-$(CONFIG_ARM_64) += -mgeneral-regs-only # No fp registers etc > > $(call cc-option-add,CFLAGS-$(CONFIG_ARM_64),CC,-mno-outline-atomics) > > > > +# Binutils >= 2.26 > > +$(call as-option-add,CFLAGS-$(CONFIG_ARM_64),CC,".arch_extension > > lse",-DHAVE_AS_LSE) > > Wouldn't this better be done in Kconfig nowadays? > > Jan Hi Jan, thanks for the review. I'll do that in V2 thanks L.
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |