KVM: Fix guest shared interrupt with in-kernel irqchip
Every call of kvm_set_irq() should offer an irq_source_id, which is allocated by kvm_request_irq_source_id(). Based on irq_source_id, we identify the irq source and implement logical OR for shared level interrupts. The allocated irq_source_id can be freed by kvm_free_irq_source_id(). Currently, we support at most sizeof(unsigned long) different irq sources. [Amit: - rebase to kvm.git HEAD - move definition of KVM_USERSPACE_IRQ_SOURCE_ID to common file - move kvm_request_irq_source_id to the update_irq ioctl] [Xiantao: - Add kvm/ia64 stuff and make it work for kvm/ia64 guests] Signed-off-by:Sheng Yang <sheng@linux.intel.com> Signed-off-by:
Amit Shah <amit.shah@redhat.com> Signed-off-by:
Xiantao Zhang <xiantao.zhang@intel.com> Signed-off-by:
Avi Kivity <avi@redhat.com>
Showing
- arch/ia64/include/asm/kvm_host.h 3 additions, 0 deletionsarch/ia64/include/asm/kvm_host.h
- arch/ia64/kvm/kvm-ia64.c 5 additions, 3 deletionsarch/ia64/kvm/kvm-ia64.c
- arch/x86/include/asm/kvm_host.h 3 additions, 0 deletionsarch/x86/include/asm/kvm_host.h
- arch/x86/kvm/i8254.c 9 additions, 2 deletionsarch/x86/kvm/i8254.c
- arch/x86/kvm/i8254.h 1 addition, 0 deletionsarch/x86/kvm/i8254.h
- arch/x86/kvm/x86.c 5 additions, 1 deletionarch/x86/kvm/x86.c
- include/linux/kvm_host.h 6 additions, 1 deletioninclude/linux/kvm_host.h
- virt/kvm/irq_comm.c 39 additions, 3 deletionsvirt/kvm/irq_comm.c
- virt/kvm/kvm_main.c 8 additions, 4 deletionsvirt/kvm/kvm_main.c
Loading
Please register or sign in to comment