[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <545CEF45.1000503@collabora.co.uk>
Date: Fri, 07 Nov 2014 17:11:49 +0100
From: Javier Martinez Canillas <javier.martinez@...labora.co.uk>
To: Krzysztof Kozlowski <k.kozlowski@...sung.com>
CC: Mark Brown <broonie@...nel.org>,
Kukjin Kim <kgene.kim@...sung.com>,
Chanwoo Choi <cw00.choi@...sung.com>,
Olof Johansson <olof@...om.net>,
Chris Zhong <zyw@...k-chips.com>,
Abhilash Kesavan <kesavan.abhilash@...il.com>,
linux-samsung-soc@...r.kernel.org, linux-kernel@...r.kernel.org,
devicetree@...r.kernel.org
Subject: Re: [PATCH v5 3/5] regulator: of: Add regulator desc param to of_get_regulator_init_data()
Hello Krzysztof,
On 11/07/2014 04:23 PM, Krzysztof Kozlowski wrote:
>>
>> static struct fan53555_platform_data *fan53555_parse_dt(struct device *dev,
>> - struct device_node *np)
>> + struct device_node *np,
>> + struct regulator_desc *desc)
>
> Not a const? Why not?
>
Right, I removed all your other mentions to the same issue but I'll double
check all the drivers to be sure that use const.
>> {
>> struct fan53555_platform_data *pdata;
>> int ret;
>> @@ -312,7 +313,7 @@ static struct fan53555_platform_data *fan53555_parse_dt(struct device *dev,
>> if (!pdata)
>> return NULL;
>>
>> - pdata->regulator = of_get_regulator_init_data(dev, np);
>> + pdata->regulator = of_get_regulator_init_data(dev, np, desc);
>
> Desc would be always NULL here which is safe (check in patch 5/5) but if
> someone puts "regulator-initial-mode" in DTS then this will always print
> warning. Just wonder - is it actually what you wanted?
>
> This applies also for tps51632 and tps62360.
>
In an early version of the series I just passed NULL for all drivers but
Mark said that is more future proof to pass the descriptor and I agree.
I guess I should just remove the warning and only show an error if the
descriptor is not NULL and also the map mode function is defined but
the callback returns an error.
> (...)
>
> Rest looks fine.
>
Thanks a lot for the review.
> Krzysztof
>
>
Best regards,
Javier
--
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