Skip to contentSkip to conversation

drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers

PATCH Superseded Tvrtko Ursulin 4 participants 7 messages Nov 23, 2017

Subsystems (3)
lore
Share & tools
lore

Tvrtko Ursulin

author maintainer
#0 lore raw

PATCH 1/1 drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers

From: Tvrtko Ursulin <[email protected]>

We have agreed during the engine classes discussion that fields marked as non-ABI are better left out altogether from uapi headers.

---
 drivers/gpu/drm/i915/intel_ringbuffer.h | 2 +-
 include/uapi/drm/i915_drm.h             | 3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)
drivers/gpu/drm/i915/intel_ringbuffer.h +1 -1
index 3bd30d011866..283c800d7ee7 100644
@@ -359,7 +359,7 @@ struct intel_engine_cs {
 		 *
 		 * Our internal timer stores the current counters in this field.
 		 */
-		struct i915_pmu_sample sample[I915_ENGINE_SAMPLE_MAX];
+		struct i915_pmu_sample sample[I915_SAMPLE_SEMA + 1];
 		/**
 		 * @busy_stats: Has enablement of engine stats tracking been
 		 * 		requested.
include/uapi/drm/i915_drm.h +1 -2
index 915a6e85a855..239e8633edc9 100644
@@ -110,8 +110,7 @@ enum drm_i915_gem_engine_class {
 enum drm_i915_pmu_engine_sample {
 	I915_SAMPLE_BUSY = 0,
 	I915_SAMPLE_WAIT = 1,
-	I915_SAMPLE_SEMA = 2,
-	I915_ENGINE_SAMPLE_MAX /* non-ABI */
+	I915_SAMPLE_SEMA = 2
 };
 
 #define I915_PMU_SAMPLE_BITS (4)
Signature · 6 lines
2.14.1

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
#1 lore raw

Quoting Tvrtko Ursulin (2017-11-23 09:32:29)

Quoted 16 lines

From: Tvrtko Ursulin <[email protected]>

We have agreed during the engine classes discussion that fields marked as non-ABI are better left out altogether from uapi headers.

---
 drivers/gpu/drm/i915/intel_ringbuffer.h | 2 +-
 include/uapi/drm/i915_drm.h             | 3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)
drivers/gpu/drm/i915/intel_ringbuffer.h +0 -0
index 3bd30d011866..283c800d7ee7 100644

drivers/gpu/drm/i915/intel_ringbuffer.h struct intel_engine_cs { · line 362

Quoted 5 lines
drivers/gpu/drm/i915/intel_ringbuffer.h +1 -1
@@ -359,7 +359,7 @@ struct intel_engine_cs {
                 *
                 * Our internal timer stores the current counters in this field.
                 */
-               struct i915_pmu_sample sample[I915_ENGINE_SAMPLE_MAX];
+               struct i915_pmu_sample sample[I915_SAMPLE_SEMA + 1];

I would stick to ENGINE_SAMPLE_MAX here, and a
#define I915_ENGINE_SAMPLE_MAX (I915_SAMPLE_SEMA + 1) above. That I think describes it better and we are less likely to be confused later if we add another engine sampler.
-Chris
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

author maintainer
#2 lore raw

PATCH v2 1/1 drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers

From: Tvrtko Ursulin <[email protected]>

We have agreed during the engine classes discussion that fields marked as non-ABI are better left out altogether from uapi headers.

v2: Use a local define for maintanability. (Chris Wilson)

---
 drivers/gpu/drm/i915/intel_ringbuffer.h | 1 +
 include/uapi/drm/i915_drm.h             | 3 +--
 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/i915/intel_ringbuffer.h +1 -0
index 3bd30d011866..2953147e1978 100644
@@ -359,6 +359,7 @@ struct intel_engine_cs {
 		 *
 		 * Our internal timer stores the current counters in this field.
 		 */
+#define I915_ENGINE_SAMPLE_MAX (I915_SAMPLE_SEMA + 1)
 		struct i915_pmu_sample sample[I915_ENGINE_SAMPLE_MAX];
 		/**
 		 * @busy_stats: Has enablement of engine stats tracking been
include/uapi/drm/i915_drm.h +1 -2
index 915a6e85a855..239e8633edc9 100644
@@ -110,8 +110,7 @@ enum drm_i915_gem_engine_class {
 enum drm_i915_pmu_engine_sample {
 	I915_SAMPLE_BUSY = 0,
 	I915_SAMPLE_WAIT = 1,
-	I915_SAMPLE_SEMA = 2,
-	I915_ENGINE_SAMPLE_MAX /* non-ABI */
+	I915_SAMPLE_SEMA = 2
 };
 
 #define I915_PMU_SAMPLE_BITS (4)
Signature · 6 lines
2.14.1

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Reviewed-by on v2 1/1
#3 lore raw

Quoting Tvrtko Ursulin (2017-11-23 10:07:01)

Quoted 8 lines

From: Tvrtko Ursulin <[email protected]>

We have agreed during the engine classes discussion that fields marked as non-ABI are better left out altogether from uapi headers.

v2: Use a local define for maintanability. (Chris Wilson)

Quoted 22 lines
---
 drivers/gpu/drm/i915/intel_ringbuffer.h | 1 +
 include/uapi/drm/i915_drm.h             | 3 +--
 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/i915/intel_ringbuffer.h +1 -0
index 3bd30d011866..2953147e1978 100644
@@ -359,6 +359,7 @@ struct intel_engine_cs {
                 *
                 * Our internal timer stores the current counters in this field.
                 */
+#define I915_ENGINE_SAMPLE_MAX (I915_SAMPLE_SEMA + 1)
                struct i915_pmu_sample sample[I915_ENGINE_SAMPLE_MAX];
                /**
                 * @busy_stats: Has enablement of engine stats tracking been
include/uapi/drm/i915_drm.h +0 -0
index 915a6e85a855..239e8633edc9 100644

include/uapi/drm/i915_drm.h enum drm_i915_gem_engine_class { · line 113

Quoted 6 lines
include/uapi/drm/i915_drm.h +1 -2
@@ -110,8 +110,7 @@ enum drm_i915_gem_engine_class {
 enum drm_i915_pmu_engine_sample {
        I915_SAMPLE_BUSY = 0,
        I915_SAMPLE_WAIT = 1,
-       I915_SAMPLE_SEMA = 2,
-       I915_ENGINE_SAMPLE_MAX /* non-ABI */
+       I915_SAMPLE_SEMA = 2

Classic K&R :)
You might choose to end with a ',' here for adding. Not having a ',' after MAX made sense (since it was by definition the final value). -Chris
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#4 lore raw

✓ Fi.CI.BAT: success for drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers (rev2)

In reply to Tvrtko Ursulin
== Series Details ==

== Series Details ==

Series: drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers (rev2)
URL : https://patchwork.freedesktop.org/series/34286/
State : success

== Summary ==

Series 34286v2 drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers
https://patchwork.freedesktop.org/api/1.0/series/34286/revisions/2/mbox/

Test kms_pipe_crc_basic:

        Subgroup suspend-read-crc-pipe-b:
                incomplete -> PASS       (fi-snb-2520m) fdo#103713

fdo#103713 https://bugs.freedesktop.org/show_bug.cgi?id=103713

fi-bdw-5557u     total:289  pass:268  dwarn:0   dfail:0   fail:0   skip:21  time:447s
fi-bdw-gvtdvm    total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:454s
fi-blb-e6850     total:289  pass:223  dwarn:1   dfail:0   fail:0   skip:65  time:383s
fi-bsw-n3050     total:289  pass:243  dwarn:0   dfail:0   fail:0   skip:46  time:536s
fi-bwr-2160      total:289  pass:183  dwarn:0   dfail:0   fail:0   skip:106 time:279s
fi-bxt-dsi       total:289  pass:259  dwarn:0   dfail:0   fail:0   skip:30  time:504s
fi-bxt-j4205     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:506s
fi-byt-j1900     total:289  pass:254  dwarn:0   dfail:0   fail:0   skip:35  time:505s
fi-byt-n2820     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:489s
fi-cfl-s2        total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:610s
fi-elk-e7500     total:289  pass:229  dwarn:0   dfail:0   fail:0   skip:60  time:431s
fi-gdg-551       total:289  pass:178  dwarn:1   dfail:0   fail:1   skip:109 time:265s
fi-glk-1         total:289  pass:261  dwarn:0   dfail:0   fail:0   skip:28  time:538s
fi-hsw-4770      total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:428s
fi-hsw-4770r     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:439s
fi-ilk-650       total:289  pass:228  dwarn:0   dfail:0   fail:0   skip:61  time:424s
fi-ivb-3520m     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:487s
fi-ivb-3770      total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:460s
fi-kbl-7500u     total:289  pass:264  dwarn:1   dfail:0   fail:0   skip:24  time:492s
fi-kbl-7560u     total:289  pass:270  dwarn:0   dfail:0   fail:0   skip:19  time:522s
fi-kbl-7567u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:475s
fi-kbl-r         total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:536s
fi-pnv-d510      total:289  pass:222  dwarn:1   dfail:0   fail:0   skip:66  time:576s
fi-skl-6260u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:460s
fi-skl-6600u     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:544s
fi-skl-6700hq    total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:563s
fi-skl-6700k     total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:518s
fi-skl-6770hq    total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:498s
fi-snb-2520m     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:564s
fi-snb-2600      total:289  pass:249  dwarn:0   dfail:0   fail:0   skip:40  time:423s

Blacklisted hosts:
fi-glk-dsi total:289 pass:259 dwarn:0 dfail:0 fail:0 skip:30 time:494s

0df0feb7141cc848766a9475b51cc919c010eaa8 drm-tip: 2017y-11m-23d-09h-17m-34s UTC integration manifest a61f312da374 drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_7251/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#5 lore raw

Re: ✓ Fi.CI.BAT: success for drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers (rev2)

Quoted 47 lines · Patchwork

== Series Details ==

Series: drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers (rev2)
URL : https://patchwork.freedesktop.org/series/34286/
State : success

== Summary ==

Series 34286v2 drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers
https://patchwork.freedesktop.org/api/1.0/series/34286/revisions/2/mbox/

Test kms_pipe_crc_basic:

         Subgroup suspend-read-crc-pipe-b:
                 incomplete -> PASS       (fi-snb-2520m) fdo#103713

fdo#103713 https://bugs.freedesktop.org/show_bug.cgi?id=103713

fi-bdw-5557u     total:289  pass:268  dwarn:0   dfail:0   fail:0   skip:21  time:447s
fi-bdw-gvtdvm    total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:454s
fi-blb-e6850     total:289  pass:223  dwarn:1   dfail:0   fail:0   skip:65  time:383s
fi-bsw-n3050     total:289  pass:243  dwarn:0   dfail:0   fail:0   skip:46  time:536s
fi-bwr-2160      total:289  pass:183  dwarn:0   dfail:0   fail:0   skip:106 time:279s
fi-bxt-dsi       total:289  pass:259  dwarn:0   dfail:0   fail:0   skip:30  time:504s
fi-bxt-j4205     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:506s
fi-byt-j1900     total:289  pass:254  dwarn:0   dfail:0   fail:0   skip:35  time:505s
fi-byt-n2820     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:489s
fi-cfl-s2        total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:610s
fi-elk-e7500     total:289  pass:229  dwarn:0   dfail:0   fail:0   skip:60  time:431s
fi-gdg-551       total:289  pass:178  dwarn:1   dfail:0   fail:1   skip:109 time:265s
fi-glk-1         total:289  pass:261  dwarn:0   dfail:0   fail:0   skip:28  time:538s
fi-hsw-4770      total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:428s
fi-hsw-4770r     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:439s
fi-ilk-650       total:289  pass:228  dwarn:0   dfail:0   fail:0   skip:61  time:424s
fi-ivb-3520m     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:487s
fi-ivb-3770      total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:460s
fi-kbl-7500u     total:289  pass:264  dwarn:1   dfail:0   fail:0   skip:24  time:492s
fi-kbl-7560u     total:289  pass:270  dwarn:0   dfail:0   fail:0   skip:19  time:522s
fi-kbl-7567u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:475s
fi-kbl-r         total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:536s
fi-pnv-d510      total:289  pass:222  dwarn:1   dfail:0   fail:0   skip:66  time:576s
fi-skl-6260u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:460s
fi-skl-6600u     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:544s
fi-skl-6700hq    total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:563s
fi-skl-6700k     total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:518s
fi-skl-6770hq    total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:498s
fi-snb-2520m     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:564s
fi-snb-2600      total:289  pass:249  dwarn:0   dfail:0   fail:0   skip:40  time:423s
Quoted 5 lines

Blacklisted hosts:
fi-glk-dsi total:289 pass:259 dwarn:0 dfail:0 fail:0 skip:30 time:494s

0df0feb7141cc848766a9475b51cc919c010eaa8 drm-tip: 2017y-11m-23d-09h-17m-34s UTC integration manifest a61f312da374 drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers

Pushed, thanks for the review!

Regards,

Tvrtko

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#6 lore raw

✓ Fi.CI.IGT: success for drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers (rev2)

In reply to Tvrtko Ursulin
== Series Details ==

== Series Details ==

Series: drm/i915/pmu: Drop I915_ENGINE_SAMPLE_MAX from uapi headers (rev2)
URL : https://patchwork.freedesktop.org/series/34286/
State : success

== Summary ==

Test kms_frontbuffer_tracking:

        Subgroup fbc-1p-offscren-pri-shrfb-draw-render:
                pass       -> FAIL       (shard-snb) fdo#101623
Test drv_selftest:
        Subgroup mock_sanitycheck:
                dmesg-warn -> PASS       (shard-snb) fdo#103717
                dmesg-warn -> PASS       (shard-hsw) fdo#103719
Test kms_setmode:
        Subgroup basic:
                fail       -> PASS       (shard-hsw) fdo#99912
Test kms_flip:
        Subgroup flip-vs-blocking-wf-vblank:
                fail       -> PASS       (shard-hsw) fdo#100368

fdo#101623 https://bugs.freedesktop.org/show_bug.cgi?id=101623
fdo#103717 https://bugs.freedesktop.org/show_bug.cgi?id=103717
fdo#103719 https://bugs.freedesktop.org/show_bug.cgi?id=103719
fdo#99912 https://bugs.freedesktop.org/show_bug.cgi?id=99912
fdo#100368 https://bugs.freedesktop.org/show_bug.cgi?id=100368

shard-hsw        total:2667 pass:1533 dwarn:1   dfail:0   fail:11  skip:1122 time:9553s
shard-snb        total:2667 pass:1311 dwarn:1   dfail:0   fail:14  skip:1341 time:8129s

Blacklisted hosts:
shard-apl total:2645 pass:1664 dwarn:2 dfail:0 fail:24 skip:954 time:13237s

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_7251/shards.html
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx