lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200512200805.GA175421@gmail.com>
Date:   Tue, 12 May 2020 13:08:05 -0700
From:   Eric Biggers <ebiggers@...nel.org>
To:     Mark Brown <broonie@...nel.org>,
        Herbert Xu <herbert@...dor.apana.org.au>
Cc:     Stephen Rothwell <sfr@...b.auug.org.au>,
        Liam Girdwood <lgirdwood@...il.com>,
        Linux Crypto List <linux-crypto@...r.kernel.org>,
        Linux Next Mailing List <linux-next@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Arnd Bergmann <arnd@...db.de>
Subject: Re: linux-next: manual merge of the sound-asoc tree with the crypto
 tree

On Tue, May 12, 2020 at 06:08:01PM +0100, Mark Brown wrote:
> On Tue, May 12, 2020 at 09:36:32AM -0700, Eric Biggers wrote:
> > On Tue, May 12, 2020 at 05:22:05PM +0100, Mark Brown wrote:
> 
> > > > from the crypto tree and commit:
> 
> > > >   a1304cba816e ("ASoC: cros_ec_codec: allocate shash_desc dynamically")
> 
> > > > from the sound-asoc tree.
> 
> > I Cc'ed it to the people listed in MAINTAINERS for "CHROMEOS EC CODEC DRIVER".
> > I guess wasn't enough and I should have added alsa-devel@...a-project.org too?
> 
> Yeah, you generally need to make sure the subsystem maintainers are
> included as well as individual driver maintainers.
> 
> > > That doesn't seem ideal - Eric, Herbert can we get a branch with the
> > > crypto patches in them to pull into the ASoC tree or something?
> 
> > We should just drop one of the patches.
> 
> > If you just want to eliminate the compiler warning about stack usage in
> > wov_hotword_model_put(), then my patch in cryptodev would be better, as it moves
> > the stack allocation into another function in another file.
> 
> > Alternatively, if you actually need to reduce the total stack usage (across all
> > functions), then the kmalloc() patch in sound-asoc would be better.
> 
> Well, reducing the stack usage overall seems nicer overall - heads off
> future problems if the struct grows or something, and if we still end up
> allocating just as much on the stack then we'll have trouble at runtime
> anyway - does that make sense?

If you're concerned about total stack usage, then my recommendation is that
Herbert drops my patch "ASoC: cros_ec_codec: use crypto_shash_tfm_digest()"
from cryptodev, and you keep the patch
"ASoC: cros_ec_codec: allocate shash_desc dynamically" in sound-asoc.

For later: if SHASH_DESC_ON_STACK is causing problems, we really ought to find a
better solution, since lots of users are using this macro.  A version of
crypto_shash_tfm_digest() that falls back to heap allocation if the descsize is
too large would be possible, but that wouldn't fully solve the problem since
some users do incremental hashing.

- Eric

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ