[PATCH] drm/i915/gt: remove redundant assignment to variable x
Colin King
colin.king at canonical.com
Fri Apr 10 19:22:52 UTC 2020
From: Colin Ian King <colin.king at canonical.com>
The variable x is being initialized with a value that is never read
and it is being updated later with a new value. The initialization is
redundant and can be removed.
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king at canonical.com>
---
drivers/gpu/drm/i915/gt/intel_engine_cs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/gt/intel_engine_cs.c b/drivers/gpu/drm/i915/gt/intel_engine_cs.c
index 3aa8a652c16d..0b597427bde9 100644
--- a/drivers/gpu/drm/i915/gt/intel_engine_cs.c
+++ b/drivers/gpu/drm/i915/gt/intel_engine_cs.c
@@ -1205,7 +1205,7 @@ static void print_request(struct drm_printer *m,
{
const char *name = rq->fence.ops->get_timeline_name(&rq->fence);
char buf[80] = "";
- int x = 0;
+ int x;
x = print_sched_attr(rq->i915, &rq->sched.attr, buf, x, sizeof(buf));
--
2.25.1
More information about the dri-devel
mailing list