lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1386470506-553-1-git-send-email-ethan.kernel@gmail.com>
Date:	Sun,  8 Dec 2013 10:41:46 +0800
From:	"ethan.zhao" <ethan.kernel@...il.com>
To:	laurent.pinchart@...asonboard.com
Cc:	linux-kernel@...r.kernel.org, "ethan.zhao" <ethan.kernel@...il.com>
Subject: [PATCH] r_du_lvdsenc.c : Check return value of devm_ioremap_resource with IS_ERR

function devm_ioremap_resource() doesn't return NULL, should check its return
value with helper IS_ERR().

Signed-off-by: ethan.zhao <ethan.kernel@...il.com>
---
 drivers/gpu/drm/rcar-du/rcar_du_lvdsenc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/rcar-du/rcar_du_lvdsenc.c b/drivers/gpu/drm/rcar-du/rcar_du_lvdsenc.c
index a0f6a17..93190ab 100644
--- a/drivers/gpu/drm/rcar-du/rcar_du_lvdsenc.c
+++ b/drivers/gpu/drm/rcar-du/rcar_du_lvdsenc.c
@@ -151,7 +151,7 @@ static int rcar_du_lvdsenc_get_resources(struct rcar_du_lvdsenc *lvds,
 	}
 
 	lvds->mmio = devm_ioremap_resource(&pdev->dev, mem);
-	if (lvds->mmio == NULL) {
+	if (IS_ERR(lvds->mmio)) {
 		dev_err(&pdev->dev, "failed to remap memory resource for %s\n",
 			name);
 		return -ENOMEM;
-- 
1.8.3.4 (Apple Git-47)

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ