Re: [PATCH v3 11/22] staging: ccree: fix line indentation and breaks

2017-08-14 Thread Joe Perches
On Tue, 2017-08-15 at 09:26 +0300, Gilad Ben-Yossef wrote: > Fix wrong indentation and line breaks, including missing tabs, > breaking lines longer then 80 char or wrongly broken. [] > diff --git a/drivers/staging/ccree/ssi_driver.c > b/drivers/staging/ccree/ssi_driver.c [] > -

[PATCH v3 01/22] staging: ccree: fix split strings

2017-08-14 Thread Gilad Ben-Yossef
Fix strings in log messages being split across lines and the resulting alignment issues when being fixed. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_aead.c| 9 ++-- drivers/staging/ccree/ssi_buffer_mgr.c | 86 ++--- drivers/staging/ccree/s

[PATCH v3 02/22] staging: ccree: kmalloc by sizeof var not type

2017-08-14 Thread Gilad Ben-Yossef
Change places where we alloc memory by sizeof type to sizeof var. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_aead.c| 4 ++-- drivers/staging/ccree/ssi_cipher.c | 4 ++-- drivers/staging/ccree/ssi_driver.c | 2 +- drivers/staging/ccree/ssi_hash.c| 4 ++

[PATCH v3 04/22] staging: ccree: Convert to devm_ioremap_resource for map, unmap

2017-08-14 Thread Gilad Ben-Yossef
From: Suniel Mahesh It is recommended to use managed function devm_ioremap_resource(), which simplifies driver cleanup paths and driver code. This patch does the following: (a) replace request_mem_region(), ioremap() and corresponding error handling with devm_ioremap_resource(). (b) remove struct

[PATCH v3 03/22] staging: ccree: Replace kzalloc with devm_kzalloc

2017-08-14 Thread Gilad Ben-Yossef
From: Suniel Mahesh It is recommended to use managed function devm_kzalloc, which simplifies driver cleanup paths and driver code. This patch does the following: (a) replace kzalloc with devm_kzalloc. (b) drop kfree(), because memory allocated with devm_kzalloc() is automatically freed on driver

[PATCH v3 05/22] staging: ccree: Use platform_get_irq and devm_request_irq

2017-08-14 Thread Gilad Ben-Yossef
From: Suniel Mahesh It is recommended to use managed function devm_request_irq(), which simplifies driver cleanup paths and driver code. This patch does the following: (a) replace platform_get_resource(), request_irq() and corresponding error handling with platform_get_irq() and devm_request_irq(

[PATCH v3 06/22] staging: ccree: simplify resource release on error

2017-08-14 Thread Gilad Ben-Yossef
The resource release on probe/init error was being handled in an awkward manner and possibly leaking memory on certain (unlikely) error path. Fix it by simplifying the error resource release and making it easier to track. Reported-by: Dan Carpenter Signed-off-by: Gilad Ben-Yossef --- drivers/s

[PATCH v3 08/22] staging: ccree: remove m32r as supported platform

2017-08-14 Thread Gilad Ben-Yossef
M32R requires special handling due due to how it has implemented ioread32. It is also an orphaned arch on Linux and doesn't seem to be worth the trouble. So until we have a real user, remove support for it. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/Kconfig | 2 +- 1 file changed,

[PATCH v3 09/22] staging: ccree: Fix format/argument mismatches

2017-08-14 Thread Gilad Ben-Yossef
From: Joe Perches By default, debug logging is disabled by CC_DEBUG not being defined. Convert SSI_LOG_DEBUG to use no_printk instead of an empty define to validate formats and arguments. Fix fallout. Miscellanea: o One of the conversions now uses %pR instead of multiple uses of %pad Signed-

[PATCH v3 07/22] staging: ccree: remove unused completion

2017-08-14 Thread Gilad Ben-Yossef
icache_setup_completion is no longer used. Remove it. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_driver.c | 2 -- drivers/staging/ccree/ssi_driver.h | 1 - 2 files changed, 3 deletions(-) diff --git a/drivers/staging/ccree/ssi_driver.c b/drivers/staging/ccree/ssi_driver.c in

[PATCH v3 10/22] staging: ccree: rewrite GET_DMA_BUFFER_TYPE as func

2017-08-14 Thread Gilad Ben-Yossef
The GET_DMA_BUFFER_TYPE macro was triggering a macro argument reuse warning from checkpatch. Rewrite the macro as inline function instead to avoid risk of unintended side effects. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_buffer_mgr.c | 26 +- drivers/

[PATCH v3 12/22] staging: ccree: align box comment correctly

2017-08-14 Thread Gilad Ben-Yossef
Fix indentation in first comment. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_hash.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/drivers/staging/ccree/ssi_hash.c b/drivers/staging/ccree/ssi_hash.c index b7d6586..b95c3ce 100

[PATCH v3 11/22] staging: ccree: fix line indentation and breaks

2017-08-14 Thread Gilad Ben-Yossef
Fix wrong indentation and line breaks, including missing tabs, breaking lines longer then 80 char or wrongly broken. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_driver.c | 107 +++-- 1 file changed, 67 insertions(+), 40 deletions(-) diff --git a

[PATCH v3 13/22] staging: ccree: fix line indentation and breaks

2017-08-14 Thread Gilad Ben-Yossef
Fix source line indentation and breaks Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_hash.c | 494 ++- 1 file changed, 284 insertions(+), 210 deletions(-) diff --git a/drivers/staging/ccree/ssi_hash.c b/drivers/staging/ccree/ssi_hash.c index b

[PATCH v3 14/22] staging: ccree: fix struct init braces

2017-08-14 Thread Gilad Ben-Yossef
Put struct init braces on line of it's own. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_hash.c | 32 1 file changed, 24 insertions(+), 8 deletions(-) diff --git a/drivers/staging/ccree/ssi_hash.c b/drivers/staging/ccree/ssi_hash.c index e2dc5d8

[PATCH v3 15/22] staging: ccree: fix line indentation and breaks

2017-08-14 Thread Gilad Ben-Yossef
Fix source line indentation and breaks in ssi_aead.c Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_aead.c | 1024 -- 1 file changed, 532 insertions(+), 492 deletions(-) diff --git a/drivers/staging/ccree/ssi_aead.c b/drivers/staging/ccree/ssi_

[PATCH v3 20/22] staging: ccree: replace noop macro with inline

2017-08-14 Thread Gilad Ben-Yossef
Replace noop macro with a noop inline function Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_driver.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/ccree/ssi_driver.h b/drivers/staging/ccree/ssi_driver.h index 0b9c7e6..063a1cc 100644 ---

[PATCH v3 18/22] staging: ccree: move over to BIT macro for bit defines

2017-08-14 Thread Gilad Ben-Yossef
Use BIT macro for bit definitions where needed. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_cipher.h | 10 +- drivers/staging/ccree/ssi_driver.c | 3 ++- drivers/staging/ccree/ssi_driver.h | 6 +++--- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/dri

[PATCH v3 17/22] staging: ccree: clean up comments

2017-08-14 Thread Gilad Ben-Yossef
Clean up comments: fix style, trim long lines and remove useless ones. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_aead.c| 40 + drivers/staging/ccree/ssi_aead.h| 47 ++--- drivers/staging/ccree/ssi_buffer_mgr.c |

[PATCH v3 16/22] staging: ccree: fix spelling mistakes

2017-08-14 Thread Gilad Ben-Yossef
Fix various spelling mistakes in comments. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_cipher.c | 2 +- drivers/staging/ccree/ssi_hash.c| 2 +- drivers/staging/ccree/ssi_hash.h| 2 +- drivers/staging/ccree/ssi_ivgen.c | 2 +- drivers/staging/ccree/ssi

[PATCH v3 19/22] staging: ccree: fix code indent

2017-08-14 Thread Gilad Ben-Yossef
Fix multiple code indentation issues. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_buffer_mgr.c | 23 --- drivers/staging/ccree/ssi_cipher.c | 2 +- drivers/staging/ccree/ssi_sysfs.c | 4 +++- 3 files changed, 16 insertions(+), 13 deletions(-) dif

[PATCH v3 22/22] staging: ccree: remove BUG macro usage

2017-08-14 Thread Gilad Ben-Yossef
Replace BUG() macro usage that crash the kernel with alternatives that signal error and/or try to recover. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_buffer_mgr.c | 14 ++ drivers/staging/ccree/ssi_cipher.c | 1 - drivers/staging/ccree/ssi_pm.c | 3

[PATCH v3 21/22] staging: ccree: save ciphertext for CTS IV

2017-08-14 Thread Gilad Ben-Yossef
The crypto API requires saving the last blocks of ciphertext in req->info for use as IV for CTS mode. The ccree driver was not doing it and so failing tcrypt tests in some situations. This patch fixes the issue. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_cipher.c | 31

[PATCH v3 00/22] staging: ccree: fixes and simplifications

2017-08-14 Thread Gilad Ben-Yossef
The series includes various bug fixes, code simplification and style cleanups. Changer from v2: - Drop M32R as supported architecture, which resolve the kbuild bot warnings on Joe Perches patch. - Bug fix that properly saves last bytes of ciphertext for CTS in skcipher - Even more coding styl

Re: [PATCH v5 18/19] crypto: mediatek: move to generic async completion

2017-08-14 Thread Ryder Lee
On Mon, 2017-08-14 at 18:21 +0300, Gilad Ben-Yossef wrote: > The mediatek driver starts several async crypto ops and waits for their > completions. Move it over to generic code doing the same. > > Signed-off-by: Gilad Ben-Yossef > --- Acked-by: Ryder Lee > drivers/crypto/mediatek/mtk-aes.c |

Re: [PATCH v5 05/19] crypto: introduce crypto wait for async op

2017-08-14 Thread Jonathan Cameron
On Mon, 14 Aug 2017 18:21:15 +0300 Gilad Ben-Yossef wrote: > Invoking a possibly async. crypto op and waiting for completion > while correctly handling backlog processing is a common task > in the crypto API implementation and outside users of it. > > This patch adds a generic implementation for

Re: random.c: LFSR polynomials are not irreducible/primitive

2017-08-14 Thread Theodore Ts'o
On Mon, Aug 14, 2017 at 10:20:18AM +0200, Stephan Mueller wrote: > Hi Ted, > > drivers/char/random.c contains the following comment: > > """ > * Our mixing functions were analyzed by Lacharme, Roeck, Strubel, and > * Videau in their paper, "The Linux Pseudorandom Number Generator > * Revisited

Re: [PATCH v5 02/19] crypto: ccp: use -EAGAIN for transient busy indication

2017-08-14 Thread Gary R Hook
On 08/14/2017 10:21 AM, Gilad Ben-Yossef wrote: Replace -EBUSY with -EAGAIN when reporting transient busy indication in the absence of backlog. Signed-off-by: Gilad Ben-Yossef Reviewed-by: Gary R Hook --- drivers/crypto/ccp/ccp-crypto-main.c | 8 +++- drivers/crypto/ccp/ccp-dev.c

[PATCH v5 01/19] crypto: change transient busy return code to -EAGAIN

2017-08-14 Thread Gilad Ben-Yossef
The crypto API was using the -EBUSY return value to indicate both a hard failure to submit a crypto operation into a transformation provider when the latter was busy and the backlog mechanism was not enabled as well as a notification that the operation was queued into the backlog when the backlog m

[PATCH v5 02/19] crypto: ccp: use -EAGAIN for transient busy indication

2017-08-14 Thread Gilad Ben-Yossef
Replace -EBUSY with -EAGAIN when reporting transient busy indication in the absence of backlog. Signed-off-by: Gilad Ben-Yossef --- drivers/crypto/ccp/ccp-crypto-main.c | 8 +++- drivers/crypto/ccp/ccp-dev.c | 7 +-- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/

[PATCH v5 04/19] crypto: marvell/cesa: remove redundant backlog checks on EBUSY

2017-08-14 Thread Gilad Ben-Yossef
Now that -EBUSY return code only indicates backlog queueing we can safely remove the now redundant check for the CRYPTO_TFM_REQ_MAY_BACKLOG flag when -EBUSY is returned. Signed-off-by: Gilad Ben-Yossef --- drivers/crypto/marvell/cesa.c | 3 +-- drivers/crypto/marvell/cesa.h | 2 +- 2 files chang

[PATCH v5 03/19] crypto: remove redundant backlog checks on EBUSY

2017-08-14 Thread Gilad Ben-Yossef
Now that -EBUSY return code only indicates backlog queueing we can safely remove the now redundant check for the CRYPTO_TFM_REQ_MAY_BACKLOG flag when -EBUSY is returned. Signed-off-by: Gilad Ben-Yossef --- crypto/ahash.c| 12 +++- crypto/cts.c | 6 ++ crypto/lrw.c

[PATCH v5 05/19] crypto: introduce crypto wait for async op

2017-08-14 Thread Gilad Ben-Yossef
Invoking a possibly async. crypto op and waiting for completion while correctly handling backlog processing is a common task in the crypto API implementation and outside users of it. This patch adds a generic implementation for doing so in preparation for using it across the board instead of hand

[PATCH v5 06/19] crypto: move algif to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
algif starts several async crypto ops and waits for their completion. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- crypto/af_alg.c | 27 --- crypto/algif_aead.c | 8 crypto/algif_hash.c | 30 ++-

[PATCH v5 08/19] crypto: move drbg to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
DRBG is starting an async. crypto op and waiting for it complete. Move it over to generic code doing the same. The code now also passes CRYPTO_TFM_REQ_MAY_SLEEP flag indicating crypto request memory allocation may use GFP_KERNEL which should be perfectly fine as the code is obviously sleeping for

[PATCH v5 07/19] crypto: move pub key to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
public_key_verify_signature() is starting an async crypto op and waiting for it to complete. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- crypto/asymmetric_keys/public_key.c | 28 1 file changed, 4 insertions(+), 24 deletions(-) d

[PATCH v5 10/19] crypto: move testmgr to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
testmgr is starting async. crypto ops and waiting for them to complete. Move it over to generic code doing the same. This also provides a test of the generic crypto async. wait code. Signed-off-by: Gilad Ben-Yossef --- crypto/testmgr.c | 204 ++---

[PATCH v5 09/19] crypto: move gcm to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
gcm is starting an async. crypto op and waiting for it complete. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- crypto/gcm.c | 32 ++-- 1 file changed, 6 insertions(+), 26 deletions(-) diff --git a/crypto/gcm.c b/crypto/gcm.c index 3

[PATCH v5 11/19] fscrypt: move to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
fscrypt starts several async. crypto ops and waiting for them to complete. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- fs/crypto/crypto.c | 28 fs/crypto/fname.c | 36 ++-- fs/cry

[PATCH v5 12/19] dm: move dm-verity to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
dm-verity is starting async. crypto ops and waiting for them to complete. Move it over to generic code doing the same. This also fixes a possible data coruption bug created by the use of wait_for_completion_interruptible() without dealing correctly with an interrupt aborting the wait prior to the

[PATCH v5 14/19] ima: move to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
ima starts several async crypto ops and waits for their completions. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef Acked-by: Mimi Zohar --- security/integrity/ima/ima_crypto.c | 56 +++-- 1 file changed, 17 insertions(+), 39 deleti

[PATCH v5 13/19] cifs: move to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
cifs starts an async. crypto op and waits for their completion. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef Acked-by: Pavel Shilovsky --- fs/cifs/smb2ops.c | 30 -- 1 file changed, 4 insertions(+), 26 deletions(-) diff --git a/fs/cif

[PATCH v5 15/19] crypto: tcrypt: move to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
tcrypt starts several async crypto ops and waits for their completions. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- crypto/tcrypt.c | 84 + 1 file changed, 25 insertions(+), 59 deletions(-) diff --git

[PATCH v5 16/19] crypto: talitos: move to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
The talitos driver starts several async crypto ops and waits for their completions. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- drivers/crypto/talitos.c | 38 +- 1 file changed, 5 insertions(+), 33 deletions(-) diff --git

[PATCH v5 18/19] crypto: mediatek: move to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
The mediatek driver starts several async crypto ops and waits for their completions. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- drivers/crypto/mediatek/mtk-aes.c | 31 +-- 1 file changed, 5 insertions(+), 26 deletions(-) diff --g

[PATCH v5 17/19] crypto: qce: move to generic async completion

2017-08-14 Thread Gilad Ben-Yossef
The qce driver starts several async crypto ops and waits for their completions. Move it over to generic code doing the same. Signed-off-by: Gilad Ben-Yossef --- drivers/crypto/qce/sha.c | 30 -- 1 file changed, 4 insertions(+), 26 deletions(-) diff --git a/drivers/c

[PATCH v5 19/19] crypto: adapt api sample to use async. op wait

2017-08-14 Thread Gilad Ben-Yossef
The code sample is waiting for an async. crypto op completion. Adapt sample to use the new generic infrastructure to do the same. This also fixes a possible data coruption bug created by the use of wait_for_completion_interruptible() without dealing correctly with an interrupt aborting the wait pr

[PATCH v5 00/19] simplify crypto wait for async op

2017-08-14 Thread Gilad Ben-Yossef
Many users of kernel async. crypto services have a pattern of starting an async. crypto op and than using a completion to wait for it to end. This patch set simplifies this common use case in two ways: First, by separating the return codes of the case where a request is queued to a backlog due to

Re: [PATCH v5 2/5] lib: Add zstd modules

2017-08-14 Thread David Sterba
On Fri, Aug 11, 2017 at 09:20:10AM -0400, Chris Mason wrote: > > > On 08/10/2017 03:25 PM, Hugo Mills wrote: > > On Thu, Aug 10, 2017 at 01:41:21PM -0400, Chris Mason wrote: > >> On 08/10/2017 04:30 AM, Eric Biggers wrote: > >>> > >>> Theses benchmarks are misleading because they compress the who

[PATCH 1/2] crypto/chacha20: fix handling of chunked input

2017-08-14 Thread Ard Biesheuvel
Commit 9ae433bc79f9 ("crypto: chacha20 - convert generic and x86 versions to skcipher") ported the existing chacha20 code to use the new skcipher API, and introduced a bug along the way. Unfortunately, the tcrypt tests did not catch the error, and it was only found recently by Tobias. Stefan kindl

[PATCH 2/2] crypto: testmgr - add chunked test cases for chacha20

2017-08-14 Thread Ard Biesheuvel
We failed to catch a bug in the chacha20 code after porting it to the skcipher API. We would have caught it if any chunked tests had been defined, so define some now so we will catch future regressions. Signed-off-by: Ard Biesheuvel --- crypto/testmgr.h | 7 +++ 1 file changed, 7 insertions(

[PATCH 1/3] crypto: skcipher - export crypto_skcipher_type2

2017-08-14 Thread Corentin Labbe
This patch export crypto_skcipher_type2 like others cra_type Signed-off-by: Corentin Labbe --- crypto/skcipher.c | 3 ++- include/crypto/algapi.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/crypto/skcipher.c b/crypto/skcipher.c index 4faa0fd53b0c..c6523826890f 1006

[PATCH 2/3] crypto: engine - find request type with cra_type

2017-08-14 Thread Corentin Labbe
The current method for finding request type is based on crypto_tfm_alg_type. But in case of skcipher, it is the same than ablkcipher. Using cra_type for this work permits to make the distinction between the two. Signed-off-by: Corentin Labbe --- crypto/crypto_engine.c | 19 ---

[PATCH 3/3] crypto: engine - Permit to enqueue skcipher request

2017-08-14 Thread Corentin Labbe
The crypto engine could actually only enqueue hash and ablkcipher request. This patch permit it to enqueue skcipher requets by adding all necessary functions. Signed-off-by: Corentin Labbe --- crypto/crypto_engine.c | 114 include/crypto/engine.h

[PATCH 0/3 v3] crypto: engine - Permit to enqueue skcipher request

2017-08-14 Thread Corentin Labbe
Hello The crypto engine could actually only enqueue hash and ablkcipher request. This patch serie permit it to enqueue skcipher requests by adding all necessary functions. Changes since v2 - added two patch for finding request type according to its cra_type Changes since v1 - Aligned to column s

Re: scatterwalk.c: Nullpointer dereference

2017-08-14 Thread Stephan Mueller
Am Montag, 14. August 2017, 14:25:49 CEST schrieb Plauth, Max: Hi Max, > Dear linux-crypto community, > > I think I might have run into a bug in crypto/scatterwalk.c: > - at the end of scatterwalk_pagedone, sg_next(walk->sg) is fed as an > argument to scatterwalk_start(...) - sg_next (lib/scatte

scatterwalk.c: Nullpointer dereference

2017-08-14 Thread Plauth, Max
Dear linux-crypto community, I think I might have run into a bug in crypto/scatterwalk.c: - at the end of scatterwalk_pagedone, sg_next(walk->sg) is fed as an argument to scatterwalk_start(...) - sg_next (lib/scatterlist.c) returns NULL in the case of sg_is_last(sg) - In this case, NULL is being

[PATCH] crypto: cavium - add release_firmware to all return case

2017-08-14 Thread Corentin Labbe
Two return case misses to call release_firmware() and so leak some memory. This patch create a fw_release label (and so a common error path) and use it on all return case. Detected by CoverityScan, CID#1416422 ("Resource Leak") Signed-off-by: Corentin Labbe --- drivers/crypto/cavium/cpt/cptpf_

Crypto Fixes for 4.13

2017-08-14 Thread Herbert Xu
Hi Linus: This push fixes an error path bug in ixp4xx as well as a read overrun in sha1-avx2. Please pull from git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6.git linus Herbert Xu (1): crypto: ixp4xx - Fix error handling path in 'aead_perform()' megha@linux.intel.

Re: [PATCH v8 0/4] crypto: add algif_akcipher user space API

2017-08-14 Thread Marcel Holtmann
Hi Stephan, >>> The first part is clearly where AF_ALG fits and keyctl does not. This is >>> provided with the current patch set. As the keyctl API only handles, well, >>> keys, access to the raw ciphers may not be possible through this API. And >>> let us face it, a lot of user space code shall s

Re: [Freedombox-discuss] Hardware Crypto

2017-08-14 Thread Gilad Ben-Yossef
Hi, On Sun, Aug 13, 2017 at 8:21 PM, Sandy Harris wrote: > Showing only the key parts of the message: > >> From: John Gilmore > > An exceedingly knowledgeable guy, one we should probably take seriously. > https://en.wikipedia.org/wiki/John_Gilmore_(activist) > >> Most hardware crypto accelerator

random.c: LFSR polynomials are not irreducible/primitive

2017-08-14 Thread Stephan Mueller
Hi Ted, drivers/char/random.c contains the following comment: """ * Our mixing functions were analyzed by Lacharme, Roeck, Strubel, and * Videau in their paper, "The Linux Pseudorandom Number Generator * Revisited" (see: http://eprint.iacr.org/2012/251.pdf). In their * paper, they point out

Re: [PATCH] crypto: caam - properly set IV after {en,de}crypt

2017-08-14 Thread Gilad Ben-Yossef
Hi, On Thu, Jun 29, 2017 at 1:19 PM, Horia Geantă wrote: > On 6/28/2017 4:42 PM, Horia Geantă wrote: >> On 6/28/2017 4:27 PM, David Gstir wrote: >>> Certain cipher modes like CTS expect the IV (req->info) of >>> ablkcipher_request (or equivalently req->iv of skcipher_request) to >>> contain the l

Re: [PATCH v8 0/4] crypto: add algif_akcipher user space API

2017-08-14 Thread Stephan Mueller
Am Montag, 14. August 2017, 08:26:22 CEST schrieb Marcel Holtmann: Hi Marcel, > > The first part is clearly where AF_ALG fits and keyctl does not. This is > > provided with the current patch set. As the keyctl API only handles, well, > > keys, access to the raw ciphers may not be possible through