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: <20140321104027.GG15213@lee--X1>
Date:	Fri, 21 Mar 2014 10:40:27 +0000
From:	Lee Jones <lee.jones@...aro.org>
To:	Charles Keepax <ckeepax@...nsource.wolfsonmicro.com>
Cc:	broonie@...nel.org, robh+dt@...nel.org, pawel.moll@....com,
	mark.rutland@....com, ijc+devicetree@...lion.org.uk,
	galak@...eaurora.org, rob@...dley.net, sameo@...ux.intel.com,
	lgirdwood@...il.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 3/5] regulator: arizona-ldo1: Move setup processing from
 arizona-core

> It is more idiomatic to process things relating to the regulator in its
> driver. This patch moves both processing of device tree relating to the
> regulator and checking if the regulator is external from arizona-core
> into the regulator driver.
> 
> Signed-off-by: Charles Keepax <ckeepax@...nsource.wolfsonmicro.com>
> ---
>  drivers/mfd/arizona-core.c       |   12 +++---------
>  drivers/regulator/arizona-ldo1.c |   30 ++++++++++++++++++++++++++++++
>  2 files changed, 33 insertions(+), 9 deletions(-)
> 
> diff --git a/drivers/mfd/arizona-core.c b/drivers/mfd/arizona-core.c
> index 333621e..c5fe3bb 100644
> --- a/drivers/mfd/arizona-core.c
> +++ b/drivers/mfd/arizona-core.c
> @@ -539,7 +539,6 @@ static int arizona_of_get_core_pdata(struct arizona *arizona)
>  	int ret, i;
>  
>  	arizona_of_get_named_gpio(arizona, "wlf,reset", true, &pdata->reset);
> -	arizona_of_get_named_gpio(arizona, "wlf,ldoena", true, &pdata->ldoena);
>  
>  	ret = of_property_read_u32_array(arizona->dev->of_node,
>  					 "wlf,gpio-defaults",
> @@ -671,6 +670,9 @@ int arizona_dev_init(struct arizona *arizona)
>  		return -EINVAL;
>  	}
>  
> +	/* Mark DCVDD as external, LDO1 driver will clear if internal */
> +	arizona->external_dcvdd = true;
> +

You don't need to do this, as it's already the default:

include/linux/mfd/arizona/core.h:

struct arizona {
 <snip>
        unsigned int external_dcvdd:1;
 <snip>
};

Also you're adding a bool value to a unsigned int.

Any reason for that?

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
--
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