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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160324120354.GA19673@lkp-ne04.intel.com>
Date:	Thu, 24 Mar 2016 20:03:54 +0800
From:	kbuild test robot <lkp@...el.com>
To:	Enric Balletbo i Serra <enric.balletbo@...labora.com>
Cc:	kbuild-all@...org, devicetree@...r.kernel.org,
	linux-kernel@...r.kernel.org, dri-devel@...ts.freedesktop.org,
	devel@...verdev.osuosl.org, treding@...dia.com, robh+dt@...nel.org,
	pawel.moll@....com, mark.rutland@....com,
	ijc+devicetree@...lion.org.uk, galak@...eaurora.org,
	airlied@...ux.ie, gregkh@...uxfoundation.org,
	sjoerd.simons@...labora.co.uk, javier@...hile0.org,
	span@...logixsemi.com, nathan.chung@...iatek.com,
	djkurtz@...omium.org, drinkcat@...omium.org,
	laurent.pinchart@...asonboard.com, dan.carpenter@...cle.com,
	jb.tsai@...iatek.com, cawa.cheng@...iatek.com,
	eddie.huang@...iatek.com, cjiao@...logixsemi.com,
	emil.l.velikov@...il.com
Subject: [PATCH] drm: bridge: anx78xx: fix ptr_ret.cocci warnings

drivers/gpu/drm/bridge/anx78xx.c:632:1-3: WARNING: PTR_ERR_OR_ZERO can be used


 Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR

Generated by: scripts/coccinelle/api/ptr_ret.cocci

CC: Enric Balletbo i Serra <enric.balletbo@...labora.com>
Signed-off-by: Fengguang Wu <fengguang.wu@...el.com>
---

 anx78xx.c |    5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

--- a/drivers/gpu/drm/bridge/anx78xx.c
+++ b/drivers/gpu/drm/bridge/anx78xx.c
@@ -629,10 +629,7 @@ static int anx78xx_init_gpio(struct anx7
 
 	/* GPIO for V10 power control */
 	pdata->gpiod_v10 = devm_gpiod_get_optional(dev, "v10", GPIOD_OUT_LOW);
-	if (IS_ERR(pdata->gpiod_v10))
-		return PTR_ERR(pdata->gpiod_v10);
-
-	return 0;
+	return PTR_ERR_OR_ZERO(pdata->gpiod_v10);
 }
 
 static int anx78xx_dp_link_training(struct anx78xx *anx78xx)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ