Message ID | 9-v2-65016290f146+33e-vfio_iommufd_jgg@nvidia.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Connect VFIO to IOMMUFD | expand |
> From: Jason Gunthorpe <jgg@nvidia.com> > Sent: Tuesday, November 8, 2022 8:53 AM > > The miscdev is in container.c, so should these related MODULE_ALIAS > statements. This is necessary for the next patch to be able to fully > disable /dev/vfio/vfio. > > Fixes: cdc71fe4ecbf ("vfio: Move container code into > drivers/vfio/container.c") > Reported-by: "Liu, Yi L" <yi.l.liu@intel.com> > Signed-off-by: Jason Gunthorpe <jgg@nvidia.com> Reviewed-by: Kevin Tian <kevin.tian@intel.com>
On 2022/11/8 08:52, Jason Gunthorpe wrote: > The miscdev is in container.c, so should these related MODULE_ALIAS > statements. This is necessary for the next patch to be able to fully > disable /dev/vfio/vfio. > > Fixes: cdc71fe4ecbf ("vfio: Move container code into drivers/vfio/container.c") > Reported-by: "Liu, Yi L" <yi.l.liu@intel.com> s/Liu Yi L/Yi Liu :) Reviewed-by: Yi Liu <yi.l.liu@intel.com> > Signed-off-by: Jason Gunthorpe <jgg@nvidia.com> > --- > drivers/vfio/container.c | 3 +++ > drivers/vfio/vfio_main.c | 2 -- > 2 files changed, 3 insertions(+), 2 deletions(-) > > diff --git a/drivers/vfio/container.c b/drivers/vfio/container.c > index 7f3961fd4b5aac..6b362d97d68220 100644 > --- a/drivers/vfio/container.c > +++ b/drivers/vfio/container.c > @@ -608,3 +608,6 @@ void vfio_container_cleanup(void) > misc_deregister(&vfio_dev); > mutex_destroy(&vfio.iommu_drivers_lock); > } > + > +MODULE_ALIAS_MISCDEV(VFIO_MINOR); > +MODULE_ALIAS("devname:vfio/vfio"); > diff --git a/drivers/vfio/vfio_main.c b/drivers/vfio/vfio_main.c > index cf49c5200a4c05..ee09ccf4a608e1 100644 > --- a/drivers/vfio/vfio_main.c > +++ b/drivers/vfio/vfio_main.c > @@ -2064,6 +2064,4 @@ MODULE_VERSION(DRIVER_VERSION); > MODULE_LICENSE("GPL v2"); > MODULE_AUTHOR(DRIVER_AUTHOR); > MODULE_DESCRIPTION(DRIVER_DESC); > -MODULE_ALIAS_MISCDEV(VFIO_MINOR); > -MODULE_ALIAS("devname:vfio/vfio"); > MODULE_SOFTDEP("post: vfio_iommu_type1 vfio_iommu_spapr_tce");
diff --git a/drivers/vfio/container.c b/drivers/vfio/container.c index 7f3961fd4b5aac..6b362d97d68220 100644 --- a/drivers/vfio/container.c +++ b/drivers/vfio/container.c @@ -608,3 +608,6 @@ void vfio_container_cleanup(void) misc_deregister(&vfio_dev); mutex_destroy(&vfio.iommu_drivers_lock); } + +MODULE_ALIAS_MISCDEV(VFIO_MINOR); +MODULE_ALIAS("devname:vfio/vfio"); diff --git a/drivers/vfio/vfio_main.c b/drivers/vfio/vfio_main.c index cf49c5200a4c05..ee09ccf4a608e1 100644 --- a/drivers/vfio/vfio_main.c +++ b/drivers/vfio/vfio_main.c @@ -2064,6 +2064,4 @@ MODULE_VERSION(DRIVER_VERSION); MODULE_LICENSE("GPL v2"); MODULE_AUTHOR(DRIVER_AUTHOR); MODULE_DESCRIPTION(DRIVER_DESC); -MODULE_ALIAS_MISCDEV(VFIO_MINOR); -MODULE_ALIAS("devname:vfio/vfio"); MODULE_SOFTDEP("post: vfio_iommu_type1 vfio_iommu_spapr_tce");
The miscdev is in container.c, so should these related MODULE_ALIAS statements. This is necessary for the next patch to be able to fully disable /dev/vfio/vfio. Fixes: cdc71fe4ecbf ("vfio: Move container code into drivers/vfio/container.c") Reported-by: "Liu, Yi L" <yi.l.liu@intel.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com> --- drivers/vfio/container.c | 3 +++ drivers/vfio/vfio_main.c | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-)