Add support for Chacha20 + Poly1305 combined AEAD:
-generic (rfc7539)
-IPsec (rfc7634 - known as rfc7539esp in the kernel)
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg.c | 4 +-
drivers/crypto/caam/caamalg_desc.c | 24 ++-
drivers/crypto/caam/caamalg_desc.h | 3
Add support for Chacha20 + Poly1305 combined AEAD:
-generic (rfc7539)
-IPsec (rfc7634 - known as rfc7539esp in the kernel)
Signed-off-by: Cristian Stoica
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg.c | 221 -
drivers/crypto/caam
updating LX2160A dts with:
-fsl-mc bus DT node
-missing dma-ranges property in soc DT node
Cristian Stoica (1):
crypto: export CHACHAPOLY_IV_SIZE
Horia Geantă (4):
crypto: caam - add register map changes cf. Era 10
crypto: caam/qi2 - add support for ChaCha20
crypto: caam/jr - add support
Era 10 changes the register map.
The updates that affect the drivers:
-new version registers are added
-DBG_DBG[deco_state] field is moved to a new register -
DBG_EXEC[19:16] @ 8_0E3Ch.
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg.c| 47 +
drivers
From: Cristian Stoica
Move CHACHAPOLY_IV_SIZE to header file, so it can be reused.
Signed-off-by: Cristian Stoica
Signed-off-by: Horia Geantă
---
crypto/chacha20poly1305.c | 2 --
include/crypto/chacha20.h | 1 +
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/crypto
Add support for ChaCha20 skcipher algorithm.
Signed-off-by: Carmen Iorga
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg_desc.c | 6 --
drivers/crypto/caam/caamalg_qi2.c | 27 +--
drivers/crypto/caam/compat.h | 1 +
drivers/crypto/caam/desc.h
d by means of MODULE_LICENSE()
-files with complete license text
-Kconfig
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/Kconfig| 1 +
drivers/crypto/caam/caamalg.c | 1 +
drivers/crypto/caam/caamalg_desc.c | 1 +
drivers/crypto/caam/caamalg_qi.c | 1 +
drivers/crypto/caam/caamhash.
Commit 110492183c4b ("crypto: compress - remove unused pcomp interface")
removed pcomp interface but missed cleaning up tcrypt.
Signed-off-by: Horia Geantă
---
crypto/tcrypt.c | 7 +--
crypto/testmgr.h | 2 --
2 files changed, 1 insertion(+), 8 deletions(-)
diff --git a/crypto/
DMA mapping and updating")
Signed-off-by: Horia Geantă
---
This is for crypto-2.6 tree / current v4.19 release cycle.
Note that it will create merge conflicts later in v4.20 due to commits
cf5448b5c3d8 ("crypto: caam/jr - remove ablkcipher IV generation")
5ca7badb1f62 (&qu
: # 4.6+
Fixes: 0660511c0bee ("crypto: tcrypt - Use ahash")
Tested-by: Franck Lenormand
Signed-off-by: Horia Geantă
---
crypto/tcrypt.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/crypto/tcrypt.c b/crypto/tcrypt.c
index bdde95e8d369..6e0a054bb61d 100644
--- a/crypto/tcry
IV generation is done only at AEAD level.
Support in ablkcipher is not needed, thus remove the dead code.
Link:
https://www.mail-archive.com/search?l=mid=20160901101257.ga3...@gondor.apana.org.au
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg.c | 275
Convert driver from deprecated ablkcipher API to skcipher.
Link:
https://www.mail-archive.com/search?l=mid=20170728085622.gc19...@gondor.apana.org.au
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg.c | 12 +-
drivers/crypto/caam/caamalg_desc.c | 61 +++---
drivers/crypto
Convert driver from deprecated ablkcipher API to skcipher.
Link:
https://www.mail-archive.com/search?l=mid=20170728085622.gc19...@gondor.apana.org.au
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg.c | 448 +++---
drivers/crypto/caam/compat.h
IV generation is done only at AEAD level.
Support in ablkcipher is not needed, thus remove the dead code.
Link:
https://www.mail-archive.com/search?l=mid=20160901101257.ga3...@gondor.apana.org.a
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg_desc.c | 81
drivers
separately:
"crypto: caam/qi - fix error path in xts setkey"
https://patchwork.kernel.org/patch/10557015
Horia Geantă (4):
crypto: caam/jr - remove ablkcipher IV generation
crypto: caam/qi - remove ablkcipher IV generation
crypto: caam/jr - ablkcipher -> skcipher conversion
cr
Cc: # 4.13+
Fixes: 52e26d77b8b3 ("crypto: caam - add support for RSA key form 2")
Fixes: 4a651b122adb ("crypto: caam - add support for RSA key form 3")
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caampkc.c | 20 ++--
1 file changed, 10 insertions(+), 10 deleti
xts setkey callback returns 0 on some error paths.
Fix this by returning -EINVAL.
Cc: # 4.12+
Fixes: b189817cf789 ("crypto: caam/qi - add ablkcipher and authenc algorithms")
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/caamalg_qi.c | 6 ++
1 file changed, 2 insert
Descriptor address needs to be swapped to CPU endianness before being
DMA unmapped.
Cc: # 4.8+
Fixes: 261ea058f016 ("crypto: caam - handle core endianness != caam endianness")
Reported-by: Laurentiu Tudor
Signed-off-by: Horia Geantă
---
drivers/crypto/caam/jr.c | 3 ++-
1 file
Avoid RCU stalls in the case of non-preemptible kernel and lengthy
speed tests by rescheduling when advancing from one block size
to another.
Signed-off-by: Horia Geantă
---
crypto/tcrypt.c | 36
1 file changed, 24 insertions(+), 12 deletions(-)
diff --git
Coverity warns about an
"Unintentional integer overflow (OVERFLOW_BEFORE_WIDEN)"
when computing the congestion threshold value.
Even though it is highly unlikely for an overflow to happen,
use this as an opportunity to simplify the code.
Signed-off-by: Horia Geantă <horia.g
on the presence of
"fsl,qoriq-mc" compatible string in the device tree.
Fixes: 297b9cebd2fc0 ("crypto: caam/jr - add support for DPAA2 parts")
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/ctrl.c | 21 -
drivers/crypto/caa
command to be blocking.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg_desc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/crypto/caam/caamalg_desc.c
b/drivers/crypto/caam/caamalg_desc.c
index 8ae7a1be7dfd..a408edd84f34
gt; # 4.8+
Fixes: 549bd8bc5987 ("crypto: talitos - Implement AEAD for SEC1 using
HMAC_SNOOP_NO_AFEU")
Reported-by: Horia Geantă <horia.gea...@nxp.com>
Signed-off-by: Christophe Leroy <christophe.le...@c-s.fr>
Tested-by: Horia Geantă <horia.gea...@nxp.com>
Signed-off-by: Herbert
d-by: David Binderman <dcb...@hotmail.com>
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caampkc.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/caam/caampkc.c b/drivers/crypto/caam/caampkc.c
index 6f990139f324..578ea63
> Signed-off-by: Fabio Estevam <fabio.este...@nxp.com>
Reviewed-by: Horia Geantă <horia.gea...@nxp.com>
Thanks,
Horia
On 4/16/2018 5:08 PM, Fabio Estevam wrote:
> From: Fabio Estevam
>
> Use kmemdup() rather than duplicating its implementation.
>
> Detected with Coccinelle script.
>
> Signed-off-by: Fabio Estevam
> ---
> drivers/crypto/caam/caampkc.c | 4 +---
>
On 4/15/2018 6:51 PM, Martin Townsend wrote:
> On Sun, Apr 15, 2018 at 3:12 PM, Fabio Estevam wrote:
>> From: Fabio Estevam
>>
>> imx6ul and imx7 report the following error:
>>
>> caam_jr 2142000.jr1: 4789: DECO: desc idx 7:
>> Protocol Size Error -
")
Cc: <sta...@vger.kernel.org> # 4.8+
Reported-by: Martin Townsend <mtownsend1...@gmail.com>
Link:
https://lkml.kernel.org/r/cabatt_ytyoryktapcb4izhnanekkgfi9xaqmjhi_n-8ywoc...@mail.gmail.com
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
(Hopefully this one will reach the
On 4/13/2018 3:12 AM, Fabio Estevam wrote:
> Hi Horia,
>
> On Thu, Apr 12, 2018 at 4:12 AM, Horia Geantă <horia.gea...@nxp.com> wrote:
>
>> Yes, driver needs to strip off leading zeros from input data before feeding
>> it
>> to the accelerator.
>&
On 4/11/2018 8:26 PM, Fabio Estevam wrote:
> Hi Horia,
>
> On Wed, Apr 11, 2018 at 7:15 AM, Horia Geantă <horia.gea...@nxp.com> wrote:
>
>> You'd want to make sure rsa is offloaded to caam in this case - check in
>> /proc/crypto.
>> IIRC there are som
roperty is not passed in the device
> tree.
>
> This function is based on the U-Boot implementation from
> drivers/crypto/fsl/sec.c
>
> Signed-off-by: Fabio Estevam <fabio.este...@nxp.com>
Reviewed-by: Horia Geantă <horia.gea...@nxp.com>
for the series.
Thanks,
Horia
On 4/11/2018 2:59 PM, Fabio Estevam wrote:
> From: Fabio Estevam
>
> The 'era' information can be retrieved from CAAM registers, so
> introduce a caam_get_era_from_hw() function that gets it via register
> reads in case the 'fsl,sec-era' property is not passed in the
On 4/11/2018 1:36 AM, James Bottomley wrote:
> On Tue, 2018-04-10 at 23:01 +0100, Martin Townsend wrote:
>> Using openssl to get the signature in my x509 cert
>>
>> Signature Algorithm: sha256WithRSAEncryption
>> 68:82:cc:5d:f9:ee:fb:1a:77:72:a6:a9:c6:4c:cc:d7:f6:2a:
>>
On 4/11/2018 5:21 AM, Fabio Estevam wrote:
> Hi Martin,
>
> On Tue, Apr 10, 2018 at 7:01 PM, Martin Townsend
> wrote:
>
>> A hexdump of the signature reveals a 0x00 at the start
>
> Yes, same is happening here on my mx6ul evk running linux-next:
>
[snip]
>
> However,
On 4/11/2018 4:54 AM, Fabio Estevam wrote:
> From: Fabio Estevam
>
> The 'era' information can be retrieved from CAAM registers, so
> introduce a caam_get_era_from_hw() function that gets it via register
> reads in case the 'fsl,sec-era' property is not passed in the
On 4/11/2018 4:54 AM, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.este...@nxp.com>
>
> caam_get_era() is only used locally, so do not export this function
> and make it static instead.
>
> Signed-off-by: Fabio Estevam <fabio.este...@nxp.com>
Reviewed-by: Hori
380522 ("crypto: caam/qi - properly set IV after {en,de}crypt")
Link: http://lkml.kernel.org/r/20170113084620.gf22...@gondor.apana.org.au
Reported-by: Gilad Ben-Yossef <gi...@benyossef.com>
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
rly set IV after {en,de}crypt")
Link: http://lkml.kernel.org/r/20170113084620.gf22...@gondor.apana.org.au
Reported-by: Gilad Ben-Yossef <gi...@benyossef.com>
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg.c | 212 ++---
ablkcipher decryption needs special handling since ciphertext
will be overwritten by the time we want to update the IV with the last
ciphertext block
Horia Geantă (3):
crypto: caam - fix DMA mapping dir for generated IV
crypto: caam - fix IV DMA mapping and updating
crypto: caam/qi - fix IV D
In case of GIVCIPHER, IV is generated by the device.
Fix the DMA mapping direction.
Cc: <sta...@vger.kernel.org> # 3.19+
Fixes: 7222d1a34103 ("crypto: caam - add support for givencrypt cbc(aes) and
rfc3686(ctr(aes))")
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
--
-by: Tudor Ambarus <tudor.amba...@microchip.com>
Reviewed-by: Horia Geantă <horia.gea...@nxp.com>
Thanks,
Horia
-by: Tudor Ambarus <tudor.amba...@microchip.com>
Reviewed-by: Horia Geantă <horia.gea...@nxp.com>
Thanks,
Horia
On 3/22/2018 12:04 PM, Christophe LEROY wrote:
> Le 16/03/2018 à 15:07, Horia Geantă a écrit :
>> On 3/16/2018 2:42 PM, Christophe LEROY wrote:
>>> Le 16/03/2018 à 09:48, Horia Geantă a écrit :
>>>> For SEC 2.x+, cipher in length must contain only the ciphertext
On 3/20/2018 10:50 AM, Kamil Konieczny wrote:
> On 20.03.2018 08:56, Horia Geantă wrote:
>> Add a note that it is perfectly legal to "abandon" a request object:
>> - call .init() and then (as many times) .update()
>> - _not_ call any of .final(), .finup() or .expor
Add a note that it is perfectly legal to "abandon" a request object:
- call .init() and then (as many times) .update()
- _not_ call any of .final(), .finup() or .export() at any point in
future
Link: https://lkml.kernel.org/r/20180222114741.ga27...@gondor.apana.org.au
Signed-off
On 3/19/2018 11:25 AM, Herbert Xu wrote:
> On Mon, Mar 19, 2018 at 06:39:50AM +0000, Horia Geantă wrote:
>>
>> The fact that there can be multiple requests in parallel (for a given tfm)
>> is a
>> different topic.
>> Each request object has its state in its ow
On 3/16/2018 5:16 PM, Herbert Xu wrote:
> On Mon, Mar 05, 2018 at 12:39:45PM +0200, Horia Geantă wrote:
>> Even though it doesn't make too much sense, it is perfectly legal to:
>> - call .init() and then (as many times) .update()
>> - subseqently _not_ call any of .final()
On 3/16/2018 2:42 PM, Christophe LEROY wrote:
> Le 16/03/2018 à 09:48, Horia Geantă a écrit :
>> For SEC 2.x+, cipher in length must contain only the ciphertext length.
>> In case of using hardware ICV checking, the ICV length is provided via
>> the "extent"
t AEAD for SEC1 using
HMAC_SNOOP_NO_AFEU")
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/talitos.c | 7 +++
1 file changed, 7 insertions(+)
diff --git a/drivers/crypto/talitos.c b/drivers/crypto/talitos.c
index 447cb8b1b16a..61a30704847f 100644
--- a/driver
an Gunthorpe <log...@deltatee.com>
> Cc: Andy Shevchenko <andy.shevche...@gmail.com>
> Cc: Horia Geantă <horia.gea...@nxp.com>
> Cc: Dan Douglass <dan.dougl...@nxp.com>
> Cc: Herbert Xu <herb...@gondor.apana.org.au>
> Cc: "David S. Miller"
: https://lkml.kernel.org/r/20180222114741.ga27...@gondor.apana.org.au
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
Documentation/crypto/devel-algos.rst | 8
1 file changed, 8 insertions(+)
diff --git a/Documentation/crypto/devel-algos.rst
b/Documentation/crypto/devel-alg
data for ahash on
> SEC1")
> Signed-off-by: Christophe Leroy <christophe.le...@c-s.fr>
Tested-by: Horia Geantă <horia.gea...@nxp.com>
Please add this to 4.15.y -stable tree.
Thanks,
Horia
On 2/22/2018 1:47 PM, Herbert Xu wrote:
> On Tue, Feb 20, 2018 at 11:32:25AM +0000, Horia Geantă wrote:
>>
>> If final/finup is optional, how is the final hash supposed to be retrieved?
>
> Sometimes the computation ends with a partial hash, that's what
> export is for
On 2/22/2018 9:08 AM, Christophe Leroy wrote:
> Upstream 87a81dce53b1ea61acaeefa5191a0376a2d1d721
>
> Performing the hash of an empty file leads to a kernel Oops
>
> [ 44.504600] Unable to handle kernel paging request for data at address
> 0x000c
> [ 44.512819] Faulting instruction
On 2/20/2018 12:34 PM, Herbert Xu wrote:
> On Mon, Feb 19, 2018 at 01:16:30PM +0000, Horia Geantă wrote:
>>
>>> And what about ALGIF path from user space ?
>>> What if the user never calls the last sendmsg() which will call
>>> hash_finup() ?
>>
On 2/19/2018 11:14 AM, Christophe LEROY wrote:
> Le 19/02/2018 à 09:30, Horia Geantă a écrit :
>> On 2/19/2018 9:58 AM, Christophe LEROY wrote:
>>> Le 18/02/2018 à 18:14, Horia Geantă a écrit :
>>>> There is no ahash_exit() callback mirroring ahash_init().
>>
On 2/19/2018 9:58 AM, Christophe LEROY wrote:
> Le 18/02/2018 à 18:14, Horia Geantă a écrit :
>> There is no ahash_exit() callback mirroring ahash_init().
>>
>> The clean-up of request ctx should be done in the last states of the hash
>> flows
>> described here:
&
On 2/17/2018 6:32 PM, Christophe LEROY wrote:
>
>
> Le 07/02/2018 à 15:39, Horia Geantă a écrit :
>> On 10/6/2017 4:06 PM, Christophe Leroy wrote:
>>> At every request, we map and unmap the same hash hw_context.
>>>
>>> This patch moves the dma
On 2/14/2018 8:32 PM, SF Markus Elfring wrote:
> From: Markus Elfring
> Date: Wed, 14 Feb 2018 19:14:49 +0100
>
> Add jump targets so that a bit of exception handling can be better reused
> at the end of these functions.
>
> Signed-off-by: Markus Elfring
le software.
>
> Signed-off-by: Markus Elfring <elfr...@users.sourceforge.net>
Reviewed-by: Horia Geantă <horia.gea...@nxp.com>
though please consider the following
> @@ -689,10 +687,8 @@ static struct ahash_edesc *ahash_edesc_alloc(struct
> caam_hash_ctx *ctx,
>
On 10/6/2017 4:06 PM, Christophe Leroy wrote:
> At every request, we map and unmap the same hash hw_context.
>
> This patch moves the dma mapping/unmapping in functions ahash_init()
> and ahash_import().
>
> Signed-off-by: Christophe Leroy
> ---
>
andles")
Reported-by: Bryan O'Donoghue <pure.lo...@nexus-software.ie>
Suggested-by: Auer Lukas <lukas.a...@aisec.fraunhofer.de>
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/ctrl.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --gi
On 2/2/2018 2:54 PM, Auer, Lukas wrote:
> On Fri, 2018-02-02 at 11:20 +, Bryan O'Donoghue wrote:
>> On 01/02/18 12:16, Horia Geantă wrote:
>>> If the loop cannot exit based on value of "ret" != -EAGAIN, then it
>>> means
>>> caam_prob
a ("crypto: caam - enable instantiation of all RNG4 state
> handles")
>
> Reported-by: Ryan Harkin <ryan.har...@linaro.org>
> Cc: "Horia Geantă" <horia.gea...@nxp.com>
> Cc: Aymen Sghaier <aymen.sgha...@nxp.com>
> Cc: Fabio Estevam <fa
scha Hauer <ker...@pengutronix.de>
> Cc: linux-arm-ker...@lists.infradead.org
> Cc: "Horia Geantă" <horia.gea...@nxp.com>
> Cc: Aymen Sghaier <aymen.sgha...@nxp.com>
> Cc: Fabio Estevam <fabio.este...@nxp.com>
> Cc: Peng Fan <peng@nxp.com>
Update gcm(aes) descriptors (generic, rfc4106 and rfc4543) such that
they would also work when submitted via the QI interface.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg.c | 19 +++--
drivers/crypto/caam/caamalg_desc.c
by HW to the right
with 0x_0001 (up to 16 bytes - AES block size), according to the
GCM specification.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg_qi.c | 374 +++
1 file changed, 374 insertions(+)
diff --git a/d
Crypto drivers are expected to return -EBADMSG in case of
ICV check (authentication) failure.
In this case it also makes sense to suppress the error message
in the QI dequeue callback.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg_qi.
On 1/24/2018 4:50 PM, Bryan O'Donoghue wrote:
> This patch-set enables CAAM on the i.MX7s and fixes a number of issues
> identified with the CAAM driver and hardware when TrustZone mode is
> enabled.
>
> The first block of patches are simple bug-fixes, followed by a second block
> of patches
Harkin <ryan.har...@linaro.org>
> Signed-off-by: Rui Miguel Silva <rui.si...@linaro.org>
> Cc: "Horia Geantă" <horia.gea...@nxp.com>
> Cc: Aymen Sghaier <aymen.sgha...@nxp.com>
> Cc: Fabio Estevam <fabio.este...@nxp.com>
> Cc: Peng Fan <peng
an Gunthorpe <log...@deltatee.com>
> Cc: Andy Shevchenko <andy.shevche...@gmail.com>
> Cc: Horia Geantă <horia.gea...@nxp.com>
> Cc: Dan Douglass <dan.dougl...@nxp.com>
> Cc: Herbert Xu <herb...@gondor.apana.org.au>
> Cc: "David S. Miller" <da...@davemloft.net>
Reviewed-by: Horia Geantă <horia.gea...@nxp.com>
Thanks,
Horia
Shevchenko <andy.shevche...@gmail.com>
> Cc: Horia Geantă <horia.gea...@nxp.com>
> Cc: Dan Douglass <dan.dougl...@nxp.com>
> Cc: Herbert Xu <herb...@gondor.apana.org.au>
> Cc: "David S. Miller" <da...@davemloft.net>
> ---
> drivers/crypto
Save Era in driver's private data for further usage,
like deciding whether an erratum applies or a feature is available
based on its value.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/ctrl.c | 4 +++-
drivers/crypto/caam/intern.h | 1 +
2 files chan
in descriptor - descriptor buffer mapping changes
-key is referenced - key buffer mapping changes
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
v2: fix DMA mapping direction for buffers holding the split key
drivers/crypto/caam/caamalg.c | 112 ---
drivers/crypt
Key data is not modified, it is copied in the shared descriptor.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg_desc.c | 6 +++---
drivers/crypto/caam/desc_constr.h | 10 +-
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/d
ablkcipher shared descriptors are relatively small, thus there is enough
space for the key to be inlined.
Accordingly, there is no need to copy the key in ctx->key.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg.c| 8 ++--
drivers/cr
On 10/12/2017 6:20 PM, Herbert Xu wrote:
> On Fri, Oct 06, 2017 at 03:04:31PM +0200, Christophe Leroy wrote:
>> This serie fixes and improves the talitos crypto driver.
>>
>> First 6 patchs are fixes of failures reported by the new tests in the
>> kernel crypto test manager.
>>
Looks like these
hreaded IRQs.
[...]
I think I've proven from the above that this patch needs to be reverted
due to the performance regression, and that there _is_ most definitely
a deterimental effect of switching from tasklets to threaded IRQs.
[/quote]
Signed-off-by: Horia Geantă <horia.gea...@nxp.
On 11/29/2017 8:28 AM, Herbert Xu wrote:
> On Tue, Oct 10, 2017 at 01:21:59PM +0300, Robert Baronescu wrote:
>> In case buffer length is a multiple of PAGE_SIZE,
>> the S/G table is incorrectly generated.
>> Fix this by handling buflen = k * PAGE_SIZE separately.
>>
>> Signed-off-by: Robert
))
^
drivers/crypto/caam/caamalg_qi.c:1062:16: note: in expansion of macro
CAAM_QI_MAX_ABLKCIPHER_SG
qm_sg_ents, CAAM_QI_MAX_ABLKCIPHER_SG);
^
Fixes: eb9ba37dc15a ("crypto: caam/qi - handle large number of S/Gs case")
Signed-off-by: Horia Geantă <horia.gea...@nxp.com&
On 11/10/2017 4:34 PM, Horia Geantă wrote:
> Offload split key generation in CAAM engine, using DKP.
> DKP is supported starting with Era 6.
>
> Note that the way assoclen is transmitted from the job descriptor
> to the shared descriptor changes - DPOVRD register is used instead
&g
On 11/14/2017 4:59 PM, Tudor Ambarus wrote:
> Results better code readability.
^^ *in* better
>
> Signed-off-by: Tudor Ambarus <tudor.amba...@microchip.com>
Reviewed-by: Horia Geantă <horia.gea...@nxp.com>
Horia
On 11/13/2017 8:28 PM, Tudor Ambarus wrote:
> Hi,
>
> On 11/12/2017 06:26 PM, Horia Geantă wrote:
>
>> -sg[0] - (1 entry) reserved for associated data, filled outside
>> sg_init_aead()
>
> Let's fill the sg[0] with aad inside sg_init_aead()!
>
This could be do
On 11/13/2017 8:24 PM, Tudor Ambarus wrote:
> Hi,
>
> On 10/10/2017 01:21 PM, Robert Baronescu wrote:
>> In case buffer length is a multiple of PAGE_SIZE,
>> the S/G table is incorrectly generated.
>> Fix this by handling buflen = k * PAGE_SIZE separately.
>>
>> Signed-off-by: Robert Baronescu
On 11/10/2017 6:44 PM, Kim Phillips wrote:
> On Fri, 10 Nov 2017 08:02:01 +
> Radu Andrei Alexe wrote:
[snip]>> 2. I wanted this driver to be tracked by the dma engine team.
They have
>> the right expertise to provide adequate feedback. If all the code was in
>> the
On 11/10/2017 1:23 PM, Herbert Xu wrote:
> On Fri, Nov 10, 2017 at 09:17:33AM +0000, Horia Geantă wrote:
>>
>>> I must be missing something. In the case rem == 0, let's say
>>> the original value of np is npo. Then at the start of the loop,
>>> np = npo - 1
registers.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamalg.c | 52 +--
drivers/crypto/caam/caamalg_desc.c | 176 ++---
drivers/crypto/caam/caamalg_desc.h | 10 +--
drivers/crypto/caam/caamalg_qi.c | 31 ++-
d
Save Era in driver's private data for further usage,
like deciding whether an erratum applies or a feature is available
based on its value.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/ctrl.c | 4 +++-
drivers/crypto/caam/intern.h | 1 +
2 files chan
On 11/10/2017 9:43 AM, Herbert Xu wrote:
> On Fri, Nov 10, 2017 at 06:37:22AM +0000, Horia Geantă wrote:
>> On 11/10/2017 12:21 AM, Herbert Xu wrote:
>>> On Thu, Nov 09, 2017 at 02:37:29PM +, Horia Geantă wrote:
>>>>
>>>>>> sg_init_t
On 11/10/2017 12:21 AM, Herbert Xu wrote:
> On Thu, Nov 09, 2017 at 02:37:29PM +0000, Horia Geantă wrote:
>>
>>>>sg_init_table(sg, np + 1);
>> sg_mark_end() marks sg[np].
>>
>>>> - np--;
>>>> + if (rem)
>>>> + np-
On 11/3/2017 2:42 PM, Herbert Xu wrote:
> On Tue, Oct 10, 2017 at 01:21:59PM +0300, Robert Baronescu wrote:
>> In case buffer length is a multiple of PAGE_SIZE,
>> the S/G table is incorrectly generated.
>> Fix this by handling buflen = k * PAGE_SIZE separately.
>>
>> Signed-off-by: Robert
On 11/2/2017 10:14 AM, Gilad Ben-Yossef wrote:
> We are being passed an IV buffer from unknown origin, which may be
> stack allocated and thus not safe for DMA. Allocate a DMA safe
> buffer for the IV and use that instead.
>
IIUC this fixes only the (a)blkcipher / skcipher algorithms.
What about
ctx_map_to_sec4_sg() function, added in
commit 045e36780f115 ("crypto: caam - ahash hmac support")
has never used the "desc" parameter, so let's drop it.
Signed-off-by: Horia Geantă <horia.gea...@nxp.com>
---
drivers/crypto/caam/caamhash.c | 8
1 file c
Extended descriptor allocation has been changed by
commit dde20ae9d6383 ("crypto: caam - Change kmalloc to kzalloc to avoid
residual data")
to provide zeroized memory, meaning we no longer have to sanitize
its members - edesc->src_nents and edesc->dst_dma.
Signed-off-by: Horia G
On 10/31/2017 10:00 AM, Herbert Xu wrote:
> On Tue, Oct 31, 2017 at 07:56:26AM +, Gilad Ben-Yossef wrote:
>> The IV was allocated on the stack in testmgr skcipher tests.
>> Since HW based tfm providers need to DMA the IV to the HW,
>> this leads to problems and is detected by the DMA-API debug
From: Radu Alexe
The caam_dma is a memcpy DMA driver based on the DMA functionality of
the CAAM hardware block. It creates a DMA channel for each JR of the
CAAM. This patch adds functionality that is used by the caam_dma that is
not yet part of the JR driver.
Signed-off-by:
From: Radu Alexe
This module introduces a memcpy DMA driver based on the DMA capabilities
of the CAAM hardware block. CAAM DMA is a platform driver that is only
probed if the device is defined in the device tree. The driver creates
a DMA channel for each JR of the CAAM. This
From: Radu Alexe
Signed-off-by: Radu Alexe
---
arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi | 6 ++
1 file changed, 6 insertions(+)
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
b/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
index
From: Radu Alexe
Signed-off-by: Radu Alexe
---
.../devicetree/bindings/crypto/fsl-sec4.txt | 21 +
1 file changed, 21 insertions(+)
diff --git a/Documentation/devicetree/bindings/crypto/fsl-sec4.txt
From: Radu Alexe
This patch-set introduces a new DMA memcpy driver based on the DMA
capabilities of the CAAM crypto engine. Because of this dependency the
included commits target various parts of the kernel tree.
Patch 1.
Since the CAAM DMA driver is a platform driver it is
1 - 100 of 375 matches
Mail list logo