[PATCH] ARM: OMAP2+: hwmod_core: enable optional clocks before main clock
Tero Kristo
t-kristo at ti.com
Tue Feb 20 04:20:41 PST 2018
On 22/12/17 20:51, Tony Lindgren wrote:
> * Keerthy <j-keerthy at ti.com> [171222 09:43]:
>>
>>
>> On Friday 22 December 2017 02:56 PM, Tero Kristo wrote:
>>> The optional clocks must be enabled before the main clock after the
>>> transition to clkctrl controlled clocks is done. Otherwise the module
>>> we attempt to enable might be stuck in transition.
>>>
>>> Reported-by: Keerthy <j-keerthy at ti.com>
>>> Signed-off-by: Tero Kristo <t-kristo at ti.com>
>>
>> Tested the patch on both DRA7-EVM and DRA72-EVM. I no longer see the issue:
>>
>> Tested-by: Keerthy <j-keerthy at ti.com>
>>
>>> ---
>>> Hi Tony,
>>>
>>> This patch fixes a regression seen in linux-next, where certain peripherals
>>> fail to enable after the clkctrl changes are in. The case seen has been
>>> with mcasp3, where it fails to transition to enabled during the audio
>>> driver probe. Not sure where you want to pick this up, maybe as early
>>> rc fixes if its too late to push this to linux-next?
>
> Thanks applying into omap-for-v4.16/soc, yeah we should
> get it merged during the merge window as a fix.
Tony,
I think this missed the merge for some reason? Can you queue this up as
a fix as its still needed?
-Tero
>
> Regards,
>
> Tony
>
>
>
>>> arch/arm/mach-omap2/omap_hwmod.c | 6 +++---
>>> 1 file changed, 3 insertions(+), 3 deletions(-)
>>>
>>> diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c
>>> index 7324048..340d05c 100644
>>> --- a/arch/arm/mach-omap2/omap_hwmod.c
>>> +++ b/arch/arm/mach-omap2/omap_hwmod.c
>>> @@ -976,6 +976,9 @@ static int _enable_clocks(struct omap_hwmod *oh)
>>>
>>> pr_debug("omap_hwmod: %s: enabling clocks\n", oh->name);
>>>
>>> + if (oh->flags & HWMOD_OPT_CLKS_NEEDED)
>>> + _enable_optional_clocks(oh);
>>> +
>>> if (oh->_clk)
>>> clk_enable(oh->_clk);
>>>
>>> @@ -984,9 +987,6 @@ static int _enable_clocks(struct omap_hwmod *oh)
>>> clk_enable(os->_clk);
>>> }
>>>
>>> - if (oh->flags & HWMOD_OPT_CLKS_NEEDED)
>>> - _enable_optional_clocks(oh);
>>> -
>>> /* The opt clocks are controlled by the device driver. */
>>>
>>> return 0;
>>>
--
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki
More information about the linux-arm-kernel
mailing list