On 06/05/2011 07:24 PM, Christoffer Dall wrote: > On ARM, we are talking about IRQs and FIQs, both of which can be > lowered and raised. In other words, four values. Two lines per cpu, each of which can be raised or lowered. > But instead of this, you want to use KVM_IRQ_LINE and just assume one > CPU to begin with and always assert/deassert the interrupts on that > CPU and later, with SMP support, you want to use KVM_SET_GSI_ROUTING > to control which CPU gets the interrupt - even though GSI is a > non-existing concept for ARM? (Also, I could not seem to find any use > of GSI_ROUTING in current upstream QEMU, but I may be missing > something here?). Almost. vcpu N's IRQ -> KVM_IRQ_LINE(N*2, level). vcpu N's FIQ -> KVM_IRQ_LINE(N*2+1, level), + documentation somewhere. > I suggest I simply use a flag in the irq field on the kvm_interrupt > struct as suggested by Jan, for now, and if we start emulating GICs > inside the kernel for ARM we can go the extra mile at that point. > IMHO, I think the semantics of actually raising an interrup line on > the VCPU, as opposed to the VM, when it's CPU interrupt we are talking > about is equally important. When you implement an interrupt controller, you can use KVM_SET_GSI_ROUTING to change the meaning of the parameter to KVM_IRQ_LINE to point to the interrupt controllers. -- error compiling committee.c: too many arguments to function