From: Colin Ian King Date: Sat, 11 Mar 2017 19:48:19 +0000 (+0000) Subject: staging: atomisp: remove redundant check for client being null X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=b8ff636cd7d72334951a7fa1dfe9f21ba4d2107b;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git staging: atomisp: remove redundant check for client being null The previous statement checks if client is null, so the null check when assigning dev is redundant and can be removed. Detected by CoverityScan, CID#1416555 ("Logically Dead Code") Signed-off-by: Colin Ian King Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/media/atomisp/platform/intel-mid/atomisp_gmin_platform.c b/drivers/staging/media/atomisp/platform/intel-mid/atomisp_gmin_platform.c index 65513cae93ce..292949273d00 100644 --- a/drivers/staging/media/atomisp/platform/intel-mid/atomisp_gmin_platform.c +++ b/drivers/staging/media/atomisp/platform/intel-mid/atomisp_gmin_platform.c @@ -354,7 +354,7 @@ static struct gmin_subdev *gmin_subdev_add(struct v4l2_subdev *subdev) if (!client) return NULL; - dev = client ? &client->dev : NULL; + dev = &client->dev; for (i=0; i < MAX_SUBDEVS && gmin_subdevs[i].subdev; i++) ;