From: Mathieu Desnoyers Date: Mon, 27 Apr 2015 21:32:54 +0000 (-0400) Subject: Fix: x86 mmutrace event extra field for kernels >= 3.11 X-Git-Tag: v2.7.0-rc1~27 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=d3a7bdc5106ec364c84cc8ea13bcc0585b7c58f4;p=lttng-modules.git Fix: x86 mmutrace event extra field for kernels >= 3.11 Signed-off-by: Mathieu Desnoyers --- diff --git a/instrumentation/events/lttng-module/arch/x86/kvm/mmutrace.h b/instrumentation/events/lttng-module/arch/x86/kvm/mmutrace.h index a71b2a1a..e0234ff5 100644 --- a/instrumentation/events/lttng-module/arch/x86/kvm/mmutrace.h +++ b/instrumentation/events/lttng-module/arch/x86/kvm/mmutrace.h @@ -3,6 +3,7 @@ #include "../../../../../../probes/lttng-tracepoint-event.h" #include +#include #undef TRACE_SYSTEM #define TRACE_SYSTEM kvm_mmu @@ -117,6 +118,26 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(kvm_mmu_page_class, kvm_mmu_prepare_zap_page, TP_ARGS(sp) ) +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,11,0)) + +LTTNG_TRACEPOINT_EVENT_MAP( + mark_mmio_spte, + + kvm_mmu_mark_mmio_spte, + + TP_PROTO(u64 *sptep, gfn_t gfn, unsigned access, unsigned int gen), + TP_ARGS(sptep, gfn, access, gen), + + TP_FIELDS( + ctf_integer(void *, sptep, sptep) + ctf_integer(gfn_t, gfn, gfn) + ctf_integer(unsigned, access, access) + ctf_integer(unsigned int, gen, gen) + ) +) + +#else /* #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,11,0)) */ + LTTNG_TRACEPOINT_EVENT_MAP( mark_mmio_spte, @@ -132,6 +153,8 @@ LTTNG_TRACEPOINT_EVENT_MAP( ) ) +#endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,11,0)) */ + LTTNG_TRACEPOINT_EVENT_MAP( handle_mmio_page_fault,