How to disable NEON in kernel5.4.55 for ARM64

Suzuki K Poulose suzuki.poulose at arm.com
Fri Nov 20 05:16:10 EST 2020


Hi Trey,

On 11/17/20 7:13 AM, Trey Chen (陳振華) wrote:
> Dear linux-arm-kernel,
> 
> We use CA-53 CPU and want to run on ARM64 Kernel5.4.55.
> For some reason, we remove NEON from CA-53.
> 
> Do you know how to disable NEON in kernel5.4.55 for ARM64?

Ideally you don't need any changes to the kernel (with all the fixes
in [0]) to run on a "no-fpsimd" system. The kernel detects the missing
fpsimd at runtime and takes the necessary steps to skip accessing the
NEON registers.

The userspace must rely on the HWCAP bits to detect whether the FP/SIMD
is supported (This is not true in the normal GNU libc, as no-fpsimd
is not part of the ABI). So, as long as the userspace doesn't access
fpsimd blindly you shouldn't need any changes.


Please let us know if you are hitting any issues.

Kind regards
Suzuki

> 
> Ps. by ARM AE’s suggestion, I have done the following two steps but I don’t know if that’s enough?!
> 
> 1.	Set KERNEL_MODE_NEON’s def_bool as n in arch/arm64/Kconfig
> 2.	Not enabling FP/ASIMD in __cpu_setup() in arch/arm64/mm/proc.S
> 
> Thanks,
> -Trey
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
> 




More information about the linux-arm-kernel mailing list