Commit c3f37199 authored by David Woodhouse's avatar David Woodhouse Committed by Paolo Bonzini

KVM: x86/xen: Add CPL to Xen hypercall tracepoint

Signed-off-by: default avatarDavid Woodhouse <dwmw@amazon.co.uk>
Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
parent 3ca9d84e
...@@ -113,12 +113,13 @@ TRACE_EVENT(kvm_hv_hypercall_done, ...@@ -113,12 +113,13 @@ TRACE_EVENT(kvm_hv_hypercall_done,
* Tracepoint for Xen hypercall. * Tracepoint for Xen hypercall.
*/ */
TRACE_EVENT(kvm_xen_hypercall, TRACE_EVENT(kvm_xen_hypercall,
TP_PROTO(unsigned long nr, unsigned long a0, unsigned long a1, TP_PROTO(u8 cpl, unsigned long nr,
unsigned long a2, unsigned long a3, unsigned long a4, unsigned long a0, unsigned long a1, unsigned long a2,
unsigned long a5), unsigned long a3, unsigned long a4, unsigned long a5),
TP_ARGS(nr, a0, a1, a2, a3, a4, a5), TP_ARGS(cpl, nr, a0, a1, a2, a3, a4, a5),
TP_STRUCT__entry( TP_STRUCT__entry(
__field(u8, cpl)
__field(unsigned long, nr) __field(unsigned long, nr)
__field(unsigned long, a0) __field(unsigned long, a0)
__field(unsigned long, a1) __field(unsigned long, a1)
...@@ -129,6 +130,7 @@ TRACE_EVENT(kvm_xen_hypercall, ...@@ -129,6 +130,7 @@ TRACE_EVENT(kvm_xen_hypercall,
), ),
TP_fast_assign( TP_fast_assign(
__entry->cpl = cpl;
__entry->nr = nr; __entry->nr = nr;
__entry->a0 = a0; __entry->a0 = a0;
__entry->a1 = a1; __entry->a1 = a1;
...@@ -138,8 +140,9 @@ TRACE_EVENT(kvm_xen_hypercall, ...@@ -138,8 +140,9 @@ TRACE_EVENT(kvm_xen_hypercall,
__entry->a4 = a5; __entry->a4 = a5;
), ),
TP_printk("nr 0x%lx a0 0x%lx a1 0x%lx a2 0x%lx a3 0x%lx a4 0x%lx a5 %lx", TP_printk("cpl %d nr 0x%lx a0 0x%lx a1 0x%lx a2 0x%lx a3 0x%lx a4 0x%lx a5 %lx",
__entry->nr, __entry->a0, __entry->a1, __entry->a2, __entry->cpl, __entry->nr,
__entry->a0, __entry->a1, __entry->a2,
__entry->a3, __entry->a4, __entry->a5) __entry->a3, __entry->a4, __entry->a5)
); );
......
...@@ -1256,7 +1256,7 @@ int kvm_xen_hypercall(struct kvm_vcpu *vcpu) ...@@ -1256,7 +1256,7 @@ int kvm_xen_hypercall(struct kvm_vcpu *vcpu)
} }
#endif #endif
cpl = static_call(kvm_x86_get_cpl)(vcpu); cpl = static_call(kvm_x86_get_cpl)(vcpu);
trace_kvm_xen_hypercall(input, params[0], params[1], params[2], trace_kvm_xen_hypercall(cpl, input, params[0], params[1], params[2],
params[3], params[4], params[5]); params[3], params[4], params[5]);
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment