linux/drivers/vdpa
Linus Torvalds 05fb07c40e vdpa_sim: disable page faults around vringh_need_notify_iotlb()
When vdpa_sim runs with use_va (the default), its rings live in user
memory, and vringh reads the ring's flags and event index with
__get_user() through the user address.  The net and block simulators
call vringh_need_notify_iotlb() with bottom halves disabled, so those
reads happen in atomic context.

That only works today because __get_user() has no might_fault() check: a
fault is not handled in atomic context and simply comes back as -EFAULT.
Make that explicit with pagefault_disable() around the call, so vringh
can use the normal user accessors without complaint.  Only the
notification check needs this: the rest of the ring processing runs in
the same kthread without bottom halves disabled, and can fault normally.

Tested-and-acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-10-20 08:05:08 -10:00
..
alibaba vdpa: alibaba: Keep DRIVER_OK clear if IRQ setup fails 2026-09-07 18:54:02 -04:00
ifcvf vdpa: ifcvf: Put device on unsupported feature error 2026-09-07 18:54:02 -04:00
mlx5 vdpa/mlx5: roll back MR update after VQ setup failure 2026-08-19 06:38:47 -04:00
octeon_ep vdpa: octeon_ep: Check dev_set_name() in dev add 2026-09-07 18:54:03 -04:00
pds vdpa/pds: check virtqueue notify mapping 2026-09-07 18:54:02 -04:00
solidrun vdpa: solidrun: Free IRQs after request failure 2026-09-07 18:54:02 -04:00
vdpa_sim vdpa_sim: disable page faults around vringh_need_notify_iotlb() 2026-10-20 08:05:08 -10:00
vdpa_user vduse: return compat ioctl results directly 2026-09-08 03:58:27 -04:00
virtio_pci vdpa: Remove redundant dev_err() 2026-08-19 06:38:47 -04:00
Kconfig vduse: switch to use virtio map API instead of DMA API 2025-10-01 07:24:55 -04:00
Makefile virtio: vdpa: vDPA driver for Marvell OCTEON DPU devices 2024-07-09 08:42:39 -04:00
vdpa.c Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00