diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2024-08-06 19:58:28 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2024-08-06 19:58:28 +0200 |
commit | d4560686726f7a357922f300fc81f5964be8df04 (patch) | |
tree | 94ab45832b29ccc4289150428455b42c289f3175 | |
parent | Merge tag 'platform-drivers-x86-v6.11-2' of git://git.kernel.org/pub/scm/linu... (diff) | |
parent | vhost-vdpa: switch to use vmf_insert_pfn() in the fault handler (diff) | |
download | linux-d4560686726f7a357922f300fc81f5964be8df04.tar.xz linux-d4560686726f7a357922f300fc81f5964be8df04.zip |
Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
Pull virtio fix from Michael Tsirkin:
"Fix a single, long-standing issue with kick pass-through vdpa"
* tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost:
vhost-vdpa: switch to use vmf_insert_pfn() in the fault handler
-rw-r--r-- | drivers/vhost/vdpa.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c index e31ec9ebc4ce..478cd46a49ed 100644 --- a/drivers/vhost/vdpa.c +++ b/drivers/vhost/vdpa.c @@ -1481,13 +1481,7 @@ static vm_fault_t vhost_vdpa_fault(struct vm_fault *vmf) notify = ops->get_vq_notification(vdpa, index); - vma->vm_page_prot = pgprot_noncached(vma->vm_page_prot); - if (remap_pfn_range(vma, vmf->address & PAGE_MASK, - PFN_DOWN(notify.addr), PAGE_SIZE, - vma->vm_page_prot)) - return VM_FAULT_SIGBUS; - - return VM_FAULT_NOPAGE; + return vmf_insert_pfn(vma, vmf->address & PAGE_MASK, PFN_DOWN(notify.addr)); } static const struct vm_operations_struct vhost_vdpa_vm_ops = { |