]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: arm/sha256-neon - avoid ADRL pseudo instruction
authorArd Biesheuvel <ardb@kernel.org>
Wed, 16 Sep 2020 06:14:17 +0000 (09:14 +0300)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 25 Sep 2020 07:48:13 +0000 (17:48 +1000)
commit7806ca5018aba4752372099b7e2e0413bc2d56f8
treed265c5a519c1765f0d5f28529d875c2b22f7bb92
parentbe105894dd1b29c8c402f613a30ff343947d0e66
crypto: arm/sha256-neon - avoid ADRL pseudo instruction

The ADRL pseudo instruction is not an architectural construct, but a
convenience macro that was supported by the ARM proprietary assembler
and adopted by binutils GAS as well, but only when assembling in 32-bit
ARM mode. Therefore, it can only be used in assembler code that is known
to assemble in ARM mode only, but as it turns out, the Clang assembler
does not implement ADRL at all, and so it is better to get rid of it
entirely.

So replace the ADRL instruction with a ADR instruction that refers to
a nearer symbol, and apply the delta explicitly using an additional
instruction.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Tested-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
arch/arm/crypto/sha256-armv4.pl
arch/arm/crypto/sha256-core.S_shipped