1 /* SPDX-License-Identifier: GPL-2.0 */ 1 2 #if !defined(_TRACE_KVM_H) || defined(TRACE_HE 3 #define _TRACE_KVM_H 4 5 #include <linux/tracepoint.h> 6 7 #undef TRACE_SYSTEM 8 #define TRACE_SYSTEM kvm 9 10 /* 11 * Tracepoint for guest mode entry. 12 */ 13 TRACE_EVENT(kvm_ppc_instr, 14 TP_PROTO(unsigned int inst, unsigned l 15 TP_ARGS(inst, _pc, emulate), 16 17 TP_STRUCT__entry( 18 __field( unsigned int, 19 __field( unsigned long, 20 __field( unsigned int, 21 ), 22 23 TP_fast_assign( 24 __entry->inst = inst 25 __entry->pc = _pc; 26 __entry->emulate = emul 27 ), 28 29 TP_printk("inst %u pc 0x%lx emulate %u 30 __entry->inst, __entry->pc, 31 ); 32 33 TRACE_EVENT(kvm_stlb_inval, 34 TP_PROTO(unsigned int stlb_index), 35 TP_ARGS(stlb_index), 36 37 TP_STRUCT__entry( 38 __field( unsigned int, 39 ), 40 41 TP_fast_assign( 42 __entry->stlb_index = stlb 43 ), 44 45 TP_printk("stlb_index %u", __entry->st 46 ); 47 48 TRACE_EVENT(kvm_stlb_write, 49 TP_PROTO(unsigned int victim, unsigned 50 unsigned int word1, unsigned 51 TP_ARGS(victim, tid, word0, word1, wor 52 53 TP_STRUCT__entry( 54 __field( unsigned int, 55 __field( unsigned int, 56 __field( unsigned int, 57 __field( unsigned int, 58 __field( unsigned int, 59 ), 60 61 TP_fast_assign( 62 __entry->victim = vict 63 __entry->tid = tid; 64 __entry->word0 = word 65 __entry->word1 = word 66 __entry->word2 = word 67 ), 68 69 TP_printk("victim %u tid %u w0 %u w1 % 70 __entry->victim, __entry->tid, 71 __entry->word1, __entry->word2 72 ); 73 74 TRACE_EVENT(kvm_gtlb_write, 75 TP_PROTO(unsigned int gtlb_index, unsi 76 unsigned int word1, unsigned 77 TP_ARGS(gtlb_index, tid, word0, word1, 78 79 TP_STRUCT__entry( 80 __field( unsigned int, 81 __field( unsigned int, 82 __field( unsigned int, 83 __field( unsigned int, 84 __field( unsigned int, 85 ), 86 87 TP_fast_assign( 88 __entry->gtlb_index = gtlb 89 __entry->tid = tid; 90 __entry->word0 = word 91 __entry->word1 = word 92 __entry->word2 = word 93 ), 94 95 TP_printk("gtlb_index %u tid %u w0 %u 96 __entry->gtlb_index, __entry-> 97 __entry->word1, __entry->word2 98 ); 99 100 TRACE_EVENT(kvm_check_requests, 101 TP_PROTO(struct kvm_vcpu *vcpu), 102 TP_ARGS(vcpu), 103 104 TP_STRUCT__entry( 105 __field( __u32, cpu_nr 106 __field( __u32, reques 107 ), 108 109 TP_fast_assign( 110 __entry->cpu_nr = vcpu 111 __entry->requests = vcpu 112 ), 113 114 TP_printk("vcpu=%x requests=%x", 115 __entry->cpu_nr, __entry->requ 116 ); 117 118 #endif /* _TRACE_KVM_H */ 119 120 /* This part must be outside protection */ 121 #undef TRACE_INCLUDE_PATH 122 #undef TRACE_INCLUDE_FILE 123 124 #define TRACE_INCLUDE_PATH . 125 #define TRACE_INCLUDE_FILE trace 126 127 #include <trace/define_trace.h> 128
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.