Skip to contentSkip to conversation

drm/i915/gem: Fix inconsistent IS_ERR and PTR_ERR

PATCH New Gustavo A. R. Silva 2 participants 2 messages May 4, 2020

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

PATCH 1/1 drm/i915/gem: Fix inconsistent IS_ERR and PTR_ERR

Fix inconsistent IS_ERR and PTR_ERR in __reloc_gpu_alloc().

The proper pointer to be passed as argument is ce.

This bug was detected with the help of Coccinelle.

Fixes 6f576d6277ce ("drm/i915/gem: Try an alternate engine for relocations")
---
 drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c +1 -1
index cce7df231cb9..78fdbfd068d3 100644
@@ -1325,7 +1325,7 @@ static int __reloc_gpu_alloc(struct i915_execbuffer *eb,
 
 		ce = intel_context_create(engine);
 		if (IS_ERR(ce)) {
-			err = PTR_ERR(rq);
+			err = PTR_ERR(ce);
 			goto err_unpin;
 		}
 
Signature · 1 line
2.26.0
#1 lore raw

[Intel-gfx] ✗ Fi.CI.BAT: failure for drm/i915/gem: Fix inconsistent IS_ERR and PTR_ERR

== Series Details ==

== Series Details ==

Series: drm/i915/gem: Fix inconsistent IS_ERR and PTR_ERR
URL : https://patchwork.freedesktop.org/series/76916/
State : failure

== Summary ==

Applying: drm/i915/gem: Fix inconsistent IS_ERR and PTR_ERR Using index info to reconstruct a base tree...
M drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c
Falling back to patching base and 3-way merge... Auto-merging drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c No changes -- Patch already applied.

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