]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
xen/events: Set irq_info->evtchn before binding the channel to CPU in __startup_pirq()
authorBoris Ostrovsky <boris.ostrovsky@oracle.com>
Wed, 29 Apr 2015 21:10:15 +0000 (17:10 -0400)
committerZefan Li <lizefan@huawei.com>
Fri, 18 Sep 2015 01:20:36 +0000 (09:20 +0800)
commit 16e6bd5970c88a2ac018b84a5f1dd5c2ff1fdf2c upstream.

.. because bind_evtchn_to_cpu(evtchn, cpu) will map evtchn to
'info' and pass 'info' down to xen_evtchn_port_bind_to_cpu().

Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Tested-by: Annie Li <annie.li@oracle.com>
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
[lizf: Backported to 3.4: adjust filename and context]
Signed-off-by: Zefan Li <lizefan@huawei.com>
drivers/xen/events.c

index 9161f06564eba8cd6371df464d488768fee43d83..fdf842c83a7ab2689a8741ab4f2c0f19c6ee9332 100644 (file)
@@ -563,8 +563,8 @@ static unsigned int __startup_pirq(unsigned int irq)
        pirq_query_unmask(irq);
 
        evtchn_to_irq[evtchn] = irq;
-       bind_evtchn_to_cpu(evtchn, 0);
        info->evtchn = evtchn;
+       bind_evtchn_to_cpu(evtchn, 0);
 
 out:
        unmask_evtchn(evtchn);