提交 c21709e7 编写于 作者: C Colin Ian King 提交者: David S. Miller

net: phy: dp83869: fix return of uninitialized variable ret

In the case where the call to phy_interface_is_rgmii returns zero
the variable ret is left uninitialized and this is returned at
the end of the function dp83869_configure_rgmii.  Fix this by
returning 0 instead of the uninitialized value in ret.

Addresses-Coverity: ("Uninitialized scalar variable")
Fixes: 01db923e ("net: phy: dp83869: Add TI dp83869 phy")
Signed-off-by: NColin Ian King <colin.king@canonical.com>
Reviewed-by: NAndrew Lunn <andrew@lunn.ch>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 3132174b
......@@ -239,7 +239,7 @@ static int dp83869_configure_rgmii(struct phy_device *phydev,
dp83869->io_impedance &
DP83869_IO_MUX_CFG_IO_IMPEDANCE_CTRL);
return ret;
return 0;
}
static int dp83869_configure_mode(struct phy_device *phydev,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册