Lines Matching refs:vdpa_device
46 struct vdpa_device { struct
199 int (*set_vq_address)(struct vdpa_device *vdev,
202 void (*set_vq_num)(struct vdpa_device *vdev, u16 idx, u32 num);
203 void (*kick_vq)(struct vdpa_device *vdev, u16 idx);
204 void (*set_vq_cb)(struct vdpa_device *vdev, u16 idx,
206 void (*set_vq_ready)(struct vdpa_device *vdev, u16 idx, bool ready);
207 bool (*get_vq_ready)(struct vdpa_device *vdev, u16 idx);
208 int (*set_vq_state)(struct vdpa_device *vdev, u16 idx,
210 int (*get_vq_state)(struct vdpa_device *vdev, u16 idx,
213 (*get_vq_notification)(struct vdpa_device *vdev, u16 idx);
215 int (*get_vq_irq)(struct vdpa_device *vdv, u16 idx);
218 u32 (*get_vq_align)(struct vdpa_device *vdev);
219 u64 (*get_features)(struct vdpa_device *vdev);
220 int (*set_features)(struct vdpa_device *vdev, u64 features);
221 void (*set_config_cb)(struct vdpa_device *vdev,
223 u16 (*get_vq_num_max)(struct vdpa_device *vdev);
224 u32 (*get_device_id)(struct vdpa_device *vdev);
225 u32 (*get_vendor_id)(struct vdpa_device *vdev);
226 u8 (*get_status)(struct vdpa_device *vdev);
227 void (*set_status)(struct vdpa_device *vdev, u8 status);
228 void (*get_config)(struct vdpa_device *vdev, unsigned int offset,
230 void (*set_config)(struct vdpa_device *vdev, unsigned int offset,
232 u32 (*get_generation)(struct vdpa_device *vdev);
233 struct vdpa_iova_range (*get_iova_range)(struct vdpa_device *vdev);
236 int (*set_map)(struct vdpa_device *vdev, struct vhost_iotlb *iotlb);
237 int (*dma_map)(struct vdpa_device *vdev, u64 iova, u64 size,
239 int (*dma_unmap)(struct vdpa_device *vdev, u64 iova, u64 size);
242 void (*free)(struct vdpa_device *vdev);
245 struct vdpa_device *__vdpa_alloc_device(struct device *parent,
258 int vdpa_register_device(struct vdpa_device *vdev);
259 void vdpa_unregister_device(struct vdpa_device *vdev);
269 int (*probe)(struct vdpa_device *vdev);
270 void (*remove)(struct vdpa_device *vdev);
287 static inline struct vdpa_device *dev_to_vdpa(struct device *_dev) in dev_to_vdpa()
289 return container_of(_dev, struct vdpa_device, dev); in dev_to_vdpa()
292 static inline void *vdpa_get_drvdata(const struct vdpa_device *vdev) in vdpa_get_drvdata()
297 static inline void vdpa_set_drvdata(struct vdpa_device *vdev, void *data) in vdpa_set_drvdata()
302 static inline struct device *vdpa_get_dma_dev(struct vdpa_device *vdev) in vdpa_get_dma_dev()
307 static inline void vdpa_reset(struct vdpa_device *vdev) in vdpa_reset()
315 static inline int vdpa_set_features(struct vdpa_device *vdev, u64 features) in vdpa_set_features()
324 static inline void vdpa_get_config(struct vdpa_device *vdev, unsigned offset, in vdpa_get_config()