xref: /linux/sound/pci/hda/hda_intel_trace.h (revision d53b8e36925256097a08d7cb749198d85cbf9b2b)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #undef TRACE_SYSTEM
3 #define TRACE_SYSTEM hda_intel
4 #define TRACE_INCLUDE_FILE hda_intel_trace
5 
6 #if !defined(_TRACE_HDA_INTEL_H) || defined(TRACE_HEADER_MULTI_READ)
7 #define _TRACE_HDA_INTEL_H
8 
9 #include <linux/tracepoint.h>
10 
11 DECLARE_EVENT_CLASS(hda_pm,
12 	TP_PROTO(struct azx *chip),
13 
14 	TP_ARGS(chip),
15 
16 	TP_STRUCT__entry(
17 		__field(int, dev_index)
18 	),
19 
20 	TP_fast_assign(
21 		__entry->dev_index = (chip)->dev_index;
22 	),
23 
24 	TP_printk("card index: %d", __entry->dev_index)
25 );
26 
27 DEFINE_EVENT(hda_pm, azx_suspend,
28 	TP_PROTO(struct azx *chip),
29 	TP_ARGS(chip)
30 );
31 
32 DEFINE_EVENT(hda_pm, azx_resume,
33 	TP_PROTO(struct azx *chip),
34 	TP_ARGS(chip)
35 );
36 
37 DEFINE_EVENT(hda_pm, azx_runtime_suspend,
38 	TP_PROTO(struct azx *chip),
39 	TP_ARGS(chip)
40 );
41 
42 DEFINE_EVENT(hda_pm, azx_runtime_resume,
43 	TP_PROTO(struct azx *chip),
44 	TP_ARGS(chip)
45 );
46 
47 #endif /* _TRACE_HDA_INTEL_H */
48 
49 /* This part must be outside protection */
50 #undef TRACE_INCLUDE_PATH
51 #define TRACE_INCLUDE_PATH .
52 #include <trace/define_trace.h>
53