Commit 9f4cc127 authored by Marcelo Tosatti's avatar Marcelo Tosatti Committed by Avi Kivity

KVM: Grab pic lock in kvm_pic_clear_isr_ack

isr_ack is protected by kvm_pic->lock.
Signed-off-by: default avatarMarcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: default avatarAvi Kivity <avi@redhat.com>
parent 238adc77
...@@ -72,8 +72,10 @@ static void pic_clear_isr(struct kvm_kpic_state *s, int irq) ...@@ -72,8 +72,10 @@ static void pic_clear_isr(struct kvm_kpic_state *s, int irq)
void kvm_pic_clear_isr_ack(struct kvm *kvm) void kvm_pic_clear_isr_ack(struct kvm *kvm)
{ {
struct kvm_pic *s = pic_irqchip(kvm); struct kvm_pic *s = pic_irqchip(kvm);
pic_lock(s);
s->pics[0].isr_ack = 0xff; s->pics[0].isr_ack = 0xff;
s->pics[1].isr_ack = 0xff; s->pics[1].isr_ack = 0xff;
pic_unlock(s);
} }
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment