summaryrefslogtreecommitdiff
path: root/src/cpu/minor
diff options
context:
space:
mode:
Diffstat (limited to 'src/cpu/minor')
-rw-r--r--src/cpu/minor/cpu.cc11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/cpu/minor/cpu.cc b/src/cpu/minor/cpu.cc
index ae4fda6f6..68c07675f 100644
--- a/src/cpu/minor/cpu.cc
+++ b/src/cpu/minor/cpu.cc
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012-2014 ARM Limited
+ * Copyright (c) 2012-2014, 2017 ARM Limited
* All rights reserved
*
* The license below extends only to copyright in the software and shall
@@ -195,6 +195,9 @@ MinorCPU::startup()
DrainState
MinorCPU::drain()
{
+ // Deschedule any power gating event (if any)
+ deschedulePowerGatingEvent();
+
if (switchedOut()) {
DPRINTF(Drain, "Minor CPU switched out, draining not needed.\n");
return DrainState::Drained;
@@ -240,10 +243,14 @@ MinorCPU::drainResume()
"'timing' mode.\n");
}
- for (ThreadID tid = 0; tid < numThreads; tid++)
+ for (ThreadID tid = 0; tid < numThreads; tid++){
wakeup(tid);
+ }
pipeline->drainResume();
+
+ // Reschedule any power gating event (if any)
+ schedulePowerGatingEvent();
}
void