linux/drivers/vfio/pci
Matt Evans 702809dabd vfio/pci: Check BAR resources before exporting a DMABUF
A DMABUF exports access to BAR resources and, although they are
requested at startup time, we need to ensure they really were reserved
before exporting.  Otherwise, it's possible to access unreserved
resources through the export.

Add a check to the DMABUF-creation path.

Fixes: 5d74781ebc ("vfio/pci: Add dma-buf export support for MMIO regions")
Signed-off-by: Matt Evans <mattev@meta.com>
Link: https://lore.kernel.org/r/20260511145829.2993601-3-mattev@meta.com
Signed-off-by: Alex Williamson <alex@shazbot.org>
History 2026-05-14 11:39:03 -06:00
..
hisilicon vfio: Adapt drivers to use the core helper vfio_check_precopy_ioctl 2026-03-19 12:32:09 -06:00
ism vfio/ism: Implement vfio_pci driver for ISM devices 2026-04-01 15:51:21 -06:00
mlx5 vfio/mlx5: Add REINIT support to VFIO_MIG_GET_PRECOPY_INFO 2026-03-19 12:32:10 -06:00
nvgrace-gpu * Reuse common phys_vec, phase out dma_buf_phys_vec 2026-01-19 10:25:24 -07:00
pds Convert more 'alloc_obj' cases to default GFP_KERNEL arguments 2026-02-21 20:03:00 -08:00
qat vfio/qat: add support for Intel QAT 420xx VFs 2026-03-23 16:18:18 -06:00
virtio vfio/virtio: Use guard() for bar_mutex in legacy I/O 2026-04-21 12:01:21 -06:00
xe VFIO updates for v7.1-rc1 2026-04-16 08:01:16 -07:00
Kconfig vfio/ism: Implement vfio_pci driver for ISM devices 2026-04-01 15:51:21 -06:00
Makefile vfio/ism: Implement vfio_pci driver for ISM devices 2026-04-01 15:51:21 -06:00
trace.h vfio/pci: Cleanup license mess 2019-01-22 11:06:05 -07:00
vfio_pci.c [v9] vfio/pci: Allow MMIO regions to be exported through dma-buf 2025-11-20 21:20:00 -07:00
vfio_pci_config.c vfio/pci: Rename vfio_config_do_rw() to vfio_pci_config_rw_single() and export it 2026-04-01 15:41:02 -06:00
vfio_pci_core.c vfio/pci: Set up BAR resources and maps in vfio_pci_core_enable() 2026-05-14 11:38:04 -06:00
vfio_pci_dmabuf.c vfio/pci: Check BAR resources before exporting a DMABUF 2026-05-14 11:39:03 -06:00
vfio_pci_igd.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
vfio_pci_intrs.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
vfio_pci_priv.h vfio/pci: Rename vfio_config_do_rw() to vfio_pci_config_rw_single() and export it 2026-04-01 15:41:02 -06:00
vfio_pci_rdwr.c vfio/pci: Set up BAR resources and maps in vfio_pci_core_enable() 2026-05-14 11:38:04 -06:00
vfio_pci_zdev.c Merge remote-tracking branch 'mlx5/mlx5-vfio' into v6.1/vfio/next 2022-09-08 10:44:34 -06:00