netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] virtio-net: Maintain reverse cleanup order
@ 2023-02-03 13:37 Parav Pandit
  2023-02-06  9:20 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 2+ messages in thread
From: Parav Pandit @ 2023-02-03 13:37 UTC (permalink / raw)
  To: mst, jasowang, davem, kuba, netdev
  Cc: edumazet, pabeni, ast, daniel, hawk, john.fastabend,
	virtualization, bpf, Parav Pandit, Jiri Pirko

To easily audit the code, better to keep the device stop()
sequence to be mirror of the device open() sequence.

Acked-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: Parav Pandit <parav@nvidia.com>
---
 drivers/net/virtio_net.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index b7d0b54c3bb0..1f8168e0f64d 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers/net/virtio_net.c
@@ -2279,9 +2279,9 @@ static int virtnet_close(struct net_device *dev)
 	cancel_delayed_work_sync(&vi->refill);
 
 	for (i = 0; i < vi->max_queue_pairs; i++) {
+		virtnet_napi_tx_disable(&vi->sq[i].napi);
 		napi_disable(&vi->rq[i].napi);
 		xdp_rxq_info_unreg(&vi->rq[i].xdp_rxq);
-		virtnet_napi_tx_disable(&vi->sq[i].napi);
 	}
 
 	return 0;
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH net-next] virtio-net: Maintain reverse cleanup order
  2023-02-03 13:37 [PATCH net-next] virtio-net: Maintain reverse cleanup order Parav Pandit
@ 2023-02-06  9:20 ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2023-02-06  9:20 UTC (permalink / raw)
  To: Parav Pandit
  Cc: mst, jasowang, davem, kuba, netdev, edumazet, pabeni, ast, daniel,
	hawk, john.fastabend, virtualization, bpf, jiri

Hello:

This patch was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:

On Fri, 3 Feb 2023 15:37:38 +0200 you wrote:
> To easily audit the code, better to keep the device stop()
> sequence to be mirror of the device open() sequence.
> 
> Acked-by: Michael S. Tsirkin <mst@redhat.com>
> Reviewed-by: Jiri Pirko <jiri@nvidia.com>
> Signed-off-by: Parav Pandit <parav@nvidia.com>
> 
> [...]

Here is the summary with links:
  - [net-next] virtio-net: Maintain reverse cleanup order
    https://git.kernel.org/netdev/net-next/c/27369c9c2b72

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:[~2023-02-06  9:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-03 13:37 [PATCH net-next] virtio-net: Maintain reverse cleanup order Parav Pandit
2023-02-06  9:20 ` 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).