summaryrefslogtreecommitdiffstats
path: root/drivers/clk
diff options
context:
space:
mode:
authorAlexandre Belloni <alexandre.belloni@free-electrons.com>2016-09-20 22:58:31 +0200
committerStephen Boyd <sboyd@codeaurora.org>2016-09-21 02:03:04 +0200
commit4135b7f8d42180d6d9820b53b0ab5e3377b7c364 (patch)
tree584f17d64287176f62c43d0c65230c74cad9b238 /drivers/clk
parentclk: at91: Add sama5d4 sckc support (diff)
downloadlinux-4135b7f8d42180d6d9820b53b0ab5e3377b7c364.tar.xz
linux-4135b7f8d42180d6d9820b53b0ab5e3377b7c364.zip
clk: at91: sckc: optimize boot time
Assume that if the oscillator is enabled (OSC32EN bit is present), the delay has already elapsed as the bootloader probably waited for the oscillator to settle. This could waste up to 1.2s. Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Diffstat (limited to 'drivers/clk')
-rw-r--r--drivers/clk/at91/sckc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/clk/at91/sckc.c b/drivers/clk/at91/sckc.c
index 199d1b3f5ad3..ab6ecefc49ad 100644
--- a/drivers/clk/at91/sckc.c
+++ b/drivers/clk/at91/sckc.c
@@ -69,7 +69,7 @@ static int clk_slow_osc_prepare(struct clk_hw *hw)
void __iomem *sckcr = osc->sckcr;
u32 tmp = readl(sckcr);
- if (tmp & AT91_SCKC_OSC32BYP)
+ if (tmp & (AT91_SCKC_OSC32BYP | AT91_SCKC_OSC32EN))
return 0;
writel(tmp | AT91_SCKC_OSC32EN, sckcr);