Re: [PATCH 12/13] KVM: arm64: implement MSI injection in ITS emulation

2015-07-07 Thread Christoffer Dall
On Mon, Jul 06, 2015 at 05:46:37PM +0100, Andre Przywara wrote: [...] > > >> + inject = itte->enabled; > >> + > >> +out_unlock: > >> + spin_unlock(&its->lock); > >> + > >> + if (inject) { > >> + spin_lock(&dist->lock); > >> + set_bit(cpuid, dist->irq_pending_on_cpu); > > isn

Re: [PATCH 12/13] KVM: arm64: implement MSI injection in ITS emulation

2015-07-06 Thread Andre Przywara
Hi Eric, >> diff --git a/virt/kvm/arm/its-emul.c b/virt/kvm/arm/its-emul.c >> index 574cf05..35e886c 100644 >> --- a/virt/kvm/arm/its-emul.c >> +++ b/virt/kvm/arm/its-emul.c >> @@ -340,6 +340,55 @@ static bool handle_mmio_gits_idregs(struct kvm_vcpu >> *vcpu, >> } >> >> /* >> + * Transl

Re: [PATCH 12/13] KVM: arm64: implement MSI injection in ITS emulation

2015-06-11 Thread Eric Auger
Hello Andre, On 05/29/2015 11:53 AM, Andre Przywara wrote: > When userland wants to inject a MSI into the guest, we have to use > our data structures to find the LPI number and the VCPU to receivce receive > the interrupt. > Use the wrapper functions to iterate the linked lists and find the > prope

[PATCH 12/13] KVM: arm64: implement MSI injection in ITS emulation

2015-05-29 Thread Andre Przywara
When userland wants to inject a MSI into the guest, we have to use our data structures to find the LPI number and the VCPU to receivce the interrupt. Use the wrapper functions to iterate the linked lists and find the proper Interrupt Translation Table Entry. Then set the pending bit in this ITTE to