Re: [Intel-gfx] [PATCH v4 9/9] vfio/pci: Allow passing zero-length fd array in VFIO_DEVICE_PCI_HOT_RESET

2023-05-02 Thread Liu, Yi L
> From: Alex Williamson > Sent: Friday, April 28, 2023 5:55 AM > > On Wed, 26 Apr 2023 07:54:19 -0700 > Yi Liu wrote: > > > This is the way user to invoke hot-reset for the devices opened by cdev > > interface. User should check the flag VFIO_PCI_HOT_RESET_FLAG_RESETTABLE > > in the output of V

Re: [Intel-gfx] [PATCH v4 9/9] vfio/pci: Allow passing zero-length fd array in VFIO_DEVICE_PCI_HOT_RESET

2023-04-27 Thread Alex Williamson
On Wed, 26 Apr 2023 07:54:19 -0700 Yi Liu wrote: > This is the way user to invoke hot-reset for the devices opened by cdev > interface. User should check the flag VFIO_PCI_HOT_RESET_FLAG_RESETTABLE > in the output of VFIO_DEVICE_GET_PCI_HOT_RESET_INFO ioctl before doing > hot-reset for cdev devic

Re: [Intel-gfx] [PATCH v4 9/9] vfio/pci: Allow passing zero-length fd array in VFIO_DEVICE_PCI_HOT_RESET

2023-04-27 Thread Liu, Yi L
> From: Tian, Kevin > Sent: Thursday, April 27, 2023 2:54 PM > > > From: Liu, Yi L > > Sent: Wednesday, April 26, 2023 10:54 PM > > > > +static bool vfio_dev_in_iommufd_ctx(struct vfio_pci_core_device *vdev, > > + struct iommufd_ctx *iommufd_ctx) > > +{ > > + stru

Re: [Intel-gfx] [PATCH v4 9/9] vfio/pci: Allow passing zero-length fd array in VFIO_DEVICE_PCI_HOT_RESET

2023-04-26 Thread Tian, Kevin
> From: Liu, Yi L > Sent: Wednesday, April 26, 2023 10:54 PM > > +static bool vfio_dev_in_iommufd_ctx(struct vfio_pci_core_device *vdev, > + struct iommufd_ctx *iommufd_ctx) > +{ > + struct iommufd_ctx *iommufd = vfio_iommufd_physical_ictx(&vdev- > >vdev); > +

[Intel-gfx] [PATCH v4 9/9] vfio/pci: Allow passing zero-length fd array in VFIO_DEVICE_PCI_HOT_RESET

2023-04-26 Thread Yi Liu
This is the way user to invoke hot-reset for the devices opened by cdev interface. User should check the flag VFIO_PCI_HOT_RESET_FLAG_RESETTABLE in the output of VFIO_DEVICE_GET_PCI_HOT_RESET_INFO ioctl before doing hot-reset for cdev devices. Suggested-by: Jason Gunthorpe Signed-off-by: Jason Gu