mirror of
https://github.com/lkl/linux.git
synced 2025-12-19 16:13:19 +09:00
vfio/mdev: Remove vfio_mdev.c
Now that all mdev drivers directly create their own mdev_device driver and directly register with the vfio core's vfio_device_ops this is all dead code. Delete vfio_mdev.c and the mdev_parent_ops members that are connected to it. Signed-off-by: Jason Gunthorpe <jgg@nvidia.com> Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Zhi Wang <zhi.a.wang@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/20220411141403.86980-31-hch@lst.de Reviewed-by: Kirti Wankhede <kwankhede@nvidia.com> Reviewed-by: Zhi Wang <zhi.a.wang@intel.com>
This commit is contained in:
committed by
Zhi Wang
parent
cba619cb0d
commit
6c7f98b334
@@ -40,40 +40,7 @@ struct device *mtype_get_parent_dev(struct mdev_type *mtype);
|
||||
* @mdev_attr_groups: Attributes of the mediated device.
|
||||
* @supported_type_groups: Attributes to define supported types. It is mandatory
|
||||
* to provide supported types.
|
||||
* @create: Called to allocate basic resources in parent device's
|
||||
* driver for a particular mediated device. It is
|
||||
* mandatory to provide create ops.
|
||||
* @mdev: mdev_device structure on of mediated device
|
||||
* that is being created
|
||||
* Returns integer: success (0) or error (< 0)
|
||||
* @remove: Called to free resources in parent device's driver for
|
||||
* a mediated device. It is mandatory to provide 'remove'
|
||||
* ops.
|
||||
* @mdev: mdev_device device structure which is being
|
||||
* destroyed
|
||||
* Returns integer: success (0) or error (< 0)
|
||||
* @read: Read emulation callback
|
||||
* @mdev: mediated device structure
|
||||
* @buf: read buffer
|
||||
* @count: number of bytes to read
|
||||
* @ppos: address.
|
||||
* Retuns number on bytes read on success or error.
|
||||
* @write: Write emulation callback
|
||||
* @mdev: mediated device structure
|
||||
* @buf: write buffer
|
||||
* @count: number of bytes to be written
|
||||
* @ppos: address.
|
||||
* Retuns number on bytes written on success or error.
|
||||
* @ioctl: IOCTL callback
|
||||
* @mdev: mediated device structure
|
||||
* @cmd: ioctl command
|
||||
* @arg: arguments to ioctl
|
||||
* @mmap: mmap callback
|
||||
* @mdev: mediated device structure
|
||||
* @vma: vma structure
|
||||
* @request: request callback to release device
|
||||
* @mdev: mediated device structure
|
||||
* @count: request sequence number
|
||||
*
|
||||
* Parent device that support mediated device should be registered with mdev
|
||||
* module with mdev_parent_ops structure.
|
||||
**/
|
||||
@@ -83,19 +50,6 @@ struct mdev_parent_ops {
|
||||
const struct attribute_group **dev_attr_groups;
|
||||
const struct attribute_group **mdev_attr_groups;
|
||||
struct attribute_group **supported_type_groups;
|
||||
|
||||
int (*create)(struct mdev_device *mdev);
|
||||
int (*remove)(struct mdev_device *mdev);
|
||||
int (*open_device)(struct mdev_device *mdev);
|
||||
void (*close_device)(struct mdev_device *mdev);
|
||||
ssize_t (*read)(struct mdev_device *mdev, char __user *buf,
|
||||
size_t count, loff_t *ppos);
|
||||
ssize_t (*write)(struct mdev_device *mdev, const char __user *buf,
|
||||
size_t count, loff_t *ppos);
|
||||
long (*ioctl)(struct mdev_device *mdev, unsigned int cmd,
|
||||
unsigned long arg);
|
||||
int (*mmap)(struct mdev_device *mdev, struct vm_area_struct *vma);
|
||||
void (*request)(struct mdev_device *mdev, unsigned int count);
|
||||
};
|
||||
|
||||
/* interface for exporting mdev supported type attributes */
|
||||
|
||||
Reference in New Issue
Block a user