Message ID | 20200323191807.3864-2-broonie@kernel.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [1/2] arm64: lib: Use .arch_extension | expand |
On Mon, Mar 23, 2020 at 07:18:07PM +0000, Mark Brown wrote: > Currently when implementing optimised assembler routines using > architecture extensions we override the base architecture along with > enabling the new extensions, causing problems for in kernel BTI support > which needs to raise the base architecture level for assembler files in > order to generate BTI landing pads. We did this due to a lack of > support for the .arch_extension gas feature in older versions of the > clang built in assembler but since current versions of clang now have > support for .arch_extension we can use that. > > Signed-off-by: Mark Brown <broonie@kernel.org> It make sense (I got burnt by this with the MTE patches). Acked-by: Catalin Marinas <catalin.marinas@arm.com>
diff --git a/arch/arm64/crypto/aes-ce-ccm-core.S b/arch/arm64/crypto/aes-ce-ccm-core.S index 99a028e298ed..90fde12f8253 100644 --- a/arch/arm64/crypto/aes-ce-ccm-core.S +++ b/arch/arm64/crypto/aes-ce-ccm-core.S @@ -9,7 +9,7 @@ #include <asm/assembler.h> .text - .arch armv8-a+crypto + .arch_extension crypto /* * void ce_aes_ccm_auth_data(u8 mac[], u8 const in[], u32 abytes, diff --git a/arch/arm64/crypto/aes-ce-core.S b/arch/arm64/crypto/aes-ce-core.S index e52e13eb8fdb..4dbc0052ffbe 100644 --- a/arch/arm64/crypto/aes-ce-core.S +++ b/arch/arm64/crypto/aes-ce-core.S @@ -6,7 +6,7 @@ #include <linux/linkage.h> #include <asm/assembler.h> - .arch armv8-a+crypto + .arch_extension crypto SYM_FUNC_START(__aes_ce_encrypt) sub w3, w3, #2 diff --git a/arch/arm64/crypto/aes-ce.S b/arch/arm64/crypto/aes-ce.S index 1dc5bbbfeed2..d57516308cf1 100644 --- a/arch/arm64/crypto/aes-ce.S +++ b/arch/arm64/crypto/aes-ce.S @@ -12,7 +12,7 @@ #define AES_FUNC_START(func) SYM_FUNC_START(ce_ ## func) #define AES_FUNC_END(func) SYM_FUNC_END(ce_ ## func) - .arch armv8-a+crypto + .arch_extension crypto xtsmask .req v16 cbciv .req v16 diff --git a/arch/arm64/crypto/crct10dif-ce-core.S b/arch/arm64/crypto/crct10dif-ce-core.S index 5a95c2628fbf..c6b8b387f3bd 100644 --- a/arch/arm64/crypto/crct10dif-ce-core.S +++ b/arch/arm64/crypto/crct10dif-ce-core.S @@ -66,7 +66,7 @@ #include <asm/assembler.h> .text - .cpu generic+crypto + .arch_extension crypto init_crc .req w19 buf .req x20 diff --git a/arch/arm64/crypto/ghash-ce-core.S b/arch/arm64/crypto/ghash-ce-core.S index 6b958dcdf136..65ed5690735a 100644 --- a/arch/arm64/crypto/ghash-ce-core.S +++ b/arch/arm64/crypto/ghash-ce-core.S @@ -57,7 +57,7 @@ HH34 .req v19 .text - .arch armv8-a+crypto + .arch_extension crypto .macro __pmull_p64, rd, rn, rm pmull \rd\().1q, \rn\().1d, \rm\().1d diff --git a/arch/arm64/crypto/sha1-ce-core.S b/arch/arm64/crypto/sha1-ce-core.S index 92d0d2753e81..8cfd30c5f605 100644 --- a/arch/arm64/crypto/sha1-ce-core.S +++ b/arch/arm64/crypto/sha1-ce-core.S @@ -9,7 +9,7 @@ #include <asm/assembler.h> .text - .arch armv8-a+crypto + .arch_extension crypto k0 .req v0 k1 .req v1 diff --git a/arch/arm64/crypto/sha2-ce-core.S b/arch/arm64/crypto/sha2-ce-core.S index 3f9d0f326987..a7ea4fc8d570 100644 --- a/arch/arm64/crypto/sha2-ce-core.S +++ b/arch/arm64/crypto/sha2-ce-core.S @@ -9,7 +9,7 @@ #include <asm/assembler.h> .text - .arch armv8-a+crypto + .arch_extension crypto dga .req q20 dgav .req v20
Currently when implementing optimised assembler routines using architecture extensions we override the base architecture along with enabling the new extensions, causing problems for in kernel BTI support which needs to raise the base architecture level for assembler files in order to generate BTI landing pads. We did this due to a lack of support for the .arch_extension gas feature in older versions of the clang built in assembler but since current versions of clang now have support for .arch_extension we can use that. Signed-off-by: Mark Brown <broonie@kernel.org> --- arch/arm64/crypto/aes-ce-ccm-core.S | 2 +- arch/arm64/crypto/aes-ce-core.S | 2 +- arch/arm64/crypto/aes-ce.S | 2 +- arch/arm64/crypto/crct10dif-ce-core.S | 2 +- arch/arm64/crypto/ghash-ce-core.S | 2 +- arch/arm64/crypto/sha1-ce-core.S | 2 +- arch/arm64/crypto/sha2-ce-core.S | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-)