path: root/arch
diff options
authorDavid Vrabel <david.vrabel@citrix.com>2013-03-25 14:11:19 +0000
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2013-03-27 12:06:04 -0400
commitc26377e62f4e6bfb4d99ef88526047209701a83f (patch)
tree839a4e5cea1aa3dbdcbc9f585106b24b360a655a /arch
parentd3eb2c89e7ba996e8781b22a6e7d0a895ef55630 (diff)
xen/events: avoid race with raising an event in unmask_evtchn()
In unmask_evtchn(), when the mask bit is cleared after testing for pending and the event becomes pending between the test and clear, then the upcall will not become pending and the event may be lost or delayed. Avoid this by always clearing the mask bit before checking for pending. If a hypercall is needed, remask the event as EVTCHNOP_unmask will only retrigger pending events if they were masked. This fixes a regression introduced in 3.7 by b5e579232d635b79a3da052964cb357ccda8d9ea (xen/events: fix unmask_evtchn for PV on HVM guests) which reordered the clear mask and check pending operations. Changes in v2: - set mask before hypercall. Cc: stable@vger.kernel.org Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: David Vrabel <david.vrabel@citrix.com> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions

Privacy Policy