KVM: s390: Use intercept_insn decoder in trace event
authorAlexander Yarygin <yarygin@linux.vnet.ibm.com>
Thu, 30 Jan 2014 18:13:40 +0000 (22:13 +0400)
committerChristian Borntraeger <borntraeger@de.ibm.com>
Fri, 16 May 2014 12:57:27 +0000 (14:57 +0200)
The current trace definition doesn't work very well with the perf tool.
Perf shows a "insn_to_mnemonic not found" message. Let's handle the
decoding completely in a parseable format.

Signed-off-by: Alexander Yarygin <yarygin@linux.vnet.ibm.com>
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
arch/s390/kvm/trace.h

index 00f57a507ea2502e79e5a25450a63f32f4bf4125..579b42afab4083c1e6ee352e7230a3773c551f6f 100644 (file)
@@ -154,7 +154,6 @@ TRACE_EVENT(kvm_s390_intercept_instruction,
            TP_STRUCT__entry(
                    VCPU_FIELD_COMMON
                    __field(__u64, instruction)
-                   __field(char, insn[8])
                    ),
 
            TP_fast_assign(
@@ -165,10 +164,8 @@ TRACE_EVENT(kvm_s390_intercept_instruction,
 
            VCPU_TP_PRINTK("intercepted instruction %016llx (%s)",
                           __entry->instruction,
-                          insn_to_mnemonic((unsigned char *)
-                                           &__entry->instruction,
-                                        __entry->insn, sizeof(__entry->insn)) ?
-                          "unknown" : __entry->insn)
+                          __print_symbolic(icpt_insn_decoder(__entry->instruction),
+                                           icpt_insn_codes))
        );
 
 /*