diff options
author | Yi Liu <yi.l.liu@intel.com> | 2023-07-18 15:55:28 +0200 |
---|---|---|
committer | Alex Williamson <alex.williamson@redhat.com> | 2023-07-25 18:18:28 +0200 |
commit | 34aeeecdb3357f9ca5aea549525a17790d1c427d (patch) | |
tree | ae473844ad815720d5fee8db5f2d3361c5e17982 /arch/sparc | |
parent | vfio: Refine vfio file kAPIs for KVM (diff) | |
download | linux-34aeeecdb3357f9ca5aea549525a17790d1c427d.tar.xz linux-34aeeecdb3357f9ca5aea549525a17790d1c427d.zip |
vfio: Accept vfio device file in the KVM facing kAPI
This makes the vfio file kAPIs to accept vfio device files, also a
preparation for vfio device cdev support.
For the kvm set with vfio device file, kvm pointer is stored in struct
vfio_device_file, and use kvm_ref_lock to protect kvm set and kvm
pointer usage within VFIO. This kvm pointer will be set to vfio_device
after device file is bound to iommufd in the cdev path.
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Tested-by: Terrence Xu <terrence.xu@intel.com>
Tested-by: Nicolin Chen <nicolinc@nvidia.com>
Tested-by: Matthew Rosato <mjrosato@linux.ibm.com>
Tested-by: Yanting Jiang <yanting.jiang@intel.com>
Tested-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Tested-by: Zhenzhong Duan <zhenzhong.duan@intel.com>
Signed-off-by: Yi Liu <yi.l.liu@intel.com>
Link: https://lore.kernel.org/r/20230718135551.6592-4-yi.l.liu@intel.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Diffstat (limited to 'arch/sparc')
0 files changed, 0 insertions, 0 deletions