diff options
-rw-r--r-- | drivers/media/platform/coda/coda-bit.c | 2 | ||||
-rw-r--r-- | drivers/media/platform/coda/trace.h | 89 |
2 files changed, 26 insertions, 65 deletions
diff --git a/drivers/media/platform/coda/coda-bit.c b/drivers/media/platform/coda/coda-bit.c index ac4dcb1f446a..226ce4a786ea 100644 --- a/drivers/media/platform/coda/coda-bit.c +++ b/drivers/media/platform/coda/coda-bit.c | |||
@@ -1978,7 +1978,7 @@ static void coda_finish_decode(struct coda_ctx *ctx) | |||
1978 | dst_buf->v4l2_buf.timecode = meta->timecode; | 1978 | dst_buf->v4l2_buf.timecode = meta->timecode; |
1979 | dst_buf->v4l2_buf.timestamp = meta->timestamp; | 1979 | dst_buf->v4l2_buf.timestamp = meta->timestamp; |
1980 | 1980 | ||
1981 | trace_coda_dec_rot_done(ctx, meta, dst_buf); | 1981 | trace_coda_dec_rot_done(ctx, dst_buf, meta); |
1982 | 1982 | ||
1983 | switch (q_data_dst->fourcc) { | 1983 | switch (q_data_dst->fourcc) { |
1984 | case V4L2_PIX_FMT_YUV420: | 1984 | case V4L2_PIX_FMT_YUV420: |
diff --git a/drivers/media/platform/coda/trace.h b/drivers/media/platform/coda/trace.h index 781bf7286d53..d9099a0f7c32 100644 --- a/drivers/media/platform/coda/trace.h +++ b/drivers/media/platform/coda/trace.h | |||
@@ -48,7 +48,7 @@ TRACE_EVENT(coda_bit_done, | |||
48 | TP_printk("minor = %d, ctx = %d", __entry->minor, __entry->ctx) | 48 | TP_printk("minor = %d, ctx = %d", __entry->minor, __entry->ctx) |
49 | ); | 49 | ); |
50 | 50 | ||
51 | TRACE_EVENT(coda_enc_pic_run, | 51 | DECLARE_EVENT_CLASS(coda_buf_class, |
52 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf), | 52 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf), |
53 | 53 | ||
54 | TP_ARGS(ctx, buf), | 54 | TP_ARGS(ctx, buf), |
@@ -69,28 +69,17 @@ TRACE_EVENT(coda_enc_pic_run, | |||
69 | __entry->minor, __entry->index, __entry->ctx) | 69 | __entry->minor, __entry->index, __entry->ctx) |
70 | ); | 70 | ); |
71 | 71 | ||
72 | TRACE_EVENT(coda_enc_pic_done, | 72 | DEFINE_EVENT(coda_buf_class, coda_enc_pic_run, |
73 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf), | 73 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf), |
74 | TP_ARGS(ctx, buf) | ||
75 | ); | ||
74 | 76 | ||
75 | TP_ARGS(ctx, buf), | 77 | DEFINE_EVENT(coda_buf_class, coda_enc_pic_done, |
76 | 78 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf), | |
77 | TP_STRUCT__entry( | 79 | TP_ARGS(ctx, buf) |
78 | __field(int, minor) | ||
79 | __field(int, index) | ||
80 | __field(int, ctx) | ||
81 | ), | ||
82 | |||
83 | TP_fast_assign( | ||
84 | __entry->minor = ctx->fh.vdev->minor; | ||
85 | __entry->index = buf->v4l2_buf.index; | ||
86 | __entry->ctx = ctx->idx; | ||
87 | ), | ||
88 | |||
89 | TP_printk("minor = %d, index = %d, ctx = %d", | ||
90 | __entry->minor, __entry->index, __entry->ctx) | ||
91 | ); | 80 | ); |
92 | 81 | ||
93 | TRACE_EVENT(coda_bit_queue, | 82 | DECLARE_EVENT_CLASS(coda_buf_meta_class, |
94 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf, | 83 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf, |
95 | struct coda_buffer_meta *meta), | 84 | struct coda_buffer_meta *meta), |
96 | 85 | ||
@@ -117,7 +106,13 @@ TRACE_EVENT(coda_bit_queue, | |||
117 | __entry->ctx) | 106 | __entry->ctx) |
118 | ); | 107 | ); |
119 | 108 | ||
120 | TRACE_EVENT(coda_dec_pic_run, | 109 | DEFINE_EVENT(coda_buf_meta_class, coda_bit_queue, |
110 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf, | ||
111 | struct coda_buffer_meta *meta), | ||
112 | TP_ARGS(ctx, buf, meta) | ||
113 | ); | ||
114 | |||
115 | DECLARE_EVENT_CLASS(coda_meta_class, | ||
121 | TP_PROTO(struct coda_ctx *ctx, struct coda_buffer_meta *meta), | 116 | TP_PROTO(struct coda_ctx *ctx, struct coda_buffer_meta *meta), |
122 | 117 | ||
123 | TP_ARGS(ctx, meta), | 118 | TP_ARGS(ctx, meta), |
@@ -140,54 +135,20 @@ TRACE_EVENT(coda_dec_pic_run, | |||
140 | __entry->minor, __entry->start, __entry->end, __entry->ctx) | 135 | __entry->minor, __entry->start, __entry->end, __entry->ctx) |
141 | ); | 136 | ); |
142 | 137 | ||
143 | TRACE_EVENT(coda_dec_pic_done, | 138 | DEFINE_EVENT(coda_meta_class, coda_dec_pic_run, |
144 | TP_PROTO(struct coda_ctx *ctx, struct coda_buffer_meta *meta), | 139 | TP_PROTO(struct coda_ctx *ctx, struct coda_buffer_meta *meta), |
145 | 140 | TP_ARGS(ctx, meta) | |
146 | TP_ARGS(ctx, meta), | ||
147 | |||
148 | TP_STRUCT__entry( | ||
149 | __field(int, minor) | ||
150 | __field(int, start) | ||
151 | __field(int, end) | ||
152 | __field(int, ctx) | ||
153 | ), | ||
154 | |||
155 | TP_fast_assign( | ||
156 | __entry->minor = ctx->fh.vdev->minor; | ||
157 | __entry->start = meta->start; | ||
158 | __entry->end = meta->end; | ||
159 | __entry->ctx = ctx->idx; | ||
160 | ), | ||
161 | |||
162 | TP_printk("minor = %d, start = 0x%x, end = 0x%x, ctx = %d", | ||
163 | __entry->minor, __entry->start, __entry->end, __entry->ctx) | ||
164 | ); | 141 | ); |
165 | 142 | ||
166 | TRACE_EVENT(coda_dec_rot_done, | 143 | DEFINE_EVENT(coda_meta_class, coda_dec_pic_done, |
167 | TP_PROTO(struct coda_ctx *ctx, struct coda_buffer_meta *meta, | 144 | TP_PROTO(struct coda_ctx *ctx, struct coda_buffer_meta *meta), |
168 | struct vb2_buffer *buf), | 145 | TP_ARGS(ctx, meta) |
169 | 146 | ); | |
170 | TP_ARGS(ctx, meta, buf), | ||
171 | |||
172 | TP_STRUCT__entry( | ||
173 | __field(int, minor) | ||
174 | __field(int, start) | ||
175 | __field(int, end) | ||
176 | __field(int, index) | ||
177 | __field(int, ctx) | ||
178 | ), | ||
179 | |||
180 | TP_fast_assign( | ||
181 | __entry->minor = ctx->fh.vdev->minor; | ||
182 | __entry->start = meta->start; | ||
183 | __entry->end = meta->end; | ||
184 | __entry->index = buf->v4l2_buf.index; | ||
185 | __entry->ctx = ctx->idx; | ||
186 | ), | ||
187 | 147 | ||
188 | TP_printk("minor = %d, start = 0x%x, end = 0x%x, index = %d, ctx = %d", | 148 | DEFINE_EVENT(coda_buf_meta_class, coda_dec_rot_done, |
189 | __entry->minor, __entry->start, __entry->end, __entry->index, | 149 | TP_PROTO(struct coda_ctx *ctx, struct vb2_buffer *buf, |
190 | __entry->ctx) | 150 | struct coda_buffer_meta *meta), |
151 | TP_ARGS(ctx, buf, meta) | ||
191 | ); | 152 | ); |
192 | 153 | ||
193 | #endif /* __CODA_TRACE_H__ */ | 154 | #endif /* __CODA_TRACE_H__ */ |