Skip to content

Commit 38eef11

Browse files
fengidrikuba-moo
authored andcommitted
Revert "virtio_net: big mode skip the unmap check"
This reverts commit a377ae5. Signed-off-by: Xuan Zhuo <[email protected]> Acked-by: Michael S. Tsirkin <[email protected]> Tested-by: Takero Funaki <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent dc4547f commit 38eef11

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/net/virtio_net.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1006,7 +1006,7 @@ static void virtnet_rq_unmap_free_buf(struct virtqueue *vq, void *buf)
10061006
return;
10071007
}
10081008

1009-
if (!vi->big_packets || vi->mergeable_rx_bufs)
1009+
if (rq->do_dma)
10101010
virtnet_rq_unmap(rq, buf, 0);
10111011

10121012
virtnet_rq_free_buf(vi, rq, buf);
@@ -2716,7 +2716,7 @@ static int virtnet_receive_packets(struct virtnet_info *vi,
27162716
}
27172717
} else {
27182718
while (packets < budget &&
2719-
(buf = virtqueue_get_buf(rq->vq, &len)) != NULL) {
2719+
(buf = virtnet_rq_get_buf(rq, &len, NULL)) != NULL) {
27202720
receive_buf(vi, rq, buf, len, NULL, xdp_xmit, stats);
27212721
packets++;
27222722
}

0 commit comments

Comments
 (0)