net: marvell: prestera: uninitialized variable bug
The "ret" variable needs to be initialized at the start.
Fixes: 52323ef754
("net: marvell: prestera: add phylink support")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/YuKeBBuGtsmd7QdT@kili
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
0f14a8351a
commit
71930846b3
|
@ -847,7 +847,7 @@ static void prestera_event_handlers_unregister(struct prestera_switch *sw)
|
|||
static int prestera_switch_set_base_mac_addr(struct prestera_switch *sw)
|
||||
{
|
||||
struct device_node *base_mac_np;
|
||||
int ret;
|
||||
int ret = 0;
|
||||
|
||||
if (sw->np) {
|
||||
base_mac_np = of_parse_phandle(sw->np, "base-mac-provider", 0);
|
||||
|
|
Loading…
Reference in New Issue