xen/events: fifo: use xen_vcpu_id mapping
authorVitaly Kuznetsov <vkuznets@redhat.com>
Thu, 30 Jun 2016 15:56:41 +0000 (17:56 +0200)
committerDavid Vrabel <david.vrabel@citrix.com>
Mon, 25 Jul 2016 12:34:12 +0000 (13:34 +0100)
EVTCHNOP_init_control has vCPU id as a parameter and Xen's idea of
vCPU id should be used. Use the newly introduced xen_vcpu_id mapping
to convert it from Linux's id.

Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
drivers/xen/events/events_fifo.c

index 9289a17..266c2c7 100644 (file)
@@ -113,7 +113,7 @@ static int init_control_block(int cpu,
 
        init_control.control_gfn = virt_to_gfn(control_block);
        init_control.offset      = 0;
-       init_control.vcpu        = cpu;
+       init_control.vcpu        = xen_vcpu_nr(cpu);
 
        return HYPERVISOR_event_channel_op(EVTCHNOP_init_control, &init_control);
 }