diff options
| author | Jason Gunthorpe <[email protected]> | 2022-05-11 13:12:58 -0600 |
|---|---|---|
| committer | Alex Williamson <[email protected]> | 2022-05-11 13:12:58 -0600 |
| commit | 09ea48efffa3156218980e20aaf23dcc7d6000fc (patch) | |
| tree | c0553900be89de4785ab215f4f6977b70cb225c3 /include | |
| parent | a77109ffca339097833f26a1fea55ff71e2b608a (diff) | |
vfio: Make vfio_(un)register_notifier accept a vfio_device
All callers have a struct vfio_device trivially available, pass it in
directly and avoid calling the expensive vfio_group_get_from_dev().
Acked-by: Eric Farman <[email protected]>
Reviewed-by: Jason J. Herne <[email protected]>
Reviewed-by: Tony Krowiak <[email protected]>
Reviewed-by: Kevin Tian <[email protected]>
Reviewed-by: Christoph Hellwig <[email protected]>
Signed-off-by: Jason Gunthorpe <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Alex Williamson <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/vfio.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/vfio.h b/include/linux/vfio.h index 66dda06ec42d..a00fd722f044 100644 --- a/include/linux/vfio.h +++ b/include/linux/vfio.h @@ -178,11 +178,11 @@ enum vfio_notify_type { /* events for VFIO_GROUP_NOTIFY */ #define VFIO_GROUP_NOTIFY_SET_KVM BIT(0) -extern int vfio_register_notifier(struct device *dev, +extern int vfio_register_notifier(struct vfio_device *device, enum vfio_notify_type type, unsigned long *required_events, struct notifier_block *nb); -extern int vfio_unregister_notifier(struct device *dev, +extern int vfio_unregister_notifier(struct vfio_device *device, enum vfio_notify_type type, struct notifier_block *nb); |