instrumentation: printk: remove compatibility code
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 13 Apr 2020 20:23:32 +0000 (16:23 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 13 Apr 2020 20:23:32 +0000 (16:23 -0400)
instrumentation/events/lttng-module/printk.h

index 444f299b78929e132913a91aa480cd13084827f2..26b04a95025b4a1c32a871eb2e88170780424423 100644 (file)
@@ -6,9 +6,6 @@
 #define LTTNG_TRACE_PRINTK_H
 
 #include <probes/lttng-tracepoint-event.h>
-#include <linux/version.h>
-
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,10,0))
 
 LTTNG_TRACEPOINT_EVENT_MAP(console,
 
@@ -23,53 +20,6 @@ LTTNG_TRACEPOINT_EVENT_MAP(console,
        )
 )
 
-#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(3,5,0))
-
-LTTNG_TRACEPOINT_EVENT_MAP(console,
-
-       printk_console,
-
-       TP_PROTO(const char *log_buf, unsigned start, unsigned end,
-                unsigned log_buf_len),
-
-       TP_ARGS(log_buf, start, end, log_buf_len),
-
-       TP_FIELDS(
-               ctf_sequence_text(char, msg, log_buf + start,
-                       size_t, end - start)
-       )
-)
-
-#else /* (LINUX_VERSION_CODE < KERNEL_VERSION(3,5,0)) */
-
-LTTNG_TRACEPOINT_EVENT_MAP(console,
-
-       printk_console,
-
-       TP_PROTO(const char *log_buf, unsigned start, unsigned end,
-                unsigned log_buf_len),
-
-       TP_ARGS(log_buf, start, end, log_buf_len),
-
-       TP_FIELDS(
-               /*
-                * printk buffer is gathered from two segments on older kernels.
-                */
-               ctf_sequence_text(char, msg1,
-                       log_buf + (start & (log_buf_len - 1)),
-                       size_t, (start & (log_buf_len - 1)) > (end & (log_buf_len - 1))
-                               ? log_buf_len - (start & (log_buf_len - 1))
-                               : end - start)
-               ctf_sequence_text(char, msg2,
-                       log_buf,
-                       size_t, (start & (log_buf_len - 1)) > (end & (log_buf_len - 1))
-                               ? end & (log_buf_len - 1)
-                               : 0)
-       )
-)
-
-#endif
-
 #endif /* LTTNG_TRACE_PRINTK_H */
 
 /* This part must be outside protection */
This page took 0.026597 seconds and 4 git commands to generate.