python: Remove redundant drain when changing memory modes

When the Python helper code switches CPU models, it sometimes also
needs to change the memory mode of the simulator. When this happens,
it accidentally tried to drain the simulator despite having done so
already. This changeset removes the redundant drain.
This commit is contained in:
Andreas Sandberg 2015-07-07 09:51:04 +01:00
parent 7773cb9565
commit 1dc5e63b88

View file

@ -224,7 +224,6 @@ def _changeMemoryMode(system, mode):
raise TypeError, "Parameter of type '%s'. Must be type %s or %s." % \
(type(system), objects.Root, objects.System)
if system.getMemoryMode() != mode:
drain(system)
system.setMemoryMode(mode)
else:
print "System already in target mode. Memory mode unchanged."