drivers: net: xgene: disable napi when register irq failed in xgene_enet_open()
PATCH 1/1 drivers: net: xgene: disable napi when register irq failed in xgene_enet_open()
When failed to register irq in xgene_enet_open() for opening device, napi isn't disabled. When open xgene device next time, it will reports a invalid opcode issue. Fix it. Only be compiled, not be tested.
Fixes aeb20b6b3f4e ("drivers: net: xgene: fix: ifconfig up/down crash")
Signed-off-by Zhengchao Shao <[email protected]>
--- drivers/net/ethernet/apm/xgene/xgene_enet_main.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/net/ethernet/apm/xgene/xgene_enet_main.c +3 -1
@@ -1004,8 +1004,10 @@ static int xgene_enet_open(struct net_device *ndev)xgene_enet_napi_enable (pdata); ret =xgene_enet_register_irq (ndev); -if (ret) +if (ret) { +xgene_enet_napi_disable (pdata);return ret; + }if (ndev->phydev) {phy_start (ndev->phydev);
Signature · 1 line
2.17.1
This patch was applied to netdev/net.git (master) by Paolo Abeni <[email protected]>:
Hello:
This patch was applied to netdev/net.git (master)
by Paolo Abeni <[email protected]>:
Quoted 8 lines · On Mon, 7 Nov 2022 12:30:32 +0800 you wrote:
When failed to register irq in
xgene_enet_open()for opening device, napi isn't disabled. When open xgene device next time, it will reports a invalid opcode issue. Fix it. Only be compiled, not be tested.Fixes aeb20b6b3f4e ("drivers: net: xgene: fix: ifconfig up/down crash")Signed-off-by Zhengchao Shao <[email protected]>[...]
Here is the summary with links:
- drivers: net: xgene: disable napi when register irq failed in xgene_enet_open()
https://git.kernel.org/netdev/net/c/ce9e57feeed8
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html