Port-arm archive

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

Re: [2/2 ABI and toolchain part] Support Raspberry Pi [0-3] in big-endian mode



On 2020/11/24 19:17, Robert Swindells wrote:

Rin Okuyama <rokuyama.rk%gmail.com@localhost> wrote:
- Compatible to ARMv5 and prior. We can build pkgsrc for earmv5{,hf}eb,
   for example (*). This is impossible on ARMv7 and later.

(*) At the moment, userland for ARMv5 and prior does not work on ARMv6
     and later. This is due to lack of swp{,b} instructions. However,
     emulation for these instructions has already been added to aarch64
     by ryo@. Porting that code to arm should be straightforward.

I thought that we had enabled SWP instructions on ARMv6 and ARMv7, it
should not need the emulation code from aarch64.

CPU_CONTROL_SWP_ENABLE bit is missing for ARMv6. See cp15 c1 register
bit definition on p.3-46 of ARM1176JZF-S Technical Reference Manual:

| [10] F bit - Should Be Zero

Also, it does not work for MULTIPROCESSOR in principle:

http://www.nerv.org/netbsd/?q=id:20200922T005509Z.a9df2b5e3f8576abe9673a4964a119fe537c7b7b

So, swp{,b} is usable only for some uniprocessor ARMv7 CPUs. For
other CPUs, we still need emulation.

Thanks,
rin


Home | Main Index | Thread Index | Old Index