phylink: Fix an uninitialized variable bug
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 9 Aug 2017 21:35:50 +0000 (00:35 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 11 Aug 2017 20:58:01 +0000 (13:58 -0700)
"ret" isn't necessarily initialized here.

Fixes: 9525ae83959b ("phylink: add phylink infrastructure")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/phylink.c

index 32917bdd1432d9de77e72e6b66f84f9a3207bb92..bcb4755bcd957d3450d64fc063dd2c37587f570e 100644 (file)
@@ -958,7 +958,7 @@ int phylink_ethtool_ksettings_set(struct phylink *pl,
        }
        mutex_unlock(&pl->state_mutex);
 
-       return ret;
+       return 0;
 }
 EXPORT_SYMBOL_GPL(phylink_ethtool_ksettings_set);