* [PATCH -next] octeon_ep: fix error return code in octep_probe()
@ 2022-04-15 2:39 Yang Yingliang
2022-04-15 10:50 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: Yang Yingliang @ 2022-04-15 2:39 UTC (permalink / raw)
To: linux-kernel, netdev; +Cc: vburru, aayarekar, sburla, davem
If register_netdev() fails , it should return error
code in octep_probe().
Fixes: 862cd659a6fb ("octeon_ep: Add driver framework and device initialization")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
drivers/net/ethernet/marvell/octeon_ep/octep_main.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/marvell/octeon_ep/octep_main.c b/drivers/net/ethernet/marvell/octeon_ep/octep_main.c
index 5d39c857ea41..f2af5ebffcf1 100644
--- a/drivers/net/ethernet/marvell/octeon_ep/octep_main.c
+++ b/drivers/net/ethernet/marvell/octeon_ep/octep_main.c
@@ -1071,7 +1071,8 @@ static int octep_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
octep_get_mac_addr(octep_dev, octep_dev->mac_addr);
eth_hw_addr_set(netdev, octep_dev->mac_addr);
- if (register_netdev(netdev)) {
+ err = register_netdev(netdev);
+ if (err) {
dev_err(&pdev->dev, "Failed to register netdev\n");
goto register_dev_err;
}
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH -next] octeon_ep: fix error return code in octep_probe()
2022-04-15 2:39 [PATCH -next] octeon_ep: fix error return code in octep_probe() Yang Yingliang
@ 2022-04-15 10:50 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-04-15 10:50 UTC (permalink / raw)
To: Yang Yingliang; +Cc: linux-kernel, netdev, vburru, aayarekar, sburla, davem
Hello:
This patch was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:
On Fri, 15 Apr 2022 10:39:57 +0800 you wrote:
> If register_netdev() fails , it should return error
> code in octep_probe().
>
> Fixes: 862cd659a6fb ("octeon_ep: Add driver framework and device initialization")
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
>
> [...]
Here is the summary with links:
- [-next] octeon_ep: fix error return code in octep_probe()
https://git.kernel.org/netdev/net-next/c/0a03f3c511f5
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-04-15 10:50 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-04-15 2:39 [PATCH -next] octeon_ep: fix error return code in octep_probe() Yang Yingliang
2022-04-15 10:50 ` patchwork-bot+netdevbpf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).