From: Changcheng Deng Date: Thu, 16 Dec 2021 09:13:39 +0000 (+0000) Subject: net: dsa: microchip: remove unneeded variable X-Git-Tag: v5.17-rc1~170^2~166 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=86df8be67f6ca85d14fd469f1d1bcc3eee8f713e;p=tomoyo%2Ftomoyo-test1.git net: dsa: microchip: remove unneeded variable Remove unneeded variable used to store return value. Reported-by: Zeal Robot Signed-off-by: Changcheng Deng Signed-off-by: David S. Miller --- diff --git a/drivers/net/dsa/microchip/ksz_common.c b/drivers/net/dsa/microchip/ksz_common.c index 47a856533cff..55dbda04ea62 100644 --- a/drivers/net/dsa/microchip/ksz_common.c +++ b/drivers/net/dsa/microchip/ksz_common.c @@ -302,7 +302,6 @@ int ksz_port_mdb_del(struct dsa_switch *ds, int port, struct ksz_device *dev = ds->priv; struct alu_struct alu; int index; - int ret = 0; for (index = 0; index < dev->num_statics; index++) { if (!dev->dev_ops->r_sta_mac_table(dev, index, &alu)) { @@ -324,7 +323,7 @@ int ksz_port_mdb_del(struct dsa_switch *ds, int port, dev->dev_ops->w_sta_mac_table(dev, index, &alu); exit: - return ret; + return 0; } EXPORT_SYMBOL_GPL(ksz_port_mdb_del);