summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--power/apollolake.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/power/apollolake.c b/power/apollolake.c
index c1fcbe8e17..dda74a29b9 100644
--- a/power/apollolake.c
+++ b/power/apollolake.c
@@ -28,6 +28,14 @@ __attribute__((weak)) void chipset_do_shutdown(void)
static void internal_chipset_shutdown(void)
{
+ /*
+ * UART buffer gets overwritten by other tasks if it is not explicitly
+ * flushed before printing it on the console by same task. Hence, clean
+ * up the UART buffer so that all the debug messages are printed on the
+ * UART console before doing shutdown.
+ */
+ cflush();
+
CPRINTS("%s()", __func__);
force_shutdown = 0;