intel-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/i915/selftests: Silence compiler warning in igt_ctx_exec
@ 2017-05-22 12:21 Chris Wilson
  2017-05-22 12:38 ` ✗ Fi.CI.BAT: warning for " Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Chris Wilson @ 2017-05-22 12:21 UTC (permalink / raw)
  To: intel-gfx; +Cc: Matthew Auld

The compiler doesn't always spot the guard that object is allocated on
the first pass, leading to:

drivers/gpu/drm/i915/selftests/i915_gem_context.c: warning: 'obj' may be used uninitialized in this function [-Wuninitialized]:  => 370:8

Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Fixes: 791ff39ae32a ("drm/i915: Live testing for context execution")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Matthew Auld <matthew.auld@intel.com>
c: <drm-intel-fixes@lists.freedesktop.org> # v4.12-rc1+
---
 drivers/gpu/drm/i915/selftests/i915_gem_context.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/selftests/i915_gem_context.c b/drivers/gpu/drm/i915/selftests/i915_gem_context.c
index 1afb8b06e3e1..4b38134eafd2 100644
--- a/drivers/gpu/drm/i915/selftests/i915_gem_context.c
+++ b/drivers/gpu/drm/i915/selftests/i915_gem_context.c
@@ -320,7 +320,7 @@ static unsigned long max_dwords(struct drm_i915_gem_object *obj)
 static int igt_ctx_exec(void *arg)
 {
 	struct drm_i915_private *i915 = arg;
-	struct drm_i915_gem_object *obj;
+	struct drm_i915_gem_object *uninitialized_var(obj);
 	struct drm_file *file;
 	IGT_TIMEOUT(end_time);
 	LIST_HEAD(objects);
-- 
2.11.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* ✗ Fi.CI.BAT: warning for drm/i915/selftests: Silence compiler warning in igt_ctx_exec
  2017-05-22 12:21 [PATCH] drm/i915/selftests: Silence compiler warning in igt_ctx_exec Chris Wilson
@ 2017-05-22 12:38 ` Patchwork
  2017-05-22 14:38 ` [PATCH] " Matthew Auld
  2017-05-23 18:18 ` Joonas Lahtinen
  2 siblings, 0 replies; 4+ messages in thread
From: Patchwork @ 2017-05-22 12:38 UTC (permalink / raw)
  To: Chris Wilson; +Cc: intel-gfx

== Series Details ==

Series: drm/i915/selftests: Silence compiler warning in igt_ctx_exec
URL   : https://patchwork.freedesktop.org/series/24787/
State : warning

== Summary ==

Series 24787v1 drm/i915/selftests: Silence compiler warning in igt_ctx_exec
https://patchwork.freedesktop.org/api/1.0/series/24787/revisions/1/mbox/

Test gem_exec_suspend:
        Subgroup basic-s4-devices:
                pass       -> DMESG-WARN (fi-snb-2600)
Test drv_module_reload:
        Subgroup basic-reload-final:
                pass       -> DMESG-WARN (fi-skl-6770hq) fdo#100248

fdo#100248 https://bugs.freedesktop.org/show_bug.cgi?id=100248

fi-bdw-5557u     total:278  pass:267  dwarn:0   dfail:0   fail:0   skip:11  time:443s
fi-bdw-gvtdvm    total:278  pass:256  dwarn:8   dfail:0   fail:0   skip:14  time:434s
fi-bsw-n3050     total:278  pass:242  dwarn:0   dfail:0   fail:0   skip:36  time:586s
fi-bxt-j4205     total:278  pass:259  dwarn:0   dfail:0   fail:0   skip:19  time:513s
fi-byt-j1900     total:278  pass:254  dwarn:0   dfail:0   fail:0   skip:24  time:499s
fi-byt-n2820     total:278  pass:250  dwarn:0   dfail:0   fail:0   skip:28  time:486s
fi-hsw-4770      total:278  pass:262  dwarn:0   dfail:0   fail:0   skip:16  time:421s
fi-hsw-4770r     total:278  pass:262  dwarn:0   dfail:0   fail:0   skip:16  time:409s
fi-ilk-650       total:278  pass:228  dwarn:0   dfail:0   fail:0   skip:50  time:416s
fi-ivb-3520m     total:278  pass:260  dwarn:0   dfail:0   fail:0   skip:18  time:498s
fi-ivb-3770      total:278  pass:260  dwarn:0   dfail:0   fail:0   skip:18  time:462s
fi-kbl-7500u     total:278  pass:255  dwarn:5   dfail:0   fail:0   skip:18  time:460s
fi-skl-6260u     total:278  pass:268  dwarn:0   dfail:0   fail:0   skip:10  time:467s
fi-skl-6700hq    total:278  pass:260  dwarn:1   dfail:0   fail:0   skip:17  time:579s
fi-skl-6700k     total:278  pass:256  dwarn:4   dfail:0   fail:0   skip:18  time:473s
fi-skl-6770hq    total:278  pass:267  dwarn:1   dfail:0   fail:0   skip:10  time:501s
fi-skl-gvtdvm    total:278  pass:265  dwarn:0   dfail:0   fail:0   skip:13  time:437s
fi-snb-2520m     total:278  pass:250  dwarn:0   dfail:0   fail:0   skip:28  time:538s
fi-snb-2600      total:278  pass:248  dwarn:1   dfail:0   fail:0   skip:29  time:412s
fi-kbl-7560u failed to collect. IGT log at Patchwork_4771/fi-kbl-7560u/igt.log

ec077216f6939248d037dc27dc6e0b56f7121d2b drm-tip: 2017y-05m-22d-10h-46m-27s UTC integration manifest
744abe7 drm/i915/selftests: Silence compiler warning in igt_ctx_exec

== Logs ==

For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_4771/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] drm/i915/selftests: Silence compiler warning in igt_ctx_exec
  2017-05-22 12:21 [PATCH] drm/i915/selftests: Silence compiler warning in igt_ctx_exec Chris Wilson
  2017-05-22 12:38 ` ✗ Fi.CI.BAT: warning for " Patchwork
@ 2017-05-22 14:38 ` Matthew Auld
  2017-05-23 18:18 ` Joonas Lahtinen
  2 siblings, 0 replies; 4+ messages in thread
From: Matthew Auld @ 2017-05-22 14:38 UTC (permalink / raw)
  To: Chris Wilson; +Cc: Intel Graphics Development, Matthew Auld

On 22 May 2017 at 13:21, Chris Wilson <chris@chris-wilson.co.uk> wrote:
> The compiler doesn't always spot the guard that object is allocated on
> the first pass, leading to:
>
> drivers/gpu/drm/i915/selftests/i915_gem_context.c: warning: 'obj' may be used uninitialized in this function [-Wuninitialized]:  => 370:8
>
> Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
> Fixes: 791ff39ae32a ("drm/i915: Live testing for context execution")
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Cc: Matthew Auld <matthew.auld@intel.com>
> c: <drm-intel-fixes@lists.freedesktop.org> # v4.12-rc1+
Cc: <drm-intel-fixes@lists.freedesktop.org> # v4.12-rc1+

Reviewed-by: Matthew Auld <matthew.auld@intel.com>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] drm/i915/selftests: Silence compiler warning in igt_ctx_exec
  2017-05-22 12:21 [PATCH] drm/i915/selftests: Silence compiler warning in igt_ctx_exec Chris Wilson
  2017-05-22 12:38 ` ✗ Fi.CI.BAT: warning for " Patchwork
  2017-05-22 14:38 ` [PATCH] " Matthew Auld
@ 2017-05-23 18:18 ` Joonas Lahtinen
  2 siblings, 0 replies; 4+ messages in thread
From: Joonas Lahtinen @ 2017-05-23 18:18 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: Matthew Auld

On ma, 2017-05-22 at 13:21 +0100, Chris Wilson wrote:
> The compiler doesn't always spot the guard that object is allocated on
> the first pass, leading to:
> 
> drivers/gpu/drm/i915/selftests/i915_gem_context.c: warning: 'obj' may be used uninitialized in this function [-Wuninitialized]:  => 370:8
> 
> Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
> Fixes: 791ff39ae32a ("drm/i915: Live testing for context execution")
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Cc: Matthew Auld <matthew.auld@intel.com>
> c: <drm-intel-fixes@lists.freedesktop.org> # v4.12-rc1+

Maybe should be "Cc:" too? Code is,

Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>

I'm not sure if this is the best way to address similar problems.

Regards, Joonas
-- 
Joonas Lahtinen
Open Source Technology Center
Intel Corporation
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-05-23 18:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-22 12:21 [PATCH] drm/i915/selftests: Silence compiler warning in igt_ctx_exec Chris Wilson
2017-05-22 12:38 ` ✗ Fi.CI.BAT: warning for " Patchwork
2017-05-22 14:38 ` [PATCH] " Matthew Auld
2017-05-23 18:18 ` Joonas Lahtinen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).