Lines Matching refs:vdev
172 struct vfio_device vdev;
489 dev_dbg(mdev_state->vdev.dev, "%s: %s @0x%llx (unhandled)\n",
516 static int mbochs_init_dev(struct vfio_device *vdev)
519 container_of(vdev, struct mdev_state, vdev);
520 struct mdev_device *mdev = to_mdev_device(vdev->dev);
557 dev_info(vdev->dev, "%s: %s, %d MB, %ld pages\n", __func__,
573 mdev_state = vfio_alloc_device(mdev_state, vdev, &mdev->dev,
578 ret = vfio_register_emulated_iommu_dev(&mdev_state->vdev);
585 vfio_put_device(&mdev_state->vdev);
589 static void mbochs_release_dev(struct vfio_device *vdev)
592 container_of(vdev, struct mdev_state, vdev);
603 vfio_unregister_group_dev(&mdev_state->vdev);
604 vfio_put_device(&mdev_state->vdev);
607 static ssize_t mbochs_read(struct vfio_device *vdev, char __user *buf,
611 container_of(vdev, struct mdev_state, vdev);
668 static ssize_t mbochs_write(struct vfio_device *vdev, const char __user *buf,
672 container_of(vdev, struct mdev_state, vdev);
795 static int mbochs_mmap(struct vfio_device *vdev, struct vm_area_struct *vma)
798 container_of(vdev, struct mdev_state, vdev);
1005 struct device *dev = mdev_state->vdev.dev;
1154 dev_dbg(mdev_state->vdev.dev, "%s: primary: %d => %d\n",
1185 static long mbochs_ioctl(struct vfio_device *vdev, unsigned int cmd,
1189 container_of(vdev, struct mdev_state, vdev);
1305 static void mbochs_close_device(struct vfio_device *vdev)
1308 container_of(vdev, struct mdev_state, vdev);