hc
2023-12-06 08f87f769b595151be1afeff53e144f543faa614
kernel/drivers/gpu/drm/i915/i915_trace.h
....@@ -2,7 +2,7 @@
22 #if !defined(_I915_TRACE_H_) || defined(TRACE_HEADER_MULTI_READ)
33 #define _I915_TRACE_H_
44
5
-#ifdef CONFIG_PREEMPT_RT_BASE
5
+#ifdef CONFIG_PREEMPT_RT
66 #define NOTRACE
77 #endif
88
....@@ -10,16 +10,96 @@
1010 #include <linux/types.h>
1111 #include <linux/tracepoint.h>
1212
13
-#include <drm/drmP.h>
13
+#include <drm/drm_drv.h>
14
+
15
+#include "display/intel_display_types.h"
16
+#include "gt/intel_engine.h"
17
+
1418 #include "i915_drv.h"
15
-#include "intel_drv.h"
16
-#include "intel_ringbuffer.h"
19
+#include "i915_irq.h"
1720
1821 #undef TRACE_SYSTEM
1922 #define TRACE_SYSTEM i915
2023 #define TRACE_INCLUDE_FILE i915_trace
2124
2225 /* watermark/fifo updates */
26
+
27
+TRACE_EVENT(intel_pipe_enable,
28
+ TP_PROTO(struct intel_crtc *crtc),
29
+ TP_ARGS(crtc),
30
+
31
+ TP_STRUCT__entry(
32
+ __array(u32, frame, 3)
33
+ __array(u32, scanline, 3)
34
+ __field(enum pipe, pipe)
35
+ ),
36
+ TP_fast_assign(
37
+ struct drm_i915_private *dev_priv = to_i915(crtc->base.dev);
38
+ struct intel_crtc *it__;
39
+ for_each_intel_crtc(&dev_priv->drm, it__) {
40
+ __entry->frame[it__->pipe] = intel_crtc_get_vblank_counter(it__);
41
+ __entry->scanline[it__->pipe] = intel_get_crtc_scanline(it__);
42
+ }
43
+ __entry->pipe = crtc->pipe;
44
+ ),
45
+
46
+ TP_printk("pipe %c enable, pipe A: frame=%u, scanline=%u, pipe B: frame=%u, scanline=%u, pipe C: frame=%u, scanline=%u",
47
+ pipe_name(__entry->pipe),
48
+ __entry->frame[PIPE_A], __entry->scanline[PIPE_A],
49
+ __entry->frame[PIPE_B], __entry->scanline[PIPE_B],
50
+ __entry->frame[PIPE_C], __entry->scanline[PIPE_C])
51
+);
52
+
53
+TRACE_EVENT(intel_pipe_disable,
54
+ TP_PROTO(struct intel_crtc *crtc),
55
+ TP_ARGS(crtc),
56
+
57
+ TP_STRUCT__entry(
58
+ __array(u32, frame, 3)
59
+ __array(u32, scanline, 3)
60
+ __field(enum pipe, pipe)
61
+ ),
62
+
63
+ TP_fast_assign(
64
+ struct drm_i915_private *dev_priv = to_i915(crtc->base.dev);
65
+ struct intel_crtc *it__;
66
+ for_each_intel_crtc(&dev_priv->drm, it__) {
67
+ __entry->frame[it__->pipe] = intel_crtc_get_vblank_counter(it__);
68
+ __entry->scanline[it__->pipe] = intel_get_crtc_scanline(it__);
69
+ }
70
+ __entry->pipe = crtc->pipe;
71
+ ),
72
+
73
+ TP_printk("pipe %c disable, pipe A: frame=%u, scanline=%u, pipe B: frame=%u, scanline=%u, pipe C: frame=%u, scanline=%u",
74
+ pipe_name(__entry->pipe),
75
+ __entry->frame[PIPE_A], __entry->scanline[PIPE_A],
76
+ __entry->frame[PIPE_B], __entry->scanline[PIPE_B],
77
+ __entry->frame[PIPE_C], __entry->scanline[PIPE_C])
78
+);
79
+
80
+TRACE_EVENT(intel_pipe_crc,
81
+ TP_PROTO(struct intel_crtc *crtc, const u32 *crcs),
82
+ TP_ARGS(crtc, crcs),
83
+
84
+ TP_STRUCT__entry(
85
+ __field(enum pipe, pipe)
86
+ __field(u32, frame)
87
+ __field(u32, scanline)
88
+ __array(u32, crcs, 5)
89
+ ),
90
+
91
+ TP_fast_assign(
92
+ __entry->pipe = crtc->pipe;
93
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
94
+ __entry->scanline = intel_get_crtc_scanline(crtc);
95
+ memcpy(__entry->crcs, crcs, sizeof(__entry->crcs));
96
+ ),
97
+
98
+ TP_printk("pipe %c, frame=%u, scanline=%u crc=%08x %08x %08x %08x %08x",
99
+ pipe_name(__entry->pipe), __entry->frame, __entry->scanline,
100
+ __entry->crcs[0], __entry->crcs[1], __entry->crcs[2],
101
+ __entry->crcs[3], __entry->crcs[4])
102
+);
23103
24104 TRACE_EVENT(intel_cpu_fifo_underrun,
25105 TP_PROTO(struct drm_i915_private *dev_priv, enum pipe pipe),
....@@ -32,9 +112,10 @@
32112 ),
33113
34114 TP_fast_assign(
115
+ struct intel_crtc *crtc = intel_get_crtc_for_pipe(dev_priv, pipe);
35116 __entry->pipe = pipe;
36
- __entry->frame = dev_priv->drm.driver->get_vblank_counter(&dev_priv->drm, pipe);
37
- __entry->scanline = intel_get_crtc_scanline(intel_get_crtc_for_pipe(dev_priv, pipe));
117
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
118
+ __entry->scanline = intel_get_crtc_scanline(crtc);
38119 ),
39120
40121 TP_printk("pipe %c, frame=%u, scanline=%u",
....@@ -54,9 +135,10 @@
54135
55136 TP_fast_assign(
56137 enum pipe pipe = pch_transcoder;
138
+ struct intel_crtc *crtc = intel_get_crtc_for_pipe(dev_priv, pipe);
57139 __entry->pipe = pipe;
58
- __entry->frame = dev_priv->drm.driver->get_vblank_counter(&dev_priv->drm, pipe);
59
- __entry->scanline = intel_get_crtc_scanline(intel_get_crtc_for_pipe(dev_priv, pipe));
140
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
141
+ __entry->scanline = intel_get_crtc_scanline(crtc);
60142 ),
61143
62144 TP_printk("pch transcoder %c, frame=%u, scanline=%u",
....@@ -76,12 +158,10 @@
76158 ),
77159
78160 TP_fast_assign(
79
- enum pipe pipe;
80
- for_each_pipe(dev_priv, pipe) {
81
- __entry->frame[pipe] =
82
- dev_priv->drm.driver->get_vblank_counter(&dev_priv->drm, pipe);
83
- __entry->scanline[pipe] =
84
- intel_get_crtc_scanline(intel_get_crtc_for_pipe(dev_priv, pipe));
161
+ struct intel_crtc *crtc;
162
+ for_each_intel_crtc(&dev_priv->drm, crtc) {
163
+ __entry->frame[crtc->pipe] = intel_crtc_get_vblank_counter(crtc);
164
+ __entry->scanline[crtc->pipe] = intel_get_crtc_scanline(crtc);
85165 }
86166 __entry->old = old;
87167 __entry->new = new;
....@@ -118,8 +198,7 @@
118198
119199 TP_fast_assign(
120200 __entry->pipe = crtc->pipe;
121
- __entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
122
- crtc->pipe);
201
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
123202 __entry->scanline = intel_get_crtc_scanline(crtc);
124203 __entry->primary = wm->pipe[crtc->pipe].plane[PLANE_PRIMARY];
125204 __entry->sprite = wm->pipe[crtc->pipe].plane[PLANE_SPRITE0];
....@@ -163,8 +242,7 @@
163242
164243 TP_fast_assign(
165244 __entry->pipe = crtc->pipe;
166
- __entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
167
- crtc->pipe);
245
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
168246 __entry->scanline = intel_get_crtc_scanline(crtc);
169247 __entry->level = wm->level;
170248 __entry->cxsr = wm->cxsr;
....@@ -198,8 +276,7 @@
198276
199277 TP_fast_assign(
200278 __entry->pipe = crtc->pipe;
201
- __entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
202
- crtc->pipe);
279
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
203280 __entry->scanline = intel_get_crtc_scanline(crtc);
204281 __entry->sprite0_start = sprite0_start;
205282 __entry->sprite1_start = sprite1_start;
....@@ -220,25 +297,24 @@
220297
221298 TP_STRUCT__entry(
222299 __field(enum pipe, pipe)
223
- __field(const char *, name)
224300 __field(u32, frame)
225301 __field(u32, scanline)
226302 __array(int, src, 4)
227303 __array(int, dst, 4)
304
+ __string(name, plane->name)
228305 ),
229306
230307 TP_fast_assign(
308
+ __assign_str(name, plane->name);
231309 __entry->pipe = crtc->pipe;
232
- __entry->name = plane->name;
233
- __entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
234
- crtc->pipe);
310
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
235311 __entry->scanline = intel_get_crtc_scanline(crtc);
236312 memcpy(__entry->src, &plane->state->src, sizeof(__entry->src));
237313 memcpy(__entry->dst, &plane->state->dst, sizeof(__entry->dst));
238314 ),
239315
240316 TP_printk("pipe %c, plane %s, frame=%u, scanline=%u, " DRM_RECT_FP_FMT " -> " DRM_RECT_FMT,
241
- pipe_name(__entry->pipe), __entry->name,
317
+ pipe_name(__entry->pipe), __get_str(name),
242318 __entry->frame, __entry->scanline,
243319 DRM_RECT_FP_ARG((const struct drm_rect *)__entry->src),
244320 DRM_RECT_ARG((const struct drm_rect *)__entry->dst))
....@@ -250,27 +326,88 @@
250326
251327 TP_STRUCT__entry(
252328 __field(enum pipe, pipe)
253
- __field(const char *, name)
329
+ __field(u32, frame)
330
+ __field(u32, scanline)
331
+ __string(name, plane->name)
332
+ ),
333
+
334
+ TP_fast_assign(
335
+ __assign_str(name, plane->name);
336
+ __entry->pipe = crtc->pipe;
337
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
338
+ __entry->scanline = intel_get_crtc_scanline(crtc);
339
+ ),
340
+
341
+ TP_printk("pipe %c, plane %s, frame=%u, scanline=%u",
342
+ pipe_name(__entry->pipe), __get_str(name),
343
+ __entry->frame, __entry->scanline)
344
+);
345
+
346
+/* fbc */
347
+
348
+TRACE_EVENT(intel_fbc_activate,
349
+ TP_PROTO(struct intel_crtc *crtc),
350
+ TP_ARGS(crtc),
351
+
352
+ TP_STRUCT__entry(
353
+ __field(enum pipe, pipe)
254354 __field(u32, frame)
255355 __field(u32, scanline)
256356 ),
257357
258358 TP_fast_assign(
259359 __entry->pipe = crtc->pipe;
260
- __entry->name = plane->name;
261
- __entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
262
- crtc->pipe);
360
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
263361 __entry->scanline = intel_get_crtc_scanline(crtc);
264362 ),
265363
266
- TP_printk("pipe %c, plane %s, frame=%u, scanline=%u",
267
- pipe_name(__entry->pipe), __entry->name,
268
- __entry->frame, __entry->scanline)
364
+ TP_printk("pipe %c, frame=%u, scanline=%u",
365
+ pipe_name(__entry->pipe), __entry->frame, __entry->scanline)
366
+);
367
+
368
+TRACE_EVENT(intel_fbc_deactivate,
369
+ TP_PROTO(struct intel_crtc *crtc),
370
+ TP_ARGS(crtc),
371
+
372
+ TP_STRUCT__entry(
373
+ __field(enum pipe, pipe)
374
+ __field(u32, frame)
375
+ __field(u32, scanline)
376
+ ),
377
+
378
+ TP_fast_assign(
379
+ __entry->pipe = crtc->pipe;
380
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
381
+ __entry->scanline = intel_get_crtc_scanline(crtc);
382
+ ),
383
+
384
+ TP_printk("pipe %c, frame=%u, scanline=%u",
385
+ pipe_name(__entry->pipe), __entry->frame, __entry->scanline)
386
+);
387
+
388
+TRACE_EVENT(intel_fbc_nuke,
389
+ TP_PROTO(struct intel_crtc *crtc),
390
+ TP_ARGS(crtc),
391
+
392
+ TP_STRUCT__entry(
393
+ __field(enum pipe, pipe)
394
+ __field(u32, frame)
395
+ __field(u32, scanline)
396
+ ),
397
+
398
+ TP_fast_assign(
399
+ __entry->pipe = crtc->pipe;
400
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
401
+ __entry->scanline = intel_get_crtc_scanline(crtc);
402
+ ),
403
+
404
+ TP_printk("pipe %c, frame=%u, scanline=%u",
405
+ pipe_name(__entry->pipe), __entry->frame, __entry->scanline)
269406 );
270407
271408 /* pipe updates */
272409
273
-TRACE_EVENT(i915_pipe_update_start,
410
+TRACE_EVENT(intel_pipe_update_start,
274411 TP_PROTO(struct intel_crtc *crtc),
275412 TP_ARGS(crtc),
276413
....@@ -284,8 +421,7 @@
284421
285422 TP_fast_assign(
286423 __entry->pipe = crtc->pipe;
287
- __entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
288
- crtc->pipe);
424
+ __entry->frame = intel_crtc_get_vblank_counter(crtc);
289425 __entry->scanline = intel_get_crtc_scanline(crtc);
290426 __entry->min = crtc->debug.min_vbl;
291427 __entry->max = crtc->debug.max_vbl;
....@@ -296,7 +432,7 @@
296432 __entry->scanline, __entry->min, __entry->max)
297433 );
298434
299
-TRACE_EVENT(i915_pipe_update_vblank_evaded,
435
+TRACE_EVENT(intel_pipe_update_vblank_evaded,
300436 TP_PROTO(struct intel_crtc *crtc),
301437 TP_ARGS(crtc),
302438
....@@ -321,7 +457,7 @@
321457 __entry->scanline, __entry->min, __entry->max)
322458 );
323459
324
-TRACE_EVENT(i915_pipe_update_end,
460
+TRACE_EVENT(intel_pipe_update_end,
325461 TP_PROTO(struct intel_crtc *crtc, u32 frame, int scanline_end),
326462 TP_ARGS(crtc, frame, scanline_end),
327463
....@@ -589,42 +725,12 @@
589725 TP_printk("dev=%d, vm=%p", __entry->dev, __entry->vm)
590726 );
591727
592
-TRACE_EVENT(i915_gem_ring_sync_to,
593
- TP_PROTO(struct i915_request *to, struct i915_request *from),
594
- TP_ARGS(to, from),
595
-
596
- TP_STRUCT__entry(
597
- __field(u32, dev)
598
- __field(u32, from_class)
599
- __field(u32, from_instance)
600
- __field(u32, to_class)
601
- __field(u32, to_instance)
602
- __field(u32, seqno)
603
- ),
604
-
605
- TP_fast_assign(
606
- __entry->dev = from->i915->drm.primary->index;
607
- __entry->from_class = from->engine->uabi_class;
608
- __entry->from_instance = from->engine->instance;
609
- __entry->to_class = to->engine->uabi_class;
610
- __entry->to_instance = to->engine->instance;
611
- __entry->seqno = from->global_seqno;
612
- ),
613
-
614
- TP_printk("dev=%u, sync-from=%u:%u, sync-to=%u:%u, seqno=%u",
615
- __entry->dev,
616
- __entry->from_class, __entry->from_instance,
617
- __entry->to_class, __entry->to_instance,
618
- __entry->seqno)
619
-);
620
-
621728 TRACE_EVENT(i915_request_queue,
622729 TP_PROTO(struct i915_request *rq, u32 flags),
623730 TP_ARGS(rq, flags),
624731
625732 TP_STRUCT__entry(
626733 __field(u32, dev)
627
- __field(u32, hw_id)
628734 __field(u64, ctx)
629735 __field(u16, class)
630736 __field(u16, instance)
....@@ -633,19 +739,17 @@
633739 ),
634740
635741 TP_fast_assign(
636
- __entry->dev = rq->i915->drm.primary->index;
637
- __entry->hw_id = rq->gem_context->hw_id;
742
+ __entry->dev = rq->engine->i915->drm.primary->index;
638743 __entry->class = rq->engine->uabi_class;
639
- __entry->instance = rq->engine->instance;
744
+ __entry->instance = rq->engine->uabi_instance;
640745 __entry->ctx = rq->fence.context;
641746 __entry->seqno = rq->fence.seqno;
642747 __entry->flags = flags;
643748 ),
644749
645
- TP_printk("dev=%u, engine=%u:%u, hw_id=%u, ctx=%llu, seqno=%u, flags=0x%x",
750
+ TP_printk("dev=%u, engine=%u:%u, ctx=%llu, seqno=%u, flags=0x%x",
646751 __entry->dev, __entry->class, __entry->instance,
647
- __entry->hw_id, __entry->ctx, __entry->seqno,
648
- __entry->flags)
752
+ __entry->ctx, __entry->seqno, __entry->flags)
649753 );
650754
651755 DECLARE_EVENT_CLASS(i915_request,
....@@ -654,28 +758,23 @@
654758
655759 TP_STRUCT__entry(
656760 __field(u32, dev)
657
- __field(u32, hw_id)
658761 __field(u64, ctx)
659762 __field(u16, class)
660763 __field(u16, instance)
661764 __field(u32, seqno)
662
- __field(u32, global)
663765 ),
664766
665767 TP_fast_assign(
666
- __entry->dev = rq->i915->drm.primary->index;
667
- __entry->hw_id = rq->gem_context->hw_id;
768
+ __entry->dev = rq->engine->i915->drm.primary->index;
668769 __entry->class = rq->engine->uabi_class;
669
- __entry->instance = rq->engine->instance;
770
+ __entry->instance = rq->engine->uabi_instance;
670771 __entry->ctx = rq->fence.context;
671772 __entry->seqno = rq->fence.seqno;
672
- __entry->global = rq->global_seqno;
673773 ),
674774
675
- TP_printk("dev=%u, engine=%u:%u, hw_id=%u, ctx=%llu, seqno=%u, global=%u",
775
+ TP_printk("dev=%u, engine=%u:%u, ctx=%llu, seqno=%u",
676776 __entry->dev, __entry->class, __entry->instance,
677
- __entry->hw_id, __entry->ctx, __entry->seqno,
678
- __entry->global)
777
+ __entry->ctx, __entry->seqno)
679778 );
680779
681780 DEFINE_EVENT(i915_request, i915_request_add,
....@@ -700,32 +799,28 @@
700799
701800 TP_STRUCT__entry(
702801 __field(u32, dev)
703
- __field(u32, hw_id)
704802 __field(u64, ctx)
705803 __field(u16, class)
706804 __field(u16, instance)
707805 __field(u32, seqno)
708
- __field(u32, global_seqno)
709806 __field(u32, port)
710
- __field(u32, prio)
807
+ __field(s32, prio)
711808 ),
712809
713810 TP_fast_assign(
714
- __entry->dev = rq->i915->drm.primary->index;
715
- __entry->hw_id = rq->gem_context->hw_id;
811
+ __entry->dev = rq->engine->i915->drm.primary->index;
716812 __entry->class = rq->engine->uabi_class;
717
- __entry->instance = rq->engine->instance;
813
+ __entry->instance = rq->engine->uabi_instance;
718814 __entry->ctx = rq->fence.context;
719815 __entry->seqno = rq->fence.seqno;
720
- __entry->global_seqno = rq->global_seqno;
721816 __entry->prio = rq->sched.attr.priority;
722817 __entry->port = port;
723818 ),
724819
725
- TP_printk("dev=%u, engine=%u:%u, hw_id=%u, ctx=%llu, seqno=%u, prio=%u, global=%u, port=%u",
820
+ TP_printk("dev=%u, engine=%u:%u, ctx=%llu, seqno=%u, prio=%d, port=%u",
726821 __entry->dev, __entry->class, __entry->instance,
727
- __entry->hw_id, __entry->ctx, __entry->seqno,
728
- __entry->prio, __entry->global_seqno, __entry->port)
822
+ __entry->ctx, __entry->seqno,
823
+ __entry->prio, __entry->port)
729824 );
730825
731826 TRACE_EVENT(i915_request_out,
....@@ -734,30 +829,25 @@
734829
735830 TP_STRUCT__entry(
736831 __field(u32, dev)
737
- __field(u32, hw_id)
738832 __field(u64, ctx)
739833 __field(u16, class)
740834 __field(u16, instance)
741835 __field(u32, seqno)
742
- __field(u32, global_seqno)
743836 __field(u32, completed)
744837 ),
745838
746839 TP_fast_assign(
747
- __entry->dev = rq->i915->drm.primary->index;
748
- __entry->hw_id = rq->gem_context->hw_id;
840
+ __entry->dev = rq->engine->i915->drm.primary->index;
749841 __entry->class = rq->engine->uabi_class;
750
- __entry->instance = rq->engine->instance;
842
+ __entry->instance = rq->engine->uabi_instance;
751843 __entry->ctx = rq->fence.context;
752844 __entry->seqno = rq->fence.seqno;
753
- __entry->global_seqno = rq->global_seqno;
754845 __entry->completed = i915_request_completed(rq);
755846 ),
756847
757
- TP_printk("dev=%u, engine=%u:%u, hw_id=%u, ctx=%llu, seqno=%u, global=%u, completed?=%u",
848
+ TP_printk("dev=%u, engine=%u:%u, ctx=%llu, seqno=%u, completed?=%u",
758849 __entry->dev, __entry->class, __entry->instance,
759
- __entry->hw_id, __entry->ctx, __entry->seqno,
760
- __entry->global_seqno, __entry->completed)
850
+ __entry->ctx, __entry->seqno, __entry->completed)
761851 );
762852
763853 #else
....@@ -784,31 +874,6 @@
784874 #endif
785875 #endif
786876
787
-TRACE_EVENT(intel_engine_notify,
788
- TP_PROTO(struct intel_engine_cs *engine, bool waiters),
789
- TP_ARGS(engine, waiters),
790
-
791
- TP_STRUCT__entry(
792
- __field(u32, dev)
793
- __field(u16, class)
794
- __field(u16, instance)
795
- __field(u32, seqno)
796
- __field(bool, waiters)
797
- ),
798
-
799
- TP_fast_assign(
800
- __entry->dev = engine->i915->drm.primary->index;
801
- __entry->class = engine->uabi_class;
802
- __entry->instance = engine->instance;
803
- __entry->seqno = intel_engine_get_seqno(engine);
804
- __entry->waiters = waiters;
805
- ),
806
-
807
- TP_printk("dev=%u, engine=%u:%u, seqno=%u, waiters=%u",
808
- __entry->dev, __entry->class, __entry->instance,
809
- __entry->seqno, __entry->waiters)
810
-);
811
-
812877 DEFINE_EVENT(i915_request, i915_request_retire,
813878 TP_PROTO(struct i915_request *rq),
814879 TP_ARGS(rq)
....@@ -820,12 +885,10 @@
820885
821886 TP_STRUCT__entry(
822887 __field(u32, dev)
823
- __field(u32, hw_id)
824888 __field(u64, ctx)
825889 __field(u16, class)
826890 __field(u16, instance)
827891 __field(u32, seqno)
828
- __field(u32, global)
829892 __field(unsigned int, flags)
830893 ),
831894
....@@ -836,20 +899,17 @@
836899 * less desirable.
837900 */
838901 TP_fast_assign(
839
- __entry->dev = rq->i915->drm.primary->index;
840
- __entry->hw_id = rq->gem_context->hw_id;
902
+ __entry->dev = rq->engine->i915->drm.primary->index;
841903 __entry->class = rq->engine->uabi_class;
842
- __entry->instance = rq->engine->instance;
904
+ __entry->instance = rq->engine->uabi_instance;
843905 __entry->ctx = rq->fence.context;
844906 __entry->seqno = rq->fence.seqno;
845
- __entry->global = rq->global_seqno;
846907 __entry->flags = flags;
847908 ),
848909
849
- TP_printk("dev=%u, engine=%u:%u, hw_id=%u, ctx=%llu, seqno=%u, global=%u, blocking=%u, flags=0x%x",
910
+ TP_printk("dev=%u, engine=%u:%u, ctx=%llu, seqno=%u, flags=0x%x",
850911 __entry->dev, __entry->class, __entry->instance,
851
- __entry->hw_id, __entry->ctx, __entry->seqno,
852
- __entry->global, !!(__entry->flags & I915_WAIT_LOCKED),
912
+ __entry->ctx, __entry->seqno,
853913 __entry->flags)
854914 );
855915
....@@ -952,19 +1012,17 @@
9521012 TP_STRUCT__entry(
9531013 __field(u32, dev)
9541014 __field(struct i915_gem_context *, ctx)
955
- __field(u32, hw_id)
9561015 __field(struct i915_address_space *, vm)
9571016 ),
9581017
9591018 TP_fast_assign(
9601019 __entry->dev = ctx->i915->drm.primary->index;
9611020 __entry->ctx = ctx;
962
- __entry->hw_id = ctx->hw_id;
963
- __entry->vm = ctx->ppgtt ? &ctx->ppgtt->vm : NULL;
1021
+ __entry->vm = rcu_access_pointer(ctx->vm);
9641022 ),
9651023
966
- TP_printk("dev=%u, ctx=%p, ctx_vm=%p, hw_id=%u",
967
- __entry->dev, __entry->ctx, __entry->vm, __entry->hw_id)
1024
+ TP_printk("dev=%u, ctx=%p, ctx_vm=%p",
1025
+ __entry->dev, __entry->ctx, __entry->vm)
9681026 )
9691027
9701028 DEFINE_EVENT(i915_context, i915_context_create,