From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Grall Subject: Re: [PATCH v10 07/10] xen: remove workaround to inject evtchn_irq on irq enable Date: Tue, 05 Aug 2014 13:34:31 +0100 Message-ID: <53E0CF57.40201@linaro.org> References: <1407237989-27654-7-git-send-email-stefano.stabellini@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1407237989-27654-7-git-send-email-stefano.stabellini@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Stefano Stabellini , xen-devel@lists.xensource.com Cc: julien.grall@citrix.com, Ian.Campbell@citrix.com List-Id: xen-devel@lists.xenproject.org Hi Stefano, On 08/05/2014 12:26 PM, Stefano Stabellini wrote: > evtchn_upcall_pending is already set by common code at vcpu creation, > therefore on ARM we also need to call vgic_vcpu_inject_irq for it. > Currently we do that from vgic_enable_irqs as a workaround. > > Do this properly by introducing an appropriate arch specific hook: > arch_evtchn_inject. arch_evtchn_inject is called by map_vcpu_info to > inject the evtchn irq into the guest. On ARM is implemented by calling > vgic_vcpu_inject_irq. > > On x86 guests typically don't call VCPUOP_register_vcpu_info on vcpu0, > therefore avoiding the issue. However theoretically they could call > VCPUOP_register_vcpu_info on vcpu0 and in that case Xen would need to > inject the event channel notification into the guest if the guest is > HVM. So implement arch_evtchn_inject on x86 by calling > hvm_assert_evtchn_irq. > > Signed-off-by: Stefano Stabellini Acked-by: Julien Grall Regards, -- Julien Grall