Skip to content

Commit

Permalink
net: ethernet: sun: remove redundant assignment to variable err
Browse files Browse the repository at this point in the history
The variable err is being assigned with a value that is never
read and it is being updated in the next statement with a new value.
The assignment is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Colin Ian King authored and David S. Miller committed Jul 4, 2019
1 parent a51df9f commit 2368a87
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions drivers/net/ethernet/sun/niu.c
Original file line number Diff line number Diff line change
Expand Up @@ -1217,8 +1217,6 @@ static int link_status_1g_rgmii(struct niu *np, int *link_up_p)

spin_lock_irqsave(&np->lock, flags);

err = -EINVAL;

err = mii_read(np, np->phy_addr, MII_BMSR);
if (err < 0)
goto out;
Expand Down

0 comments on commit 2368a87

Please sign in to comment.