]> git.baikalelectronics.ru Git - kernel.git/commit
qlcnic: remove redundant zero check on retries counter
authorColin Ian King <colin.king@canonical.com>
Fri, 1 Sep 2017 13:44:31 +0000 (14:44 +0100)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 Sep 2017 17:33:55 +0000 (10:33 -0700)
commita06ce60516e9b0ba8c5c3a2932213e521c487659
treeaae18b94c6678d7ef42f471da674d0046ae4785e
parent9c253605591b974b3d1fad1baa8edf673fb1082c
qlcnic: remove redundant zero check on retries counter

At the end of the do while loop the integer counter retries will
always be zero and so the subsequent check to see if it is zero
is always true and therefore redundant.  Remove the redundant check
and always return -EIO on this return path.  Also unbreak the literal
string in dev_err message to clean up a checkpatch warning.

Detected by CoverityScan, CID#744279 ("Logically dead code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qlcnic/qlcnic_init.c