From 81db5ccf3c41e28966ce547e3fd783634581a077 Mon Sep 17 00:00:00 2001 From: Curtis Dunham Date: Wed, 26 Apr 2017 15:21:34 +0000 Subject: kvm, arm: don't create interrupt events while saving GIC state If an interrupt was pending according to Kvm state during a drain, the Pl390 model would create an interrupt event that could not be serviced, preventing the system from draining. The proper behavior is for the Pl390 not actively being used for simulation to just skip the GIC state machine that delivers interrupts. Change-Id: Icb37e7e992f1fb441a9b3a26daa1bb5a6fe19228 Reviewed-by: Andreas Sandberg Reviewed-on: https://gem5-review.googlesource.com/3661 Maintainer: Andreas Sandberg --- src/dev/arm/gic_pl390.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/dev/arm/gic_pl390.cc') diff --git a/src/dev/arm/gic_pl390.cc b/src/dev/arm/gic_pl390.cc index 7b63306c3..93aaf5c45 100644 --- a/src/dev/arm/gic_pl390.cc +++ b/src/dev/arm/gic_pl390.cc @@ -871,6 +871,14 @@ Pl390::drain() } } + +void +Pl390::drainResume() +{ + // There may be pending interrupts if checkpointed from Kvm; post them. + updateIntState(-1); +} + void Pl390::serialize(CheckpointOut &cp) const { -- cgit v1.2.3