diff options
author | Borislav Petkov <bp@suse.de> | 2015-11-20 13:52:12 -0500 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2015-12-16 12:49:48 -0500 |
commit | 671d9ab38097fae45ff4f24562789b98b51d37ec (patch) | |
tree | b6ab3a4d95066376ef5354f8b2fe6903c0e106f6 | |
parent | 8a86aea920f1bb1cf7050e48112227a1c42cafe5 (diff) |
kvm: Dump guest rIP when the guest tried something unsupported
It looks like this in action:
kvm [5197]: vcpu0, guest rIP: 0xffffffff810187ba unhandled rdmsr: 0xc001102
and helps to pinpoint quickly where in the guest we did the unsupported
thing.
Signed-off-by: Borislav Petkov <bp@suse.de>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r-- | include/linux/kvm_host.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index 2969c474a399..61c3e6c69f27 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h | |||
@@ -447,7 +447,8 @@ struct kvm { | |||
447 | 447 | ||
448 | /* The guest did something we don't support. */ | 448 | /* The guest did something we don't support. */ |
449 | #define vcpu_unimpl(vcpu, fmt, ...) \ | 449 | #define vcpu_unimpl(vcpu, fmt, ...) \ |
450 | kvm_pr_unimpl("vcpu%i " fmt, (vcpu)->vcpu_id, ## __VA_ARGS__) | 450 | kvm_pr_unimpl("vcpu%i, guest rIP: 0x%lx " fmt, \ |
451 | (vcpu)->vcpu_id, kvm_rip_read(vcpu), ## __VA_ARGS__) | ||
451 | 452 | ||
452 | #define vcpu_debug(vcpu, fmt, ...) \ | 453 | #define vcpu_debug(vcpu, fmt, ...) \ |
453 | kvm_debug("vcpu%i " fmt, (vcpu)->vcpu_id, ## __VA_ARGS__) | 454 | kvm_debug("vcpu%i " fmt, (vcpu)->vcpu_id, ## __VA_ARGS__) |