1 /* SPDX-License-Identifier: ISC */
3 * Copyright (C) 2019 Lorenzo Bianconi <lorenzo@kernel.org>
6 #if !defined(__MT7615_TRACE_H) || defined(TRACE_HEADER_MULTI_READ)
7 #define __MT7615_TRACE_H
9 #include <linux/tracepoint.h>
13 #define TRACE_SYSTEM mt7615
16 #define DEV_ENTRY __array(char, wiphy_name, 32)
17 #define DEV_ASSIGN strlcpy(__entry->wiphy_name, \
18 wiphy_name(mt76_hw(dev)->wiphy), MAXNAME)
19 #define DEV_PR_FMT "%s"
20 #define DEV_PR_ARG __entry->wiphy_name
22 #define TOKEN_ENTRY __field(u16, token)
23 #define TOKEN_ASSIGN __entry->token = token
24 #define TOKEN_PR_FMT " %d"
25 #define TOKEN_PR_ARG __entry->token
27 DECLARE_EVENT_CLASS(dev_token
,
28 TP_PROTO(struct mt7615_dev
*dev
, u16 token
),
39 DEV_PR_FMT TOKEN_PR_FMT
,
40 DEV_PR_ARG
, TOKEN_PR_ARG
44 DEFINE_EVENT(dev_token
, mac_tx_free
,
45 TP_PROTO(struct mt7615_dev
*dev
, u16 token
),
51 #undef TRACE_INCLUDE_PATH
52 #define TRACE_INCLUDE_PATH .
53 #undef TRACE_INCLUDE_FILE
54 #define TRACE_INCLUDE_FILE mt7615_trace
56 #include <trace/define_trace.h>