1 /******************************************************************************
3 * Copyright(c) 2009 - 2014 Intel Corporation. All rights reserved.
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of version 2 of the GNU General Public License as
7 * published by the Free Software Foundation.
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 * You should have received a copy of the GNU General Public License along with
15 * this program; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
18 * The full GNU General Public License is included in this distribution in the
19 * file called LICENSE.
21 * Contact Information:
22 * Intel Linux Wireless <linuxwifi@intel.com>
23 * Intel Corporation, 5200 N.E. Elam Young Parkway, Hillsboro, OR 97124-6497
25 *****************************************************************************/
27 #if !defined(__IWLWIFI_DEVICE_TRACE_IO) || defined(TRACE_HEADER_MULTI_READ)
28 #define __IWLWIFI_DEVICE_TRACE_IO
30 #include <linux/tracepoint.h>
33 #define TRACE_SYSTEM iwlwifi_io
35 TRACE_EVENT(iwlwifi_dev_ioread32
,
36 TP_PROTO(const struct device
*dev
, u32 offs
, u32 val
),
37 TP_ARGS(dev
, offs
, val
),
48 TP_printk("[%s] read io[%#x] = %#x",
49 __get_str(dev
), __entry
->offs
, __entry
->val
)
52 TRACE_EVENT(iwlwifi_dev_iowrite8
,
53 TP_PROTO(const struct device
*dev
, u32 offs
, u8 val
),
54 TP_ARGS(dev
, offs
, val
),
65 TP_printk("[%s] write io[%#x] = %#x)",
66 __get_str(dev
), __entry
->offs
, __entry
->val
)
69 TRACE_EVENT(iwlwifi_dev_iowrite32
,
70 TP_PROTO(const struct device
*dev
, u32 offs
, u32 val
),
71 TP_ARGS(dev
, offs
, val
),
82 TP_printk("[%s] write io[%#x] = %#x)",
83 __get_str(dev
), __entry
->offs
, __entry
->val
)
86 TRACE_EVENT(iwlwifi_dev_iowrite_prph32
,
87 TP_PROTO(const struct device
*dev
, u32 offs
, u32 val
),
88 TP_ARGS(dev
, offs
, val
),
99 TP_printk("[%s] write PRPH[%#x] = %#x)",
100 __get_str(dev
), __entry
->offs
, __entry
->val
)
103 TRACE_EVENT(iwlwifi_dev_ioread_prph32
,
104 TP_PROTO(const struct device
*dev
, u32 offs
, u32 val
),
105 TP_ARGS(dev
, offs
, val
),
113 __entry
->offs
= offs
;
116 TP_printk("[%s] read PRPH[%#x] = %#x",
117 __get_str(dev
), __entry
->offs
, __entry
->val
)
120 TRACE_EVENT(iwlwifi_dev_irq
,
121 TP_PROTO(const struct device
*dev
),
129 /* TP_printk("") doesn't compile */
133 TRACE_EVENT(iwlwifi_dev_ict_read
,
134 TP_PROTO(const struct device
*dev
, u32 index
, u32 value
),
135 TP_ARGS(dev
, index
, value
),
143 __entry
->index
= index
;
144 __entry
->value
= value
;
146 TP_printk("[%s] read ict[%d] = %#.8x",
147 __get_str(dev
), __entry
->index
, __entry
->value
)
149 #endif /* __IWLWIFI_DEVICE_TRACE_IO */
151 #undef TRACE_INCLUDE_PATH
152 #define TRACE_INCLUDE_PATH .
153 #undef TRACE_INCLUDE_FILE
154 #define TRACE_INCLUDE_FILE iwl-devtrace-io
155 #include <trace/define_trace.h>