git: f95acbd89d59 - main - vmm: Rename the amdiommu driver to amdviiommu
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 04 Nov 2024 14:46:31 UTC
The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=f95acbd89d594b5932197679d94d2ba23c1d0331 commit f95acbd89d594b5932197679d94d2ba23c1d0331 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2024-11-04 14:44:19 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2024-11-04 14:45:57 +0000 vmm: Rename the amdiommu driver to amdviiommu To avoid a conflict with the new amdiommu driver imported recently. Fixes: 0f5116d7efe3 ("AMD IOMMU driver") Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D47415 --- sys/amd64/vmm/amd/{amdiommu.c => amdviiommu.c} | 38 +++++++++++++------------- sys/modules/vmm/Makefile | 2 +- 2 files changed, 20 insertions(+), 20 deletions(-) diff --git a/sys/amd64/vmm/amd/amdiommu.c b/sys/amd64/vmm/amd/amdviiommu.c similarity index 85% rename from sys/amd64/vmm/amd/amdiommu.c rename to sys/amd64/vmm/amd/amdviiommu.c index 69432498a5c2..5f5822a667b5 100644 --- a/sys/amd64/vmm/amd/amdiommu.c +++ b/sys/amd64/vmm/amd/amdviiommu.c @@ -40,36 +40,36 @@ #include "amdvi_priv.h" #include "ivhd_if.h" -struct amdiommu_softc { +struct amdviiommu_softc { struct resource *event_res; /* Event interrupt resource. */ void *event_tag; /* Event interrupt tag. */ int event_rid; }; -static int amdiommu_probe(device_t); -static int amdiommu_attach(device_t); -static int amdiommu_detach(device_t); +static int amdviiommu_probe(device_t); +static int amdviiommu_attach(device_t); +static int amdviiommu_detach(device_t); static int ivhd_setup_intr(device_t, driver_intr_t, void *, const char *); static int ivhd_teardown_intr(device_t); -static device_method_t amdiommu_methods[] = { +static device_method_t amdviiommu_methods[] = { /* device interface */ - DEVMETHOD(device_probe, amdiommu_probe), - DEVMETHOD(device_attach, amdiommu_attach), - DEVMETHOD(device_detach, amdiommu_detach), + DEVMETHOD(device_probe, amdviiommu_probe), + DEVMETHOD(device_attach, amdviiommu_attach), + DEVMETHOD(device_detach, amdviiommu_detach), DEVMETHOD(ivhd_setup_intr, ivhd_setup_intr), DEVMETHOD(ivhd_teardown_intr, ivhd_teardown_intr), DEVMETHOD_END }; -static driver_t amdiommu_driver = { - "amdiommu", - amdiommu_methods, - sizeof(struct amdiommu_softc), +static driver_t amdviiommu_driver = { + "amdviiommu", + amdviiommu_methods, + sizeof(struct amdviiommu_softc), }; static int -amdiommu_probe(device_t dev) +amdviiommu_probe(device_t dev) { int error; int capoff; @@ -99,7 +99,7 @@ amdiommu_probe(device_t dev) } static int -amdiommu_attach(device_t dev) +amdviiommu_attach(device_t dev) { device_set_desc(dev, "AMD-Vi/IOMMU PCI function"); @@ -107,7 +107,7 @@ amdiommu_attach(device_t dev) } static int -amdiommu_detach(device_t dev) +amdviiommu_detach(device_t dev) { return (0); @@ -117,7 +117,7 @@ static int ivhd_setup_intr(device_t dev, driver_intr_t handler, void *arg, const char *desc) { - struct amdiommu_softc *sc; + struct amdviiommu_softc *sc; int error, msicnt; sc = device_get_softc(dev); @@ -158,7 +158,7 @@ fail: static int ivhd_teardown_intr(device_t dev) { - struct amdiommu_softc *sc; + struct amdviiommu_softc *sc; sc = device_get_softc(dev); @@ -176,5 +176,5 @@ ivhd_teardown_intr(device_t dev) } /* This driver has to be loaded before ivhd */ -DRIVER_MODULE(amdiommu, pci, amdiommu_driver, 0, 0); -MODULE_DEPEND(amdiommu, pci, 1, 1, 1); +DRIVER_MODULE(amdviiommu, pci, amdviiommu_driver, 0, 0); +MODULE_DEPEND(amdviiommu, pci, 1, 1, 1); diff --git a/sys/modules/vmm/Makefile b/sys/modules/vmm/Makefile index 47504a053c34..15454b345934 100644 --- a/sys/modules/vmm/Makefile +++ b/sys/modules/vmm/Makefile @@ -107,7 +107,7 @@ SRCS+= ept.c \ # amd-specific files .PATH: ${SRCTOP}/sys/amd64/vmm/amd SRCS+= vmcb.c \ - amdiommu.c \ + amdviiommu.c \ ivhd_if.c \ ivhd_if.h \ svm.c \