]> git.baikalelectronics.ru Git - kernel.git/commit
xen: disable interrupts before saving in percpu
authorJeremy Fitzhardinge <jeremy@goop.org>
Wed, 4 Feb 2009 00:01:46 +0000 (16:01 -0800)
committerH. Peter Anvin <hpa@zytor.com>
Wed, 4 Feb 2009 01:22:40 +0000 (17:22 -0800)
commitb58e7fecc1c12a816b690ba0c4424231c9abdc70
treeeb6a202f5bc01a5c8ac9f7245b9097f18ac44e57
parentd70cd0d73359ce79c2a5b424a6199b95a32bfbea
xen: disable interrupts before saving in percpu

Impact: Fix race condition

xen_mc_batch has a small preempt race where it takes the address of a
percpu variable immediately before disabling interrupts, thereby
leaving a small window in which we may migrate to another cpu and save
the flags in the wrong percpu variable.  Disable interrupts before
saving the old flags in a percpu.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
arch/x86/xen/multicalls.h