* i2c: xiic: Strange clk_prepare_enable() in xiic_i2c_remove()
@ 2016-12-16 21:54 Alexey Khoroshilov
2016-12-17 7:06 ` Shubhrajyoti Datta
0 siblings, 1 reply; 2+ messages in thread
From: Alexey Khoroshilov @ 2016-12-16 21:54 UTC (permalink / raw)
To: Shubhrajyoti Datta
Cc: Alexey Khoroshilov, Rob Herring, Wolfram Sang, linux-i2c,
linux-kernel, ldv-project
Dear Shubhrajyoti,
Looking at 36ecbcab84d0 ("i2c: xiic: Implement power management")
it is not clear why clk_prepare_enable(i2c->clk) is required in
xiic_i2c_remove()?
It is enabled in xiic_i2c_probe() and disabled/enabled in
cdns_i2c_runtime_suspend()/cdns_i2c_runtime_resume().
Could you please clarify the point.
--
Alexey Khoroshilov
Linux Verification Center, ISPRAS
web: http://linuxtesting.org
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: i2c: xiic: Strange clk_prepare_enable() in xiic_i2c_remove()
2016-12-16 21:54 i2c: xiic: Strange clk_prepare_enable() in xiic_i2c_remove() Alexey Khoroshilov
@ 2016-12-17 7:06 ` Shubhrajyoti Datta
0 siblings, 0 replies; 2+ messages in thread
From: Shubhrajyoti Datta @ 2016-12-17 7:06 UTC (permalink / raw)
To: Alexey Khoroshilov
Cc: Shubhrajyoti Datta, Rob Herring, Wolfram Sang, linux-i2c,
linux-kernel, ldv-project
On Sat, Dec 17, 2016 at 3:24 AM, Alexey Khoroshilov
<khoroshilov@ispras.ru> wrote:
> Dear Shubhrajyoti,
>
> Looking at 36ecbcab84d0 ("i2c: xiic: Implement power management")
> it is not clear why clk_prepare_enable(i2c->clk) is required in
> xiic_i2c_remove()?
834 ret = clk_prepare_enable(i2c->clk);
835 if (ret) {
836 dev_err(&pdev->dev, "Unable to enable clock.\n");
837 return ret;
838 }
839 xiic_deinit(i2c);
840 clk_disable_unprepare(i2c->clk);
so it is enabled and disabled after xiic_deinit.
>
> It is enabled in xiic_i2c_probe() and disabled/enabled in
> cdns_i2c_runtime_suspend()/cdns_i2c_runtime_resume().
>
> Could you please clarify the point.
>
> --
> Alexey Khoroshilov
> Linux Verification Center, ISPRAS
> web: http://linuxtesting.org
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-12-17 7:06 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-16 21:54 i2c: xiic: Strange clk_prepare_enable() in xiic_i2c_remove() Alexey Khoroshilov
2016-12-17 7:06 ` Shubhrajyoti Datta
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).