[Intel-gfx] [PATCH v2] drm/i915/selftest: Fix an error code in live_noa_gpr()

Dan Carpenter dan.carpenter at oracle.com
Tue Jul 14 14:36:52 UTC 2020


The error code needs to be set on this path.  It currently returns
success.

Fixes: ed2690a9ca89 ("drm/i915/selftest: Check that GPR are restored across noa_wait")
Reported-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Signed-off-by: Dan Carpenter <dan.carpenter at oracle.com>
---
v2: Fix a different bug instead.  :P  Colin fixed mine already.

 drivers/gpu/drm/i915/selftests/i915_perf.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/i915/selftests/i915_perf.c b/drivers/gpu/drm/i915/selftests/i915_perf.c
index 0aa151501fb3..c232194c60a2 100644
--- a/drivers/gpu/drm/i915/selftests/i915_perf.c
+++ b/drivers/gpu/drm/i915/selftests/i915_perf.c
@@ -358,6 +358,7 @@ static int live_noa_gpr(void *arg)
 		cs = intel_ring_begin(rq, 4);
 		if (IS_ERR(cs)) {
 			i915_request_add(rq);
+			err = PTR_ERR(cs);
 			goto out_rq;
 		}
 
-- 
2.27.0



More information about the Intel-gfx mailing list