3 * Intel Management Engine Interface (Intel MEI) Linux driver
4 * Copyright (c) 2015, Intel Corporation.
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms and conditions of the GNU General Public License,
8 * version 2, as published by the Free Software Foundation.
10 * This program is distributed in the hope it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
17 #if !defined(_MEI_TRACE_H_) || defined(TRACE_HEADER_MULTI_READ)
20 #include <linux/stringify.h>
21 #include <linux/types.h>
22 #include <linux/tracepoint.h>
24 #include <linux/device.h>
28 #define TRACE_SYSTEM mei
29 #define TRACE_SYSTEM_STRING __stringify(TRACE_SYSTEM)
31 TRACE_EVENT(mei_reg_read,
32 TP_PROTO(const struct device *dev, const char *reg, u32 offs, u32 val),
33 TP_ARGS(dev, reg, offs, val),
35 __string(dev, dev_name(dev))
36 __field(const char *, reg)
41 __assign_str(dev, dev_name(dev))
46 TP_printk("[%s] read %s:[%#x] = %#x",
47 __get_str(dev), __entry->reg, __entry->offs, __entry->val)
50 TRACE_EVENT(mei_reg_write,
51 TP_PROTO(const struct device *dev, const char *reg, u32 offs, u32 val),
52 TP_ARGS(dev, reg, offs, val),
54 __string(dev, dev_name(dev))
55 __field(const char *, reg)
60 __assign_str(dev, dev_name(dev))
65 TP_printk("[%s] write %s[%#x] = %#x)",
66 __get_str(dev), __entry->reg, __entry->offs, __entry->val)
69 #endif /* _MEI_TRACE_H_ */
71 /* This part must be outside protection */
72 #undef TRACE_INCLUDE_PATH
73 #undef TRACE_INCLUDE_FILE
74 #define TRACE_INCLUDE_PATH .
75 #define TRACE_INCLUDE_FILE mei-trace
76 #include <trace/define_trace.h>