mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-08-30 12:13:51 -04:00
net: remove conditional return with no effect
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly. This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Link: https://patch.msgid.link/20260725150852.859188-4-ekffu200098@gmail.com Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
committed by
Paolo Abeni
parent
66084e9510
commit
cd833378ba
@@ -1028,11 +1028,7 @@ static int lan87xx_read_status(struct phy_device *phydev)
|
||||
if (rc < 0)
|
||||
return rc;
|
||||
|
||||
rc = genphy_read_status_fixed(phydev);
|
||||
if (rc < 0)
|
||||
return rc;
|
||||
|
||||
return rc;
|
||||
return genphy_read_status_fixed(phydev);
|
||||
}
|
||||
|
||||
static int lan87xx_config_aneg(struct phy_device *phydev)
|
||||
|
||||
@@ -1520,11 +1520,7 @@ static int tps23881_i2c_probe(struct i2c_client *client)
|
||||
"failed to register PSE controller\n");
|
||||
}
|
||||
|
||||
ret = tps23881_setup_irq(priv, client->irq);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
return ret;
|
||||
return tps23881_setup_irq(priv, client->irq);
|
||||
}
|
||||
|
||||
static const struct i2c_device_id tps23881_id[] = {
|
||||
|
||||
Reference in New Issue
Block a user