summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHu, Hebo <hebo.hu@intel.com>2019-07-02 17:34:08 +0800
committerCommit Bot <commit-bot@chromium.org>2019-07-08 13:43:15 +0000
commit05a9bd2711c79d89619d316ee0807cfaec72c9b1 (patch)
tree52742580924ce61c51e320be127e00a632133461
parent2b200899c01c4b0f970c55a4c6774cea13445f19 (diff)
downloadchrome-ec-05a9bd2711c79d89619d316ee0807cfaec72c9b1.tar.gz
ish: fix osscaisonally not load issue when doing shutdown & reboot
Before switch to aon task, cache and ROM will be power gated (PMU_RF_ROM_PWR_CTRL control register) in ecos, and resume after switched back to ecos. But for reset_prep/D3 process, aon task will reset minute ia to ROM finally but forget to resume the power of ROM. This keeps ROM still power gated and make ROM code can't run correctly. The fix is simple, just disable power gating of ROM before reset to ROM in aon task. BUG=b:136265450 BRANCH=none TEST=ISH fw should always load Change-Id: Ib26678bbfdd5dbb17389154478f2565c44d392ab Signed-off-by: Hu, Hebo <hebo.hu@intel.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1690420 Reviewed-by: Jett Rink <jettrink@chromium.org> Commit-Queue: Jett Rink <jettrink@chromium.org> Tested-by: Jett Rink <jettrink@chromium.org>
-rw-r--r--chip/ish/aontaskfw/ish_aontask.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/chip/ish/aontaskfw/ish_aontask.c b/chip/ish/aontaskfw/ish_aontask.c
index 5e16ee7d6a..7020f2e323 100644
--- a/chip/ish/aontaskfw/ish_aontask.c
+++ b/chip/ish/aontaskfw/ish_aontask.c
@@ -593,6 +593,16 @@ static void handle_reset(int pm_state)
/* clear error register in MISC space */
MISC_ISH_ECC_ERR_SRESP = 1;
+ /*
+ * Disable power gating of RF(Cache) and ROMs.
+ *
+ * Before switch to aon task, RF and ROMs are already
+ * power gated, so we need disable the power gating
+ * before reset to ROM, to make sure ROM code runs
+ * correctly.
+ */
+ PMU_RF_ROM_PWR_CTRL = 0;
+
/* reset ISH minute-ia cpu core, will goto ISH ROM */
ish_mia_reset();