Skip to contentSkip to conversation

ARM: multi_v7_defconfig: enable some newly added crypto modules

PATCH New Ard Biesheuvel 3 participants 4 messages Feb 15, 2017 – Feb 28, 2017 Arm (32-bit)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: multi_v7_defconfig: enable some newly added crypto modules

Enable the new accelerated CRC32(C), CRC-T10DIF and ChaCha20 drivers as modules for multi_v7_defconfig builds.

---
 arch/arm/configs/multi_v7_defconfig | 3 +++
 1 file changed, 3 insertions(+)
arch/arm/configs/multi_v7_defconfig +3 -0
index b01a43851294..597e56047747 100644
@@ -936,6 +936,9 @@ CONFIG_CRYPTO_SHA512_ARM=m
 CONFIG_CRYPTO_AES_ARM=m
 CONFIG_CRYPTO_AES_ARM_BS=m
 CONFIG_CRYPTO_AES_ARM_CE=m
+CONFIG_CRYPTO_CHACHA20_NEON=m
+CONFIG_CRYPTO_CRC32_ARM_CE=m
+CONFIG_CRYPTO_CRCT10DIF_ARM_CE=m
 CONFIG_CRYPTO_GHASH_ARM_CE=m
 CONFIG_CRYPTO_DEV_ATMEL_AES=m
 CONFIG_CRYPTO_DEV_ATMEL_TDES=m
Signature · 1 line
2.7.4
#1 lore raw

PATCH 1/1 ARM: multi_v7_defconfig: enable some newly added crypto modules

Quoted 5 lines · CET Ard Biesheuvel

Enable the new accelerated CRC32(C), CRC-T10DIF and ChaCha20 drivers as modules for multi_v7_defconfig builds.

Applied to next/defconfig, thanks!

Arnd

#2 lore raw

PATCH 1/1 ARM: multi_v7_defconfig: enable some newly added crypto modules

In reply to Ard Biesheuvel
Quoted 13 lines · Ard Biesheuvel

Enable the new accelerated CRC32(C), CRC-T10DIF and ChaCha20 drivers as modules for multi_v7_defconfig builds.

---
 arch/arm/configs/multi_v7_defconfig | 3 +++
 1 file changed, 3 insertions(+)
arch/arm/configs/multi_v7_defconfig +0 -0
index b01a43851294..597e56047747 100644

arch/arm/configs/multi_v7_defconfig CONFIG_CRYPTO_SHA512_ARM=m · line 944

Quoted 9 lines
arch/arm/configs/multi_v7_defconfig +3 -0
@@ -936,6 +936,9 @@ CONFIG_CRYPTO_SHA512_ARM=m
 CONFIG_CRYPTO_AES_ARM=m
 CONFIG_CRYPTO_AES_ARM_BS=m
 CONFIG_CRYPTO_AES_ARM_CE=m
+CONFIG_CRYPTO_CHACHA20_NEON=m
+CONFIG_CRYPTO_CRC32_ARM_CE=m
+CONFIG_CRYPTO_CRCT10DIF_ARM_CE=m
 CONFIG_CRYPTO_GHASH_ARM_CE=m
 CONFIG_CRYPTO_DEV_ATMEL_AES=m
 CONFIG_CRYPTO_DEV_ATMEL_TDES=m

Now these are enabled by default, I see the following error ...

AS [M] arch/arm/crypto/crc32-ce-core.o arch/arm/crypto/crc32-ce-core.S: Assembler messages:
arch/arm/crypto/crc32-ce-core.S:56: Error: unknown architecture `crc'

arch/arm/crypto/crc32-ce-core.S:138: Error: bad type for scalar -- vmov dCONSTANTl[0],CRC' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32w r0,r0,r2' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32w r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32w r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32h r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32b r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32b r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32h r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cw r0,r0,r2' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cw r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cw r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32ch r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cb r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cb r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction `crc32ch r0,r0,r3' scripts/Makefile.build:395: recipe for target 'arch/arm/crypto/crc32-ce-core.o' failed make[1]: *** [arch/arm/crypto/crc32-ce-core.o] Error 1

Yes this is with an older toolchain that uses an older assembler (GNU assembler (crosstool-NG linaro-1.13.1-4.7-2013.04-20130415 - Linaro GCC 2013.04) 2.23.1), however, I am curious if older toolchains not supporting the 'crc' arch_extension are deprecated now?

Cheers
Jon

#3 lore raw

PATCH 1/1 ARM: multi_v7_defconfig: enable some newly added crypto modules

Quoted 49 lines · Jon Hunter
Quoted 13 lines · Ard Biesheuvel

Enable the new accelerated CRC32(C), CRC-T10DIF and ChaCha20 drivers as modules for multi_v7_defconfig builds.

---
 arch/arm/configs/multi_v7_defconfig | 3 +++
 1 file changed, 3 insertions(+)
arch/arm/configs/multi_v7_defconfig +0 -0
index b01a43851294..597e56047747 100644

arch/arm/configs/multi_v7_defconfig CONFIG_CRYPTO_SHA512_ARM=m · line 944

Quoted 9 lines
arch/arm/configs/multi_v7_defconfig +3 -0
@@ -936,6 +936,9 @@ CONFIG_CRYPTO_SHA512_ARM=m
 CONFIG_CRYPTO_AES_ARM=m
 CONFIG_CRYPTO_AES_ARM_BS=m
 CONFIG_CRYPTO_AES_ARM_CE=m
+CONFIG_CRYPTO_CHACHA20_NEON=m
+CONFIG_CRYPTO_CRC32_ARM_CE=m
+CONFIG_CRYPTO_CRCT10DIF_ARM_CE=m
 CONFIG_CRYPTO_GHASH_ARM_CE=m
 CONFIG_CRYPTO_DEV_ATMEL_AES=m
 CONFIG_CRYPTO_DEV_ATMEL_TDES=m

Now these are enabled by default, I see the following error ...

AS [M] arch/arm/crypto/crc32-ce-core.o arch/arm/crypto/crc32-ce-core.S: Assembler messages:
arch/arm/crypto/crc32-ce-core.S:56: Error: unknown architecture `crc'

arch/arm/crypto/crc32-ce-core.S:138: Error: bad type for scalar -- vmov dCONSTANTl[0],CRC' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32w r0,r0,r2' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32w r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32w r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32h r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32b r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32b r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:300: Error: bad instruction crc32h r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cw r0,r0,r2' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cw r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cw r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32ch r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cb r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction crc32cb r0,r0,r3' arch/arm/crypto/crc32-ce-core.S:305: Error: bad instruction `crc32ch r0,r0,r3' scripts/Makefile.build:395: recipe for target 'arch/arm/crypto/crc32-ce-core.o' failed make[1]: *** [arch/arm/crypto/crc32-ce-core.o] Error 1

Quoted 5 lines

Yes this is with an older toolchain that uses an older assembler (GNU assembler (crosstool-NG linaro-1.13.1-4.7-2013.04-20130415 - Linaro GCC 2013.04) 2.23.1), however, I am curious if older toolchains not supporting the 'crc' arch_extension are deprecated now?

Hello Jon,

This is surprising: this implies that there are toolchain that do support the crypto-neon-fp-armv8 FPU type but not the scalar (i.e., non-NEON) CRC instructions. We could easily fix this by adding another build time test, I just didn't expect we'd need one