From b3ce29e2a1cf28aed50470037a177cd462a96598 Mon Sep 17 00:00:00 2001 From: Jyotheeswar Reddy Date: Thu, 6 Aug 2015 11:02:30 -0700 Subject: [PATCH] PMUFW: Core: Clear DONT_SLEEP bit during initialization DONT_SLEEP bit in PMU GLobal control register, if set, wakes up the microblaze from sleep state. This makes the "sleep" instruction ineffective by making the MB to toggle between sleep and wake states in the core loop. So this bit is cleared to prevent such a situation and ensure that MB wakes up only in case of an interrupt event. Signed-off-by: Jyotheeswar Reddy Acked-by: Soren Brinkmann --- lib/sw_apps/zynqmp_pmufw/src/xpfw_core.c | 3 +++ lib/sw_apps/zynqmp_pmufw/src/xpfw_version.h | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/sw_apps/zynqmp_pmufw/src/xpfw_core.c b/lib/sw_apps/zynqmp_pmufw/src/xpfw_core.c index eb3debe8..958c19fc 100644 --- a/lib/sw_apps/zynqmp_pmufw/src/xpfw_core.c +++ b/lib/sw_apps/zynqmp_pmufw/src/xpfw_core.c @@ -51,6 +51,9 @@ XStatus XPfw_CoreInit(u32 Options) XPfw_InterruptInit(); + /* Clear the DONT_SLEEP bit */ + XPfw_RMW32(PMU_GLOBAL_GLOBAL_CNTRL, + PMU_GLOBAL_GLOBAL_CNTRL_DONT_SLEEP_MASK, 0U); CorePtr->ModCount = (u8)0U; diff --git a/lib/sw_apps/zynqmp_pmufw/src/xpfw_version.h b/lib/sw_apps/zynqmp_pmufw/src/xpfw_version.h index 11d90f15..4caef48a 100644 --- a/lib/sw_apps/zynqmp_pmufw/src/xpfw_version.h +++ b/lib/sw_apps/zynqmp_pmufw/src/xpfw_version.h @@ -1,4 +1,4 @@ #ifndef ZYNQMP_XPFW_VERSION__H_ #define ZYNQMP_XPFW_VERSION__H_ - #define ZYNQMP_XPFW_VERSION "2015.3-rc1-17-g29451ae9733a" + #define ZYNQMP_XPFW_VERSION "2015.3-rc1-19-g232f40177e69" #endif