diff options
author | avg <avg@FreeBSD.org> | 2010-09-10 11:19:03 +0000 |
---|---|---|
committer | avg <avg@FreeBSD.org> | 2010-09-10 11:19:03 +0000 |
commit | c9fe8ad7f06a5eb11bd5ba5224721d64a9b81afd (patch) | |
tree | df34a15378a2bfdd3403ef89e431e6f0c53c379c | |
parent | cab433458afbc7e2f04ab7edaf6866c0d70724ea (diff) | |
download | FreeBSD-src-c9fe8ad7f06a5eb11bd5ba5224721d64a9b81afd.zip FreeBSD-src-c9fe8ad7f06a5eb11bd5ba5224721d64a9b81afd.tar.gz |
bus_add_child: change type of order parameter to u_int
This reflects actual type used to store and compare child device orders.
Change is mostly done via a Coccinelle (soon to be devel/coccinelle)
semantic patch.
Verified by LINT+modules kernel builds.
Followup to: r212213
MFC after: 10 days
33 files changed, 58 insertions, 58 deletions
diff --git a/sys/amd64/amd64/legacy.c b/sys/amd64/amd64/legacy.c index 9aa0365..4123f84 100644 --- a/sys/amd64/amd64/legacy.c +++ b/sys/amd64/amd64/legacy.c @@ -60,7 +60,7 @@ struct legacy_device { static int legacy_probe(device_t); static int legacy_attach(device_t); static int legacy_print_child(device_t, device_t); -static device_t legacy_add_child(device_t bus, int order, const char *name, +static device_t legacy_add_child(device_t bus, u_int order, const char *name, int unit); static int legacy_read_ivar(device_t, device_t, int, uintptr_t *); static int legacy_write_ivar(device_t, device_t, int, uintptr_t); @@ -149,7 +149,7 @@ legacy_print_child(device_t bus, device_t child) } static device_t -legacy_add_child(device_t bus, int order, const char *name, int unit) +legacy_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct legacy_device *atdev; @@ -213,7 +213,7 @@ legacy_write_ivar(device_t dev, device_t child, int which, uintptr_t value) static void cpu_identify(driver_t *driver, device_t parent); static int cpu_read_ivar(device_t dev, device_t child, int index, uintptr_t *result); -static device_t cpu_add_child(device_t bus, int order, const char *name, +static device_t cpu_add_child(device_t bus, u_int order, const char *name, int unit); static struct resource_list *cpu_get_rlist(device_t dev, device_t child); @@ -277,7 +277,7 @@ cpu_identify(driver_t *driver, device_t parent) } static device_t -cpu_add_child(device_t bus, int order, const char *name, int unit) +cpu_add_child(device_t bus, u_int order, const char *name, int unit) { struct cpu_device *cd; device_t child; diff --git a/sys/amd64/amd64/nexus.c b/sys/amd64/amd64/nexus.c index 4c701a0..037d4ac 100644 --- a/sys/amd64/amd64/nexus.c +++ b/sys/amd64/amd64/nexus.c @@ -83,7 +83,7 @@ static int nexus_probe(device_t); static int nexus_attach(device_t); static int nexus_print_all_resources(device_t dev); static int nexus_print_child(device_t, device_t); -static device_t nexus_add_child(device_t bus, int order, const char *name, +static device_t nexus_add_child(device_t bus, u_int order, const char *name, int unit); static struct resource *nexus_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -293,7 +293,7 @@ nexus_print_child(device_t bus, device_t child) } static device_t -nexus_add_child(device_t bus, int order, const char *name, int unit) +nexus_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct nexus_device *ndev; diff --git a/sys/arm/arm/nexus.c b/sys/arm/arm/nexus.c index 584960f..4efca14 100644 --- a/sys/arm/arm/nexus.c +++ b/sys/arm/arm/nexus.c @@ -74,7 +74,7 @@ static struct rman mem_rman; static int nexus_probe(device_t); static int nexus_attach(device_t); static int nexus_print_child(device_t, device_t); -static device_t nexus_add_child(device_t, int, const char *, int); +static device_t nexus_add_child(device_t, u_int, const char *, int); static struct resource *nexus_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); static int nexus_activate_resource(device_t, device_t, int, int, @@ -166,7 +166,7 @@ nexus_print_child(device_t bus, device_t child) } static device_t -nexus_add_child(device_t bus, int order, const char *name, int unit) +nexus_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct nexus_device *ndev; diff --git a/sys/arm/xscale/ixp425/ixp425.c b/sys/arm/xscale/ixp425/ixp425.c index ac70bcb..9b11b43 100644 --- a/sys/arm/xscale/ixp425/ixp425.c +++ b/sys/arm/xscale/ixp425/ixp425.c @@ -369,7 +369,7 @@ ixp425_hinted_child(device_t bus, const char *dname, int dunit) } static device_t -ixp425_add_child(device_t dev, int order, const char *name, int unit) +ixp425_add_child(device_t dev, u_int order, const char *name, int unit) { device_t child; struct ixp425_ivar *ivar; diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 7c941f3..5cccc9e 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -105,7 +105,7 @@ static int acpi_attach(device_t dev); static int acpi_suspend(device_t dev); static int acpi_resume(device_t dev); static int acpi_shutdown(device_t dev); -static device_t acpi_add_child(device_t bus, int order, const char *name, +static device_t acpi_add_child(device_t bus, u_int order, const char *name, int unit); static int acpi_print_child(device_t bus, device_t child); static void acpi_probe_nomatch(device_t bus, device_t child); @@ -781,7 +781,7 @@ acpi_shutdown(device_t dev) * Handle a new device being added */ static device_t -acpi_add_child(device_t bus, int order, const char *name, int unit) +acpi_add_child(device_t bus, u_int order, const char *name, int unit) { struct acpi_device *ad; device_t child; diff --git a/sys/dev/acpica/acpi_cpu.c b/sys/dev/acpica/acpi_cpu.c index 45882a2..5dd6ab9 100644 --- a/sys/dev/acpica/acpi_cpu.c +++ b/sys/dev/acpica/acpi_cpu.c @@ -148,7 +148,7 @@ static int acpi_cpu_resume(device_t dev); static int acpi_pcpu_get_id(uint32_t idx, uint32_t *acpi_id, uint32_t *cpu_id); static struct resource_list *acpi_cpu_get_rlist(device_t dev, device_t child); -static device_t acpi_cpu_add_child(device_t dev, int order, const char *name, +static device_t acpi_cpu_add_child(device_t dev, u_int order, const char *name, int unit); static int acpi_cpu_read_ivar(device_t dev, device_t child, int index, uintptr_t *result); @@ -479,7 +479,7 @@ acpi_cpu_get_rlist(device_t dev, device_t child) } static device_t -acpi_cpu_add_child(device_t dev, int order, const char *name, int unit) +acpi_cpu_add_child(device_t dev, u_int order, const char *name, int unit) { struct acpi_cpu_device *ad; device_t child; diff --git a/sys/dev/atkbdc/atkbdc_isa.c b/sys/dev/atkbdc/atkbdc_isa.c index 10e172f..42bb67b 100644 --- a/sys/dev/atkbdc/atkbdc_isa.c +++ b/sys/dev/atkbdc/atkbdc_isa.c @@ -47,7 +47,7 @@ __FBSDID("$FreeBSD$"); static int atkbdc_isa_probe(device_t dev); static int atkbdc_isa_attach(device_t dev); -static device_t atkbdc_isa_add_child(device_t bus, int order, const char *name, +static device_t atkbdc_isa_add_child(device_t bus, u_int order, const char *name, int unit); static device_method_t atkbdc_isa_methods[] = { @@ -230,7 +230,7 @@ atkbdc_isa_attach(device_t dev) } static device_t -atkbdc_isa_add_child(device_t bus, int order, const char *name, int unit) +atkbdc_isa_add_child(device_t bus, u_int order, const char *name, int unit) { atkbdc_device_t *ivar; device_t child; diff --git a/sys/dev/firewire/firewire.c b/sys/dev/firewire/firewire.c index a035959..490f39b 100644 --- a/sys/dev/firewire/firewire.c +++ b/sys/dev/firewire/firewire.c @@ -102,7 +102,7 @@ static void firewire_xfer_timeout(void *, int); #if 0 static int firewire_shutdown (device_t); #endif -static device_t firewire_add_child (device_t, int, const char *, int); +static device_t firewire_add_child(device_t, u_int, const char *, int); static void fw_try_bmr (void *); static void fw_try_bmr_callback (struct fw_xfer *); static void fw_asystart (struct fw_xfer *); @@ -488,7 +488,7 @@ firewire_attach(device_t dev) * Attach it as child. */ static device_t -firewire_add_child(device_t dev, int order, const char *name, int unit) +firewire_add_child(device_t dev, u_int order, const char *name, int unit) { device_t child; struct firewire_softc *sc; diff --git a/sys/dev/firewire/fwohci_pci.c b/sys/dev/firewire/fwohci_pci.c index 5524954..0bb66a9 100644 --- a/sys/dev/firewire/fwohci_pci.c +++ b/sys/dev/firewire/fwohci_pci.c @@ -487,7 +487,7 @@ fwohci_pci_shutdown(device_t dev) } static device_t -fwohci_pci_add_child(device_t dev, int order, const char *name, int unit) +fwohci_pci_add_child(device_t dev, u_int order, const char *name, int unit) { struct fwohci_softc *sc; device_t child; diff --git a/sys/dev/iicbus/iicbus.c b/sys/dev/iicbus/iicbus.c index 5c16f20..ca110c8 100644 --- a/sys/dev/iicbus/iicbus.c +++ b/sys/dev/iicbus/iicbus.c @@ -188,7 +188,7 @@ iicbus_read_ivar(device_t bus, device_t child, int which, uintptr_t *result) } static device_t -iicbus_add_child(device_t dev, int order, const char *name, int unit) +iicbus_add_child(device_t dev, u_int order, const char *name, int unit) { device_t child; struct iicbus_ivar *devi; diff --git a/sys/dev/ofw/ofw_iicbus.c b/sys/dev/ofw/ofw_iicbus.c index 2ee9a72..875e4dd 100644 --- a/sys/dev/ofw/ofw_iicbus.c +++ b/sys/dev/ofw/ofw_iicbus.c @@ -46,8 +46,8 @@ __FBSDID("$FreeBSD$"); /* Methods */ static device_probe_t ofw_iicbus_probe; static device_attach_t ofw_iicbus_attach; -static device_t ofw_iicbus_add_child(device_t dev, int order, const char *name, - int unit); +static device_t ofw_iicbus_add_child(device_t dev, u_int order, + const char *name, int unit); static const struct ofw_bus_devinfo *ofw_iicbus_get_devinfo(device_t bus, device_t dev); @@ -147,7 +147,7 @@ ofw_iicbus_attach(device_t dev) } static device_t -ofw_iicbus_add_child(device_t dev, int order, const char *name, int unit) +ofw_iicbus_add_child(device_t dev, u_int order, const char *name, int unit) { device_t child; struct ofw_iicbus_devinfo *devi; diff --git a/sys/dev/ppbus/ppbconf.c b/sys/dev/ppbus/ppbconf.c index a994355..9e21c67 100644 --- a/sys/dev/ppbus/ppbconf.c +++ b/sys/dev/ppbus/ppbconf.c @@ -90,7 +90,7 @@ ppbus_probe(device_t dev) * Add a ppbus device, allocate/initialize the ivars */ static device_t -ppbus_add_child(device_t dev, int order, const char *name, int unit) +ppbus_add_child(device_t dev, u_int order, const char *name, int unit) { struct ppb_device *ppbdev; device_t child; diff --git a/sys/dev/siba/siba.c b/sys/dev/siba/siba.c index 4ee11ca..b2c49fb 100644 --- a/sys/dev/siba/siba.c +++ b/sys/dev/siba/siba.c @@ -90,7 +90,7 @@ static struct siba_devid siba_devids[] = { static int siba_activate_resource(device_t, device_t, int, int, struct resource *); -static device_t siba_add_child(device_t, int, const char *, int); +static device_t siba_add_child(device_t, u_int, const char *, int); static struct resource * siba_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -505,7 +505,7 @@ siba_destroy_devinfo(struct siba_devinfo *sdi) /* XXX is this needed? */ static device_t -siba_add_child(device_t dev, int order, const char *name, int unit) +siba_add_child(device_t dev, u_int order, const char *name, int unit) { #if 1 diff --git a/sys/dev/spibus/spibus.c b/sys/dev/spibus/spibus.c index a0c0380..9491734 100644 --- a/sys/dev/spibus/spibus.c +++ b/sys/dev/spibus/spibus.c @@ -127,7 +127,7 @@ spibus_read_ivar(device_t bus, device_t child, int which, u_int *result) } static device_t -spibus_add_child(device_t dev, int order, const char *name, int unit) +spibus_add_child(device_t dev, u_int order, const char *name, int unit) { device_t child; struct spibus_ivar *devi; diff --git a/sys/i386/i386/legacy.c b/sys/i386/i386/legacy.c index 39f3e22..fe9b403 100644 --- a/sys/i386/i386/legacy.c +++ b/sys/i386/i386/legacy.c @@ -65,7 +65,7 @@ struct legacy_device { static int legacy_probe(device_t); static int legacy_attach(device_t); static int legacy_print_child(device_t, device_t); -static device_t legacy_add_child(device_t bus, int order, const char *name, +static device_t legacy_add_child(device_t bus, u_int order, const char *name, int unit); static int legacy_read_ivar(device_t, device_t, int, uintptr_t *); static int legacy_write_ivar(device_t, device_t, int, uintptr_t); @@ -170,7 +170,7 @@ legacy_print_child(device_t bus, device_t child) } static device_t -legacy_add_child(device_t bus, int order, const char *name, int unit) +legacy_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct legacy_device *atdev; @@ -234,7 +234,7 @@ legacy_write_ivar(device_t dev, device_t child, int which, uintptr_t value) static void cpu_identify(driver_t *driver, device_t parent); static int cpu_read_ivar(device_t dev, device_t child, int index, uintptr_t *result); -static device_t cpu_add_child(device_t bus, int order, const char *name, +static device_t cpu_add_child(device_t bus, u_int order, const char *name, int unit); static struct resource_list *cpu_get_rlist(device_t dev, device_t child); @@ -298,7 +298,7 @@ cpu_identify(driver_t *driver, device_t parent) } static device_t -cpu_add_child(device_t bus, int order, const char *name, int unit) +cpu_add_child(device_t bus, u_int order, const char *name, int unit) { struct cpu_device *cd; device_t child; diff --git a/sys/i386/i386/nexus.c b/sys/i386/i386/nexus.c index 04dd464..ec87528 100644 --- a/sys/i386/i386/nexus.c +++ b/sys/i386/i386/nexus.c @@ -87,7 +87,7 @@ static int nexus_probe(device_t); static int nexus_attach(device_t); static int nexus_print_all_resources(device_t dev); static int nexus_print_child(device_t, device_t); -static device_t nexus_add_child(device_t bus, int order, const char *name, +static device_t nexus_add_child(device_t bus, u_int order, const char *name, int unit); static struct resource *nexus_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -305,7 +305,7 @@ nexus_print_child(device_t bus, device_t child) } static device_t -nexus_add_child(device_t bus, int order, const char *name, int unit) +nexus_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct nexus_device *ndev; diff --git a/sys/ia64/ia64/nexus.c b/sys/ia64/ia64/nexus.c index 9885b74..43d0632 100644 --- a/sys/ia64/ia64/nexus.c +++ b/sys/ia64/ia64/nexus.c @@ -82,7 +82,7 @@ static struct rman irq_rman, port_rman, mem_rman; static int nexus_probe(device_t); static int nexus_attach(device_t); static int nexus_print_child(device_t, device_t); -static device_t nexus_add_child(device_t bus, int order, const char *name, +static device_t nexus_add_child(device_t bus, u_int order, const char *name, int unit); static struct resource *nexus_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -220,7 +220,7 @@ nexus_print_child(device_t bus, device_t child) } static device_t -nexus_add_child(device_t bus, int order, const char *name, int unit) +nexus_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct nexus_device *ndev; diff --git a/sys/isa/isa_common.c b/sys/isa/isa_common.c index bcf7729..1d1a13a 100644 --- a/sys/isa/isa_common.c +++ b/sys/isa/isa_common.c @@ -597,7 +597,7 @@ isa_probe_children(device_t dev) * Add a new child with default ivars. */ static device_t -isa_add_child(device_t dev, int order, const char *name, int unit) +isa_add_child(device_t dev, u_int order, const char *name, int unit) { device_t child; struct isa_device *idev; diff --git a/sys/kern/bus_if.m b/sys/kern/bus_if.m index 326156e..688a470 100644 --- a/sys/kern/bus_if.m +++ b/sys/kern/bus_if.m @@ -200,7 +200,7 @@ METHOD void driver_added { */ METHOD device_t add_child { device_t _dev; - int _order; + u_int _order; const char *_name; int _unit; }; diff --git a/sys/kern/subr_bus.c b/sys/kern/subr_bus.c index 9912d980..fe3b294 100644 --- a/sys/kern/subr_bus.c +++ b/sys/kern/subr_bus.c @@ -3284,7 +3284,7 @@ resource_list_purge(struct resource_list *rl) } device_t -bus_generic_add_child(device_t dev, int order, const char *name, int unit) +bus_generic_add_child(device_t dev, u_int order, const char *name, int unit) { return (device_add_child_ordered(dev, order, name, unit)); diff --git a/sys/mips/adm5120/obio.c b/sys/mips/adm5120/obio.c index ad6cb6e..b89c957 100644 --- a/sys/mips/adm5120/obio.c +++ b/sys/mips/adm5120/obio.c @@ -101,7 +101,7 @@ int irq_priorities[NIRQS] = { static int obio_activate_resource(device_t, device_t, int, int, struct resource *); -static device_t obio_add_child(device_t, int, const char *, int); +static device_t obio_add_child(device_t, u_int, const char *, int); static struct resource * obio_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -480,7 +480,7 @@ obio_hinted_child(device_t bus, const char *dname, int dunit) } static device_t -obio_add_child(device_t bus, int order, const char *name, int unit) +obio_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct obio_ivar *ivar; diff --git a/sys/mips/alchemy/obio.c b/sys/mips/alchemy/obio.c index fb55813..90e41d6 100644 --- a/sys/mips/alchemy/obio.c +++ b/sys/mips/alchemy/obio.c @@ -101,7 +101,7 @@ int irq_priorities[NIRQS] = { static int obio_activate_resource(device_t, device_t, int, int, struct resource *); -static device_t obio_add_child(device_t, int, const char *, int); +static device_t obio_add_child(device_t, u_int, const char *, int); static struct resource * obio_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -472,7 +472,7 @@ obio_hinted_child(device_t bus, const char *dname, int dunit) } static device_t -obio_add_child(device_t bus, int order, const char *name, int unit) +obio_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct obio_ivar *ivar; diff --git a/sys/mips/atheros/apb.c b/sys/mips/atheros/apb.c index d71b242..c004741 100644 --- a/sys/mips/atheros/apb.c +++ b/sys/mips/atheros/apb.c @@ -52,7 +52,7 @@ __FBSDID("$FreeBSD$"); static int apb_activate_resource(device_t, device_t, int, int, struct resource *); -static device_t apb_add_child(device_t, int, const char *, int); +static device_t apb_add_child(device_t, u_int, const char *, int); static struct resource * apb_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -397,7 +397,7 @@ apb_hinted_child(device_t bus, const char *dname, int dunit) } static device_t -apb_add_child(device_t bus, int order, const char *name, int unit) +apb_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct apb_ivar *ivar; diff --git a/sys/mips/idt/obio.c b/sys/mips/idt/obio.c index 44e9bfa..034b93a 100644 --- a/sys/mips/idt/obio.c +++ b/sys/mips/idt/obio.c @@ -57,7 +57,7 @@ __FBSDID("$FreeBSD$"); static int obio_activate_resource(device_t, device_t, int, int, struct resource *); -static device_t obio_add_child(device_t, int, const char *, int); +static device_t obio_add_child(device_t, u_int, const char *, int); static struct resource * obio_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -422,7 +422,7 @@ obio_hinted_child(device_t bus, const char *dname, int dunit) } static device_t -obio_add_child(device_t bus, int order, const char *name, int unit) +obio_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct obio_ivar *ivar; diff --git a/sys/mips/mips/mainbus.c b/sys/mips/mips/mainbus.c index 3e1e66a..587b409 100644 --- a/sys/mips/mips/mainbus.c +++ b/sys/mips/mips/mainbus.c @@ -67,7 +67,7 @@ static struct rman irq_rman, port_rman, mem_rman; static int mainbus_probe(device_t); static int mainbus_attach(device_t); static int mainbus_print_child(device_t, device_t); -static device_t mainbus_add_child(device_t bus, int order, const char *name, +static device_t mainbus_add_child(device_t bus, u_int order, const char *name, int unit); static struct resource *mainbus_alloc_resource(device_t, device_t, int, int *, u_long, u_long, u_long, u_int); @@ -178,7 +178,7 @@ mainbus_print_child(device_t bus, device_t child) } static device_t -mainbus_add_child(device_t bus, int order, const char *name, int unit) +mainbus_add_child(device_t bus, u_int order, const char *name, int unit) { return device_add_child_ordered(bus, order, name, unit); } diff --git a/sys/mips/mips/nexus.c b/sys/mips/mips/nexus.c index 10b38b5..2274466 100644 --- a/sys/mips/mips/nexus.c +++ b/sys/mips/mips/nexus.c @@ -82,7 +82,7 @@ static struct resource * u_long, u_long, u_int); static int nexus_activate_resource(device_t, device_t, int, int, struct resource *); -static device_t nexus_add_child(device_t, int, const char *, int); +static device_t nexus_add_child(device_t, u_int, const char *, int); static int nexus_attach(device_t); static int nexus_deactivate_resource(device_t, device_t, int, int, struct resource *); @@ -282,7 +282,7 @@ nexus_hinted_child(device_t bus, const char *dname, int dunit) } static device_t -nexus_add_child(device_t bus, int order, const char *name, int unit) +nexus_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct nexus_device *ndev; diff --git a/sys/mips/sibyte/sb_zbbus.c b/sys/mips/sibyte/sb_zbbus.c index cd16856..e166b8f 100644 --- a/sys/mips/sibyte/sb_zbbus.c +++ b/sys/mips/sibyte/sb_zbbus.c @@ -402,7 +402,7 @@ zbbus_setup_intr(device_t dev, device_t child, struct resource *irq, int flags, } static device_t -zbbus_add_child(device_t bus, int order, const char *name, int unit) +zbbus_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct zbbus_devinfo *dinfo; diff --git a/sys/pc98/pc98/canbus.c b/sys/pc98/pc98/canbus.c index 522b4d0..ceb2d71 100644 --- a/sys/pc98/pc98/canbus.c +++ b/sys/pc98/pc98/canbus.c @@ -82,7 +82,7 @@ static int canbus_detach(device_t); /* Bus interface methods */ static int canbus_print_child(device_t, device_t); -static device_t canbus_add_child(device_t, int, const char *, int); +static device_t canbus_add_child(device_t, u_int, const char *, int); static struct resource * canbus_alloc_resource( device_t, device_t, int, int *, u_long, u_long, u_long, u_int); static int canbus_activate_resource( @@ -235,7 +235,7 @@ canbus_print_child(device_t dev, device_t child) } static device_t -canbus_add_child(device_t bus, int order, const char *name, int unit) +canbus_add_child(device_t bus, u_int order, const char *name, int unit) { device_t child; struct canbus_device *cbdev; diff --git a/sys/powerpc/aim/nexus.c b/sys/powerpc/aim/nexus.c index 46e57a5..b17de11 100644 --- a/sys/powerpc/aim/nexus.c +++ b/sys/powerpc/aim/nexus.c @@ -115,7 +115,7 @@ static int nexus_attach(device_t); /* * Bus interface */ -static device_t nexus_add_child(device_t, int, const char *, int); +static device_t nexus_add_child(device_t, u_int, const char *, int); static void nexus_probe_nomatch(device_t, device_t); static int nexus_read_ivar(device_t, device_t, int, uintptr_t *); static int nexus_write_ivar(device_t, device_t, int, uintptr_t); @@ -262,7 +262,7 @@ nexus_probe_nomatch(device_t dev, device_t child) } static device_t -nexus_add_child(device_t dev, int order, const char *name, int unit) +nexus_add_child(device_t dev, u_int order, const char *name, int unit) { device_t child; struct nexus_devinfo *dinfo; diff --git a/sys/sparc64/sparc64/nexus.c b/sys/sparc64/sparc64/nexus.c index 192251d..4c1379e 100644 --- a/sys/sparc64/sparc64/nexus.c +++ b/sys/sparc64/sparc64/nexus.c @@ -258,7 +258,7 @@ nexus_attach(device_t dev) } static device_t -nexus_add_child(device_t dev, int order, const char *name, int unit) +nexus_add_child(device_t dev, u_int order, const char *name, int unit) { device_t cdev; struct nexus_devinfo *ndi; diff --git a/sys/sun4v/sun4v/nexus.c b/sys/sun4v/sun4v/nexus.c index 2156a23..125b2f7 100644 --- a/sys/sun4v/sun4v/nexus.c +++ b/sys/sun4v/sun4v/nexus.c @@ -234,7 +234,7 @@ nexus_attach(device_t dev) } static device_t -nexus_add_child(device_t dev, int order, const char *name, int unit) +nexus_add_child(device_t dev, u_int order, const char *name, int unit) { device_t cdev; struct nexus_devinfo *ndi; diff --git a/sys/sun4v/sun4v/vnex.c b/sys/sun4v/sun4v/vnex.c index 305d0bb..d2554eb 100644 --- a/sys/sun4v/sun4v/vnex.c +++ b/sys/sun4v/sun4v/vnex.c @@ -204,7 +204,7 @@ vnex_attach(device_t dev) } static device_t -vnex_add_child(device_t dev, int order, const char *name, int unit) +vnex_add_child(device_t dev, u_int order, const char *name, int unit) { device_t cdev; struct vnex_devinfo *vndi; diff --git a/sys/sys/bus.h b/sys/sys/bus.h index 276ebb0..88a0f60 100644 --- a/sys/sys/bus.h +++ b/sys/sys/bus.h @@ -298,7 +298,7 @@ void root_bus_configure(void); int bus_generic_activate_resource(device_t dev, device_t child, int type, int rid, struct resource *r); device_t - bus_generic_add_child(device_t dev, int order, const char *name, + bus_generic_add_child(device_t dev, u_int order, const char *name, int unit); struct resource * bus_generic_alloc_resource(device_t bus, device_t child, int type, |