summaryrefslogtreecommitdiff
path: root/dev/tsunami_uart.cc
diff options
context:
space:
mode:
Diffstat (limited to 'dev/tsunami_uart.cc')
-rw-r--r--dev/tsunami_uart.cc13
1 files changed, 13 insertions, 0 deletions
diff --git a/dev/tsunami_uart.cc b/dev/tsunami_uart.cc
index 1eef24926..28c97c4cd 100644
--- a/dev/tsunami_uart.cc
+++ b/dev/tsunami_uart.cc
@@ -255,6 +255,14 @@ TsunamiUart::serialize(ostream &os)
SERIALIZE_SCALAR(next_char);
SERIALIZE_SCALAR(valid_char);
SERIALIZE_SCALAR(IER);
+ Tick intrwhen;
+ if (intrEvent.scheduled())
+ intrwhen = intrEvent.when();
+ else
+ intrwhen = 0;
+ SERIALIZE_SCALAR(intrwhen);
+
+
}
void
@@ -264,6 +272,11 @@ TsunamiUart::unserialize(Checkpoint *cp, const std::string &section)
UNSERIALIZE_SCALAR(next_char);
UNSERIALIZE_SCALAR(valid_char);
UNSERIALIZE_SCALAR(IER);
+ Tick intrwhen;
+ UNSERIALIZE_SCALAR(intrwhen);
+ if (intrwhen != 0)
+ intrEvent.schedule(intrwhen);
+
}
BEGIN_DECLARE_SIM_OBJECT_PARAMS(TsunamiUart)