summaryrefslogtreecommitdiff
path: root/chip/it83xx/clock.c
diff options
context:
space:
mode:
authorDino Li <dino.li@ite.com.tw>2014-03-17 15:01:55 +0800
committerchrome-internal-fetch <chrome-internal-fetch@google.com>2014-03-18 11:24:24 +0000
commitfa9f407a66e10b4871d02b118952a9b0ac7e3263 (patch)
tree53c0a4d4910206a61fe1c128c984bb501205f8fb /chip/it83xx/clock.c
parent24417669a626fcda285c79aa8fa54268683d695a (diff)
downloadchrome-ec-fa9f407a66e10b4871d02b118952a9b0ac7e3263.tar.gz
it8380dev: fix firmware can't startup (re-generate)
Some section(entry point, interrupt vector, e-flash signature and so on) of linker script file are not linked. The start address of e-flash signature should always at 00000080h. Default firmware treats VCC logic high to prevent pin 11 logic low but use following functions. (EC2I, KBC, SWUC, PMC, CIR, SSPI, UART, BRAM, and PECI) Signed-off-by: Dino Li <dino.li@ite.com.tw> BRANCH=none BUG=none TEST=Firmware can startup on IT8380 emulation board. Change-Id: I9860ac5b99dcc6e9e00dbc9d1e79a141237b7789 Reviewed-on: https://chromium-review.googlesource.com/190008 Reviewed-by: Alec Berg <alecaberg@chromium.org> Reviewed-by: Vincent Palatin <vpalatin@chromium.org> Tested-by: Dino Li <dino.li@ite.com.tw> Commit-Queue: Dino Li <dino.li@ite.com.tw>
Diffstat (limited to 'chip/it83xx/clock.c')
-rw-r--r--chip/it83xx/clock.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/chip/it83xx/clock.c b/chip/it83xx/clock.c
index f2e2a6d37b..437cb3b4b7 100644
--- a/chip/it83xx/clock.c
+++ b/chip/it83xx/clock.c
@@ -37,6 +37,16 @@ void clock_init(void)
/* Set EC Clock Frequency to PLL frequency. */
IT83XX_ECPM_SCDCR3 &= 0xf0;
+ /*
+ * The VCC power status is treated as power-on.
+ * The VCC supply of LPC and related functions (EC2I,
+ * KBC, SWUC, PMC, CIR, SSPI, UART, BRAM, and PECI).
+ * It means VCC (pin 11) should be logic high before using
+ * these functions, or firmware treats VCC logic high
+ * as following setting.
+ */
+ IT83XX_GCTRL_RSTS = (IT83XX_GCTRL_RSTS & 0x3F) + 0x40;
+
/* Turn off auto clock gating. */
IT83XX_ECPM_AUTOCG = 0x00;
}