Skip to content

Commit

Permalink
KVM: PPC: BookE: Allow irq deliveries to inject requests
Browse files Browse the repository at this point in the history
When injecting an interrupt into guest context, we usually don't need
to check for requests anymore. At least not until today.

With the introduction of EPR, we will have to create a request when the
guest has successfully accepted an external interrupt though.

So we need to prepare the interrupt delivery to abort guest entry
gracefully. Otherwise we'd delay the EPR request.

Signed-off-by: Alexander Graf <agraf@suse.de>
  • Loading branch information
Alexander Graf committed Jan 10, 2013
1 parent f2be655 commit b8c649a
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions arch/powerpc/kvm/booke.c
Original file line number Diff line number Diff line change
Expand Up @@ -581,6 +581,11 @@ int kvmppc_core_prepare_to_enter(struct kvm_vcpu *vcpu)

kvmppc_core_check_exceptions(vcpu);

if (vcpu->requests) {
/* Exception delivery raised request; start over */
return 1;
}

if (vcpu->arch.shared->msr & MSR_WE) {
local_irq_enable();
kvm_vcpu_block(vcpu);
Expand Down

0 comments on commit b8c649a

Please sign in to comment.