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: <20101221070401.GF1936@bicker>
Date:	Tue, 21 Dec 2010 10:04:02 +0300
From:	Dan Carpenter <error27@...il.com>
To:	Eilon Greenstein <eilong@...adcom.com>
Cc:	netdev@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: [patch -next] bnx2x: remove bogus check

We dereferenced params on the line before so it's too late to check if
params is NULL.  In fact, params can never be NULL and strict_cos is
either 0 or 1 so that part of the check is bogus too.  Let's remove it.

Signed-off-by: Dan Carpenter <error27@...il.com>

diff --git a/drivers/net/bnx2x/bnx2x_link.c b/drivers/net/bnx2x/bnx2x_link.c
index 97cbee2..43b0de2 100644
--- a/drivers/net/bnx2x/bnx2x_link.c
+++ b/drivers/net/bnx2x/bnx2x_link.c
@@ -354,9 +354,6 @@ u8 bnx2x_ets_strict(const struct link_params *params, const u8 strict_cos)
 	struct bnx2x *bp = params->bp;
 	u32 val	= 0;
 
-	if ((1 < strict_cos) && (NULL == params))
-		return -EINVAL;
-
 	DP(NETIF_MSG_LINK, "ETS enabled strict configuration\n");
 	/**
 	 * Bitmap of 5bits length. Each bit specifies whether the entry behaves
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ