diff options
Diffstat (limited to 'arch/ia64/kvm/kvm_fw.c')
-rw-r--r-- | arch/ia64/kvm/kvm_fw.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/arch/ia64/kvm/kvm_fw.c b/arch/ia64/kvm/kvm_fw.c index 0c69d9ec92d4..cb7600bdff9d 100644 --- a/arch/ia64/kvm/kvm_fw.c +++ b/arch/ia64/kvm/kvm_fw.c | |||
@@ -286,6 +286,12 @@ static u64 kvm_get_pal_call_index(struct kvm_vcpu *vcpu) | |||
286 | return index; | 286 | return index; |
287 | } | 287 | } |
288 | 288 | ||
289 | static void prepare_for_halt(struct kvm_vcpu *vcpu) | ||
290 | { | ||
291 | vcpu->arch.timer_pending = 1; | ||
292 | vcpu->arch.timer_fired = 0; | ||
293 | } | ||
294 | |||
289 | int kvm_pal_emul(struct kvm_vcpu *vcpu, struct kvm_run *run) | 295 | int kvm_pal_emul(struct kvm_vcpu *vcpu, struct kvm_run *run) |
290 | { | 296 | { |
291 | 297 | ||
@@ -304,11 +310,10 @@ int kvm_pal_emul(struct kvm_vcpu *vcpu, struct kvm_run *run) | |||
304 | break; | 310 | break; |
305 | case PAL_HALT_LIGHT: | 311 | case PAL_HALT_LIGHT: |
306 | { | 312 | { |
307 | vcpu->arch.timer_pending = 1; | ||
308 | INIT_PAL_STATUS_SUCCESS(result); | 313 | INIT_PAL_STATUS_SUCCESS(result); |
314 | prepare_for_halt(vcpu); | ||
309 | if (kvm_highest_pending_irq(vcpu) == -1) | 315 | if (kvm_highest_pending_irq(vcpu) == -1) |
310 | ret = kvm_emulate_halt(vcpu); | 316 | ret = kvm_emulate_halt(vcpu); |
311 | |||
312 | } | 317 | } |
313 | break; | 318 | break; |
314 | 319 | ||