Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-27 Thread Herbert Xu
On Sat, Jul 26, 2014 at 04:01:26PM +0200, Corentin LABBE wrote: > > Even if it is undocumented, the hardware seems to support it. > Since crypto_ahash_ctx is for a tfm, does ahash_request_ctx is the good place > to store data ? > (after a call to crypto_ahash_set_reqsize in cra_init) Yes any

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-27 Thread Herbert Xu
On Sat, Jul 26, 2014 at 04:01:26PM +0200, Corentin LABBE wrote: Even if it is undocumented, the hardware seems to support it. Since crypto_ahash_ctx is for a tfm, does ahash_request_ctx is the good place to store data ? (after a call to crypto_ahash_set_reqsize in cra_init) Yes any hash

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-26 Thread Corentin LABBE
Le 24/07/2014 15:38, Herbert Xu a écrit : > On Thu, Jul 24, 2014 at 01:04:55PM +0200, Corentin LABBE wrote: >> Le 24/07/2014 08:00, Herbert Xu a écrit : >>> On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: +/* sunxi_hash_init: initialize request context + * Activate

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-26 Thread Corentin LABBE
Le 24/07/2014 15:38, Herbert Xu a écrit : On Thu, Jul 24, 2014 at 01:04:55PM +0200, Corentin LABBE wrote: Le 24/07/2014 08:00, Herbert Xu a écrit : On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: +/* sunxi_hash_init: initialize request context + * Activate the SS, and

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-25 Thread Maxime Ripard
On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: > Add support for the Security System included in Allwinner SoC A20. > The Security System is a hardware cryptographic accelerator that support > AES/MD5/SHA1/DES/3DES/PRNG algorithms. > > Signed-off-by: LABBE Corentin > --- >

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-25 Thread Maxime Ripard
On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: Add support for the Security System included in Allwinner SoC A20. The Security System is a hardware cryptographic accelerator that support AES/MD5/SHA1/DES/3DES/PRNG algorithms. Signed-off-by: LABBE Corentin

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-24 Thread Herbert Xu
On Thu, Jul 24, 2014 at 01:04:55PM +0200, Corentin LABBE wrote: > Le 24/07/2014 08:00, Herbert Xu a écrit : > > On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: > >> > >> +/* sunxi_hash_init: initialize request context > >> + * Activate the SS, and configure it for MD5 or SHA1 > >>

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-24 Thread Corentin LABBE
Le 24/07/2014 08:00, Herbert Xu a écrit : > On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: >> >> +/* sunxi_hash_init: initialize request context >> + * Activate the SS, and configure it for MD5 or SHA1 >> + */ >> +int sunxi_hash_init(struct ahash_request *areq) >> +{ >> +const

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-24 Thread Herbert Xu
On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: > > +/* sunxi_hash_init: initialize request context > + * Activate the SS, and configure it for MD5 or SHA1 > + */ > +int sunxi_hash_init(struct ahash_request *areq) > +{ > + const char *hash_type; > + struct crypto_ahash *tfm

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-24 Thread Herbert Xu
On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: +/* sunxi_hash_init: initialize request context + * Activate the SS, and configure it for MD5 or SHA1 + */ +int sunxi_hash_init(struct ahash_request *areq) +{ + const char *hash_type; + struct crypto_ahash *tfm =

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-24 Thread Corentin LABBE
Le 24/07/2014 08:00, Herbert Xu a écrit : On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: +/* sunxi_hash_init: initialize request context + * Activate the SS, and configure it for MD5 or SHA1 + */ +int sunxi_hash_init(struct ahash_request *areq) +{ +const char

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-24 Thread Herbert Xu
On Thu, Jul 24, 2014 at 01:04:55PM +0200, Corentin LABBE wrote: Le 24/07/2014 08:00, Herbert Xu a écrit : On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: +/* sunxi_hash_init: initialize request context + * Activate the SS, and configure it for MD5 or SHA1 + */ +int

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-23 Thread Herbert Xu
On Wed, Jul 23, 2014 at 03:48:57PM +0200, Maxime Ripard wrote: > > The exact opposite has been asked for during v1's review... Indeed but unfortunately it was bogus advice. The async interface brings with it a lot of complexity which should be avoided unless you actually need it. Even if you

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-23 Thread Maxime Ripard
Hi, On Wed, Jul 23, 2014 at 09:16:20PM +0800, Herbert Xu wrote: > On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: > > Add support for the Security System included in Allwinner SoC A20. > > The Security System is a hardware cryptographic accelerator that support > >

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-23 Thread Herbert Xu
On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: > Add support for the Security System included in Allwinner SoC A20. > The Security System is a hardware cryptographic accelerator that support > AES/MD5/SHA1/DES/3DES/PRNG algorithms. > > Signed-off-by: LABBE Corentin This is

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-23 Thread Herbert Xu
On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: Add support for the Security System included in Allwinner SoC A20. The Security System is a hardware cryptographic accelerator that support AES/MD5/SHA1/DES/3DES/PRNG algorithms. Signed-off-by: LABBE Corentin

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-23 Thread Maxime Ripard
Hi, On Wed, Jul 23, 2014 at 09:16:20PM +0800, Herbert Xu wrote: On Sat, Jul 12, 2014 at 02:59:13PM +0200, LABBE Corentin wrote: Add support for the Security System included in Allwinner SoC A20. The Security System is a hardware cryptographic accelerator that support

Re: [PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-23 Thread Herbert Xu
On Wed, Jul 23, 2014 at 03:48:57PM +0200, Maxime Ripard wrote: The exact opposite has been asked for during v1's review... Indeed but unfortunately it was bogus advice. The async interface brings with it a lot of complexity which should be avoided unless you actually need it. Even if you use

[PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-12 Thread LABBE Corentin
Add support for the Security System included in Allwinner SoC A20. The Security System is a hardware cryptographic accelerator that support AES/MD5/SHA1/DES/3DES/PRNG algorithms. Signed-off-by: LABBE Corentin --- drivers/crypto/Kconfig| 17 ++ drivers/crypto/Makefile

[PATCH v4 3/3] crypto: Add Allwinner Security System crypto accelerator

2014-07-12 Thread LABBE Corentin
Add support for the Security System included in Allwinner SoC A20. The Security System is a hardware cryptographic accelerator that support AES/MD5/SHA1/DES/3DES/PRNG algorithms. Signed-off-by: LABBE Corentin clabbe.montj...@gmail.com --- drivers/crypto/Kconfig| 17 ++