Skip to contentSkip to conversation

drm/i915: Use uabi engines for the default engine map

PATCH In review Jonathan Cavitt 3 participants 5 messages Jan 23, 2023 – Jan 24, 2023

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/i915: Use uabi engines for the default engine map

From: Tvrtko Ursulin <[email protected]>

Default engine map is exactly about uabi engines so no excuse not to use the appropriate iterator to populate it.

---
 drivers/gpu/drm/i915/gem/i915_gem_context.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)
drivers/gpu/drm/i915/gem/i915_gem_context.c +4 -5
index 454e73a433c8..42a39e103d7c 100644
@@ -1096,16 +1096,15 @@ static struct i915_gem_engines *alloc_engines(unsigned int count)
 static struct i915_gem_engines *default_engines(struct i915_gem_context *ctx,
 						struct intel_sseu rcs_sseu)
 {
-	const struct intel_gt *gt = to_gt(ctx->i915);
+	const unsigned int max = I915_NUM_ENGINES;
 	struct intel_engine_cs *engine;
 	struct i915_gem_engines *e, *err;
-	enum intel_engine_id id;
 
-	e = alloc_engines(I915_NUM_ENGINES);
+	e = alloc_engines(max);
 	if (!e)
 		return ERR_PTR(-ENOMEM);
 
-	for_each_engine(engine, gt, id) {
+	for_each_uabi_engine(engine, ctx->i915) {
 		struct intel_context *ce;
 		struct intel_sseu sseu = {};
 		int ret;
@@ -1113,7 +1112,7 @@ static struct i915_gem_engines *default_engines(struct i915_gem_context *ctx,
 		if (engine->legacy_idx == INVALID_ENGINE)
 			continue;
 
-		GEM_BUG_ON(engine->legacy_idx >= I915_NUM_ENGINES);
+		GEM_BUG_ON(engine->legacy_idx >= max);
 		GEM_BUG_ON(e->engines[engine->legacy_idx]);
 
 		ce = intel_context_create(engine);
Signature · 1 line
2.25.1
#1 lore raw

[Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Use uabi engines for the default engine map (rev4)

== Series Details ==

== Series Details ==

Series: drm/i915: Use uabi engines for the default engine map (rev4)
URL : https://patchwork.freedesktop.org/series/68395/
State : warning

== Summary ==

Error: dim checkpatch failed
0d0b8f01c267 drm/i915: Use uabi engines for the default engine map
-:11: WARNING:BAD_SIGN_OFF: Non-standard signature: 'Reveiwed-by:' - perhaps 'Reviewed-by:'? #11:

-:42: WARNING:AVOID_BUG: Do not crash the kernel unless it is absolutely unavoidable--use WARN_ON_ONCE() plus recovery code (if feasible) instead of BUG() or variants #42: FILE: drivers/gpu/drm/i915/gem/i915_gem_context.c:1115:
+ GEM_BUG_ON(engine->legacy_idx >= max);

total: 0 errors, 2 warnings, 0 checks, 27 lines checked

#2 lore raw

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Use uabi engines for the default engine map (rev4)

In reply to Jonathan Cavitt
== Series Details ==

== Series Details ==

Series: drm/i915: Use uabi engines for the default engine map (rev4)
URL : https://patchwork.freedesktop.org/series/68395/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_12624 -> Patchwork_68395v4
====================================================

Summary
-------

**SUCCESS**

No regressions found.

External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/index.html

Participating hosts (38 -> 39)
------------------------------

Additional (2): fi-kbl-soraka fi-pnv-d510
Missing (1): fi-snb-2520m

Known issues
------------

Here are the changes found in Patchwork_68395v4 that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@gem_huc_copy@huc-copy:
- fi-kbl-soraka: NOTRUN -> [SKIP][1] ([fdo#109271] / [i915#2190])
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/fi-kbl-soraka/igt@[email protected]

* igt@gem_lmem_swapping@basic:
- fi-kbl-soraka: NOTRUN -> [SKIP][2] ([fdo#109271] / [i915#4613]) +3 similar issues
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/fi-kbl-soraka/igt@[email protected]

* igt@i915_selftest@live@gt_pm:
- fi-kbl-soraka: NOTRUN -> [DMESG-FAIL][3] ([i915#1886])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/fi-kbl-soraka/igt@i915_selftest@live@gt_pm.html

* igt@i915_selftest@live@late_gt_pm:
- fi-kbl-soraka: NOTRUN -> [INCOMPLETE][4] ([i915#7640])
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/fi-kbl-soraka/igt@i915_selftest@live@late_gt_pm.html

* igt@kms_chamelium_frames@hdmi-crc-fast:
- fi-kbl-soraka: NOTRUN -> [SKIP][5] ([fdo#109271]) +15 similar issues
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/fi-kbl-soraka/igt@[email protected]

* igt@kms_psr@primary_page_flip:
- fi-pnv-d510: NOTRUN -> [SKIP][6] ([fdo#109271]) +44 similar issues
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/fi-pnv-d510/igt@kms_psr@primary_page_flip.html

#### Possible fixes ####

* igt@i915_selftest@live@gt_mocs:
- {bat-rpls-1}: [DMESG-FAIL][7] ([i915#7059]) -> [PASS][8]
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/bat-rpls-1/igt@i915_selftest@live@gt_mocs.html
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/bat-rpls-1/igt@i915_selftest@live@gt_mocs.html

* igt@i915_selftest@live@requests:
- {bat-rpls-2}: [INCOMPLETE][9] ([i915#6257]) -> [PASS][10]
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/bat-rpls-2/igt@i915_selftest@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/bat-rpls-2/igt@i915_selftest@[email protected]
- {bat-rpls-1}: [INCOMPLETE][11] ([i915#4983]) -> [PASS][12]
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/bat-rpls-1/igt@i915_selftest@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/bat-rpls-1/igt@i915_selftest@[email protected]

* igt@kms_cursor_legacy@basic-busy-flip-before-cursor@atomic-transitions:
- fi-bsw-kefka: [FAIL][13] ([i915#6298]) -> [PASS][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/fi-bsw-kefka/igt@kms_cursor_legacy@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/fi-bsw-kefka/igt@kms_cursor_legacy@[email protected]

* igt@kms_pipe_crc_basic@read-crc@pipe-c-dp-1:
- {bat-adlp-9}: [FAIL][15] ([i915#4137]) -> [PASS][16] +3 similar issues
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/bat-adlp-9/igt@kms_pipe_crc_basic@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/bat-adlp-9/igt@kms_pipe_crc_basic@[email protected]

{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).

[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[i915#1845]: https://gitlab.freedesktop.org/drm/intel/issues/1845
[i915#1886]: https://gitlab.freedesktop.org/drm/intel/issues/1886
[i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
[i915#4137]: https://gitlab.freedesktop.org/drm/intel/issues/4137
[i915#4312]: https://gitlab.freedesktop.org/drm/intel/issues/4312
[i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
[i915#4983]: https://gitlab.freedesktop.org/drm/intel/issues/4983
[i915#6257]: https://gitlab.freedesktop.org/drm/intel/issues/6257
[i915#6298]: https://gitlab.freedesktop.org/drm/intel/issues/6298
[i915#6367]: https://gitlab.freedesktop.org/drm/intel/issues/6367
[i915#7059]: https://gitlab.freedesktop.org/drm/intel/issues/7059
[i915#7625]: https://gitlab.freedesktop.org/drm/intel/issues/7625
[i915#7640]: https://gitlab.freedesktop.org/drm/intel/issues/7640
[i915#7699]: https://gitlab.freedesktop.org/drm/intel/issues/7699
[i915#7828]: https://gitlab.freedesktop.org/drm/intel/issues/7828
[i915#7834]: https://gitlab.freedesktop.org/drm/intel/issues/7834

Build changes
-------------

* Linux: CI_DRM_12624 -> Patchwork_68395v4

CI-20190529: 20190529
CI_DRM_12624: 18fa3d2237f6df82980349f6bef5281096dfc91d @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_7134: 61b8c0a0c8a9611c47749c0b1a262843892cccd7 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_68395v4: 18fa3d2237f6df82980349f6bef5281096dfc91d @ git://anongit.freedesktop.org/gfx-ci/linux

### Linux commits

13df6f76e347 drm/i915: Use uabi engines for the default engine map

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/index.html

#3 lore raw

[Intel-gfx] ✓ Fi.CI.IGT: success for drm/i915: Use uabi engines for the default engine map (rev4)

In reply to Jonathan Cavitt
== Series Details ==

== Series Details ==

Series: drm/i915: Use uabi engines for the default engine map (rev4)
URL : https://patchwork.freedesktop.org/series/68395/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_12624_full -> Patchwork_68395v4_full
====================================================

Summary
-------

**SUCCESS**

No regressions found.

External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/index.html

Participating hosts (12 -> 10)
------------------------------

Missing (2): pig-skl-6260u pig-kbl-iris

Possible new issues
-------------------

Here are the unknown changes that may have been introduced in Patchwork_68395v4_full:

### IGT changes ###

#### Suppressed ####

The following results come from untrusted machines, tests, or statuses. They do not affect the overall result.

* igt@gem_ccs@block-copy-inplace:
- {shard-rkl}: [SKIP][1] ([i915#3555] / [i915#5325]) -> [SKIP][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@gem_ccs@suspend-resume:
- {shard-rkl}: [SKIP][3] ([i915#5325]) -> [SKIP][4] +1 similar issue
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-4/igt@[email protected]
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

Known issues
------------

Here are the changes found in Patchwork_68395v4_full that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@gem_exec_fair@basic-pace-share@rcs0:
- shard-glk: [PASS][5] -> [FAIL][6] ([i915#2842])
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-glk6/igt@gem_exec_fair@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-glk2/igt@gem_exec_fair@[email protected]

* igt@kms_flip@2x-flip-vs-expired-vblank-interruptible@bc-hdmi-a1-hdmi-a2:
- shard-glk: [PASS][7] -> [FAIL][8] ([i915#79])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-glk9/igt@kms_flip@[email protected]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-glk4/igt@kms_flip@[email protected]

* igt@kms_flip@flip-vs-expired-vblank-interruptible@b-hdmi-a2:
- shard-glk: [PASS][9] -> [FAIL][10] ([i915#2122])
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-glk8/igt@kms_flip@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-glk5/igt@kms_flip@[email protected]

#### Possible fixes ####

* igt@api_intel_bb@object-reloc-keep-cache:
- {shard-rkl}: [SKIP][11] ([i915#3281]) -> [PASS][12] +8 similar issues
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@fbdev@write:
- {shard-rkl}: [SKIP][13] ([i915#2582]) -> [PASS][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-4/igt@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@[email protected]

* igt@gem_ctx_exec@basic-nohangcheck:
- {shard-rkl}: [FAIL][15] ([i915#6268]) -> [PASS][16]
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@gem_ctx_persistence@legacy-engines-hang@blt:
- {shard-rkl}: [SKIP][17] ([i915#6252]) -> [PASS][18]
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-5/igt@gem_ctx_persistence@[email protected]
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-1/igt@gem_ctx_persistence@[email protected]

* igt@gem_exec_fair@basic-none-rrul@rcs0:
- {shard-rkl}: [FAIL][19] ([i915#2842]) -> [PASS][20]
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@gem_exec_fair@[email protected]
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-none-vip@rcs0:
- shard-glk: [FAIL][21] ([i915#2842]) -> [PASS][22]
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-glk8/igt@gem_exec_fair@[email protected]
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-glk5/igt@gem_exec_fair@[email protected]

* igt@gem_mmap_gtt@coherency:
- {shard-rkl}: [SKIP][23] ([fdo#111656]) -> [PASS][24]
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@gem_partial_pwrite_pread@writes-after-reads-uncached:
- {shard-rkl}: [SKIP][25] ([i915#3282]) -> [PASS][26] +2 similar issues
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@gen9_exec_parse@secure-batches:
- {shard-rkl}: [SKIP][27] ([i915#2527]) -> [PASS][28] +3 similar issues
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-4/igt@[email protected]
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@i915_hangman@gt-engine-error@bcs0:
- {shard-rkl}: [SKIP][29] ([i915#6258]) -> [PASS][30]
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-5/igt@i915_hangman@[email protected]
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-4/igt@i915_hangman@[email protected]

* igt@i915_pm_rpm@i2c:
- {shard-rkl}: [SKIP][31] ([fdo#109308]) -> [PASS][32]
[31]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[32]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@[email protected]

* igt@i915_pm_sseu@full-enable:
- {shard-rkl}: [SKIP][33] ([i915#4387]) -> [PASS][34]
[33]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-4/igt@[email protected]
[34]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@kms_atomic@atomic_plane_damage:
- {shard-rkl}: [SKIP][35] ([i915#4098]) -> [PASS][36] +1 similar issue
[35]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-4/igt@kms_atomic@atomic_plane_damage.html
[36]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@kms_atomic@atomic_plane_damage.html

* igt@kms_big_fb@x-tiled-32bpp-rotate-0:
- {shard-rkl}: [SKIP][37] ([i915#1845] / [i915#4098]) -> [PASS][38] +26 similar issues
[37]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[38]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@[email protected]

* igt@kms_frontbuffer_tracking@fbc-shrfb-scaledprimary:
- {shard-rkl}: [SKIP][39] ([i915#1849] / [i915#4098]) -> [PASS][40] +18 similar issues
[39]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[40]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@[email protected]

* igt@kms_psr@cursor_mmap_cpu:
- {shard-rkl}: [SKIP][41] ([i915#1072]) -> [PASS][42] +2 similar issues
[41]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@kms_psr@cursor_mmap_cpu.html
[42]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@kms_psr@cursor_mmap_cpu.html

* igt@kms_psr_stress_test@flip-primary-invalidate-overlay:
- {shard-rkl}: [SKIP][43] ([i915#5461]) -> [PASS][44] +1 similar issue
[43]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[44]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@[email protected]

* igt@kms_universal_plane@universal-plane-pipe-a-sanity:
- {shard-rkl}: [SKIP][45] ([i915#1845] / [i915#4070] / [i915#4098]) -> [PASS][46]
[45]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[46]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@[email protected]

* igt@perf@gen12-mi-rpc:
- {shard-rkl}: [SKIP][47] ([fdo#109289]) -> [PASS][48]
[47]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-5/igt@[email protected]
[48]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-1/igt@[email protected]

* igt@perf@mi-rpc:
- {shard-rkl}: [SKIP][49] ([i915#2434]) -> [PASS][50]
[49]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[50]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

* igt@prime_vgem@basic-fence-flip:
- {shard-rkl}: [SKIP][51] ([fdo#109295] / [i915#3708] / [i915#4098]) -> [PASS][52]
[51]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[52]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-6/igt@[email protected]

* igt@prime_vgem@basic-write:
- {shard-rkl}: [SKIP][53] ([fdo#109295] / [i915#3291] / [i915#3708]) -> [PASS][54]
[53]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12624/shard-rkl-2/igt@[email protected]
[54]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/shard-rkl-5/igt@[email protected]

{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).

[fdo#103375]: https://bugs.freedesktop.org/show_bug.cgi?id=103375
[fdo#109274]: https://bugs.freedesktop.org/show_bug.cgi?id=109274
[fdo#109279]: https://bugs.freedesktop.org/show_bug.cgi?id=109279
[fdo#109280]: https://bugs.freedesktop.org/show_bug.cgi?id=109280
[fdo#109283]: https://bugs.freedesktop.org/show_bug.cgi?id=109283
[fdo#109289]: https://bugs.freedesktop.org/show_bug.cgi?id=109289
[fdo#109295]: https://bugs.freedesktop.org/show_bug.cgi?id=109295
[fdo#109302]: https://bugs.freedesktop.org/show_bug.cgi?id=109302
[fdo#109308]: https://bugs.freedesktop.org/show_bug.cgi?id=109308
[fdo#109312]: https://bugs.freedesktop.org/show_bug.cgi?id=109312
[fdo#109313]: https://bugs.freedesktop.org/show_bug.cgi?id=109313
[fdo#109315]: https://bugs.freedesktop.org/show_bug.cgi?id=109315
[fdo#109506]: https://bugs.freedesktop.org/show_bug.cgi?id=109506
[fdo#109642]: https://bugs.freedesktop.org/show_bug.cgi?id=109642
[fdo#110189]: https://bugs.freedesktop.org/show_bug.cgi?id=110189
[fdo#110542]: https://bugs.freedesktop.org/show_bug.cgi?id=110542
[fdo#110723]: https://bugs.freedesktop.org/show_bug.cgi?id=110723
[fdo#111068]: https://bugs.freedesktop.org/show_bug.cgi?id=111068
[fdo#111614]: https://bugs.freedesktop.org/show_bug.cgi?id=111614
[fdo#111615]: https://bugs.freedesktop.org/show_bug.cgi?id=111615
[fdo#111644]: https://bugs.freedesktop.org/show_bug.cgi?id=111644
[fdo#111656]: https://bugs.freedesktop.org/show_bug.cgi?id=111656
[fdo#111825]: https://bugs.freedesktop.org/show_bug.cgi?id=111825
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[fdo#112054]: https://bugs.freedesktop.org/show_bug.cgi?id=112054
[fdo#112283]: https://bugs.freedesktop.org/show_bug.cgi?id=112283
[i915#1072]: https://gitlab.freedesktop.org/drm/intel/issues/1072
[i915#132]: https://gitlab.freedesktop.org/drm/intel/issues/132
[i915#1397]: https://gitlab.freedesktop.org/drm/intel/issues/1397
[i915#1755]: https://gitlab.freedesktop.org/drm/intel/issues/1755
[i915#1769]: https://gitlab.freedesktop.org/drm/intel/issues/1769
[i915#1825]: https://gitlab.freedesktop.org/drm/intel/issues/1825
[i915#1839]: https://gitlab.freedesktop.org/drm/intel/issues/1839
[i915#1845]: https://gitlab.freedesktop.org/drm/intel/issues/1845
[i915#1849]: https://gitlab.freedesktop.org/drm/intel/issues/1849
[i915#1850]: https://gitlab.freedesktop.org/drm/intel/issues/1850
[i915#2122]: https://gitlab.freedesktop.org/drm/intel/issues/2122
[i915#2434]: https://gitlab.freedesktop.org/drm/intel/issues/2434
[i915#2436]: https://gitlab.freedesktop.org/drm/intel/issues/2436
[i915#2437]: https://gitlab.freedesktop.org/drm/intel/issues/2437
[i915#2527]: https://gitlab.freedesktop.org/drm/intel/issues/2527
[i915#2575]: https://gitlab.freedesktop.org/drm/intel/issues/2575
[i915#2582]: https://gitlab.freedesktop.org/drm/intel/issues/2582
[i915#2587]: https://gitlab.freedesktop.org/drm/intel/issues/2587
[i915#2658]: https://gitlab.freedesktop.org/drm/intel/issues/2658
[i915#2672]: https://gitlab.freedesktop.org/drm/intel/issues/2672
[i915#2705]: https://gitlab.freedesktop.org/drm/intel/issues/2705
[i915#280]: https://gitlab.freedesktop.org/drm/intel/issues/280
[i915#284]: https://gitlab.freedesktop.org/drm/intel/issues/284
[i915#2842]: https://gitlab.freedesktop.org/drm/intel/issues/2842
[i915#2856]: https://gitlab.freedesktop.org/drm/intel/issues/2856
[i915#2920]: https://gitlab.freedesktop.org/drm/intel/issues/2920
[i915#3116]: https://gitlab.freedesktop.org/drm/intel/issues/3116
[i915#315]: https://gitlab.freedesktop.org/drm/intel/issues/315
[i915#3281]: https://gitlab.freedesktop.org/drm/intel/issues/3281
[i915#3282]: https://gitlab.freedesktop.org/drm/intel/issues/3282
[i915#3291]: https://gitlab.freedesktop.org/drm/intel/issues/3291
[i915#3297]: https://gitlab.freedesktop.org/drm/intel/issues/3297
[i915#3299]: https://gitlab.freedesktop.org/drm/intel/issues/3299
[i915#3318]: https://gitlab.freedesktop.org/drm/intel/issues/3318
[i915#3359]: https://gitlab.freedesktop.org/drm/intel/issues/3359
[i915#3361]: https://gitlab.freedesktop.org/drm/intel/issues/3361
[i915#3458]: https://gitlab.freedesktop.org/drm/intel/issues/3458
[i915#3469]: https://gitlab.freedesktop.org/drm/intel/issues/3469
[i915#3528]: https://gitlab.freedesktop.org/drm/intel/issues/3528
[i915#3539]: https://gitlab.freedesktop.org/drm/intel/issues/3539
[i915#3546]: https://gitlab.freedesktop.org/drm/intel/issues/3546
[i915#3555]: https://gitlab.freedesktop.org/drm/intel/issues/3555
[i915#3558]: https://gitlab.freedesktop.org/drm/intel/issues/3558
[i915#3591]: https://gitlab.freedesktop.org/drm/intel/issues/3591
[i915#3637]: https://gitlab.freedesktop.org/drm/intel/issues/3637
[i915#3638]: https://gitlab.freedesktop.org/drm/intel/issues/3638
[i915#3689]: https://gitlab.freedesktop.org/drm/intel/issues/3689
[i915#3708]: https://gitlab.freedesktop.org/drm/intel/issues/3708
[i915#3734]: https://gitlab.freedesktop.org/drm/intel/issues/3734
[i915#3742]: https://gitlab.freedesktop.org/drm/intel/issues/3742
[i915#3804]: https://gitlab.freedesktop.org/drm/intel/issues/3804
[i915#3886]: https://gitlab.freedesktop.org/drm/intel/issues/3886
[i915#3955]: https://gitlab.freedesktop.org/drm/intel/issues/3955
[i915#3966]: https://gitlab.freedesktop.org/drm/intel/issues/3966
[i915#4070]: https://gitlab.freedesktop.org/drm/intel/issues/4070
[i915#4077]: https://gitlab.freedesktop.org/drm/intel/issues/4077
[i915#4079]: https://gitlab.freedesktop.org/drm/intel/issues/4079
[i915#4083]: https://gitlab.freedesktop.org/drm/intel/issues/4083
[i915#4098]: https://gitlab.freedesktop.org/drm/intel/issues/4098
[i915#4103]: https://gitlab.freedesktop.org/drm/intel/issues/4103
[i915#4213]: https://gitlab.freedesktop.org/drm/intel/issues/4213
[i915#4270]: https://gitlab.freedesktop.org/drm/intel/issues/4270
[i915#4349]: https://gitlab.freedesktop.org/drm/intel/issues/4349
[i915#4387]: https://gitlab.freedesktop.org/drm/intel/issues/4387
[i915#4538]: https://gitlab.freedesktop.org/drm/intel/issues/4538
[i915#4565]: https://gitlab.freedesktop.org/drm/intel/issues/4565
[i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
[i915#4767]: https://gitlab.freedesktop.org/drm/intel/issues/4767
[i915#4812]: https://gitlab.freedesktop.org/drm/intel/issues/4812
[i915#4833]: https://gitlab.freedesktop.org/drm/intel/issues/4833
[i915#4852]: https://gitlab.freedesktop.org/drm/intel/issues/4852
[i915#4854]: https://gitlab.freedesktop.org/drm/intel/issues/4854
[i915#4859]: https://gitlab.freedesktop.org/drm/intel/issues/4859
[i915#4860]: https://gitlab.freedesktop.org/drm/intel/issues/4860
[i915#4881]: https://gitlab.freedesktop.org/drm/intel/issues/4881
[i915#4885]: https://gitlab.freedesktop.org/drm/intel/issues/4885
[i915#5176]: https://gitlab.freedesktop.org/drm/intel/issues/5176
[i915#5235]: https://gitlab.freedesktop.org/drm/intel/issues/5235
[i915#5286]: https://gitlab.freedesktop.org/drm/intel/issues/5286
[i915#5288]: https://gitlab.freedesktop.org/drm/intel/issues/5288
[i915#5289]: https://gitlab.freedesktop.org/drm/intel/issues/5289
[i915#5325]: https://gitlab.freedesktop.org/drm/intel/issues/5325
[i915#533]: https://gitlab.freedesktop.org/drm/intel/issues/533
[i915#5439]: https://gitlab.freedesktop.org/drm/intel/issues/5439
[i915#5461]: https://gitlab.freedesktop.org/drm/intel/issues/5461
[i915#5563]: https://gitlab.freedesktop.org/drm/intel/issues/5563
[i915#5784]: https://gitlab.freedesktop.org/drm/intel/issues/5784
[i915#6095]: https://gitlab.freedesktop.org/drm/intel/issues/6095
[i915#6117]: https://gitlab.freedesktop.org/drm/intel/issues/6117
[i915#6227]: https://gitlab.freedesktop.org/drm/intel/issues/6227
[i915#6230]: https://gitlab.freedesktop.org/drm/intel/issues/6230
[i915#6245]: https://gitlab.freedesktop.org/drm/intel/issues/6245
[i915#6247]: https://gitlab.freedesktop.org/drm/intel/issues/6247
[i915#6248]: https://gitlab.freedesktop.org/drm/intel/issues/6248
[i915#6252]: https://gitlab.freedesktop.org/drm/intel/issues/6252
[i915#6258]: https://gitlab.freedesktop.org/drm/intel/issues/6258
[i915#6268]: https://gitlab.freedesktop.org/drm/intel/issues/6268
[i915#6301]: https://gitlab.freedesktop.org/drm/intel/issues/6301
[i915#6433]: https://gitlab.freedesktop.org/drm/intel/issues/6433
[i915#6497]: https://gitlab.freedesktop.org/drm/intel/issues/6497
[i915#6524]: https://gitlab.freedesktop.org/drm/intel/issues/6524
[i915#658]: https://gitlab.freedesktop.org/drm/intel/issues/658
[i915#6621]: https://gitlab.freedesktop.org/drm/intel/issues/6621
[i915#6768]: https://gitlab.freedesktop.org/drm/intel/issues/6768
[i915#6944]: https://gitlab.freedesktop.org/drm/intel/issues/6944
[i915#6946]: https://gitlab.freedesktop.org/drm/intel/issues/6946
[i915#6953]: https://gitlab.freedesktop.org/drm/intel/issues/6953
[i915#7037]: https://gitlab.freedesktop.org/drm/intel/issues/7037
[i915#7052]: https://gitlab.freedesktop.org/drm/intel/issues/7052
[i915#7116]: https://gitlab.freedesktop.org/drm/intel/issues/7116
[i915#7118]: https://gitlab.freedesktop.org/drm/intel/issues/7118
[i915#7128]: https://gitlab.freedesktop.org/drm/intel/issues/7128
[i915#7294]: https://gitlab.freedesktop.org/drm/intel/issues/7294
[i915#7443]: https://gitlab.freedesktop.org/drm/intel/issues/7443
[i915#7561]: https://gitlab.freedesktop.org/drm/intel/issues/7561
[i915#7582]: https://gitlab.freedesktop.org/drm/intel/issues/7582
[i915#7651]: https://gitlab.freedesktop.org/drm/intel/issues/7651
[i915#7697]: https://gitlab.freedesktop.org/drm/intel/issues/7697
[i915#7701]: https://gitlab.freedesktop.org/drm/intel/issues/7701
[i915#7711]: https://gitlab.freedesktop.org/drm/intel/issues/7711
[i915#7742]: https://gitlab.freedesktop.org/drm/intel/issues/7742
[i915#7828]: https://gitlab.freedesktop.org/drm/intel/issues/7828
[i915#79]: https://gitlab.freedesktop.org/drm/intel/issues/79

Build changes
-------------

* Linux: CI_DRM_12624 -> Patchwork_68395v4
* Piglit: piglit_4509 -> None

CI-20190529: 20190529
CI_DRM_12624: 18fa3d2237f6df82980349f6bef5281096dfc91d @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_7134: 61b8c0a0c8a9611c47749c0b1a262843892cccd7 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_68395v4: 18fa3d2237f6df82980349f6bef5281096dfc91d @ git://anongit.freedesktop.org/gfx-ci/linux
piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_68395v4/index.html

#4 lore raw
In reply to Jonathan Cavitt
Quoted 8 lines · Jonathan Cavitt

From: Tvrtko Ursulin <[email protected]>

Default engine map is exactly about uabi engines so no excuse not to use the appropriate iterator to populate it.

Fixed the r-b spelling and pushed - thanks for the review and sending the patch over!

Regards,

Tvrtko

Quoted 37 lines
---
  drivers/gpu/drm/i915/gem/i915_gem_context.c | 9 ++++-----
  1 file changed, 4 insertions(+), 5 deletions(-)
drivers/gpu/drm/i915/gem/i915_gem_context.c +4 -5
index 454e73a433c8..42a39e103d7c 100644
@@ -1096,16 +1096,15 @@ static struct i915_gem_engines *alloc_engines(unsigned int count)
  static struct i915_gem_engines *default_engines(struct i915_gem_context *ctx,
  						struct intel_sseu rcs_sseu)
  {
-	const struct intel_gt *gt = to_gt(ctx->i915);
+	const unsigned int max = I915_NUM_ENGINES;
  	struct intel_engine_cs *engine;
  	struct i915_gem_engines *e, *err;
-	enum intel_engine_id id;
 
-	e = alloc_engines(I915_NUM_ENGINES);
+	e = alloc_engines(max);
  	if (!e)
  		return ERR_PTR(-ENOMEM);
 
-	for_each_engine(engine, gt, id) {
+	for_each_uabi_engine(engine, ctx->i915) {
  		struct intel_context *ce;
  		struct intel_sseu sseu = {};
  		int ret;
@@ -1113,7 +1112,7 @@ static struct i915_gem_engines *default_engines(struct i915_gem_context *ctx,
  		if (engine->legacy_idx == INVALID_ENGINE)
  			continue;
 
-		GEM_BUG_ON(engine->legacy_idx >= I915_NUM_ENGINES);
+		GEM_BUG_ON(engine->legacy_idx >= max);
  		GEM_BUG_ON(e->engines[engine->legacy_idx]);
 
  		ce = intel_context_create(engine);