From: hwangjae lee Date: Wed, 10 Oct 2018 11:23:18 +0000 (+0900) Subject: [9610] fbdev: dpu: 'ret' value is initialized X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=883b9b41687dd8436bf550db8247cc3ee1eb6563;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git [9610] fbdev: dpu: 'ret' value is initialized In decon_init_resource(), 'ret' value is initialzed. prevent defect 233996. Change-Id: I7e50ebc470bd3e6e5ced40fe4fae5778f6644b00 Signed-off-by: hwangjae lee --- diff --git a/drivers/video/fbdev/exynos/dpu20/decon_core.c b/drivers/video/fbdev/exynos/dpu20/decon_core.c index a34b90f0f6f9..92304612039a 100644 --- a/drivers/video/fbdev/exynos/dpu20/decon_core.c +++ b/drivers/video/fbdev/exynos/dpu20/decon_core.c @@ -3517,7 +3517,7 @@ static int decon_init_resources(struct decon_device *decon, struct platform_device *pdev, char *name) { struct resource *res; - int ret; + int ret = 0; /* Get memory resource and map SFR region. */ res = platform_get_resource(pdev, IORESOURCE_MEM, 0); @@ -3558,6 +3558,7 @@ static int decon_init_resources(struct decon_device *decon, decon->res.ss_regs = dpu_get_sysreg_addr(); if (IS_ERR_OR_NULL(decon->res.ss_regs)) { decon_err("failed to get sysreg addr\n"); + ret = -EINVAL; goto err; }