summaryrefslogtreecommitdiff
path: root/src/cpu
diff options
context:
space:
mode:
authorAndreas Sandberg <andreas.sandberg@arm.com>2017-04-24 16:38:46 +0000
committerAndreas Sandberg <andreas.sandberg@arm.com>2017-07-07 10:11:16 +0000
commitfeb91ce576f2da6e1941697100d14bc10ace6a90 (patch)
tree6af40ee5970c4234f29c3a69c31fe2fe246d5017 /src/cpu
parent166da650a3c864b31193ade893ed99e547c67644 (diff)
downloadgem5-feb91ce576f2da6e1941697100d14bc10ace6a90.tar.xz
kvm, arm: Don't forward IRQ/FIQ when using the kernel's GIC
The BaseArmKvmCPU is responsible for forwarding the IRQ and FIQ signals from gem5's simulated GIC to KVM. However, these signals shouldn't be used when the in-kernel GIC emulator is used. Instead of delivering the interrupts to the guest, we should just ignore them since any such pending interrupts are likely to be an artifact of CPU switching or incorrect draining. Change-Id: I083b72639384272157f92f44a6606bdf0be7413c Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com> Reviewed-by: Sudhanshu Jha <sudhanshu.jha@arm.com> Reviewed-by: Curtis Dunham <curtis.dunham@arm.com> Reviewed-on: https://gem5-review.googlesource.com/3660
Diffstat (limited to 'src/cpu')
-rw-r--r--src/cpu/kvm/vm.hh9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/cpu/kvm/vm.hh b/src/cpu/kvm/vm.hh
index df2e4119a..e122bbf86 100644
--- a/src/cpu/kvm/vm.hh
+++ b/src/cpu/kvm/vm.hh
@@ -351,6 +351,15 @@ class KvmVM : public SimObject
* Is in-kernel IRQ chip emulation enabled?
*/
bool hasKernelIRQChip() const { return _hasKernelIRQChip; }
+
+ /**
+ * Tell the VM and VCPUs to use an in-kernel IRQ chip for
+ * interrupt delivery.
+ *
+ * @note This is set automatically if the IRQ chip is created
+ * using the KvmVM::createIRQChip() API.
+ */
+ void enableKernelIRQChip() { _hasKernelIRQChip = true; }
/** @} */
struct MemSlot