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:	Wed, 27 Nov 2013 16:32:59 +0000
From:	"Jon Medhurst (Tixy)" <tixy@...aro.org>
To:	Mark Brown <broonie@...nel.org>
Cc:	Fabio Estevam <festevam@...il.com>,
	Liam Girdwood <lgirdwood@...il.com>, thierry.reding@...il.com,
	linux-kernel@...r.kernel.org, linaro-kernel@...ts.linaro.org,
	Mark Brown <broonie@...aro.org>
Subject: Re: [PATCH 2/2] regulator: core: Check for DT every time we check
 full constraints

On Wed, 2013-11-27 at 16:24 +0000, Mark Brown wrote:
> From: Mark Brown <broonie@...aro.org>
> 
> Eliminate the gap between DT becoming available and this being used to say
> we have full constraints by checking directly for DT every time we check
> for full constraints. This improves interoperaton with optional regulator
> support.
> 
> Signed-off-by: Mark Brown <broonie@...aro.org>
> ---
>  drivers/regulator/core.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
> index 02fdf925bb56..d85f31385b24 100644
> --- a/drivers/regulator/core.c
> +++ b/drivers/regulator/core.c
> @@ -121,7 +121,7 @@ static const char *rdev_get_name(struct regulator_dev *rdev)
>  
>  static bool have_full_constraints(void)
>  {
> -	return has_full_constraints;
> +	return has_full_constraints || of_have_populated_dt();
>  }
>  
>  /**

Doesn't this now make this code in regulator_init_complete()
redundant..?

	if (of_have_populated_dt())
		has_full_constraints = true;

Or is keeping this to avoid one less variable check a worthwhile
optimisation?

-- 
Tixy

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ