]> git.baikalelectronics.ru Git - kernel.git/commit
clk: fix critical clock locking
authorMaxime Ripard <maxime.ripard@free-electrons.com>
Fri, 13 May 2016 08:00:31 +0000 (10:00 +0200)
committerStephen Boyd <sboyd@codeaurora.org>
Thu, 19 May 2016 21:09:30 +0000 (14:09 -0700)
commitcce3b0788491d13cfcf0a336c1e42735bbb9621d
tree0121cda9a0842adc5f8f5bf1220d208d4f772c29
parent90209d4cc8380fe0f9b4460b042ce847612163ed
clk: fix critical clock locking

The critical clock handling in __clk_core_init isn't taking the enable lock
before calling clk_core_enable, which in turns triggers the warning in the
lockdep_assert_held call in that function when lockep is enabled.

Add the calls to clk_enable_lock/unlock to make sure it doesn't happen.

Fixes: fd98b139624d ("clk: Allow clocks to be marked as CRITICAL")
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
drivers/clk/clk.c