git: 5edf159ff17e - main - powerpc powernv: Remove unused devclass arguments to DRIVER_MODULE.
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 10 May 2022 17:36:24 UTC
The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=5edf159ff17e24ae9d25256ae687cab117af90f2 commit 5edf159ff17e24ae9d25256ae687cab117af90f2 Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2022-05-10 17:21:38 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2022-05-10 17:21:38 +0000 powerpc powernv: Remove unused devclass arguments to DRIVER_MODULE. --- sys/powerpc/powernv/opal_console.c | 4 +--- sys/powerpc/powernv/opal_dev.c | 5 +---- sys/powerpc/powernv/opal_flash.c | 4 +--- sys/powerpc/powernv/opal_i2c.c | 5 +---- sys/powerpc/powernv/opal_i2cm.c | 8 ++------ sys/powerpc/powernv/opal_nvram.c | 4 +--- sys/powerpc/powernv/opal_pci.c | 4 +--- sys/powerpc/powernv/opal_sensor.c | 9 ++------- sys/powerpc/powernv/powernv_centaur.c | 5 +---- sys/powerpc/powernv/powernv_xscom.c | 5 +---- sys/powerpc/powernv/xive.c | 9 ++------- 11 files changed, 14 insertions(+), 48 deletions(-) diff --git a/sys/powerpc/powernv/opal_console.c b/sys/powerpc/powernv/opal_console.c index 6b7e16891ec7..8adaec0dc070 100644 --- a/sys/powerpc/powernv/opal_console.c +++ b/sys/powerpc/powernv/opal_console.c @@ -611,6 +611,4 @@ static driver_t opalcons_driver = { 0 }; -static devclass_t opalcons_devclass; - -DRIVER_MODULE(opalcons, opal, opalcons_driver, opalcons_devclass, 0, 0); +DRIVER_MODULE(opalcons, opal, opalcons_driver, 0, 0); diff --git a/sys/powerpc/powernv/opal_dev.c b/sys/powerpc/powernv/opal_dev.c index d07dea566303..ef54c965eaba 100644 --- a/sys/powerpc/powernv/opal_dev.c +++ b/sys/powerpc/powernv/opal_dev.c @@ -94,10 +94,7 @@ static driver_t opaldev_driver = { 0 }; -static devclass_t opaldev_devclass; - -EARLY_DRIVER_MODULE(opaldev, ofwbus, opaldev_driver, opaldev_devclass, 0, 0, - BUS_PASS_BUS); +EARLY_DRIVER_MODULE(opaldev, ofwbus, opaldev_driver, 0, 0, BUS_PASS_BUS); static void opal_heartbeat(void); static void opal_handle_messages(void); diff --git a/sys/powerpc/powernv/opal_flash.c b/sys/powerpc/powernv/opal_flash.c index 5c56a0018ff5..6b35c7d2cc3e 100644 --- a/sys/powerpc/powernv/opal_flash.c +++ b/sys/powerpc/powernv/opal_flash.c @@ -98,9 +98,7 @@ static driver_t opalflash_driver = { sizeof(struct opalflash_softc) }; -static devclass_t opalflash_devclass; - -DRIVER_MODULE(opalflash, opal, opalflash_driver, opalflash_devclass, 0, 0); +DRIVER_MODULE(opalflash, opal, opalflash_driver, 0, 0); /* GEOM Disk interfaces. */ static int diff --git a/sys/powerpc/powernv/opal_i2c.c b/sys/powerpc/powernv/opal_i2c.c index 9e387cb29f4b..dea3c2f5090b 100644 --- a/sys/powerpc/powernv/opal_i2c.c +++ b/sys/powerpc/powernv/opal_i2c.c @@ -110,8 +110,6 @@ static device_method_t opal_i2c_methods[] = { mtx_init(&_sc->sc_mtx, device_get_nameunit(_sc->dev), \ "i2c", MTX_DEF) -static devclass_t opal_i2c_devclass; - static driver_t opal_i2c_driver = { "iichb", opal_i2c_methods, @@ -245,7 +243,6 @@ opal_i2c_get_node(device_t bus, device_t dev) return (ofw_bus_get_node(bus)); } -DRIVER_MODULE(opal_i2c, opal_i2cm, opal_i2c_driver, opal_i2c_devclass, NULL, - NULL); +DRIVER_MODULE(opal_i2c, opal_i2cm, opal_i2c_driver, NULL, NULL); DRIVER_MODULE(iicbus, opal_i2c, iicbus_driver, NULL, NULL); MODULE_DEPEND(opal_i2c, iicbus, 1, 1, 1); diff --git a/sys/powerpc/powernv/opal_i2cm.c b/sys/powerpc/powernv/opal_i2cm.c index 4f3ad518567b..df35d86b261e 100644 --- a/sys/powerpc/powernv/opal_i2cm.c +++ b/sys/powerpc/powernv/opal_i2cm.c @@ -76,8 +76,6 @@ static device_method_t opal_i2cm_methods[] = { DEVMETHOD_END }; -static devclass_t opal_i2cm_devclass; - static int opal_i2cm_probe(device_t dev) { @@ -126,7 +124,5 @@ opal_i2cm_get_devinfo(device_t dev, device_t child) DEFINE_CLASS_0(opal_i2cm, opal_i2cm_driver, opal_i2cm_methods, sizeof(struct opal_i2cm_softc)); -DRIVER_MODULE(opal_i2cm, powernv_xscom, opal_i2cm_driver, opal_i2cm_devclass, NULL, - NULL); -DRIVER_MODULE(opal_i2cm, powernv_centaur, opal_i2cm_driver, opal_i2cm_devclass, NULL, - NULL); +DRIVER_MODULE(opal_i2cm, powernv_xscom, opal_i2cm_driver, NULL, NULL); +DRIVER_MODULE(opal_i2cm, powernv_centaur, opal_i2cm_driver, NULL, NULL); diff --git a/sys/powerpc/powernv/opal_nvram.c b/sys/powerpc/powernv/opal_nvram.c index 095f8ebd725b..c053ec1ff2aa 100644 --- a/sys/powerpc/powernv/opal_nvram.c +++ b/sys/powerpc/powernv/opal_nvram.c @@ -93,9 +93,7 @@ static driver_t opal_nvram_driver = { sizeof(struct opal_nvram_softc) }; -static devclass_t opal_nvram_devclass; - -DRIVER_MODULE(opal_nvram, opal, opal_nvram_driver, opal_nvram_devclass, 0, 0); +DRIVER_MODULE(opal_nvram, opal, opal_nvram_driver, 0, 0); /* * Cdev methods. diff --git a/sys/powerpc/powernv/opal_pci.c b/sys/powerpc/powernv/opal_pci.c index cbaa638863c7..5683ffee95c7 100644 --- a/sys/powerpc/powernv/opal_pci.c +++ b/sys/powerpc/powernv/opal_pci.c @@ -167,11 +167,9 @@ struct opalpci_softc { struct resource *r_reg; }; -static devclass_t opalpci_devclass; DEFINE_CLASS_1(pcib, opalpci_driver, opalpci_methods, sizeof(struct opalpci_softc), ofw_pcib_driver); -EARLY_DRIVER_MODULE(opalpci, ofwbus, opalpci_driver, opalpci_devclass, 0, 0, - BUS_PASS_BUS); +EARLY_DRIVER_MODULE(opalpci, ofwbus, opalpci_driver, 0, 0, BUS_PASS_BUS); static int opalpci_probe(device_t dev) diff --git a/sys/powerpc/powernv/opal_sensor.c b/sys/powerpc/powernv/opal_sensor.c index a95746472975..97d50797d33c 100644 --- a/sys/powerpc/powernv/opal_sensor.c +++ b/sys/powerpc/powernv/opal_sensor.c @@ -255,10 +255,7 @@ static driver_t opal_sensor_driver = { sizeof(struct opal_sensor_softc) }; -static devclass_t opal_sensor_devclass; - -DRIVER_MODULE(opal_sensor, opalsens, opal_sensor_driver, opal_sensor_devclass, - NULL, NULL); +DRIVER_MODULE(opal_sensor, opalsens, opal_sensor_driver, NULL, NULL); static int opalsens_probe(device_t dev) @@ -327,6 +324,4 @@ static driver_t opalsens_driver = { 0 }; -static devclass_t opalsens_devclass; - -DRIVER_MODULE(opalsens, opal, opalsens_driver, opalsens_devclass, NULL, NULL); +DRIVER_MODULE(opalsens, opal, opalsens_driver, NULL, NULL); diff --git a/sys/powerpc/powernv/powernv_centaur.c b/sys/powerpc/powernv/powernv_centaur.c index b112bd83b4ea..750d43873954 100644 --- a/sys/powerpc/powernv/powernv_centaur.c +++ b/sys/powerpc/powernv/powernv_centaur.c @@ -76,8 +76,6 @@ static device_method_t powernv_centaur_methods[] = { DEVMETHOD_END }; -static devclass_t powernv_centaur_devclass; - static int powernv_centaur_probe(device_t dev) { @@ -125,5 +123,4 @@ powernv_centaur_get_devinfo(device_t dev, device_t child) DEFINE_CLASS_0(powernv_centaur, powernv_centaur_driver, powernv_centaur_methods, sizeof(struct powernv_centaur_softc)); -DRIVER_MODULE(powernv_centaur, ofwbus, powernv_centaur_driver, powernv_centaur_devclass, NULL, - NULL); +DRIVER_MODULE(powernv_centaur, ofwbus, powernv_centaur_driver, NULL, NULL); diff --git a/sys/powerpc/powernv/powernv_xscom.c b/sys/powerpc/powernv/powernv_xscom.c index ba8a3a7d6690..36dcc80751ae 100644 --- a/sys/powerpc/powernv/powernv_xscom.c +++ b/sys/powerpc/powernv/powernv_xscom.c @@ -76,8 +76,6 @@ static device_method_t powernv_xscom_methods[] = { DEVMETHOD_END }; -static devclass_t powernv_xscom_devclass; - static int powernv_xscom_probe(device_t dev) { @@ -125,5 +123,4 @@ powernv_xscom_get_devinfo(device_t dev, device_t child) DEFINE_CLASS_0(powernv_xscom, powernv_xscom_driver, powernv_xscom_methods, sizeof(struct powernv_xscom_softc)); -DRIVER_MODULE(powernv_xscom, ofwbus, powernv_xscom_driver, powernv_xscom_devclass, NULL, - NULL); +DRIVER_MODULE(powernv_xscom, ofwbus, powernv_xscom_driver, NULL, NULL); diff --git a/sys/powerpc/powernv/xive.c b/sys/powerpc/powernv/xive.c index 77467dc9fcd7..f750385714e5 100644 --- a/sys/powerpc/powernv/xive.c +++ b/sys/powerpc/powernv/xive.c @@ -202,13 +202,8 @@ static driver_t xics_driver = { 0 }; -static devclass_t xive_devclass; -static devclass_t xics_devclass; - -EARLY_DRIVER_MODULE(xive, ofwbus, xive_driver, xive_devclass, 0, 0, - BUS_PASS_INTERRUPT-1); -EARLY_DRIVER_MODULE(xivevc, ofwbus, xics_driver, xics_devclass, 0, 0, - BUS_PASS_INTERRUPT); +EARLY_DRIVER_MODULE(xive, ofwbus, xive_driver, 0, 0, BUS_PASS_INTERRUPT - 1); +EARLY_DRIVER_MODULE(xivevc, ofwbus, xics_driver, 0, 0, BUS_PASS_INTERRUPT); MALLOC_DEFINE(M_XIVE, "xive", "XIVE Memory");