| /* SPDX-License-Identifier: GPL-2.0 */ |
| #define TRACE_SYSTEM printk |
| #if !defined(_TRACE_PRINTK_H) || defined(TRACE_HEADER_MULTI_READ) |
| #include <linux/tracepoint.h> |
| TP_PROTO(const char *text, size_t len), |
| __dynamic_array(char, msg, len + 1) |
| * Each trace entry is printed in a new line. |
| * If the msg finishes with '\n', cut it off |
| * to avoid blank lines in the trace. |
| if ((len > 0) && (text[len-1] == '\n')) |
| memcpy(__get_str(msg), text, len); |
| TP_printk("%s", __get_str(msg)) |
| #endif /* _TRACE_PRINTK_H */ |
| /* This part must be outside protection */ |
| #include <trace/define_trace.h> |