lkml.org 
[lkml]   [2017]   [Mar]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V2 2/2] mmc: tegra: Fix setting of Tegra SDHCI module clock
On Fri, Mar 17, 2017 at 09:25:32AM +0000, Jon Hunter wrote:
> Commit a8e326a911d3 ("mmc: tegra: implement module external clock change")
> implemented the SDHCI 'set_clock' handler for Tegra in order to change
> the module clock for the Tegra SDHCI controller by using the common
> clock framework API clk_set_rate(). The problem is the clk_set_rate()
> may sleep and the 'set_clock' handler is always called from within the
> context of a spinlock. Hence, occasionally, 'scheduling while atomic'
> errors are seen. Fix this by moving the setting of the module clock to
> the new 'set_parent_clock' handler which is not called from within the
> context of a spinlock.
>
> Fixes: a8e326a911d3 ("mmc: tegra: implement module external clock change")
>
> Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
> ---
>
> Changes since V1:
> - None
>
> drivers/mmc/host/sdhci-tegra.c | 15 ++++++++++++---
> 1 file changed, 12 insertions(+), 3 deletions(-)

Reviewed-by: Thierry Reding <treding@nvidia.com>
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2017-03-20 17:54    [W:0.059 / U:0.460 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site