diff options
author | Jeremy Fitzhardinge <jeremy@goop.org> | 2008-05-26 18:31:05 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2008-05-27 04:11:35 -0400 |
commit | 239d1fc04ed0b58d638096b12a7f6d50269d30c9 (patch) | |
tree | 746cadf690dd34a07e62ce00e7963bf2eba4710d /arch/x86/xen | |
parent | 2956a3511c8c5dccb1d4739ead17c7c3c23a24b7 (diff) |
xen: don't worry about preempt during xen_irq_enable()
When enabling interrupts, we don't need to worry about preemption,
because we either enter with interrupts disabled - so no preemption -
or the caller is confused and is re-enabling interrupts on some
indeterminate processor.
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/xen')
-rw-r--r-- | arch/x86/xen/enlighten.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index f6876485ee7d..4a372b71239d 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c | |||
@@ -235,13 +235,13 @@ static void xen_irq_enable(void) | |||
235 | { | 235 | { |
236 | struct vcpu_info *vcpu; | 236 | struct vcpu_info *vcpu; |
237 | 237 | ||
238 | /* There's a one instruction preempt window here. We need to | 238 | /* We don't need to worry about being preempted here, since |
239 | make sure we're don't switch CPUs between getting the vcpu | 239 | either a) interrupts are disabled, so no preemption, or b) |
240 | pointer and updating the mask. */ | 240 | the caller is confused and is trying to re-enable interrupts |
241 | preempt_disable(); | 241 | on an indeterminate processor. */ |
242 | |||
242 | vcpu = x86_read_percpu(xen_vcpu); | 243 | vcpu = x86_read_percpu(xen_vcpu); |
243 | vcpu->evtchn_upcall_mask = 0; | 244 | vcpu->evtchn_upcall_mask = 0; |
244 | preempt_enable_no_resched(); | ||
245 | 245 | ||
246 | /* Doesn't matter if we get preempted here, because any | 246 | /* Doesn't matter if we get preempted here, because any |
247 | pending event will get dealt with anyway. */ | 247 | pending event will get dealt with anyway. */ |