summaryrefslogtreecommitdiff
path: root/src/arch/x86/interrupts.hh
diff options
context:
space:
mode:
authorAndreas Sandberg <andreas@sandberg.pp.se>2013-09-18 11:28:27 +0200
committerAndreas Sandberg <andreas@sandberg.pp.se>2013-09-18 11:28:27 +0200
commit4b840b8322f4536a4e0c49c43f999c00fa66a1e9 (patch)
tree80ec23fcbe371ccc23a184f246546f758c54310e /src/arch/x86/interrupts.hh
parent15733e9b33921236c2da2d4f6d1772bdd4d21069 (diff)
downloadgem5-4b840b8322f4536a4e0c49c43f999c00fa66a1e9.tar.xz
x86: Add support for checking the raw state of an interrupt
In order to support hardware virtualization, we need to be able to check if there are any interrupts pending irregardless of the rflags.intf value. This changeset adds the checkInterruptsRaw() method to the x86 interrupt control. It returns true if there are pending interrupts that can be delivered as soon as the CPU is ready for interrupt delivery.
Diffstat (limited to 'src/arch/x86/interrupts.hh')
-rw-r--r--src/arch/x86/interrupts.hh7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/arch/x86/interrupts.hh b/src/arch/x86/interrupts.hh
index da0d767fd..8997d7402 100644
--- a/src/arch/x86/interrupts.hh
+++ b/src/arch/x86/interrupts.hh
@@ -274,6 +274,13 @@ class Interrupts : public BasicPioDevice, IntDevice
*/
bool checkInterrupts(ThreadContext *tc) const;
+ /**
+ * Check if there are pending interrupts without ignoring the
+ * interrupts disabled flag.
+ *
+ * @return true if there are interrupts pending.
+ */
+ bool checkInterruptsRaw() const;
Fault getInterrupt(ThreadContext *tc);
void updateIntrInfo(ThreadContext *tc);