Re: [PATCH 1/4] crypto: qat: Fix random config build warnings

2014-06-25 Thread Herbert Xu
On Wed, Jun 25, 2014 at 06:52:16AM -0700, Tadeusz Struk wrote: > On 06/25/2014 06:36 AM, Herbert Xu wrote: > >>struct icp_qat_fw_la_resp *qat_resp = resp; > >> > struct qat_crypto_request *qat_req = > >> > -(void *)(dma_addr_t)qat_resp->opaque_data; > >> > +

Re: [PATCH v2] DRBG: simplify ordering of linked list in drbg_ctr_df

2014-06-25 Thread Herbert Xu
On Wed, Jun 25, 2014 at 05:08:28PM +0800, Herbert Xu wrote: > On Mon, Jun 23, 2014 at 09:11:29AM +0200, Stephan Mueller wrote: > > As reported by a static code analyzer, the code for the ordering of > > the linked list can be simplified. > > > > Reported-by: kbuild test robot > > Signed-off-by: S

Re: Using s5p-sss hw crypto causes ipsec to break

2014-06-25 Thread Herbert Xu
Sonny Rao wrote: > Hi, I've been investigating an issue relating to hardware crypto which > is that when I enable the s5p-sss module for hardware cryptographic > acceleration on Samsung Exynos SoCs the in-kernel IPSec seems to > break, although cryptographic operations on filesystems/block devices

[PATCH] crypto: print cra driver name in tcrypt tests output

2014-06-25 Thread Luca Clementi
Print the driver name that is being tested. The driver name can be inferred parsing /proc/crypto but having it in the output is clearer Signed-off-by: Luca Clementi --- crypto/tcrypt.c | 31 --- 1 file changed, 20 insertions(+), 11 deletions(-) diff --git a/crypto/

Re: [PATCH] crypto/xor.c: use 2 pages for xor speed testing

2014-06-25 Thread Marek Vasut
On Tuesday, June 17, 2014 at 09:16:03 AM, Amos Kong wrote: [...] > > While looking at this code, can anyone explain to me why we have this > > stuff in crypto/xor.c please ? > > > > 135 #define xor_speed(templ)do_xor_speed((templ), b1, b2) > > 136 > > 137 if (fastest) { > > 138

Re: [PATCH 00/22] Add and use pci_zalloc_consistent

2014-06-25 Thread John W. Linville
On Mon, Jun 23, 2014 at 06:41:28AM -0700, Joe Perches wrote: > Adding the helper reduces object code size as well as overall > source size line count. > > It's also consistent with all the various zalloc mechanisms > in the kernel. > > Done with a simple cocci script and some typing. > > Joe Per

[PATCH v4 2/3] crypto: qce: Build Qualcomm crypto driver

2014-06-25 Thread Stanimir Varbanov
Modify crypto Kconfig and Makefile in order to build the qce driver and adds qce Makefile as well. Signed-off-by: Stanimir Varbanov --- drivers/crypto/Kconfig | 15 +++ drivers/crypto/Makefile |1 + drivers/crypto/qce/Makefile |6 ++ 3 files changed, 22 inserti

[PATCH v4 3/3] ARM: DT: qcom: Add Qualcomm crypto driver binding document

2014-06-25 Thread Stanimir Varbanov
Here is Qualcomm crypto driver device tree binding documentation to used as a reference example. Signed-off-by: Stanimir Varbanov --- .../devicetree/bindings/crypto/qcom-qce.txt| 25 1 files changed, 25 insertions(+), 0 deletions(-) create mode 100644 Documentatio

[PATCH v4 0/3] Add Qualcomm crypto driver

2014-06-25 Thread Stanimir Varbanov
Here is v4 of the patchset. Changes since v3: - Fixed trivial typo related to unnecessary semicolon. regards, Stan - Here is the third version of the crypto driver. Changes since v2: - reworked crypto_enqueue/dequeue_request

Re: [PATCH] crypto: lzo: use kvfree() helper

2014-06-25 Thread Herbert Xu
On Tue, Jun 24, 2014 at 01:23:45AM -0700, Eric Dumazet wrote: > From: Eric Dumazet > > kvfree() helper is now available, use it instead of open code it. > > Signed-off-by: Eric Dumazet Patch applied. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.

Re: [PATCH] crypto: sha512_ssse3: fix byte count to bit count conversion

2014-06-25 Thread Herbert Xu
On Mon, Jun 23, 2014 at 07:41:05PM +0300, Jussi Kivilinna wrote: > Byte-to-bit-count computation is only partly converted to big-endian and is > mixing in CPU-endian values. Problem was noticed by sparce with warning: > > CHECK arch/x86/crypto/sha512_ssse3_glue.c > arch/x86/crypto/sha512_ssse3

Re: [PATCH 1/4] crypto: qat: Fix random config build warnings

2014-06-25 Thread Tadeusz Struk
On 06/25/2014 06:36 AM, Herbert Xu wrote: >> struct icp_qat_fw_la_resp *qat_resp = resp; >> >struct qat_crypto_request *qat_req = >> > - (void *)(dma_addr_t)qat_resp->opaque_data; >> > + (void *)(__force long)qat_resp->opaque_data; > Why not just g

Re: [PATCH] crypto: des3_ede/x86-64: fix parse warning

2014-06-25 Thread Herbert Xu
On Mon, Jun 23, 2014 at 07:39:17PM +0300, Jussi Kivilinna wrote: > Patch fixes following sparse warning: > > CHECK arch/x86/crypto/des3_ede_glue.c > arch/x86/crypto/des3_ede_glue.c:308:52: warning: restricted __be64 degrades > to integer > arch/x86/crypto/des3_ede_glue.c:309:52: warning: rest

Re: [PATCH] crypto:caam - Correct the dma mapping for sg table

2014-06-25 Thread Herbert Xu
On Mon, Jun 23, 2014 at 07:50:26PM +0530, Ruchika Gupta wrote: > At few places in caamhash and caamalg, after allocating a dmable > buffer for sg table , the buffer was being modified. As per > definition of DMA_FROM_DEVICE ,afer allocation the memory should > be treated as read-only by the driver

Re: [PATCH] crypto: caam - Add definition of rd/wr_reg64 for little endian platform

2014-06-25 Thread Herbert Xu
On Mon, Jun 23, 2014 at 06:49:30PM +0530, Ruchika Gupta wrote: > CAAM IP has certain 64 bit registers . 32 bit architectures cannot force > atomic-64 operations. This patch adds definition of these atomic-64 > operations for little endian platforms. The definitions which existed > previously were

Re: [PATCH] crypto:caam - Configuration for platforms with virtualization enabled in CAAM

2014-06-25 Thread Herbert Xu
On Mon, Jun 23, 2014 at 05:42:33PM +0530, Ruchika Gupta wrote: > For platforms with virtualization enabled > > 1. The job ring registers can be written to only is the job ring has been >started i.e STARTR bit in JRSTART register is 1 > > 2. For DECO's under direct software control

Re: [PATCH][v4] crypto: caam - Correct definition of registers in memory map

2014-06-25 Thread Herbert Xu
On Mon, Jun 23, 2014 at 03:08:28PM +0530, Ruchika Gupta wrote: > Some registers like SECVID, CHAVID, CHA Revision Number, > CTPR were defined as 64 bit resgisters. The IP provides > a DWT bit(Double word Transpose) to transpose the two words when > a double word register is accessed. However setti

Re: [PATCH 1/4] crypto: qat: Fix random config build warnings

2014-06-25 Thread Herbert Xu
On Tue, Jun 24, 2014 at 03:19:24PM -0700, Tadeusz Struk wrote: > Fix random config build warnings: > > Implicit-function-declaration ‘__raw_writel’ > Cast to pointer from integer of different size [-Wint-to-pointer-cast] > > Reviewed-by: Bruce Allan > Signed-off-by: Tadeusz Struk > --- > drive

Re: [PATCH v2] DRBG: simplify ordering of linked list in drbg_ctr_df

2014-06-25 Thread Herbert Xu
On Mon, Jun 23, 2014 at 09:11:29AM +0200, Stephan Mueller wrote: > As reported by a static code analyzer, the code for the ordering of > the linked list can be simplified. > > Reported-by: kbuild test robot > Signed-off-by: Stephan Mueller > --- > crypto/drbg.c | 10 +- > 1 file changed

Re: [cryptodev:master 9/28] crypto/drbg.c:526 drbg_ctr_df() error: we previously assumed 'tempstr' could be null (see line 523)

2014-06-25 Thread Herbert Xu
On Sat, Jun 21, 2014 at 02:45:33PM +0200, Stephan Mueller wrote: > Am Freitag, 20. Juni 2014, 23:24:18 schrieb kbuild test robot: > > Hi, > > first of all, thanks for the information. As you have seen, I created a patch > covering your comments on the NULL pointer handling. > > > > The kernel a

Re: [PATCH] Potential NULL pointer deference in drbg_ctr_df

2014-06-25 Thread Herbert Xu
On Sat, Jun 21, 2014 at 02:26:29PM +0200, Stephan Mueller wrote: > The handling of additional input data / personalization string data may > be subject to a NULL pointer deference for the CTR DRBG. The > caller-provided data may be NULL which must be caught by the DRBG. > > Reported-by: kbuild tes

Re: [cryptodev:master 9/28] crypto/drbg.c:1998:1: sparse: directive in argument list

2014-06-25 Thread Herbert Xu
On Sat, Jun 21, 2014 at 02:30:29PM +0200, Stephan Mueller wrote: > Am Samstag, 21. Juni 2014, 04:17:26 schrieb kbuild test robot: > > Hi, > > > tree: > > git://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git > > master head: 6c9e3dcd36691c8690861a5f6902226ed2d8a75e > > commi