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] [day] [month] [year] [list]
Date:	Wed, 16 Apr 2014 21:47:33 +0100
From:	Mark Brown <broonie@...nel.org>
To:	Andrew Bresticker <abrestic@...omium.org>
Cc:	Mike Looijmans <mike.looijmans@...ic.nl>,
	Arnd Bergmann <arnd@...db.de>,
	Ben Dooks <ben.dooks@...ethink.co.uk>,
	"linux-mmc@...r.kernel.org" <linux-mmc@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	cjb@...top.org, gdjakov@...sol.com
Subject: Re: [PATCH] sdhci: Forward EPROBE_DEFER on vmmc and vqmmc regulators

On Wed, Apr 16, 2014 at 01:15:53PM -0700, Andrew Bresticker wrote:

> Not true.  If !CONFIG_REGULATOR, regulator_get() and co. will return
> NULL.  Normally it is ok to ignore this case, but the sdhci driver
> will call regulator_is_supported_voltage() on vqmmc to determine
> whether 1.8V signalling is supported.  With !CONFIG_REGULATOR,
> regulator_is_supported_voltage() will always return false, causing the
> sdhci driver to disable all UHS modes.  So we still need to handle the
> NULL (!CONFIG_REGULATOR) case.  One possibility is to guard the
> voltage check with #ifdef CONFIG_REGULATOR, as is done later with
> vmmc.

It seems better to just fix regulator_get_optional() to return an error
if the API is disabled, that case didn't really get considered since
it's a bit surprising that something actively using regulators (rather
than simply ensuring they're enabled) would be using that function.
Though if you already have ifdefs the ifdef is probably fine.

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