RE: [PATCH v8 08/11] vfio/pci: Share the core device pointer while invoking feature functions

Tian, Kevin
2025-11-18T07:11:32Z

> From: Leon Romanovsky <leon@kernel.org>
> Sent: Tuesday, November 11, 2025 5:58 PM
>
> From: Vivek Kasireddy <vivek.kasireddy@intel.com>
>
> There is no need to share the main device pointer (struct vfio_device *)
> with all the feature functions as they only need the core device
> pointer. Therefore, extract the core device pointer once in the
> caller (vfio_pci_core_ioctl_feature) and share it instead.
>
> Signed-off-by: Vivek Kasireddy <vivek.kasireddy@intel.com>
> Tested-by: Alex Mastro <amastro@fb.com>
> Tested-by: Nicolin Chen <nicolinc@nvidia.com>
> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>

Reviewed-by: Kevin Tian <kevin.tian@intel.com>