summaryrefslogtreecommitdiff
path: root/tools/include
diff options
context:
space:
mode:
authorCindy Lu <lulu@redhat.com>2023-04-20 18:17:34 +0300
committerMichael S. Tsirkin <mst@redhat.com>2023-04-21 10:02:36 +0300
commitc82729e06644f4e087f5ff0f91b8fb15e03b8890 (patch)
tree754f2344eb28b424db35761eba6a367c88948f16 /tools/include
parent11841c52fa525c9be17c0731cc897d93c3c0f4fe (diff)
downloadlinux-c82729e06644f4e087f5ff0f91b8fb15e03b8890.tar.xz
vhost_vdpa: fix unmap process in no-batch mode
While using the vdpa device with vIOMMU enabled in the guest VM, when the vdpa device bind to vfio-pci and run testpmd then system will fail to unmap. The test process is Load guest VM --> attach to virtio driver--> bind to vfio-pci driver So the mapping process is 1)batched mode map to normal MR 2)batched mode unmapped the normal MR 3)unmapped all the memory 4)mapped to iommu MR This error happened in step 3). The iotlb was freed in step 2) and the function vhost_vdpa_process_iotlb_msg will return fail Which causes failure. To fix this, we will not remove the AS while the iotlb->nmaps is 0. This will free in the vhost_vdpa_clean Cc: stable@vger.kernel.org Fixes: aaca8373c4b1 ("vhost-vdpa: support ASID based IOTLB API") Signed-off-by: Cindy Lu <lulu@redhat.com> Message-Id: <20230420151734.860168-1-lulu@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'tools/include')
0 files changed, 0 insertions, 0 deletions