Commit 799a8295 authored by Andy Chiu's avatar Andy Chiu Committed by David S. Miller

net: axienet: start napi before enabling Rx/Tx

softirq may get lost if an Rx interrupt comes before we call
napi_enable. Move napi_enable in front of axienet_setoptions(), which
turns on the device, to address the issue.

Link: https://lists.gnu.org/archive/html/qemu-devel/2024-07/msg06160.html
Fixes: cc37610c ("net: axienet: implement NAPI and GRO receive")
Signed-off-by: default avatarAndy Chiu <andy.chiu@sifive.com>
Reviewed-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 05f76b2d
...@@ -2219,9 +2219,9 @@ static void axienet_dma_err_handler(struct work_struct *work) ...@@ -2219,9 +2219,9 @@ static void axienet_dma_err_handler(struct work_struct *work)
~(XAE_OPTION_TXEN | XAE_OPTION_RXEN)); ~(XAE_OPTION_TXEN | XAE_OPTION_RXEN));
axienet_set_mac_address(ndev, NULL); axienet_set_mac_address(ndev, NULL);
axienet_set_multicast_list(ndev); axienet_set_multicast_list(ndev);
axienet_setoptions(ndev, lp->options);
napi_enable(&lp->napi_rx); napi_enable(&lp->napi_rx);
napi_enable(&lp->napi_tx); napi_enable(&lp->napi_tx);
axienet_setoptions(ndev, lp->options);
} }
/** /**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment