Lines Matching refs:device

10 #include <linux/device.h>
20 struct vfio_device *device;
30 void vfio_device_put_registration(struct vfio_device *device);
31 bool vfio_device_try_get_registration(struct vfio_device *device);
35 vfio_allocate_device_file(struct vfio_device *device);
47 * Physical device with IOMMU backing.
52 * Virtual device without IOMMU backing. The VFIO core fakes up an
60 * Physical device without IOMMU backing. The VFIO core fakes up an
62 * userspace ABI. Users can trigger unmediated DMA by the device,
71 struct device dev;
74 * When drivers is non-zero a driver is attached to the struct device
99 int vfio_device_block_group(struct vfio_device *device);
100 void vfio_device_unblock_group(struct vfio_device *device);
101 int vfio_device_set_group(struct vfio_device *device,
103 void vfio_device_remove_group(struct vfio_device *device);
104 void vfio_device_group_register(struct vfio_device *device);
105 void vfio_device_group_unregister(struct vfio_device *device);
106 int vfio_device_group_use_iommu(struct vfio_device *device);
107 void vfio_device_group_unuse_iommu(struct vfio_device *device);
112 bool vfio_device_has_container(struct vfio_device *device);
124 static inline int vfio_device_block_group(struct vfio_device *device)
129 static inline void vfio_device_unblock_group(struct vfio_device *device)
133 static inline int vfio_device_set_group(struct vfio_device *device,
139 static inline void vfio_device_remove_group(struct vfio_device *device)
143 static inline void vfio_device_group_register(struct vfio_device *device)
147 static inline void vfio_device_group_unregister(struct vfio_device *device)
151 static inline int vfio_device_group_use_iommu(struct vfio_device *device)
156 static inline void vfio_device_group_unuse_iommu(struct vfio_device *device)
178 static inline bool vfio_device_has_container(struct vfio_device *device)
245 void vfio_device_container_register(struct vfio_device *device);
246 void vfio_device_container_unregister(struct vfio_device *device);
247 int vfio_device_container_pin_pages(struct vfio_device *device,
250 void vfio_device_container_unpin_pages(struct vfio_device *device,
252 int vfio_device_container_dma_rw(struct vfio_device *device,
284 static inline void vfio_device_container_register(struct vfio_device *device)
288 static inline void vfio_device_container_unregister(struct vfio_device *device)
292 static inline int vfio_device_container_pin_pages(struct vfio_device *device,
299 static inline void vfio_device_container_unpin_pages(struct vfio_device *device,
304 static inline int vfio_device_container_dma_rw(struct vfio_device *device,
325 int vfio_iommufd_compat_attach_ioas(struct vfio_device *device,
345 vfio_iommufd_compat_attach_ioas(struct vfio_device *device,
358 void vfio_init_device_cdev(struct vfio_device *device);
360 static inline int vfio_device_add(struct vfio_device *device)
362 /* cdev does not support noiommu device */
363 if (vfio_device_is_noiommu(device))
364 return device_add(&device->device);
365 vfio_init_device_cdev(device);
366 return cdev_device_add(&device->cdev, &device->device);
369 static inline void vfio_device_del(struct vfio_device *device)
371 if (vfio_device_is_noiommu(device))
372 device_del(&device->device);
374 cdev_device_del(&device->cdev, &device->device);
384 static inline void vfio_init_device_cdev(struct vfio_device *device)
388 static inline int vfio_device_add(struct vfio_device *device)
390 return device_add(&device->device);
393 static inline void vfio_device_del(struct vfio_device *device)
395 device_del(&device->device);
438 void vfio_device_get_kvm_safe(struct vfio_device *device, struct kvm *kvm);
439 void vfio_device_put_kvm(struct vfio_device *device);
441 static inline void vfio_device_get_kvm_safe(struct vfio_device *device,
446 static inline void vfio_device_put_kvm(struct vfio_device *device)