-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git…
…/herbert/crypto-2.6 Pull crypto updates from Herbert Xu: "API: - Enforce the setting of keys for keyed aead/hash/skcipher algorithms. - Add multibuf speed tests in tcrypt. Algorithms: - Improve performance of sha3-generic. - Add native sha512 support on arm64. - Add v8.2 Crypto Extentions version of sha3/sm3 on arm64. - Avoid hmac nesting by requiring underlying algorithm to be unkeyed. - Add cryptd_max_cpu_qlen module parameter to cryptd. Drivers: - Add support for EIP97 engine in inside-secure. - Add inline IPsec support to chelsio. - Add RevB core support to crypto4xx. - Fix AEAD ICV check in crypto4xx. - Add stm32 crypto driver. - Add support for BCM63xx platforms in bcm2835 and remove bcm63xx. - Add Derived Key Protocol (DKP) support in caam. - Add Samsung Exynos True RNG driver. - Add support for Exynos5250+ SoCs in exynos PRNG driver" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (166 commits) crypto: picoxcell - Fix error handling in spacc_probe() crypto: arm64/sha512 - fix/improve new v8.2 Crypto Extensions code crypto: arm64/sm3 - new v8.2 Crypto Extensions implementation crypto: arm64/sha3 - new v8.2 Crypto Extensions implementation crypto: testmgr - add new testcases for sha3 crypto: sha3-generic - export init/update/final routines crypto: sha3-generic - simplify code crypto: sha3-generic - rewrite KECCAK transform to help the compiler optimize crypto: sha3-generic - fixes for alignment and big endian operation crypto: aesni - handle zero length dst buffer crypto: artpec6 - remove select on non-existing CRYPTO_SHA384 hwrng: bcm2835 - Remove redundant dev_err call in bcm2835_rng_probe() crypto: stm32 - remove redundant dev_err call in stm32_cryp_probe() crypto: axis - remove unnecessary platform_get_resource() error check crypto: testmgr - test misuse of result in ahash crypto: inside-secure - make function safexcel_try_push_requests static crypto: aes-generic - fix aes-generic regression on powerpc crypto: chelsio - Fix indentation warning crypto: arm64/sha1-ce - get rid of literal pool crypto: arm64/sha2-ce - move the round constant table to .rodata section ...
- Loading branch information
Showing
162 changed files
with
7,473 additions
and
2,684 deletions.
There are no files selected for viewing
22 changes: 22 additions & 0 deletions
22
Documentation/devicetree/bindings/crypto/arm-cryptocell.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
Arm TrustZone CryptoCell cryptographic engine | ||
|
||
Required properties: | ||
- compatible: Should be "arm,cryptocell-712-ree". | ||
- reg: Base physical address of the engine and length of memory mapped region. | ||
- interrupts: Interrupt number for the device. | ||
|
||
Optional properties: | ||
- interrupt-parent: The phandle for the interrupt controller that services | ||
interrupts for this device. | ||
- clocks: Reference to the crypto engine clock. | ||
- dma-coherent: Present if dma operations are coherent. | ||
|
||
Examples: | ||
|
||
arm_cc712: crypto@80000000 { | ||
compatible = "arm,cryptocell-712-ree"; | ||
interrupt-parent = <&intc>; | ||
interrupts = < 0 30 4 >; | ||
reg = < 0x80000000 0x10000 >; | ||
|
||
}; |
3 changes: 2 additions & 1 deletion
3
Documentation/devicetree/bindings/crypto/inside-secure-safexcel.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
Documentation/devicetree/bindings/crypto/st,stm32-cryp.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
* STMicroelectronics STM32 CRYP | ||
|
||
Required properties: | ||
- compatible: Should be "st,stm32f756-cryp". | ||
- reg: The address and length of the peripheral registers space | ||
- clocks: The input clock of the CRYP instance | ||
- interrupts: The CRYP interrupt | ||
|
||
Optional properties: | ||
- resets: The input reset of the CRYP instance | ||
|
||
Example: | ||
crypto@50060000 { | ||
compatible = "st,stm32f756-cryp"; | ||
reg = <0x50060000 0x400>; | ||
interrupts = <79>; | ||
clocks = <&rcc 0 STM32F7_AHB2_CLOCK(CRYP)>; | ||
resets = <&rcc STM32F7_AHB2_RESET(CRYP)>; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
/* | ||
* Copyright (C) 2013 - 2017 Linaro Ltd <ard.biesheuvel@linaro.org> | ||
* | ||
* This program is free software; you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License version 2 as | ||
* published by the Free Software Foundation. | ||
*/ | ||
|
||
#include <linux/linkage.h> | ||
#include <asm/assembler.h> | ||
|
||
.arch armv8-a+crypto | ||
|
||
ENTRY(__aes_ce_encrypt) | ||
sub w3, w3, #2 | ||
ld1 {v0.16b}, [x2] | ||
ld1 {v1.4s}, [x0], #16 | ||
cmp w3, #10 | ||
bmi 0f | ||
bne 3f | ||
mov v3.16b, v1.16b | ||
b 2f | ||
0: mov v2.16b, v1.16b | ||
ld1 {v3.4s}, [x0], #16 | ||
1: aese v0.16b, v2.16b | ||
aesmc v0.16b, v0.16b | ||
2: ld1 {v1.4s}, [x0], #16 | ||
aese v0.16b, v3.16b | ||
aesmc v0.16b, v0.16b | ||
3: ld1 {v2.4s}, [x0], #16 | ||
subs w3, w3, #3 | ||
aese v0.16b, v1.16b | ||
aesmc v0.16b, v0.16b | ||
ld1 {v3.4s}, [x0], #16 | ||
bpl 1b | ||
aese v0.16b, v2.16b | ||
eor v0.16b, v0.16b, v3.16b | ||
st1 {v0.16b}, [x1] | ||
ret | ||
ENDPROC(__aes_ce_encrypt) | ||
|
||
ENTRY(__aes_ce_decrypt) | ||
sub w3, w3, #2 | ||
ld1 {v0.16b}, [x2] | ||
ld1 {v1.4s}, [x0], #16 | ||
cmp w3, #10 | ||
bmi 0f | ||
bne 3f | ||
mov v3.16b, v1.16b | ||
b 2f | ||
0: mov v2.16b, v1.16b | ||
ld1 {v3.4s}, [x0], #16 | ||
1: aesd v0.16b, v2.16b | ||
aesimc v0.16b, v0.16b | ||
2: ld1 {v1.4s}, [x0], #16 | ||
aesd v0.16b, v3.16b | ||
aesimc v0.16b, v0.16b | ||
3: ld1 {v2.4s}, [x0], #16 | ||
subs w3, w3, #3 | ||
aesd v0.16b, v1.16b | ||
aesimc v0.16b, v0.16b | ||
ld1 {v3.4s}, [x0], #16 | ||
bpl 1b | ||
aesd v0.16b, v2.16b | ||
eor v0.16b, v0.16b, v3.16b | ||
st1 {v0.16b}, [x1] | ||
ret | ||
ENDPROC(__aes_ce_decrypt) | ||
|
||
/* | ||
* __aes_ce_sub() - use the aese instruction to perform the AES sbox | ||
* substitution on each byte in 'input' | ||
*/ | ||
ENTRY(__aes_ce_sub) | ||
dup v1.4s, w0 | ||
movi v0.16b, #0 | ||
aese v0.16b, v1.16b | ||
umov w0, v0.s[0] | ||
ret | ||
ENDPROC(__aes_ce_sub) | ||
|
||
ENTRY(__aes_ce_invert) | ||
ld1 {v0.4s}, [x1] | ||
aesimc v1.16b, v0.16b | ||
st1 {v1.4s}, [x0] | ||
ret | ||
ENDPROC(__aes_ce_invert) |
Oops, something went wrong.