]> git.baikalelectronics.ru Git - kernel.git/commit
net: sparx5: fix error return code in sparx5_register_notifier_blocks()
authorYang Yingliang <yangyingliang@huawei.com>
Sat, 26 Jun 2021 04:44:20 +0000 (12:44 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 28 Jun 2021 21:20:23 +0000 (14:20 -0700)
commit77a912c2634be2883fe57fa830b233ea91b83eb7
tree7d8f76825cc9361a0c55ca87288120240d706b33
parent22ade1b851e1ce291266908e181308d3f9e050d3
net: sparx5: fix error return code in sparx5_register_notifier_blocks()

Fix to return a negative error code from the error handling
case instead of 0, as done elsewhere in this function.

Fixes: 3800980e8a20 ("net: sparx5: add switching support")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/microchip/sparx5/sparx5_switchdev.c