提交 4b97f8e1 编写于 作者: D Dan Carpenter 提交者: David S. Miller

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: NDan Carpenter <error27@gmail.com>
Acked-by: NEilon Greenstein <eilong@broadcom.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 70978182
...@@ -354,9 +354,6 @@ u8 bnx2x_ets_strict(const struct link_params *params, const u8 strict_cos) ...@@ -354,9 +354,6 @@ u8 bnx2x_ets_strict(const struct link_params *params, const u8 strict_cos)
struct bnx2x *bp = params->bp; struct bnx2x *bp = params->bp;
u32 val = 0; u32 val = 0;
if ((1 < strict_cos) && (NULL == params))
return -EINVAL;
DP(NETIF_MSG_LINK, "ETS enabled strict configuration\n"); DP(NETIF_MSG_LINK, "ETS enabled strict configuration\n");
/** /**
* Bitmap of 5bits length. Each bit specifies whether the entry behaves * Bitmap of 5bits length. Each bit specifies whether the entry behaves
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册