diff options
| author | H. Peter Anvin <hpa@zytor.com> | 2010-02-22 19:20:34 -0500 |
|---|---|---|
| committer | H. Peter Anvin <hpa@zytor.com> | 2010-02-22 19:20:34 -0500 |
| commit | d02e30c31c57683a66ed68a1bcff900ca78f6d56 (patch) | |
| tree | c3ce99a00061bcc1199b50fa838147d876c56717 /arch/x86/kvm/lapic.c | |
| parent | 0fdc7a8022c3eaff6b5ee27ffb9e913e5e58d8e9 (diff) | |
| parent | aef55d4922e62a0d887e60d87319f3718aec6ced (diff) | |
Merge branch 'x86/irq' into x86/apic
Merge reason:
Conflicts in arch/x86/kernel/apic/io_apic.c
Resolved Conflicts:
arch/x86/kernel/apic/io_apic.c
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'arch/x86/kvm/lapic.c')
| -rw-r--r-- | arch/x86/kvm/lapic.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c index cd60c0bd1b32..ba8c045da782 100644 --- a/arch/x86/kvm/lapic.c +++ b/arch/x86/kvm/lapic.c | |||
| @@ -373,6 +373,12 @@ static int __apic_accept_irq(struct kvm_lapic *apic, int delivery_mode, | |||
| 373 | if (unlikely(!apic_enabled(apic))) | 373 | if (unlikely(!apic_enabled(apic))) |
| 374 | break; | 374 | break; |
| 375 | 375 | ||
| 376 | if (trig_mode) { | ||
| 377 | apic_debug("level trig mode for vector %d", vector); | ||
| 378 | apic_set_vector(vector, apic->regs + APIC_TMR); | ||
| 379 | } else | ||
| 380 | apic_clear_vector(vector, apic->regs + APIC_TMR); | ||
| 381 | |||
| 376 | result = !apic_test_and_set_irr(vector, apic); | 382 | result = !apic_test_and_set_irr(vector, apic); |
| 377 | trace_kvm_apic_accept_irq(vcpu->vcpu_id, delivery_mode, | 383 | trace_kvm_apic_accept_irq(vcpu->vcpu_id, delivery_mode, |
| 378 | trig_mode, vector, !result); | 384 | trig_mode, vector, !result); |
| @@ -383,11 +389,6 @@ static int __apic_accept_irq(struct kvm_lapic *apic, int delivery_mode, | |||
| 383 | break; | 389 | break; |
| 384 | } | 390 | } |
| 385 | 391 | ||
| 386 | if (trig_mode) { | ||
| 387 | apic_debug("level trig mode for vector %d", vector); | ||
| 388 | apic_set_vector(vector, apic->regs + APIC_TMR); | ||
| 389 | } else | ||
| 390 | apic_clear_vector(vector, apic->regs + APIC_TMR); | ||
| 391 | kvm_vcpu_kick(vcpu); | 392 | kvm_vcpu_kick(vcpu); |
| 392 | break; | 393 | break; |
| 393 | 394 | ||
| @@ -1150,6 +1151,7 @@ void kvm_apic_post_state_restore(struct kvm_vcpu *vcpu) | |||
| 1150 | hrtimer_cancel(&apic->lapic_timer.timer); | 1151 | hrtimer_cancel(&apic->lapic_timer.timer); |
| 1151 | update_divide_count(apic); | 1152 | update_divide_count(apic); |
| 1152 | start_apic_timer(apic); | 1153 | start_apic_timer(apic); |
| 1154 | apic->irr_pending = true; | ||
| 1153 | } | 1155 | } |
| 1154 | 1156 | ||
| 1155 | void __kvm_migrate_apic_timer(struct kvm_vcpu *vcpu) | 1157 | void __kvm_migrate_apic_timer(struct kvm_vcpu *vcpu) |
