summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/python/m5/config.py2
-rw-r--r--src/sim/sim_object.cc2
-rw-r--r--src/sim/sim_object.hh2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/python/m5/config.py b/src/python/m5/config.py
index cffe06984..8291e1e1b 100644
--- a/src/python/m5/config.py
+++ b/src/python/m5/config.py
@@ -547,7 +547,7 @@ class SimObject(object):
count = 0
# ParamContexts don't serialize
if isinstance(self, SimObject) and not isinstance(self, ParamContext):
- if self._ccObject.drain(drain_event):
+ if not self._ccObject.drain(drain_event):
count = 1
if recursive:
for child in self._children.itervalues():
diff --git a/src/sim/sim_object.cc b/src/sim/sim_object.cc
index 655bdcf4e..a0278dba0 100644
--- a/src/sim/sim_object.cc
+++ b/src/sim/sim_object.cc
@@ -277,7 +277,7 @@ SimObject::drain(Event *drain_event)
"in timing mode!");
}
state = DrainedAtomic;
- return false;
+ return true;
}
void
diff --git a/src/sim/sim_object.hh b/src/sim/sim_object.hh
index 4833192d6..7ecc00958 100644
--- a/src/sim/sim_object.hh
+++ b/src/sim/sim_object.hh
@@ -116,7 +116,7 @@ class SimObject : public Serializable, protected StartupCallback
// Methods to drain objects in order to take checkpoints
// Or switch from timing -> atomic memory model
- // Quiesce returns true if the SimObject cannot quiesce immediately.
+ // Drain returns false if the SimObject cannot drain immediately.
virtual bool drain(Event *drain_event);
virtual void resume();
virtual void setMemoryMode(State new_mode);