Re: [PATCH 1/2] ARM: EXYNOS: Get current parent clock for power domain on/off

Krzysztof Kozlowski
2015-04-03T08:36:02Z

2015-04-03 10:12 GMT+02:00 Andrzej Hajda <a.hajda@samsung.com>:
> On 04/02/2015 02:44 PM, Krzysztof Kozlowski wrote:
>> 2015-04-02 14:29 GMT+02:00 Javier Martinez Canillas
>> <javier.martinez@collabora.co.uk>:
>>> Hello Krzysztof,
>>>
>>> On 04/02/2015 10:06 AM, Krzysztof Kozlowski wrote:
>>>> Using a fixed (by DTS) parent for clocks when turning on the power domain
>>>> may introduce issues in other drivers. For example when such driver
>>>> changes the parent during runtime and expects that he is the only place
>>>> of such change.
>>>>
>>>> Do not rely entirely on DTS providing the fixed parent for such clocks.
>>>> Instead if "pclkN" clock name is missing, grab a current parent of clock
>>>> with clk_get_parent().
>
> Hi Krzysztof,
>
> I wonder if it wouldn't be better to drop entirely pclks. Power domains
> should save/restore its previous state, setting fixed parents on domain
> resume can fool drivers as you described earlier.

I wanted to preserve full backward compatibility (including behaviour
compatibility). However I can't find valid reason to switch to some
fixed clock after powering up domain so if there are not objections I
will drop pclk entirely.

Thanks!
Krzysztof