Skip to contentSkip to conversation

drm/i915/selftests: fix error handling in guc_steal_ids

PATCH New Matthew Auld 2 participants 2 messages Jan 25, 2022

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

PATCH 1/1 drm/i915/selftests: fix error handling in guc_steal_ids

Ensure we drop the reference to the last rq, otherwise we are leaking the context etc. Also don't zero the previous valid context.

---
 drivers/gpu/drm/i915/gt/uc/selftest_guc.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/gt/uc/selftest_guc.c +3 -1
index d3327b802b76..b170f6b6e729 100644
@@ -190,7 +190,6 @@ static int intel_guc_steal_guc_ids(void *arg)
 		ce[++context_index] = intel_context_create(engine);
 		if (IS_ERR(ce[context_index])) {
 			ret = PTR_ERR(ce[context_index--]);
-			ce[context_index] = NULL;
 			pr_err("Failed to create context: %d\n", ret);
 			goto err_spin_rq;
 		}
@@ -226,6 +225,7 @@ static int intel_guc_steal_guc_ids(void *arg)
 	/* Wait for last request */
 	ret = i915_request_wait(last, 0, HZ * 30);
 	i915_request_put(last);
+	last = NULL;
 	if (ret < 0) {
 		pr_err("Last request failed to complete: %d\n", ret);
 		goto err_spin_rq;
@@ -271,6 +271,8 @@ static int intel_guc_steal_guc_ids(void *arg)
 		igt_spinner_fini(&spin);
 		intel_gt_wait_for_idle(gt, HZ * 30);
 	}
+	if (last)
+		i915_request_put(last);
 err_contexts:
 	for (; context_index >= 0 && ce[context_index]; --context_index)
 		intel_context_put(ce[context_index]);
Signature · 1 line
2.34.1
#1 lore raw

[Intel-gfx] ✗ Fi.CI.BAT: failure for drm/i915/selftests: fix error handling in guc_steal_ids

== Series Details ==

== Series Details ==

Series: drm/i915/selftests: fix error handling in guc_steal_ids
URL : https://patchwork.freedesktop.org/series/99318/
State : failure

== Summary ==

CI Bug Log - changes from CI_DRM_11132 -> Patchwork_22100
====================================================

Summary
-------

**FAILURE**

Serious unknown changes coming with Patchwork_22100 absolutely need to be verified manually.

If you think the reported changes have nothing to do with the changes introduced in Patchwork_22100, please notify your bug team to allow them to document this new failure mode, which will reduce false positives in CI.

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

Participating hosts (43 -> 43)
------------------------------

Additional (3): fi-kbl-8809g bat-adlp-6 fi-pnv-d510
Missing (3): fi-ctg-p8600 fi-bsw-cyan fi-hsw-4200u

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

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

### IGT changes ###

#### Possible regressions ####

* igt@vgem_basic@second-client:
- fi-kbl-soraka: [PASS][1] -> [INCOMPLETE][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_11132/fi-kbl-soraka/igt@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-kbl-soraka/igt@[email protected]

#### Suppressed ####

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

* igt@kms_addfb_basic@addfb25-framebuffer-vs-set-tiling:
- {bat-adlp-6}: NOTRUN -> [DMESG-WARN][3]
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/bat-adlp-6/igt@[email protected]

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

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

### IGT changes ###

#### Issues hit ####

* igt@amdgpu/amd_basic@semaphore:
- fi-bdw-5557u: NOTRUN -> [SKIP][4] ([fdo#109271]) +31 similar issues
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-bdw-5557u/igt@amdgpu/[email protected]

* igt@amdgpu/amd_cs_nop@sync-fork-gfx0:
- fi-skl-6600u: NOTRUN -> [SKIP][5] ([fdo#109271]) +21 similar issues
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-skl-6600u/igt@amdgpu/[email protected]

* igt@gem_exec_suspend@basic-s0@smem:
- fi-kbl-8809g: NOTRUN -> [DMESG-WARN][6] ([i915#4962]) +1 similar issue
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-kbl-8809g/igt@gem_exec_suspend@[email protected]

* igt@gem_huc_copy@huc-copy:
- fi-skl-6600u: NOTRUN -> [SKIP][7] ([fdo#109271] / [i915#2190])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-skl-6600u/igt@[email protected]
- fi-kbl-8809g: NOTRUN -> [SKIP][8] ([fdo#109271] / [i915#2190])
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-kbl-8809g/igt@[email protected]

* igt@gem_lmem_swapping@random-engines:
- fi-kbl-8809g: NOTRUN -> [SKIP][9] ([fdo#109271] / [i915#4613]) +3 similar issues
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-kbl-8809g/igt@[email protected]

* igt@gem_lmem_swapping@verify-random:
- fi-skl-6600u: NOTRUN -> [SKIP][10] ([fdo#109271] / [i915#4613]) +3 similar issues
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-skl-6600u/igt@[email protected]

* igt@kms_chamelium@dp-crc-fast:
- fi-bdw-5557u: NOTRUN -> [SKIP][11] ([fdo#109271] / [fdo#111827]) +8 similar issues
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-bdw-5557u/igt@[email protected]

* igt@kms_chamelium@hdmi-edid-read:
- fi-kbl-8809g: NOTRUN -> [SKIP][12] ([fdo#109271] / [fdo#111827]) +8 similar issues
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-kbl-8809g/igt@[email protected]

* igt@kms_chamelium@vga-edid-read:
- fi-skl-6600u: NOTRUN -> [SKIP][13] ([fdo#109271] / [fdo#111827]) +8 similar issues
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-skl-6600u/igt@[email protected]

* igt@kms_pipe_crc_basic@compare-crc-sanitycheck-pipe-d:
- fi-skl-6600u: NOTRUN -> [SKIP][14] ([fdo#109271] / [i915#533])
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-skl-6600u/igt@[email protected]
- fi-kbl-8809g: NOTRUN -> [SKIP][15] ([fdo#109271] / [i915#533])
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-kbl-8809g/igt@[email protected]

* igt@kms_psr@cursor_plane_move:
- fi-kbl-8809g: NOTRUN -> [SKIP][16] ([fdo#109271]) +54 similar issues
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-kbl-8809g/igt@kms_psr@cursor_plane_move.html

* igt@prime_vgem@basic-userptr:
- fi-pnv-d510: NOTRUN -> [SKIP][17] ([fdo#109271]) +57 similar issues
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-pnv-d510/igt@[email protected]

#### Possible fixes ####

* igt@gem_flink_basic@bad-flink:
- fi-skl-6600u: [FAIL][18] ([i915#4547]) -> [PASS][19]
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_11132/fi-skl-6600u/igt@[email protected]
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-skl-6600u/igt@[email protected]

* igt@i915_selftest@live@hugepages:
- fi-rkl-guc: [DMESG-WARN][20] -> [PASS][21]
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_11132/fi-rkl-guc/igt@i915_selftest@[email protected]
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-rkl-guc/igt@i915_selftest@[email protected]

* igt@kms_pipe_crc_basic@compare-crc-sanitycheck-pipe-b:
- fi-cfl-8109u: [DMESG-WARN][22] ([i915#295]) -> [PASS][23] +11 similar issues
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_11132/fi-cfl-8109u/igt@[email protected]
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22100/fi-cfl-8109u/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#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
[i915#295]: https://gitlab.freedesktop.org/drm/intel/issues/295
[i915#3282]: https://gitlab.freedesktop.org/drm/intel/issues/3282
[i915#4312]: https://gitlab.freedesktop.org/drm/intel/issues/4312
[i915#4547]: https://gitlab.freedesktop.org/drm/intel/issues/4547
[i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
[i915#4897]: https://gitlab.freedesktop.org/drm/intel/issues/4897
[i915#4962]: https://gitlab.freedesktop.org/drm/intel/issues/4962
[i915#533]: https://gitlab.freedesktop.org/drm/intel/issues/533

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

* Linux: CI_DRM_11132 -> Patchwork_22100

CI-20190529: 20190529
CI_DRM_11132: f75afdb6d5b6db97043e5bf5f93e7f893ab9c057 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_6331: 74fc362b425cf92cf41a29210980b25966dd5951 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_22100: e39bc8d4231f28d2b7fec73f696ae4ee2fa6015f @ git://anongit.freedesktop.org/gfx-ci/linux

== Linux commits ==

e39bc8d4231f drm/i915/selftests: fix error handling in guc_steal_ids

== Logs ==

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