[32/35] KVM: PPC: Document KVM_INTERRUPT ioctl

Message ID 1283221937-21006-33-git-send-email-agraf@suse.de
State Not Applicable
Headers show

Commit Message

Alexander Graf Aug. 31, 2010, 2:32 a.m.
This adds some documentation for the KVM_INTERRUPT special cases that
PowerPC now implements.

Signed-off-by: Alexander Graf <agraf@suse.de>
 Documentation/kvm/api.txt |   33 +++++++++++++++++++++++++++++++--
 1 files changed, 31 insertions(+), 2 deletions(-)


diff --git a/Documentation/kvm/api.txt b/Documentation/kvm/api.txt
index 44d9893..24d6341 100644
--- a/Documentation/kvm/api.txt
+++ b/Documentation/kvm/api.txt
@@ -320,13 +320,13 @@  struct kvm_translation {
 Capability: basic
-Architectures: x86
+Architectures: x86, ppc
 Type: vcpu ioctl
 Parameters: struct kvm_interrupt (in)
 Returns: 0 on success, -1 on error
 Queues a hardware interrupt vector to be injected.  This is only
-useful if in-kernel local APIC is not used.
+useful if in-kernel local APIC or equivalent is not used.
 /* for KVM_INTERRUPT */
 struct kvm_interrupt {
@@ -334,8 +334,37 @@  struct kvm_interrupt {
 	__u32 irq;
 Note 'irq' is an interrupt vector, not an interrupt pin or line.
+Queues an external interrupt to be injected. This ioctl is overleaded
+with 3 different irq values:
+  This injects an edge type external interrupt into the guest once it's ready
+  to receive interrupts. When injected, the interrupt is done.
+  This unsets any pending interrupt.
+  Only available with KVM_CAP_PPC_UNSET_IRQ.
+  This injects a level type external interrupt into the guest context. The
+  interrupt stays pending until a specific ioctl with KVM_INTERRUPT_UNSET
+  is triggered.
+  Only available with KVM_CAP_PPC_IRQ_LEVEL.
+Note that any value for 'irq' other than the ones stated above is invalid
+and incurs unexpected behavior.
 Capability: basic