events: drop arch_evtchn_inject()
authorJan Beulich <jbeulich@suse.com>
Tue, 12 Mar 2019 13:40:24 +0000 (14:40 +0100)
committerJan Beulich <jbeulich@suse.com>
Tue, 12 Mar 2019 13:40:24 +0000 (14:40 +0100)
Have the only user call vcpu_mark_events_pending() instead, at the same
time arranging for correct ordering of the writes (evtchn_pending_sel
should be written before evtchn_upcall_pending).

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Julien Grall <julien.grall@arm.com>
xen/arch/arm/vgic.c
xen/arch/arm/vgic/vgic.c
xen/arch/x86/irq.c
xen/common/domain.c
xen/include/xen/event.h

index f2608b042dabe99ab249ec304f0b3179d483ae53..19d8c9b87637fe3108a4372fea3a0626cefae355 100644 (file)
@@ -597,11 +597,6 @@ out:
     return;
 }
 
-void arch_evtchn_inject(struct vcpu *v)
-{
-    vgic_inject_irq(v->domain, v, v->domain->arch.evtchn_irq, true);
-}
-
 bool vgic_evtchn_irq_pending(struct vcpu *v)
 {
     struct pending_irq *p;
index e2844dcc207191a1b3f691e63d46cbce94026d70..f0f2ea502195901d6c9654f00ae9e330eff95215 100644 (file)
@@ -692,11 +692,6 @@ void vgic_kick_vcpus(struct domain *d)
     }
 }
 
-void arch_evtchn_inject(struct vcpu *v)
-{
-    vgic_inject_irq(v->domain, v, v->domain->arch.evtchn_irq, true);
-}
-
 bool vgic_evtchn_irq_pending(struct vcpu *v)
 {
     struct vgic_irq *irq;
index 23b4f423e660ef4f0d60fefec9942a246c8d64f0..8511953977c1dd26d081ada2e03f3a6fe3f189b3 100644 (file)
@@ -2724,9 +2724,3 @@ int allocate_and_map_msi_pirq(struct domain *d, int index, int *pirq_p,
 
     return ret;
 }
-
-void arch_evtchn_inject(struct vcpu *v)
-{
-    if ( is_hvm_vcpu(v) )
-        hvm_assert_evtchn_irq(v);
-}
index 32bca8dbf2df7bf09d2d2476df5ff2536c205abb..05423388628fb8b3336cbdab02694bed9e1e9bed 100644 (file)
@@ -1306,10 +1306,9 @@ int map_vcpu_info(struct vcpu *v, unsigned long gfn, unsigned offset)
      * Mark everything as being pending just to make sure nothing gets
      * lost.  The domain will get a spurious event, but it can cope.
      */
-    vcpu_info(v, evtchn_upcall_pending) = 1;
     for ( i = 0; i < BITS_PER_EVTCHN_WORD(d); i++ )
         set_bit(i, &vcpu_info(v, evtchn_pending_sel));
-    arch_evtchn_inject(v);
+    vcpu_mark_events_pending(v);
 
     return 0;
 }
index e91097d77efb1527a4bd0a60b7350f51fa0e9b70..a7798f676515d11a5dd6c8f1a996df9cd2141ad4 100644 (file)
@@ -91,9 +91,6 @@ int guest_enabled_event(struct vcpu *v, uint32_t virq);
 /* Notify remote end of a Xen-attached event channel.*/
 void notify_via_xen_event_channel(struct domain *ld, int lport);
 
-/* Inject an event channel notification into the guest */
-void arch_evtchn_inject(struct vcpu *v);
-
 /*
  * Internal event channel object storage.
  *