blob: 950145cb69bbdc56c01ab485e19edf0e428735e6 [file] [log] [blame]
Alan Kwong1a00e4d2016-07-18 09:42:30 -04001/* Copyright (c) 2014-2016, The Linux Foundation. All rights reserved.
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 */
12
13#if !defined(_SDE_TRACE_H_) || defined(TRACE_HEADER_MULTI_READ)
14#define _SDE_TRACE_H_
15
16#include <linux/stringify.h>
17#include <linux/types.h>
18#include <linux/tracepoint.h>
19
20#undef TRACE_SYSTEM
21#define TRACE_SYSTEM sde
22#undef TRACE_INCLUDE_FILE
23#define TRACE_INCLUDE_FILE sde_trace
24
25TRACE_EVENT(sde_perf_set_qos_luts,
26 TP_PROTO(u32 pnum, u32 fmt, bool rt, u32 fl,
27 u32 lut, bool linear),
28 TP_ARGS(pnum, fmt, rt, fl, lut, linear),
29 TP_STRUCT__entry(
30 __field(u32, pnum)
31 __field(u32, fmt)
32 __field(bool, rt)
33 __field(u32, fl)
34 __field(u32, lut)
35 __field(bool, linear)
36 ),
37 TP_fast_assign(
38 __entry->pnum = pnum;
39 __entry->fmt = fmt;
40 __entry->rt = rt;
41 __entry->fl = fl;
42 __entry->lut = lut;
43 __entry->linear = linear;
44 ),
45 TP_printk("pnum=%d fmt=%x rt=%d fl=%d lut=0x%x lin=%d",
46 __entry->pnum, __entry->fmt,
47 __entry->rt, __entry->fl,
48 __entry->lut, __entry->linear)
49);
50
51TRACE_EVENT(sde_perf_set_danger_luts,
52 TP_PROTO(u32 pnum, u32 fmt, u32 mode, u32 danger_lut,
53 u32 safe_lut),
54 TP_ARGS(pnum, fmt, mode, danger_lut, safe_lut),
55 TP_STRUCT__entry(
56 __field(u32, pnum)
57 __field(u32, fmt)
58 __field(u32, mode)
59 __field(u32, danger_lut)
60 __field(u32, safe_lut)
61 ),
62 TP_fast_assign(
63 __entry->pnum = pnum;
64 __entry->fmt = fmt;
65 __entry->mode = mode;
66 __entry->danger_lut = danger_lut;
67 __entry->safe_lut = safe_lut;
68 ),
69 TP_printk("pnum=%d fmt=%x mode=%d luts[0x%x, 0x%x]",
70 __entry->pnum, __entry->fmt,
71 __entry->mode, __entry->danger_lut,
72 __entry->safe_lut)
73);
74
Alan Kwong5d324e42016-07-28 22:56:18 -040075TRACE_EVENT(sde_perf_set_ot,
76 TP_PROTO(u32 pnum, u32 xin_id, u32 rd_lim, u32 vbif_idx),
77 TP_ARGS(pnum, xin_id, rd_lim, vbif_idx),
78 TP_STRUCT__entry(
79 __field(u32, pnum)
80 __field(u32, xin_id)
81 __field(u32, rd_lim)
82 __field(u32, vbif_idx)
83 ),
84 TP_fast_assign(
85 __entry->pnum = pnum;
86 __entry->xin_id = xin_id;
87 __entry->rd_lim = rd_lim;
88 __entry->vbif_idx = vbif_idx;
89 ),
90 TP_printk("pnum:%d xin_id:%d ot:%d vbif:%d",
91 __entry->pnum, __entry->xin_id, __entry->rd_lim,
92 __entry->vbif_idx)
93)
94
Alan Kwong1a00e4d2016-07-18 09:42:30 -040095#endif /* _SDE_TRACE_H_ */
96
97/* This part must be outside protection */
98#undef TRACE_INCLUDE_PATH
99#define TRACE_INCLUDE_PATH .
100#include <trace/define_trace.h>