[PATCH] crypto: caam - fix sg dump

2016-09-16 Thread Catalin Vasile
Ensure scatterlists have a virtual memory mapping before dumping. Signed-off-by: Catalin Vasile --- drivers/crypto/caam/caamalg.c | 65 +-- 1 file changed, 50 insertions(+), 15 deletions(-) diff --git a/drivers/crypto/caam/caamalg.c b/drivers/crypto/caam/

Re: [PATCH v2 3/8] hwrng: omap - Switch to non-obsolete read API implementation

2016-09-16 Thread Romain Perier
Hi, Le 13/09/2016 11:48, Herbert Xu a écrit : On Wed, Sep 07, 2016 at 05:57:38PM +0200, Romain Perier wrote: + +static int omap_rng_do_read(struct hwrng *rng, void *data, size_t max, + bool wait) { struct omap_rng_dev *priv; - int data, i; priv

[PATCH v3 0/8] Add support for SafeXcel IP-76 to OMAP RNG

2016-09-16 Thread Romain Perier
The driver omap-rng has a lot of similarity with the IP block SafeXcel IP-76. A lot of registers are the same and the way that the driver works is very closed the description of the TRNG EIP76 in its datasheet. This series refactorize the driver, add support for generating bigger output random dat

[PATCH v3 1/8] dt-bindings: Add vendor prefix for INSIDE Secure

2016-09-16 Thread Romain Perier
This commits adds a vendor for the company INSIDE Secure. See https://www.insidesecure.com, for more details. Signed-off-by: Romain Perier --- Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/vendor-prefix

[PATCH v3 8/8] arm64: dts: marvell: add TRNG description for Armada 8K CP

2016-09-16 Thread Romain Perier
This commits adds the devicetree description of the SafeXcel IP-76 TRNG found in the two Armada CP110. Signed-off-by: Romain Perier --- arch/arm64/boot/dts/marvell/armada-cp110-master.dtsi | 8 arch/arm64/boot/dts/marvell/armada-cp110-slave.dtsi | 8 2 files changed, 16 insert

[PATCH v3 5/8] hwrng: omap - Add support for 128-bit output of data

2016-09-16 Thread Romain Perier
So far, this driver only supports up to 64 bits of output data generated by an RNG. Some IP blocks, like the SafeXcel IP-76 supports up to 128 bits of output data. This commits renames registers descriptions OUTPUT_L_REG and OUTPUT_H_REG to OUTPUT_0_REG and OUPUT_1_REG, respectively. It also adds t

[PATCH v3 2/8] dt-bindings: omap-rng: Document SafeXcel IP-76 device variant

2016-09-16 Thread Romain Perier
This commits add missing fields in the documentation that are used by the new device variant. It also includes DT example to show how the variant should be used. Signed-off-by: Romain Perier --- Documentation/devicetree/bindings/rng/omap_rng.txt | 14 -- 1 file changed, 12 insertions

[PATCH v3 4/8] hwrng: omap - Remove global definition of hwrng

2016-09-16 Thread Romain Perier
The omap-rng driver currently assumes that there will only ever be a single instance of an RNG device. For this reason, there is a statically allocated struct hwrng, with a fixed name. However, registering two struct hwrng with the same isn't accepted by the RNG framework, so we need to switch to a

[PATCH v3 7/8] hwrng: omap - Add device variant for SafeXcel IP-76 found in Armada 8K

2016-09-16 Thread Romain Perier
This commits adds a device variant for Safexcel,EIP76 found in Marvell Armada 8k. It defines registers mapping with the good offset and add a specific initialization function. Signed-off-by: Romain Perier --- Changes in v2: - Call pm_runtime_put_sync from the label err_register. When there is a

[PATCH v3 3/8] hwrng: omap - Switch to non-obsolete read API implementation

2016-09-16 Thread Romain Perier
The ".data_present" and ".data_read" operations are marked as OBSOLETE in the hwrng API. We have to use the ".read" operation instead. It makes the driver simpler and moves the busy loop, that waits until enough data is generated, to the read function. We simplify this step by only checking the sta

[PATCH v3 6/8] hwrng: omap - Don't prefix the probe message with OMAP

2016-09-16 Thread Romain Perier
So far, this driver was only used for OMAP SoCs. However, if a device variant is added for an IP block that has nothing to do with the OMAP platform, the message "OMAP Random Number Generator Ver" is displayed anyway. Instead of hardcoding "OMAP" into this message, we decide to only display "Random

[PATCH] crypto: gcm - Fix IV buffer size in crypto_gcm_setkey

2016-09-16 Thread Ondrej Mosnáček
The cipher block size for GCM is 16 bytes, and thus the CTR transform used in crypto_gcm_setkey() will also expect a 16-byte IV. However, the code currently reserves only 8 bytes for the IV, causing an out-of-bounds access in the CTR transform. This patch fixes the issue by setting the size of the

Re: [PATCH v3 0/8] Add support for SafeXcel IP-76 to OMAP RNG

2016-09-16 Thread Romain Perier
Hello, Le 16/09/2016 12:08, Romain Perier a écrit : The driver omap-rng has a lot of similarity with the IP block SafeXcel IP-76. A lot of registers are the same and the way that the driver works is very closed the description of the TRNG EIP76 in its datasheet. This series refactorize the driv

Re: [PATCH -next] hwrng: amd - Fix return value check in mod_init()

2016-09-16 Thread PrasannaKumar Muralidharan
> In case of error, the function devm_kzalloc() or devm_ioport_map() > return NULL pointer not ERR_PTR(). The IS_ERR() test in the return > value check should be replaced with NULL test. > > Fixes: 31b2a73c9c5f ("hwrng: amd - Migrate to managed API") > Signed-off-by: Wei Yongjun > --- > drivers/c

Re: [PATCH] crypto: caam - fix sg dump

2016-09-16 Thread Horia Geanta Neag
On 9/16/2016 12:06 PM, Catalin Vasile wrote: > Ensure scatterlists have a virtual memory mapping before dumping. > > Signed-off-by: Catalin Vasile > --- > drivers/crypto/caam/caamalg.c | 65 > +-- > 1 file changed, 50 insertions(+), 15 deletions(-) > > d

crypto: caam from tasklet to threadirq

2016-09-16 Thread Cata Vasile
Hi, We've tried to test and benchmark your submitted work[1]. Cryptographic offloading is also used in IPsec in the Linux Kernel. In heavy traffic scenarios, the NIC driver competes with the crypto device driver. Most NICs use the NAPI context, which is one of the most prioritized context types

Re: crypto: caam from tasklet to threadirq

2016-09-16 Thread Russell King - ARM Linux
On Fri, Sep 16, 2016 at 02:01:00PM +, Cata Vasile wrote: > Hi, > > We've tried to test and benchmark your submitted work[1]. > > Cryptographic offloading is also used in IPsec in the Linux Kernel. In > heavy traffic scenarios, the NIC driver competes with the crypto device > driver. Most NICs

[PATCH net-next] chcr/cxgb4i/cxgbit/RDMA/cxgb4: Allocate resources dynamically for all cxgb4 ULD's

2016-09-16 Thread Hariprasad Shenai
Allocate resources dynamically to cxgb4's Upper layer driver's(ULD) like cxgbit, iw_cxgb4 and cxgb4i. Allocate resources when they register with cxgb4 driver and free them while unregistering. All the queues and the interrupts for them will be allocated during ULD probe only and freed during remove