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

2018-11-06 Thread Ard Biesheuvel
(+ TLS maintainers and netdev) On 7 November 2018 at 02:38, syzbot wrote: > Hello, > > syzbot found the following crash on: > > HEAD commit:4710e78940d8 Merge tag 'nfs-for-4.20-2' of git://git.linux.. > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=17a68

[PATCH] dt-bindings: rng: update bindings for MT7629 SoC

2018-11-06 Thread Ryder Lee
This updates bindings for MT7629 RNG driver. Signed-off-by: Ryder Lee --- Documentation/devicetree/bindings/rng/mtk-rng.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/rng/mtk-rng.txt b/Documentation/devicetree/bindings/rng/mtk-rng.txt

KASAN: use-after-free Read in crypto_gcm_init_common

2018-11-06 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:4710e78940d8 Merge tag 'nfs-for-4.20-2' of git://git.linux.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=17a6809340 kernel config: https://syzkaller.appspot.com/x/.config?x=9384ecb1c973baed da

[PATCH v4 1/3] crypto: streebog - add Streebog hash function

2018-11-06 Thread Vitaly Chikunov
Add GOST/IETF Streebog hash function (GOST R 34.11-2012, RFC 6986) generic hash transformation. Cc: linux-integr...@vger.kernel.org Signed-off-by: Vitaly Chikunov --- crypto/Kconfig| 12 + crypto/Makefile |1 + crypto/streebog_generic.c | 1140

[PATCH v4 3/3] crypto: streebog - add Streebog test vectors

2018-11-06 Thread Vitaly Chikunov
Add testmgr and tcrypt tests and vectors for Streebog hash function from RFC 6986 and GOST R 34.11-2012, for HMAC-Streebog vectors are from RFC 7836 and R 50.1.113-2016. Cc: linux-integr...@vger.kernel.org Signed-off-by: Vitaly Chikunov Acked-by: Ard Biesheuvel --- crypto/tcrypt.c | 37 ++

[PATCH v4 2/3] crypto: streebog - register Streebog in hash info for IMA

2018-11-06 Thread Vitaly Chikunov
Register Streebog hash function in Hash Info arrays to let IMA use it for its purposes. Cc: linux-integr...@vger.kernel.org Signed-off-by: Vitaly Chikunov Reviewed-by: Mimi Zohar --- crypto/hash_info.c | 4 include/crypto/hash_info.h | 1 + include/uapi/linux/hash_info.h |

[PATCH v4 0/3] crypto: streebog - add Streebog hash function

2018-11-06 Thread Vitaly Chikunov
Add GOST/IETF Streebog hash function (GOST R 34.11-2012, RFC 6986) generic hash transformation with appropriate testmgr and tcrypt tests and vectors. Streebog Hash Function (GOST R 34.11-2012, RFC 6986) is one of the Russian cryptographic standard algorithms (called GOST algorithms). Intended use

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

2018-11-06 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 v23 0/6] Add io{read|write}64 to io-64-atomic headers

2018-11-06 Thread Logan Gunthorpe
This is another resend: Andrew, can you please pick this set up again so it can get into linux-next? Or let me know if there's something else I should do. I've been try to get this in for 15 months and I'm getting a bit tired of submitting it repeatedly with no responses. Thanks, Logan -- Cha

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

2018-11-06 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 v23 2/6] parisc: iomap: introduce io{read|write}64

2018-11-06 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 v23 3/6] iomap: introduce io{read|write}64_{lo_hi|hi_lo}

2018-11-06 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 v23 5/6] ntb: ntb_hw_intel: use io-64-nonatomic instead of in-driver hacks

2018-11-06 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/

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

2018-11-06 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

Re: [PATCH] crypto: bcm: fix normal/non key hash algorithm failure

2018-11-06 Thread Florian Fainelli
On 11/6/18 12:28 AM, Raveendra Padasalagi wrote: > Remove setkey() callback handler for normal/non key > hash algorithms and keep it for AES-CBC/CMAC which needs key. > > Signed-off-by: Raveendra Padasalagi Should this have the following Fixes tag? Fixes: 9d12ba86f818 ("crypto: brcm - Add Broad

Re: [RFC PATCH v3 10/15] crypto: poly1305 - use structures for key and accumulator

2018-11-06 Thread Ard Biesheuvel
On 6 November 2018 at 00:25, Eric Biggers wrote: > From: Eric Biggers > > In preparation for exposing a low-level Poly1305 API which implements > the ε-almost-∆-universal (εA∆U) hash function underlying the Poly1305 > MAC and supports block-aligned inputs only, create structures > poly1305_key an

Re: [PATCH] arm/crypto/aes-ce-glue.c: Remove duplicate header

2018-11-06 Thread Ard Biesheuvel
On 6 November 2018 at 13:16, Brajeswar Ghosh wrote: > Remove asm/hwcap.h which is included more than once > > Signed-off-by: Brajeswar Ghosh Acked-by: Ard Biesheuvel > --- > arch/arm/crypto/aes-ce-glue.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/arch/arm/crypto/aes-ce-glue.c b/a

Re: [RFC PATCH v3 08/15] crypto: arm/chacha20 - refactor to allow varying number of rounds

2018-11-06 Thread Ard Biesheuvel
On 6 November 2018 at 00:25, Eric Biggers wrote: > From: Eric Biggers > > In preparation for adding XChaCha12 support, rename/refactor the NEON > implementation of ChaCha20 to support different numbers of rounds. > > Signed-off-by: Eric Biggers Reviewed-by: Ard Biesheuvel > --- > arch/arm/cr

Re: [RFC PATCH v3 07/15] crypto: arm/chacha20 - add XChaCha20 support

2018-11-06 Thread Ard Biesheuvel
On 6 November 2018 at 00:25, Eric Biggers wrote: > From: Eric Biggers > > Add an XChaCha20 implementation that is hooked up to the ARM NEON > implementation of ChaCha20. This is needed for use in the Adiantum > encryption mode; see the generic code patch, > "crypto: chacha20-generic - add XChaCh

[PATCH] arm/crypto/aes-ce-glue.c: Remove duplicate header

2018-11-06 Thread Brajeswar Ghosh
Remove asm/hwcap.h which is included more than once Signed-off-by: Brajeswar Ghosh --- arch/arm/crypto/aes-ce-glue.c | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/crypto/aes-ce-glue.c b/arch/arm/crypto/aes-ce-glue.c index d0a9cec73707..5affb8482379 100644 --- a/arch/arm/crypto/aes-

[PATCH] crypto: bcm: fix normal/non key hash algorithm failure

2018-11-06 Thread Raveendra Padasalagi
Remove setkey() callback handler for normal/non key hash algorithms and keep it for AES-CBC/CMAC which needs key. Signed-off-by: Raveendra Padasalagi --- drivers/crypto/bcm/cipher.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/crypto/bcm/cipher.c b/drivers/cry