xref: /linux/drivers/net/wireless/intel/iwlwifi/iwl-devtrace-ucode.h (revision fd7d598270724cc787982ea48bbe17ad383a8b7f)
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /******************************************************************************
3  *
4  * Copyright(c) 2009 - 2014 Intel Corporation. All rights reserved.
5  *****************************************************************************/
6 
7 #if !defined(__IWLWIFI_DEVICE_TRACE_UCODE) || defined(TRACE_HEADER_MULTI_READ)
8 #define __IWLWIFI_DEVICE_TRACE_UCODE
9 
10 #include <linux/tracepoint.h>
11 
12 #undef TRACE_SYSTEM
13 #define TRACE_SYSTEM iwlwifi_ucode
14 
15 TRACE_EVENT(iwlwifi_dev_ucode_cont_event,
16 	TP_PROTO(const struct device *dev, u32 time, u32 data, u32 ev),
17 	TP_ARGS(dev, time, data, ev),
18 	TP_STRUCT__entry(
19 		DEV_ENTRY
20 
21 		__field(u32, time)
22 		__field(u32, data)
23 		__field(u32, ev)
24 	),
25 	TP_fast_assign(
26 		DEV_ASSIGN;
27 		__entry->time = time;
28 		__entry->data = data;
29 		__entry->ev = ev;
30 	),
31 	TP_printk("[%s] EVT_LOGT:%010u:0x%08x:%04u",
32 		  __get_str(dev), __entry->time, __entry->data, __entry->ev)
33 );
34 
35 TRACE_EVENT(iwlwifi_dev_ucode_wrap_event,
36 	TP_PROTO(const struct device *dev, u32 wraps, u32 n_entry, u32 p_entry),
37 	TP_ARGS(dev, wraps, n_entry, p_entry),
38 	TP_STRUCT__entry(
39 		DEV_ENTRY
40 
41 		__field(u32, wraps)
42 		__field(u32, n_entry)
43 		__field(u32, p_entry)
44 	),
45 	TP_fast_assign(
46 		DEV_ASSIGN;
47 		__entry->wraps = wraps;
48 		__entry->n_entry = n_entry;
49 		__entry->p_entry = p_entry;
50 	),
51 	TP_printk("[%s] wraps=#%02d n=0x%X p=0x%X",
52 		  __get_str(dev), __entry->wraps, __entry->n_entry,
53 		  __entry->p_entry)
54 );
55 #endif /* __IWLWIFI_DEVICE_TRACE_UCODE */
56 
57 #undef TRACE_INCLUDE_PATH
58 #define TRACE_INCLUDE_PATH .
59 #undef TRACE_INCLUDE_FILE
60 #define TRACE_INCLUDE_FILE iwl-devtrace-ucode
61 #include <trace/define_trace.h>
62