diff options
author | Vijay Mohan Pandarathil <vijaymohan.pandarathil@hp.com> | 2013-03-11 09:28:44 -0600 |
---|---|---|
committer | Alex Williamson <alex.williamson@redhat.com> | 2013-03-11 09:28:44 -0600 |
commit | 44f507163d9e51238458ee6904b4d71fb0723723 (patch) | |
tree | ddd48ebd567813495ddeb718d7d54524f16f313f /include/linux/vfio.h | |
parent | f6161aa153581da4a3867a2d1a7caf4be19b6ec9 (diff) |
VFIO: Wrapper for getting reference to vfio_device
- Added vfio_device_get_from_dev() as wrapper to get
reference to vfio_device from struct device.
- Added vfio_device_data() as a wrapper to get device_data from
vfio_device.
Signed-off-by: Vijay Mohan Pandarathil <vijaymohan.pandarathil@hp.com>
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Diffstat (limited to 'include/linux/vfio.h')
-rw-r--r-- | include/linux/vfio.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/vfio.h b/include/linux/vfio.h index ab9e86224c54..ac8d488e4372 100644 --- a/include/linux/vfio.h +++ b/include/linux/vfio.h @@ -45,6 +45,9 @@ extern int vfio_add_group_dev(struct device *dev, void *device_data); extern void *vfio_del_group_dev(struct device *dev); +extern struct vfio_device *vfio_device_get_from_dev(struct device *dev); +extern void vfio_device_put(struct vfio_device *device); +extern void *vfio_device_data(struct vfio_device *device); /** * struct vfio_iommu_driver_ops - VFIO IOMMU driver callbacks |