diff options
author | jhibbits <jhibbits@FreeBSD.org> | 2016-01-27 02:23:54 +0000 |
---|---|---|
committer | jhibbits <jhibbits@FreeBSD.org> | 2016-01-27 02:23:54 +0000 |
commit | 31bb8ee5bdf9a6332a86e4774ebdccba877ce42e (patch) | |
tree | 5ac500b634909ff3fe2556201aef7e16d85316d2 /sys/sparc64 | |
parent | d2ca0a07825355904475b1fe585efdd49eeae0b3 (diff) | |
download | FreeBSD-src-31bb8ee5bdf9a6332a86e4774ebdccba877ce42e.zip FreeBSD-src-31bb8ee5bdf9a6332a86e4774ebdccba877ce42e.tar.gz |
Convert rman to use rman_res_t instead of u_long
Summary:
Migrate to using the semi-opaque type rman_res_t to specify rman resources. For
now, this is still compatible with u_long.
This is step one in migrating rman to use uintmax_t for resources instead of
u_long.
Going forward, this could feasibly be used to specify architecture-specific
definitions of resource ranges, rather than baking a specific integer type into
the API.
This change has been broken out to facilitate MFC'ing drivers back to 10 without
breaking ABI.
Reviewed By: jhb
Sponsored by: Alex Perez/Inertial Computing
Differential Revision: https://reviews.freebsd.org/D5075
Diffstat (limited to 'sys/sparc64')
-rw-r--r-- | sys/sparc64/central/central.c | 6 | ||||
-rw-r--r-- | sys/sparc64/ebus/ebus.c | 6 | ||||
-rw-r--r-- | sys/sparc64/fhc/fhc.c | 6 | ||||
-rw-r--r-- | sys/sparc64/isa/isa.c | 2 | ||||
-rw-r--r-- | sys/sparc64/pci/apb.c | 8 | ||||
-rw-r--r-- | sys/sparc64/pci/fire.c | 2 | ||||
-rw-r--r-- | sys/sparc64/pci/ofw_pci.c | 4 | ||||
-rw-r--r-- | sys/sparc64/pci/psycho.c | 2 | ||||
-rw-r--r-- | sys/sparc64/pci/sbbc.c | 6 | ||||
-rw-r--r-- | sys/sparc64/pci/schizo.c | 2 | ||||
-rw-r--r-- | sys/sparc64/sbus/sbus.c | 4 | ||||
-rw-r--r-- | sys/sparc64/sparc64/nexus.c | 4 | ||||
-rw-r--r-- | sys/sparc64/sparc64/upa.c | 8 |
13 files changed, 30 insertions, 30 deletions
diff --git a/sys/sparc64/central/central.c b/sys/sparc64/central/central.c index 86cb3f4..62fa79d 100644 --- a/sys/sparc64/central/central.c +++ b/sys/sparc64/central/central.c @@ -183,8 +183,8 @@ central_attach(device_t dev) static int central_adjust_resource(device_t bus __unused, device_t child __unused, - int type __unused, struct resource *r __unused, u_long start __unused, - u_long end __unused) + int type __unused, struct resource *r __unused, rman_res_t start __unused, + rman_res_t end __unused) { return (ENXIO); @@ -215,7 +215,7 @@ central_probe_nomatch(device_t dev, device_t child) static struct resource * central_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct resource_list *rl; struct resource_list_entry *rle; diff --git a/sys/sparc64/ebus/ebus.c b/sys/sparc64/ebus/ebus.c index 0967c5d..961dd07 100644 --- a/sys/sparc64/ebus/ebus.c +++ b/sys/sparc64/ebus/ebus.c @@ -427,7 +427,7 @@ ebus_probe_nomatch(device_t dev, device_t child) static struct resource * ebus_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct ebus_softc *sc; struct resource_list *rl; @@ -544,8 +544,8 @@ ebus_activate_resource(device_t bus, device_t child, int type, int rid, static int ebus_adjust_resource(device_t bus __unused, device_t child __unused, - int type __unused, struct resource *res __unused, u_long start __unused, - u_long end __unused) + int type __unused, struct resource *res __unused, rman_res_t start __unused, + rman_res_t end __unused) { return (ENXIO); diff --git a/sys/sparc64/fhc/fhc.c b/sys/sparc64/fhc/fhc.c index 4d6a6bd..3de81ff 100644 --- a/sys/sparc64/fhc/fhc.c +++ b/sys/sparc64/fhc/fhc.c @@ -420,7 +420,7 @@ fhc_setup_intr(device_t bus, device_t child, struct resource *r, int flags, static struct resource * fhc_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct resource_list *rl; struct resource_list_entry *rle; @@ -479,8 +479,8 @@ fhc_alloc_resource(device_t bus, device_t child, int type, int *rid, static int fhc_adjust_resource(device_t bus __unused, device_t child __unused, - int type __unused, struct resource *r __unused, u_long start __unused, - u_long end __unused) + int type __unused, struct resource *r __unused, rman_res_t start __unused, + rman_res_t end __unused) { return (ENXIO); diff --git a/sys/sparc64/isa/isa.c b/sys/sparc64/isa/isa.c index 6783440..ad4bcdb 100644 --- a/sys/sparc64/isa/isa.c +++ b/sys/sparc64/isa/isa.c @@ -273,7 +273,7 @@ isa_setup_children(device_t dev, phandle_t parent) struct resource * isa_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { /* * Consider adding a resource definition. diff --git a/sys/sparc64/pci/apb.c b/sys/sparc64/pci/apb.c index c0d6172..c2fe508 100644 --- a/sys/sparc64/pci/apb.c +++ b/sys/sparc64/pci/apb.c @@ -130,7 +130,7 @@ apb_probe(device_t dev) } static void -apb_map_print(uint8_t map, u_long scale) +apb_map_print(uint8_t map, rman_res_t scale) { int i, first; @@ -144,7 +144,7 @@ apb_map_print(uint8_t map, u_long scale) } static int -apb_checkrange(uint8_t map, u_long scale, u_long start, u_long end) +apb_checkrange(uint8_t map, rman_res_t scale, rman_res_t start, rman_res_t end) { int i, ei; @@ -227,7 +227,7 @@ apb_attach(device_t dev) */ static struct resource * apb_alloc_resource(device_t dev, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct apb_softc *sc; @@ -287,7 +287,7 @@ apb_alloc_resource(device_t dev, device_t child, int type, int *rid, static int apb_adjust_resource(device_t dev, device_t child, int type, - struct resource *r, u_long start, u_long end) + struct resource *r, rman_res_t start, rman_res_t end) { struct apb_softc *sc; diff --git a/sys/sparc64/pci/fire.c b/sys/sparc64/pci/fire.c index be0c64b..c2d2285 100644 --- a/sys/sparc64/pci/fire.c +++ b/sys/sparc64/pci/fire.c @@ -1852,7 +1852,7 @@ fire_teardown_intr(device_t dev, device_t child, struct resource *ires, static struct resource * fire_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct fire_softc *sc; diff --git a/sys/sparc64/pci/ofw_pci.c b/sys/sparc64/pci/ofw_pci.c index a18052f..8babd49 100644 --- a/sys/sparc64/pci/ofw_pci.c +++ b/sys/sparc64/pci/ofw_pci.c @@ -287,7 +287,7 @@ ofw_pci_read_ivar(device_t dev, device_t child __unused, int which, struct resource * ofw_pci_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct ofw_pci_softc *sc; struct resource *rv; @@ -362,7 +362,7 @@ ofw_pci_activate_resource(device_t bus, device_t child, int type, int rid, int ofw_pci_adjust_resource(device_t bus, device_t child, int type, - struct resource *r, u_long start, u_long end) + struct resource *r, rman_res_t start, rman_res_t end) { struct ofw_pci_softc *sc; struct rman *rm; diff --git a/sys/sparc64/pci/psycho.c b/sys/sparc64/pci/psycho.c index 38f4656..496df96 100644 --- a/sys/sparc64/pci/psycho.c +++ b/sys/sparc64/pci/psycho.c @@ -1038,7 +1038,7 @@ psycho_setup_intr(device_t dev, device_t child, struct resource *ires, static struct resource * psycho_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct psycho_softc *sc; diff --git a/sys/sparc64/pci/sbbc.c b/sys/sparc64/pci/sbbc.c index f1e7fab..e509363 100644 --- a/sys/sparc64/pci/sbbc.c +++ b/sys/sparc64/pci/sbbc.c @@ -397,7 +397,7 @@ sbbc_pci_attach(device_t dev) static struct resource * sbbc_bus_alloc_resource(device_t dev, device_t child __unused, int type, - int *rid, u_long start, u_long end, u_long count, u_int flags) + int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct sbbc_softc *sc; @@ -435,8 +435,8 @@ sbbc_bus_deactivate_resource(device_t bus, device_t child, int type, int rid, static int sbbc_bus_adjust_resource(device_t bus __unused, device_t child __unused, - int type __unused, struct resource *res __unused, u_long start __unused, - u_long end __unused) + int type __unused, struct resource *res __unused, rman_res_t start __unused, + rman_res_t end __unused) { return (ENXIO); diff --git a/sys/sparc64/pci/schizo.c b/sys/sparc64/pci/schizo.c index ed1cccd..a96155b 100644 --- a/sys/sparc64/pci/schizo.c +++ b/sys/sparc64/pci/schizo.c @@ -1196,7 +1196,7 @@ schizo_setup_intr(device_t dev, device_t child, struct resource *ires, static struct resource * schizo_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct schizo_softc *sc; diff --git a/sys/sparc64/sbus/sbus.c b/sys/sparc64/sbus/sbus.c index 0b27655..e4bc3b4 100644 --- a/sys/sparc64/sbus/sbus.c +++ b/sys/sparc64/sbus/sbus.c @@ -710,7 +710,7 @@ sbus_setup_intr(device_t dev, device_t child, struct resource *ires, int flags, static struct resource * sbus_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct sbus_softc *sc; struct rman *rm; @@ -821,7 +821,7 @@ sbus_activate_resource(device_t bus, device_t child, int type, int rid, static int sbus_adjust_resource(device_t bus, device_t child, int type, - struct resource *r, u_long start, u_long end) + struct resource *r, rman_res_t start, rman_res_t end) { struct sbus_softc *sc; int i; diff --git a/sys/sparc64/sparc64/nexus.c b/sys/sparc64/sparc64/nexus.c index 30374e5..7082220 100644 --- a/sys/sparc64/sparc64/nexus.c +++ b/sys/sparc64/sparc64/nexus.c @@ -359,7 +359,7 @@ nexus_describe_intr(device_t bus __unused, device_t child __unused, static struct resource * nexus_alloc_resource(device_t bus, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct nexus_softc *sc; struct rman *rm; @@ -445,7 +445,7 @@ nexus_deactivate_resource(device_t bus __unused, device_t child __unused, static int nexus_adjust_resource(device_t bus, device_t child __unused, int type, - struct resource *r, u_long start, u_long end) + struct resource *r, rman_res_t start, rman_res_t end) { struct nexus_softc *sc; struct rman *rm; diff --git a/sys/sparc64/sparc64/upa.c b/sys/sparc64/sparc64/upa.c index cd615d9..f3a73bc 100644 --- a/sys/sparc64/sparc64/upa.c +++ b/sys/sparc64/sparc64/upa.c @@ -194,7 +194,7 @@ upa_attach(device_t dev) int i, imr, j, rid; #if 1 device_t *children, schizo; - u_long scount, sstart, ucount, ustart; + rman_res_t scount, sstart, ucount, ustart; int nchildren; #endif @@ -403,7 +403,7 @@ upa_probe_nomatch(device_t dev, device_t child) static struct resource * upa_alloc_resource(device_t dev, device_t child, int type, int *rid, - u_long start, u_long end, u_long count, u_int flags) + rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct resource_list *rl; struct resource_list_entry *rle; @@ -510,8 +510,8 @@ upa_setup_intr(device_t dev, device_t child, struct resource *ires, int flags, static int upa_adjust_resource(device_t bus __unused, device_t child __unused, - int type __unused, struct resource *r __unused, u_long start __unused, - u_long end __unused) + int type __unused, struct resource *r __unused, rman_res_t start __unused, + rman_res_t end __unused) { return (ENXIO); |