ARM: KVM: abstract exception class decoding away

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
This commit is contained in:
Marc Zyngier
2012-09-18 14:09:58 +01:00
committed by Christoffer Dall
parent 23b415d61a
commit 4926d445eb
3 changed files with 8 additions and 3 deletions

View File

@@ -142,4 +142,9 @@ static inline bool kvm_vcpu_trap_il_is32bit(struct kvm_vcpu *vcpu)
return kvm_vcpu_get_hsr(vcpu) & HSR_IL;
}
static inline u8 kvm_vcpu_trap_get_class(struct kvm_vcpu *vcpu)
{
return kvm_vcpu_get_hsr(vcpu) >> HSR_EC_SHIFT;
}
#endif /* __ARM_KVM_EMULATE_H__ */