Re: [PATCH v2 15/17] zinc: Curve25519 ARM implementation

2018-08-28 Thread Jason A. Donenfeld
Hey Ard, Thanks for the thorough review. Very much appreciated. I've incorporated nearly all of your suggestions into my development tree: https://git.kernel.org/pub/scm/linux/kernel/git/zx2c4/linux.git/tree/lib/zinc/curve25519/curve25519-arm.S?h=jd/wireguard These changes will be part of v3. R

Crypto Fixes for 4.19

2018-08-28 Thread Herbert Xu
Hi Linus: This push fixes the following issues: - Check for the right CPU feature bit in sm4-ce on arm64. - Fix scatterwalk WARN_ON in aes-gcm-ce on arm64. - Fix unaligned fault in aesni on x86. - Fix potential NULL pointer dereference on exit in chtls. - Fix DMA mapping direction for RSA in caa

[PATCH v20 2/6] parisc: iomap: introduce io{read|write}64

2018-08-28 Thread Logan Gunthorpe
Add support for io{read|write}64() functions in parisc architecture. These are pretty straightforward copies of similar functions which make use of readq and writeq. Also, indicate that the lo_hi and hi_lo variants of these functions are not provided by this architecture. Signed-off-by: Logan Gun

[PATCH v20 6/6] ntb: ntb_hw_switchtec: Cleanup 64bit IO defines to use the common header

2018-08-28 Thread Logan Gunthorpe
Clean up the ifdefs which conditionally defined the io{read|write}64 functions in favour of the new common io-64-nonatomic-lo-hi header. Per a nit from Andy Shevchenko, the include list is also made alphabetical. Signed-off-by: Logan Gunthorpe Reviewed-by: Andy Shevchenko Cc: Jon Mason --- dr

[PATCH v20 1/6] iomap: Use non-raw io functions for io{read|write}XXbe

2018-08-28 Thread Logan Gunthorpe
Fix an asymmetry in the io{read|write}XXbe functions in that the big-endian variants make use of the raw io accessors while the little-endian variants use the regular accessors. Some architectures implement barriers to order against both spinlocks and DMA accesses and for these case, the big-endian

[PATCH v20 0/6] Add io{read|write}64 to io-64-atomic headers

2018-08-28 Thread Logan Gunthorpe
Andrew, can you please pick this set up again so it can get into linux-next again this cycle? Thanks, Logan -- Changes since v19: - Rebased onto v4.19-rc1 (No Changes) Changes since v18: - Dropped the CAAM patch as it was subtly wrong and broke when people tested it in linux-next. Seeing the

[PATCH v20 4/6] io-64-nonatomic: add io{read|write}64[be]{_lo_hi|_hi_lo} macros

2018-08-28 Thread Logan Gunthorpe
This patch adds generic io{read|write}64[be]{_lo_hi|_hi_lo} macros if they are not already defined by the architecture. (As they are provided by the generic iomap library). The patch also points io{read|write}64[be] to the variant specified by the header name. This is because new drivers are enco

[PATCH v20 3/6] iomap: introduce io{read|write}64_{lo_hi|hi_lo}

2018-08-28 Thread Logan Gunthorpe
In order to provide non-atomic functions for io{read|write}64 that will use readq and writeq when appropriate. We define a number of variants of these functions in the generic iomap that will do non-atomic operations on pio but atomic operations on mmio. These functions are only defined if readq a

[PATCH v20 5/6] ntb: ntb_hw_intel: use io-64-nonatomic instead of in-driver hacks

2018-08-28 Thread Logan Gunthorpe
Now that ioread64 and iowrite64 are available in io-64-nonatomic, we can remove the hack at the top of ntb_hw_intel.c and replace it with an include. Signed-off-by: Logan Gunthorpe Reviewed-by: Andy Shevchenko Acked-by: Dave Jiang Acked-by: Allen Hubbe Acked-by: Jon Mason --- drivers/ntb/hw/

Re: KASAN: use-after-free Read in sha512_ctx_mgr_resubmit

2018-08-28 Thread Megha Dey
On Tue, 2018-08-28 at 01:01 +0200, Ard Biesheuvel wrote: > On 28 August 2018 at 01:08, Megha Dey wrote: > > On Wed, 2018-08-22 at 14:20 +0800, Herbert Xu wrote: > >> On Tue, Aug 21, 2018 at 02:43:56PM +0200, Ard Biesheuvel wrote: > >> > > >> > I agree. The code is obviously broken in a way that wo

Re: [PATCH 2/4] arm64: cpufeature: add feature for CRC32 instructions

2018-08-28 Thread Ard Biesheuvel
On 28 August 2018 at 19:01, Will Deacon wrote: > On Mon, Aug 27, 2018 at 01:02:43PM +0200, Ard Biesheuvel wrote: >> Add a CRC32 feature bit and wire it up to the CPU id register so we >> will be able to use alternatives patching for CRC32 operations. >> >> Signed-off-by: Ard Biesheuvel >> --- >>

Re: [PATCH 2/4] arm64: cpufeature: add feature for CRC32 instructions

2018-08-28 Thread Will Deacon
On Mon, Aug 27, 2018 at 01:02:43PM +0200, Ard Biesheuvel wrote: > Add a CRC32 feature bit and wire it up to the CPU id register so we > will be able to use alternatives patching for CRC32 operations. > > Signed-off-by: Ard Biesheuvel > --- > arch/arm64/include/asm/cpucaps.h | 3 ++- > arch/arm64