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]
Date:	Tue, 12 Feb 2013 05:01:49 +0100
From:	Cyril Roelandt <tipecaml@...il.com>
To:	linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org
Cc:	Cyril Roelandt <tipecaml@...il.com>, airlied@...ux.ie,
	alexander.deucher@....com, paulmck@...ux.vnet.ibm.com,
	dhowells@...hat.com, mattst88@...il.com,
	dri-devel@...ts.freedesktop.org
Subject: [PATCH 1/5] radeon: Remove redundant NULL check before radeon_i2c_destroy().

radeon_i2c_destroy on a NULL pointer is a no-op.

Signed-off-by: Cyril Roelandt <tipecaml@...il.com>
---
 drivers/gpu/drm/radeon/radeon_i2c.c |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/radeon/radeon_i2c.c b/drivers/gpu/drm/radeon/radeon_i2c.c
index fc60b74..850df44 100644
--- a/drivers/gpu/drm/radeon/radeon_i2c.c
+++ b/drivers/gpu/drm/radeon/radeon_i2c.c
@@ -1032,10 +1032,8 @@ void radeon_i2c_fini(struct radeon_device *rdev)
 	int i;
 
 	for (i = 0; i < RADEON_MAX_I2C_BUS; i++) {
-		if (rdev->i2c_bus[i]) {
-			radeon_i2c_destroy(rdev->i2c_bus[i]);
-			rdev->i2c_bus[i] = NULL;
-		}
+		radeon_i2c_destroy(rdev->i2c_bus[i]);
+		rdev->i2c_bus[i] = NULL;
 	}
 }
 
-- 
1.7.10.4

--
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