]> www.infradead.org Git - users/dwmw2/linux.git/commit
virtio_net: enable premapped mode for merge and small by default
authorXuan Zhuo <xuanzhuo@linux.alibaba.com>
Tue, 29 Oct 2024 08:46:14 +0000 (16:46 +0800)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 5 Nov 2024 10:37:40 +0000 (11:37 +0100)
commit47008bb51c3e11c187dacc17af334bdca97c2dca
treea02b82d3a2ddb7199aad0efeb4f1ecafe5c439ac
parenta33f3df850750216f432b637a5020ad6a740cac1
virtio_net: enable premapped mode for merge and small by default

Currently, the virtio core will perform a dma operation for each
buffer. Although, the same page may be operated multiple times.

In premapped mod, we can perform only one dma operation for the pages of
the alloc frag. This is beneficial for the iommu device.

kernel command line: intel_iommu=on iommu.passthrough=0

       |  strict=0  | strict=1
Before |  775496pps | 428614pps
After  | 1109316pps | 742853pps

In the 6.11, we disabled this feature because a regress [1].

Now, we fix the problem and re-enable it.

[1]: http://lore.kernel.org/all/8b20cc28-45a9-4643-8e87-ba164a540c0a@oracle.com

Tested-by: Darren Kenny <darren.kenny@oracle.com>
Signed-off-by: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/virtio_net.c