[PATCH trace-cmd 3/3] kvm: display the new kvm_exit info1 and info2 fields, if available

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Avi Kivity <avi@xxxxxxxxxx>
---
 plugin_kvm.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/plugin_kvm.c b/plugin_kvm.c
index 659b27f..c1cb2e4 100644
--- a/plugin_kvm.c
+++ b/plugin_kvm.c
@@ -244,6 +244,7 @@ static int kvm_exit_handler(struct trace_seq *s, struct record *record,
 {
 	unsigned long long isa;
 	unsigned long long val;
+	unsigned long long info1 = 0, info2 = 0;
 
 	if (pevent_get_field_val(s, event, "exit_reason", record, &val, 1) < 0)
 		return -1;
@@ -255,6 +256,10 @@ static int kvm_exit_handler(struct trace_seq *s, struct record *record,
 
 	pevent_print_num_field(s, " rip 0x%lx", event, "guest_rip", record, 1);
 
+	if (pevent_get_field_val(s, event, "info1", record, &info1, 1) >= 0
+	    && pevent_get_field_val(s, event, "info2", record, &info2, 1) >= 0)
+		trace_seq_printf(s, " info %llx %llx\n", info1, info2);
+
 	return 0;
 }
 
-- 
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-trace-users" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Development]     [Linux USB Development]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux