diff options
author | Dan Carpenter <error27@gmail.com> | 2023-02-15 07:21:47 +0300 |
---|---|---|
committer | Minda Chen <minda.chen@starfivetech.com> | 2024-01-11 13:59:00 +0300 |
commit | b95bcbb4d335af9830041fd07ec1f2c8a2b83abb (patch) | |
tree | 4fbd169a898d7a36ca624e3816890c60fe8e03ea | |
parent | ea48948699e354a65fcd8671f1115dd52e9c9692 (diff) | |
download | linux-b95bcbb4d335af9830041fd07ec1f2c8a2b83abb.tar.xz |
net: phy: motorcomm: uninitialized variables in yt8531_link_change_notify()
These booleans are never set to false, but are just used without being
initialized.
Fixes: 4ac94f728a58 ("net: phy: Add driver for Motorcomm yt8531 gigabit ethernet phy")
Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Frank Sae <Frank.Sae@motor-comm.com>
Link: https://lore.kernel.org/r/Y+xd2yJet2ImHLoQ@kili
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
-rw-r--r-- | drivers/net/phy/motorcomm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/phy/motorcomm.c b/drivers/net/phy/motorcomm.c index ee7c37dfdca0..2fa5a90e073b 100644 --- a/drivers/net/phy/motorcomm.c +++ b/drivers/net/phy/motorcomm.c @@ -1533,10 +1533,10 @@ static int yt8531_config_init(struct phy_device *phydev) static void yt8531_link_change_notify(struct phy_device *phydev) { struct device_node *node = phydev->mdio.dev.of_node; + bool tx_clk_1000_inverted = false; + bool tx_clk_100_inverted = false; + bool tx_clk_10_inverted = false; bool tx_clk_adj_enabled = false; - bool tx_clk_1000_inverted; - bool tx_clk_100_inverted; - bool tx_clk_10_inverted; u16 val = 0; int ret; |