Skip to contentSkip to conversation

drm/i915/selftests: Fix inconsistent object in IS_ERR and PTR_ERR

PATCH In review Miaoqian Lin 2 participants 3 messages Dec 10, 2021 – Dec 13, 2021

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

PATCH 1/1 drm/i915/selftests: Fix inconsistent object in IS_ERR and PTR_ERR

Fix inconsistent object in IS_ERR and PTR_ERR in igt_dmabuf_import_same_driver and igt_dmabuf_import_same_driver_lmem. As obj is the return value of __i915_gem_object_create_user, the proper object to be passed as argument to PTR_ERR is obj.

---
 drivers/gpu/drm/i915/gem/selftests/i915_gem_dmabuf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/i915/gem/selftests/i915_gem_dmabuf.c +2 -2
index 4a6bb64c3a35..3cc74b0fed06 100644
@@ -102,7 +102,7 @@ static int igt_dmabuf_import_same_driver_lmem(void *arg)
 	obj = __i915_gem_object_create_user(i915, PAGE_SIZE, &lmem, 1);
 	if (IS_ERR(obj)) {
 		pr_err("__i915_gem_object_create_user failed with err=%ld\n",
-		       PTR_ERR(dmabuf));
+		       PTR_ERR(obj));
 		err = PTR_ERR(obj);
 		goto out_ret;
 	}
@@ -158,7 +158,7 @@ static int igt_dmabuf_import_same_driver(struct drm_i915_private *i915,
 					    regions, num_regions);
 	if (IS_ERR(obj)) {
 		pr_err("__i915_gem_object_create_user failed with err=%ld\n",
-		       PTR_ERR(dmabuf));
+		       PTR_ERR(obj));
 		err = PTR_ERR(obj);
 		goto out_ret;
 	}
Signature · 1 line
2.17.1
#1 lore raw

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

== Series Details ==

== Series Details ==

Series: drm/i915/selftests: Fix inconsistent object in IS_ERR and PTR_ERR
URL : https://patchwork.freedesktop.org/series/97868/
State : failure

== Summary ==

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

author
#2 lore raw

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

I have no idea why it failed without a detailed log, from my humble opinion, this bug indeed exists and is easy to understand, I hope someone could look into it.

Quoted 12 lines · Patchwork <[email protected]> 于2021年12月11日周六 00:40写道:

*Patch Details*
*Series:* drm/i915/selftests: Fix inconsistent object in IS_ERR and PTR_ERR
*URL:* https://patchwork.freedesktop.org/series/97868/
*State:* failure

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