Hi Thomas,
On Mon, May 22, 2017 at 09:34:16PM +0200, Thomas Petazzoni wrote:
> On Mon, 22 May 2017 16:45:11 +0200, Antoine Tenart wrote:
> > + interrupts = > IRQ_TYPE_LEVEL_HIGH)>,
>
> You already got the feedback previously that an interrupt that is both
> edge and level at the same
The crypto engine could actually only enqueue hash and ablkcipher request.
This patch permit it to enqueue skcipher requets by adding all necessary
functions.
The only problem is that ablkcipher and skcipher id are the same, so
only one cipher type is usable on the same crypto engine.
Rename ecdh_make_pub_key() to ecc_make_pub_key().
This function might as well be used by ecdsa.
Signed-off-by: Tudor Ambarus
---
crypto/ecc.c | 4 ++--
crypto/ecc.h | 4 ++--
crypto/ecdh.c | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git
setkey can be called multiple times during the existence
of the transformation object. In case of multiple setkey calls,
the old key was not freed and we leaked memory.
Free the old MPI key if any.
Signed-off-by: Tudor Ambarus
---
crypto/dh.c | 3 +++
1 file
On 22/05/17 20:37, Thomas Petazzoni wrote:
> Hello,
>
> On Mon, 22 May 2017 16:02:33 +0100, Marc Zyngier wrote:
>
>>> It also says: 87 => 34 En Lv 5, which is the IRQ I'm looking for.
>>
>> Ah, that one as well. So how is the interrupt routed? Via the ICU, and
>> then to the GIC (with several
crypto_kpp_maxsize() returns minimum length for output buffer
or error code if key hasn't been set. Check for error before
allocating memory.
Signed-off-by: Tudor Ambarus
---
crypto/testmgr.c | 5 +
1 file changed, 5 insertions(+)
diff --git a/crypto/testmgr.c
Hi,
These are various fixes that I made while reading kpp and akcipher
implementations.
For KEYS there is only one patch. It checks the return value of
crypto_akcipher_maxsize().
Changes in v3:
- change error code to ENOKEY instead of EINVAL in
dh/ecdh/rsa_max_size()
- reorder commits
-
If key was not successfully set, return -ENOKEY instead of
-EINVAL.
Signed-off-by: Tudor Ambarus
---
crypto/rsa.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/crypto/rsa.c b/crypto/rsa.c
index 4c280b6..3cf640e 100644
--- a/crypto/rsa.c
+++
Signed-off-by: Tudor Ambarus
---
crypto/ecc.c | 8 +++-
crypto/ecc.h | 13 +++--
crypto/ecdh.c | 11 +--
3 files changed, 11 insertions(+), 21 deletions(-)
diff --git a/crypto/ecc.c b/crypto/ecc.c
index 414c78a..69b4cc4 100644
---
If someone called this function before a successful setkey,
we would end up in a NULL dereference.
The function should return minimum size for output buffer
or error code if key hasn't been set.
Signed-off-by: Tudor Ambarus
---
crypto/dh.c | 2 +-
1 file changed, 1
ecc software implementation works with chunks of u64 data. There were some
unnecessary casts to u8 and then back to u64 for the ecc keys. This patch
removes the unnecessary casts.
Signed-off-by: Tudor Ambarus
---
crypto/ecc.c | 28 +---
crypto_akcipher_maxsize() returns minimum length for output buffer
or error code if key hasn't been set. Check for error before
allocating memory.
Signed-off-by: Tudor Ambarus
---
crypto/asymmetric_keys/public_key.c | 5 +
1 file changed, 5 insertions(+)
diff
While here, add missing argument description (ndigits).
Signed-off-by: Tudor Ambarus
---
crypto/dh.c | 4 ++--
crypto/dh_helper.c| 4 ++--
crypto/ecc.h | 8 +---
crypto/ecdh.c | 4 ++--
crypto/ecdh_helper.c | 4 ++--
crypto_akcipher_maxsize() returns minimum length for output buffer
or error code if key hasn't been set. Check for error before
allocating memory.
Signed-off-by: Tudor Ambarus
---
crypto/testmgr.c | 5 +
1 file changed, 5 insertions(+)
diff --git
If someone called this function before a successful setkey,
we would end up in a NULL dereference.
The function should return minimum size for output buffer
or error code if key hasn't been set.
Signed-off-by: Tudor Ambarus
---
crypto/ecdh.c | 6 +++---
1 file
On Wed, May 17, 2017 at 03:29:10PM -0700, Rick Altherr wrote:
> Signed-off-by: Rick Altherr
> ---
>
> Documentation/devicetree/bindings/rng/timeriomem_rng.txt | 7 +++
> 1 file changed, 7 insertions(+)
Acked-by: Rob Herring
By adding a struct device *dev to struct engine, we could store the
device used at register time and so use all dev_xxx functions instead of
pr_xxx.
Signed-off-by: Corentin Labbe
---
crypto/crypto_engine.c | 23 +--
include/crypto/engine.h | 1 +
Hello,
On Tue, 23 May 2017 12:13:28 +0100, Marc Zyngier wrote:
> > The crypto block being in the CP part, it has a wired interrupt to the
> > ICU (also in the CP). The ICU then turns this wired interrupt into a
> > memory write transaction to a register called GICP SPI in the AP, which
> >
On Tue, 2017-05-23 at 14:09 +0200, Corentin Labbe wrote:
> By adding a struct device *dev to struct engine, we could store the
> device used at register time and so use all dev_xxx functions instead of
> pr_xxx.
trivia:
> diff --git a/include/crypto/engine.h b/include/crypto/engine.h
[]
> @@
Dan Carpenter wrote:
> cert->pub->key = kmemdup(ctx->key, ctx->key_size, GFP_KERNEL);
> - if (!cert->pub->key)
> + if (!cert->pub->key) {
> + ret = -ENOMEM;
> goto error_decode;
> + }
Put the "ret = -ENOMEM" line before the
We forgot to set the error code on this path so it could result in
returning NULL which leads to a NULL dereference.
Fixes: db6c43bd2132 ("crypto: KEYS: convert public key and digsig asym to the
akcipher api")
Signed-off-by: Dan Carpenter
diff --git
The updated memory management is described in the top part of the code.
As one benefit of the changed memory management, the AIO and synchronous
operation is now implemented in one common function. The AF_ALG
operation uses the async kernel crypto API interface for each cipher
operation. Thus, the
The updated memory management is described in the top part of the code.
As one benefit of the changed memory management, the AIO and synchronous
operation is now implemented in one common function. The AF_ALG
operation uses the async kernel crypto API interface for each cipher
operation. Thus, the
Hi Herbert,
Changes v8:
- algif_skcipher: fix complaint by checkpatch.pl
- algif_aead: port to 4.12-rc1
- algif_aead: fix complaint by checkpatch.pl
With the changes, you will see a lot of code duplication now
as I deliberately tried to use the same struct and variable names,
the same function
Fixes the following sparse warnings:
drivers/staging/ccree/ssi_hash.c:2447:24: warning: cast to non-scalar
drivers/staging/ccree/ssi_hash.c:2447:24: warning: cast from non-scalar
drivers/staging/ccree/ssi_hash.c:2448:28: warning: cast to non-scalar
drivers/staging/ccree/ssi_hash.c:2448:28:
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_sysfs.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_sysfs.c
b/drivers/staging/ccree/ssi_sysfs.c
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_request_mgr.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_request_mgr.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_sysfs.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_sysfs.h
b/drivers/staging/ccree/ssi_sysfs.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_cipher.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_cipher.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_driver.h | 16 ++--
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/drivers/staging/ccree/ssi_driver.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_fips.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/ccree/ssi_fips.h b/drivers/staging/ccree/ssi_fips.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_fips_data.h | 93 +--
1 file changed, 46 insertions(+), 47 deletions(-)
diff --git
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_pm_ext.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_pm_ext.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_pm_ext.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/staging/ccree/ssi_pm_ext.c
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_request_mgr.c | 37 -
1 file changed, 22 insertions(+), 15 deletions(-)
diff --git
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_pm.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_pm.h b/drivers/staging/ccree/ssi_pm.h
index
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/cc_crypto_ctx.h | 17 ++---
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/drivers/staging/ccree/cc_crypto_ctx.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/cc_hw_queue_defs.h | 32
1 file changed, 16 insertions(+), 16 deletions(-)
diff --git
Fixed block comments across whole ccree driver
Derek Robson (27):
Drivers: ccree: ssi_sysfs.h - align block comments
Drivers: ccree: ssi_sysfs.c - align block comments
Drivers: ccree: ssi_request_mgr.h - align block comments
Drivers: ccree: ssi_request_mgr.c - align block comments
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_fips_ext.c | 46 ++--
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_fips_local.c | 21 -
1 file changed, 12 insertions(+), 9 deletions(-)
diff --git a/drivers/staging/ccree/ssi_fips_local.c
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_hash.c | 9 ++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/ccree/ssi_hash.c
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_ivgen.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/ccree/ssi_ivgen.c
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_fips_ll.c | 21 -
1 file changed, 12 insertions(+), 9 deletions(-)
diff --git a/drivers/staging/ccree/ssi_fips_ll.c
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_hash.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_hash.h b/drivers/staging/ccree/ssi_hash.h
index
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/cc_regs.h | 13 +++--
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/drivers/staging/ccree/cc_regs.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_aead.h | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/ccree/ssi_aead.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/hash_defs.h | 15 ---
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/drivers/staging/ccree/hash_defs.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_aead.c | 45 ++--
1 file changed, 29 insertions(+), 16 deletions(-)
diff --git
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_buffer_mgr.c | 87 +++---
1 file changed, 49 insertions(+), 38 deletions(-)
diff --git
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_buffer_mgr.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ccree/ssi_buffer_mgr.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_config.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/ccree/ssi_config.h
Fixed block comment alignment, Style fix only
Found using checkpatch
Signed-off-by: Derek Robson
---
drivers/staging/ccree/ssi_fips.c | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/staging/ccree/ssi_fips.c
On 23.05.2017 07:08, Herbert Xu wrote:
On Wed, May 17, 2017 at 06:00:35PM +0300, Tudor Ambarus wrote:
crypto_akcipher_maxsize() returns minimum length for output buffer
or error code if key hasn't been set.
Signed-off-by: Tudor Ambarus
---
crypto/testmgr.c | 5
On 23.05.2017 06:58, Herbert Xu wrote:
On Thu, Apr 27, 2017 at 05:17:58PM +0300, Tudor Ambarus wrote:
Hi, Herbert,
I'm working with a crypto accelerator that is capable of generating and
retaining ecc private keys in hardware and further use them for ecdh.
The private keys can not be read
55 matches
Mail list logo