summaryrefslogtreecommitdiff
path: root/chip/ish/power_mgt.c
diff options
context:
space:
mode:
authorJack Rosenthal <jrosenth@chromium.org>2019-05-29 15:51:48 -0600
committerCommit Bot <commit-bot@chromium.org>2019-06-06 14:43:50 +0000
commit3643c1d0036400c2b95230ce2b1c06d7327f549f (patch)
treeeaaae372e797246abfe4f9f7b62d5801eedd2f00 /chip/ish/power_mgt.c
parente5be2fdf9a26c380f5cce863592f9f8115f48884 (diff)
downloadchrome-ec-3643c1d0036400c2b95230ce2b1c06d7327f549f.tar.gz
ish: use magic number to verify persistent data
Move persistent data definitions to a structure and have linker script define the address of the symbol into the AON ROM (persistent data storage). Use the magic number "ISHd" to verify persistent data storage and copy to static memory when valid. Commit changes from the local copy during reset. BUG=b:133779707,b:133647823,b:132059981 BRANCH=none TEST=power-on is only reset flag under cold reset, panic data persists, watchdog reset produces correct reset flags, UART always printing system info on boot Cq-Depend: chromium:1644188 Change-Id: I65a458cc2656f8fe26361ef2117ceb5439edff6c Signed-off-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1644208 Commit-Queue: Jett Rink <jettrink@chromium.org> Tested-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'chip/ish/power_mgt.c')
-rw-r--r--chip/ish/power_mgt.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/chip/ish/power_mgt.c b/chip/ish/power_mgt.c
index 63d9b6bc5d..e61838b953 100644
--- a/chip/ish/power_mgt.c
+++ b/chip/ish/power_mgt.c
@@ -3,15 +3,15 @@
* found in the LICENSE file.
*/
-#include <console.h>
-#include <task.h>
-#include <system.h>
-#include <hwtimer.h>
-#include <util.h>
-#include "interrupts.h"
#include "aontaskfw/ish_aon_share.h"
-#include "power_mgt.h"
+#include "console.h"
+#include "hwtimer.h"
+#include "interrupts.h"
#include "ish_dma.h"
+#include "power_mgt.h"
+#include "system.h"
+#include "task.h"
+#include "util.h"
#ifdef CONFIG_ISH_PM_DEBUG
#define CPUTS(outstr) cputs(CC_SYSTEM, outstr)