Commit 5720c43
virtio_net: fix the missing of the dma cpu sync
Commit 295525e ("virtio_net: merge dma operations when filling
mergeable buffers") unmaps the buffer with DMA_ATTR_SKIP_CPU_SYNC when
the dma->ref is zero. We do that with DMA_ATTR_SKIP_CPU_SYNC, because we
do not want to do the sync for the entire page_frag. But that misses the
sync for the current area.
This patch does cpu sync regardless of whether the ref is zero or not.
Fixes: 295525e ("virtio_net: merge dma operations when filling mergeable buffers")
Reported-by: Michael Roth <michael.roth@amd.com>
Closes: http://lore.kernel.org/all/20230926130451.axgodaa6tvwqs3ut@amd.com
Signed-off-by: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>1 parent 11d3f72 commit 5720c43
1 file changed
+7
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
607 | 607 | | |
608 | 608 | | |
609 | 609 | | |
610 | | - | |
611 | | - | |
612 | | - | |
| 610 | + | |
| 611 | + | |
613 | 612 | | |
614 | | - | |
615 | | - | |
616 | | - | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
617 | 617 | | |
| 618 | + | |
618 | 619 | | |
619 | | - | |
620 | 620 | | |
621 | 621 | | |
622 | 622 | | |
| |||
0 commit comments