Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-10-20 Thread Joe Perches
> git checkout 5fb8ef25803ef33e2eb60b626435828b937bed75 > > > # save the attached .config to linux build tree > > > make W=1 ARCH=i386 > > > > > > If you fix the issue, kindly add following tag as appropriate > > > Reported-by

RE: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-10-20 Thread David Laight
gt; > > > If you fix the issue, kindly add following tag as appropriate > > Reported-by: kernel test robot > > > > All warnings (new ones prefixed by >>): > > > >lib/crypto/chacha.c: In function 'chacha_permute': > > > > lib/crypto/chacha.c:65:

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-10-19 Thread Joe Perches
>lib/crypto/chacha.c: In function 'chacha_permute': > > > lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger > > > than 1024 bytes [-Wframe-larger-than=] > 65 | } > | ^ > > vim +65 lib/crypto/chacha.c This seems to

lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-10-18 Thread kernel test robot
following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): lib/crypto/chacha.c: In function 'chacha_permute': >> lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger >> than 1024 bytes [-Wframe-larg

lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-09-19 Thread kernel test robot
If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): lib/crypto/chacha.c: In function 'chacha_permute': >> lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger >> than 1024 byt

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Linus Torvalds
On Thu, Aug 27, 2020 at 12:12 PM Arnd Bergmann wrote: > > Ah right, that explains why I never saw the warning in my randconfig > build tests, I run those with COMPILE_TEST force-enabled. .. but your clang test did enable this? .. never mind, I have clang locally anyway, and while I usually

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Kees Cook
On Thu, Aug 27, 2020 at 09:11:52PM +0200, Arnd Bergmann wrote: > On Thu, Aug 27, 2020 at 7:55 PM Linus Torvalds > wrote: > > > > On Thu, Aug 27, 2020 at 10:34 AM Linus Torvalds > > wrote: > > > > > > How are you guys testing? I have UBSAN and GCOV on, and don't see > > > crazy frames on either

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Kees Cook
On Thu, Aug 27, 2020 at 12:02:12PM -0700, Linus Torvalds wrote: > On Thu, Aug 27, 2020 at 11:42 AM Kees Cook wrote: > > > > Do you mean you checked both gcc and clang and it was only a problem with > > gcc? > > I didn't check with clang, but Arnd claimed it was fine. > > > (If so, I can tweak

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Arnd Bergmann
On Thu, Aug 27, 2020 at 7:55 PM Linus Torvalds wrote: > > On Thu, Aug 27, 2020 at 10:34 AM Linus Torvalds > wrote: > > > > How are you guys testing? I have UBSAN and GCOV on, and don't see > > crazy frames on either i386 or x86-64. > > Oh, never mind. I also have COMPILE_TEST on, so it ends up

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Linus Torvalds
On Thu, Aug 27, 2020 at 11:42 AM Kees Cook wrote: > > Do you mean you checked both gcc and clang and it was only a problem with gcc? I didn't check with clang, but Arnd claimed it was fine. > (If so, I can tweak the "depends" below...) Ugh. Instead of making the Makefile even uglier, why

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Kees Cook
On Thu, Aug 27, 2020 at 10:55:32AM -0700, Linus Torvalds wrote: > On Thu, Aug 27, 2020 at 10:34 AM Linus Torvalds > wrote: > > > > How are you guys testing? I have UBSAN and GCOV on, and don't see > > crazy frames on either i386 or x86-64. > > Oh, never mind. I also have COMPILE_TEST on, so it

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Linus Torvalds
On Thu, Aug 27, 2020 at 10:34 AM Linus Torvalds wrote: > > How are you guys testing? I have UBSAN and GCOV on, and don't see > crazy frames on either i386 or x86-64. Oh, never mind. I also have COMPILE_TEST on, so it ends up disabling GCOV_PROFILE_ALL and UBSAN_SANITIZE_ALL. And yeah, this

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Linus Torvalds
On Thu, Aug 27, 2020 at 1:25 AM Herbert Xu wrote: > > Interestingly this particular file fails with those options on > gcc 8, 9 and 10. How are you guys testing? I have UBSAN and GCOV on, and don't see crazy frames on either i386 or x86-64. I see 72 bytes and 64 bytes respectively for

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Arnd Bergmann
On Thu, Aug 27, 2020 at 1:51 PM Herbert Xu wrote: > > On Thu, Aug 27, 2020 at 12:41:53PM +0200, Ard Biesheuvel wrote: > > > > That does not help, unfortunately. > > > > What does seem to work is > > > > struct chacha_state { u32 x[16]; }; > > > > struct chacha_state chacha_permute(struct

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Herbert Xu
On Thu, Aug 27, 2020 at 12:41:53PM +0200, Ard Biesheuvel wrote: > > That does not help, unfortunately. > > What does seem to work is > > struct chacha_state { u32 x[16]; }; > > struct chacha_state chacha_permute(struct chacha_state st, int nrounds) Passing 64 bytes by value is not good.

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Ard Biesheuvel
On Thu, 27 Aug 2020 at 11:20, Arnd Bergmann wrote: > > On Thu, Aug 27, 2020 at 10:42 AM Ard Biesheuvel wrote: > > > > In that case, I suppose we should simply disable instrumentation for > > chacha_permute()? It is a straight-forward arithmetic transformation > > on a u32[16] array, where ubsan

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Arnd Bergmann
On Thu, Aug 27, 2020 at 10:42 AM Ard Biesheuvel wrote: > > In that case, I suppose we should simply disable instrumentation for > chacha_permute()? It is a straight-forward arithmetic transformation > on a u32[16] array, where ubsan has limited value afaict. I guess that always works as a last

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Ard Biesheuvel
86 > > > > > > > > If you fix the issue, kindly add following tag as appropriate > > > > Reported-by: kernel test robot > > > > > > > > All warnings (new ones prefixed by >>): > > > > > > > >lib/crypto/chacha.c: In func

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Arnd Bergmann
t; > # save the attached .config to linux build tree > > > make W=1 ARCH=i386 > > > > > > If you fix the issue, kindly add following tag as appropriate > > > Reported-by: kernel test robot > > > > > > All warnings (new o

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Herbert Xu
On Thu, Aug 27, 2020 at 10:10:19AM +0200, Ard Biesheuvel wrote: > > Is it really worth it to obsess about this? Special compiler > instrumentation simply leads to a larger stack footprint in many > cases, which is why we use a larger stack to begin with (at least we > do so for Kasan, so if we

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Ard Biesheuvel
the issue, kindly add following tag as appropriate > > Reported-by: kernel test robot > > > > All warnings (new ones prefixed by >>): > > > >lib/crypto/chacha.c: In function 'chacha_permute': > > >> lib/crypto/chacha.c:65:1: warning: t

Re: lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-27 Thread Herbert Xu
gt; >lib/crypto/chacha.c: In function 'chacha_permute': > >> lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger > >> than 1024 bytes [-Wframe-larger-than=] > 65 | } > | ^ This doesn't happen with a normal configuration. To recrea

lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger than 1024 bytes

2020-08-26 Thread kernel test robot
If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): lib/crypto/chacha.c: In function 'chacha_permute': >> lib/crypto/chacha.c:65:1: warning: the frame size of 1604 bytes is larger >> than 1024 byt