]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: lib/blake2s - reduce stack frame usage in self test
authorJason A. Donenfeld <Jason@zx2c4.com>
Mon, 20 Jun 2022 07:52:43 +0000 (09:52 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Aug 2022 12:24:29 +0000 (14:24 +0200)
commit5d764069d609efb7f85b930dcde76a390807f107
tree7692d3cfdb9871bfc549ece2cc86c49f084e65b9
parentfe33948de1bc3639b59a82b876a3d50d636dc2da
crypto: lib/blake2s - reduce stack frame usage in self test

commit 1efdb449ecc6361774d8041c5cd297a9fcef300b upstream.

Using 3 blocks here doesn't give us much more than using 2, and it
causes a stack frame size warning on certain compiler/config/arch
combinations:

   lib/crypto/blake2s-selftest.c: In function 'blake2s_selftest':
>> lib/crypto/blake2s-selftest.c:632:1: warning: the frame size of 1088 bytes is larger than 1024 bytes [-Wframe-larger-than=]
     632 | }
         | ^

So this patch just reduces the block from 3 to 2, which makes the
warning go away.

Reported-by: kernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/linux-crypto/202206200851.gE3MHCgd-lkp@intel.com
Fixes: 33f982a314cc ("crypto: blake2s - remove shash module")
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
lib/crypto/blake2s-selftest.c