android_kernel_sony_sdm845/drivers/vfio
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Schspa Shi 62a50c36d4 vfio: Clear the caps->buf to NULL after free
[ Upstream commit 6641085e8d7b3f061911517f79a2a15a0a21b97b ]

On buffer resize failure, vfio_info_cap_add() will free the buffer,
report zero for the size, and return -ENOMEM.  As additional
hardening, also clear the buffer pointer to prevent any chance of a
double free.

Signed-off-by: Schspa Shi <schspa@gmail.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Link: https://lore.kernel.org/r/20220629022948.55608-1-schspa@gmail.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-08-25 11:09:31 +02:00
..
pci vfio/pci: zap_vma_ptes() needs MMU 2021-06-10 12:42:35 +02:00
platform vfio/platform: fix module_put call in error flow 2021-06-10 12:42:35 +02:00
Kconfig vfio: Use config not menuconfig for VFIO_NOIOMMU 2021-09-22 11:43:04 +02:00
Makefile vfio: Split virqfd into a separate module for vfio bus drivers 2015-03-17 08:33:38 -06:00
vfio.c vfio: Clear the caps->buf to NULL after free 2022-08-25 11:09:31 +02:00
vfio_iommu_spapr_tce.c vfio/spapr_tce: Get rid of possible infinite loop 2019-12-05 15:34:47 +01:00
vfio_iommu_type1.c vfio/type1: Support faulting PFNMAP vmas 2020-09-12 11:47:37 +02:00
vfio_spapr_eeh.c drivers/vfio: Support EEH error injection 2015-05-12 20:33:35 +10:00
virqfd.c vfio: Split virqfd into a separate module for vfio bus drivers 2015-03-17 08:33:38 -06:00