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]
Date:	Thu, 27 Feb 2014 20:37:48 +0900
From:	Mark Brown <broonie@...nel.org>
To:	Andrew Bresticker <abrestic@...omium.org>
Cc:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] regmap: don't use spinlocks with
 REGCACHE_{RBTREE,COMPRESSED}

On Wed, Feb 26, 2014 at 07:50:57PM -0800, Andrew Bresticker wrote:
> Both REGCACHE_RBTREE and REGCACHE_COMPRESSED make GFP_KERNEL allocations
> with the regmap lock held.  If we're initializing a regmap which would
> normally use a spinlock (e.g. MMIO), fall back to using a mutex if one
> of these caching types is to be used.

Have all the users been audited to verify that they're actually safe
with this?  I just took a quick look at the Tegra drivers and they're
doing regmap operations in their trigger operations which is done from
atomic context so they should run into problems trying to take mutexes
anyway.

I think we need to either ensure that all users allocate their caches at
probe time (which is fine and is hopefully what the current users are
doing), provide a mechanism for them to do cache allocations outside of
the spinlock (which sounds hairy) or convert them to flat cache.

Download attachment "signature.asc" of type "application/pgp-signature" (837 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ