diff options
author | Daniel Jordan <daniel.m.jordan@oracle.com> | 2021-03-08 18:24:52 +0100 |
---|---|---|
committer | Alex Williamson <alex.williamson@redhat.com> | 2021-03-16 17:39:29 +0100 |
commit | 4ab4fcfce5b540227d80eb32f1db45ab615f7c92 (patch) | |
tree | 16a732b5116123ebacb1e4da4b385b887e008e6f /include | |
parent | vfio: Depend on MMU (diff) | |
download | linux-4ab4fcfce5b540227d80eb32f1db45ab615f7c92.tar.xz linux-4ab4fcfce5b540227d80eb32f1db45ab615f7c92.zip |
vfio/type1: fix vaddr_get_pfns() return in vfio_pin_page_external()
vaddr_get_pfns() now returns the positive number of pfns successfully
gotten instead of zero. vfio_pin_page_external() might return 1 to
vfio_iommu_type1_pin_pages(), which will treat it as an error, if
vaddr_get_pfns() is successful but vfio_pin_page_external() doesn't
reach vfio_lock_acct().
Fix it up in vfio_pin_page_external(). Found by inspection.
Fixes: be16c1fd99f4 ("vfio/type1: Change success value of vaddr_get_pfn()")
Signed-off-by: Daniel Jordan <daniel.m.jordan@oracle.com>
Message-Id: <20210308172452.38864-1-daniel.m.jordan@oracle.com>
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions