Re: [Xen-devel] [RFC PATCH 24/49] ARM: new VGIC: Add IRQ sync/flush framework

2018-02-16 Thread Julien Grall
On 13/02/18 15:40, Andre Przywara wrote: Hi, On 13/02/18 12:41, Julien Grall wrote: Hi Andre, On 09/02/18 14:39, Andre Przywara wrote: gets called on guest entry and exit. The code talking to the actual GICv2/v3 hardware is added in the following patches. This is based on Linux commit 0919

Re: [Xen-devel] [RFC PATCH 24/49] ARM: new VGIC: Add IRQ sync/flush framework

2018-02-13 Thread Andre Przywara
Hi, On 13/02/18 12:41, Julien Grall wrote: > Hi Andre, > > On 09/02/18 14:39, Andre Przywara wrote: >> Implement the framework for syncing IRQs between our emulation and the >> list registers, which represent the guest's view of IRQs. >> This is done in kvm_vgic_flush_hwstate and kvm_vgic_sync_hw

Re: [Xen-devel] [RFC PATCH 24/49] ARM: new VGIC: Add IRQ sync/flush framework

2018-02-13 Thread Julien Grall
On 13/02/18 14:56, Andre Przywara wrote: Hi, On 13/02/18 14:31, Julien Grall wrote: Hi Andre, On 09/02/18 14:39, Andre Przywara wrote: +/* Requires the VCPU's ap_list_lock to be held. */ +static void vgic_flush_lr_state(struct vcpu *vcpu) +{ +    struct vgic_cpu *vgic_cpu = &vcpu->arch.vgic

Re: [Xen-devel] [RFC PATCH 24/49] ARM: new VGIC: Add IRQ sync/flush framework

2018-02-13 Thread Andre Przywara
Hi, On 13/02/18 14:31, Julien Grall wrote: > Hi Andre, > > On 09/02/18 14:39, Andre Przywara wrote: >> +/* Requires the VCPU's ap_list_lock to be held. */ >> +static void vgic_flush_lr_state(struct vcpu *vcpu) >> +{ >> +    struct vgic_cpu *vgic_cpu = &vcpu->arch.vgic_cpu; >> +    struct vgic_irq

Re: [Xen-devel] [RFC PATCH 24/49] ARM: new VGIC: Add IRQ sync/flush framework

2018-02-13 Thread Julien Grall
Hi Andre, On 09/02/18 14:39, Andre Przywara wrote: +/* Requires the VCPU's ap_list_lock to be held. */ +static void vgic_flush_lr_state(struct vcpu *vcpu) +{ +struct vgic_cpu *vgic_cpu = &vcpu->arch.vgic_cpu; +struct vgic_irq *irq; +int count = 0; + +ASSERT(spin_is_locked(&vgic_c

Re: [Xen-devel] [RFC PATCH 24/49] ARM: new VGIC: Add IRQ sync/flush framework

2018-02-13 Thread Julien Grall
Hi Andre, On 09/02/18 14:39, Andre Przywara wrote: Implement the framework for syncing IRQs between our emulation and the list registers, which represent the guest's view of IRQs. This is done in kvm_vgic_flush_hwstate and kvm_vgic_sync_hwstate, which You probably want to update the names here