summaryrefslogtreecommitdiff
path: root/include/clock.h
diff options
context:
space:
mode:
authorRandall Spangler <rspangler@chromium.org>2012-04-24 09:59:31 -0700
committerRandall Spangler <rspangler@chromium.org>2012-04-24 09:59:31 -0700
commit7ecb8358b9ae4594abc9cc6251719283e079a494 (patch)
tree5b9d4a7323515d97f1aaee242e8d9a6091e1d260 /include/clock.h
parente8c86b2a6845b5fa9b73a6410c0442a0f03f771d (diff)
downloadchrome-ec-7ecb8358b9ae4594abc9cc6251719283e079a494.tar.gz
Disable PLL at end of init
This saves power. Signed-off-by: Randall Spangler <rspangler@chromium.org> BUG=chrome-os-partner:8798 TEST=manual Get a proto1 system modified with INA current sensor 1) From chroot: dut-control i2c_mux_en:on i2c_mux:rem dut-control pp3300_alw_mv pp3300_alw_ma 2) From EC console: pll (this should turn the PLL back on; it'll report clock frequency ~66MHz) 3) From chroot: dut-control i2c_mux_en:on i2c_mux:rem dut-control pp3300_alw_mv pp3300_alw_ma Current (ma) should be bigger than in step 1 Change-Id: I806953684c57fd60bf481acb01dddffe2f2ad0ed
Diffstat (limited to 'include/clock.h')
-rw-r--r--include/clock.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/clock.h b/include/clock.h
index 081c9c95a9..209f42c0f0 100644
--- a/include/clock.h
+++ b/include/clock.h
@@ -13,9 +13,12 @@
/* Set the CPU clocks and PLLs. */
int clock_init(void);
-/* Returns the current clock frequency in Hz. */
+/* Return the current clock frequency in Hz. */
int clock_get_freq(void);
+/* Enable or disable the PLL. */
+int clock_enable_pll(int enable);
+
/* Wait <cycles> system clock cycles. Simple busy waiting for before
* clocks/timers are initialized. */
void clock_wait_cycles(uint32_t cycles);