Re: [PATCH 0/2] crypto: add new driver for Marvell CESA

2015-04-09 Thread Stephan Mueller
Am Donnerstag, 9. April 2015, 16:58:41 schrieb Boris Brezillon: Hi Boris, Hello, This is an attempt to replace the mv_cesa driver by a new one to address some limitations of the existing driver. From a performance and CPU load point of view the most important limitation is the lack of DMA

[PATCH 0/2] crypto: add new driver for Marvell CESA

2015-04-09 Thread Boris Brezillon
Hello, This is an attempt to replace the mv_cesa driver by a new one to address some limitations of the existing driver. From a performance and CPU load point of view the most important limitation is the lack of DMA support, thus preventing us from chaining crypto operations. I know we usually

[PATCH v4] crypto: remove instance when test failed

2015-04-09 Thread Stephan Mueller
A cipher instance is added to the list of instances unconditionally regardless of whether the associated test failed. However, a failed test implies that during another lookup, the cipher instance will be added to the list again as it will not be found by the lookup code. That means that the list

[PATCH v4 05/16] crypto: sha256-generic: move to generic glue implementation

2015-04-09 Thread Ard Biesheuvel
This updates the generic SHA-256 implementation to use the new shared SHA-256 glue code. It also implements a .finup hook crypto_sha256_finup() and exports it to other modules. The import and export() functions and the .statesize member are dropped, since the default implementation is perfectly

[PATCH v4 07/16] crypto/arm: move SHA-1 ARM asm implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- arch/arm/crypto/sha1-ce-glue.c | 3 +- arch/arm/{include/asm = }/crypto/sha1.h | 3 +

[PATCH 2/2] crypto: marvell/CESA: update DT bindings documentation

2015-04-09 Thread Boris Brezillon
Document new compatible strings, document the new method to reference the crypto SRAM and deprecate the old one and document the the 'clocks' and 'clock-names' properties. Signed-off-by: Boris Brezillon boris.brezil...@free-electrons.com --- .../devicetree/bindings/crypto/mv_cesa.txt |

Re: [PATCH 0/2] crypto: add new driver for Marvell CESA

2015-04-09 Thread Sebastian Hesselbarth
On 09.04.2015 16:58, Boris Brezillon wrote: This is an attempt to replace the mv_cesa driver by a new one to address some limitations of the existing driver. From a performance and CPU load point of view the most important limitation is the lack of DMA support, thus preventing us from chaining

Re: [PATCH v3] crypto: remove instance when test failed

2015-04-09 Thread Stephan Mueller
Am Donnerstag, 9. April 2015, 17:40:35 schrieb Herbert Xu: Hi Herbert, On Thu, Apr 09, 2015 at 11:22:19AM +0200, Stephan Mueller wrote: I tested it and this approach does not work. If I see that right, the reason for that is the following: The suggestion is to grab the ref count at the

[PATCH v4 08/16] crypto/arm: move SHA-1 NEON implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- arch/arm/crypto/sha1_neon_glue.c | 135 +++ 1 file changed, 24 insertions(+), 111

[PATCH v4 01/16] crypto: sha1: implement base layer for SHA-1

2015-04-09 Thread Ard Biesheuvel
To reduce the number of copies of boilerplate code throughout the tree, this patch implements generic glue for the SHA-1 algorithm. This allows a specific arch or hardware implementation to only implement the special handling that it needs. The users need to supply an implementation of void

[PATCH v4 02/16] crypto: sha256: implement base layer for SHA-256

2015-04-09 Thread Ard Biesheuvel
To reduce the number of copies of boilerplate code throughout the tree, this patch implements generic glue for the SHA-256 algorithm. This allows a specific arch or hardware implementation to only implement the special handling that it needs. The users need to supply an implementation of void

[PATCH v4 12/16] crypto/arm64: move SHA-1 ARMv8 implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- arch/arm64/crypto/sha1-ce-core.S | 33 - arch/arm64/crypto/sha1-ce-glue.c | 151

[PATCH v4 09/16] crypto/arm: move SHA-1 ARMv8 implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- arch/arm/crypto/Kconfig| 1 - arch/arm/crypto/sha1-ce-core.S | 23 +++-- arch/arm/crypto/sha1-ce-glue.c |

[PATCH v4 06/16] crypto: sha512-generic: move to generic glue implementation

2015-04-09 Thread Ard Biesheuvel
This updated the generic SHA-512 implementation to use the generic shared SHA-512 glue code. It also implements a .finup hook crypto_sha512_finup() and exports it to other modules. The import and export() functions and the .statesize member are dropped, since the default implementation is

[PATCH v4 04/16] crypto: sha1-generic: move to generic glue implementation

2015-04-09 Thread Ard Biesheuvel
This updated the generic SHA-1 implementation to use the generic shared SHA-1 glue code. It also implements a .finup hook crypto_sha1_finup() and exports it to other modules. The import and export() functions and the .statesize member are dropped, since the default implementation is perfectly

[PATCH v4 15/16] crypto/x86: move SHA-224/256 SSSE3 implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. It also changes the prototypes of the core asm functions to be compatible with the base prototype void (sha256_block_fn)(struct sha256_state *sst, u8 const *src, int blocks) so

[PATCH v4 03/16] crypto: sha512: implement base layer for SHA-512

2015-04-09 Thread Ard Biesheuvel
To reduce the number of copies of boilerplate code throughout the tree, this patch implements generic glue for the SHA-512 algorithm. This allows a specific arch or hardware implementation to only implement the special handling that it needs. The users need to supply an implementation of void

[PATCH v4 11/16] crypto/arm: move SHA-224/256 ARMv8 implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- arch/arm/crypto/Kconfig| 2 +- arch/arm/crypto/sha2-ce-core.S | 19 ++--- arch/arm/crypto/sha2-ce-glue.c | 155

Re: [PATCH 0/2] crypto: add new driver for Marvell CESA

2015-04-09 Thread Andrew Lunn
On Thu, Apr 09, 2015 at 04:58:41PM +0200, Boris Brezillon wrote: Hello, This is an attempt to replace the mv_cesa driver by a new one to address some limitations of the existing driver. From a performance and CPU load point of view the most important limitation is the lack of DMA support,

[PATCH v4 16/16] crypto/x86: move SHA-384/512 SSSE3 implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. It also changes the prototypes of the core asm functions to be compatible with the base prototype void (sha512_block_fn)(struct sha256_state *sst, u8 const *src, int blocks) so

[PATCH v4 14/16] crypto/x86: move SHA-1 SSSE3 implementation to base layer

2015-04-09 Thread Ard Biesheuvel
This removes all the boilerplate from the existing implementation, and replaces it with calls into the base layer. Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- arch/x86/crypto/sha1_ssse3_glue.c | 139 -- 1 file changed, 28 insertions(+), 111

Re: [PATCH v3] crypto: remove instance when test failed

2015-04-09 Thread Herbert Xu
On Thu, Apr 09, 2015 at 09:36:03AM +0200, Stephan Mueller wrote: diff --git a/crypto/algapi.c b/crypto/algapi.c index f1d0307..cfca1de 100644 --- a/crypto/algapi.c +++ b/crypto/algapi.c @@ -533,6 +533,13 @@ int crypto_register_instance(struct crypto_template *tmpl, if