diff options
author | jhibbits <jhibbits@FreeBSD.org> | 2016-02-20 01:32:58 +0000 |
---|---|---|
committer | jhibbits <jhibbits@FreeBSD.org> | 2016-02-20 01:32:58 +0000 |
commit | f8385663eeba2c10cd82a51c0a461a4f932458a3 (patch) | |
tree | 1d99680c416ab999716f7e3fb78956be8804e81f /sys/sparc64/pci | |
parent | 7a33cbc5f75355b9aacc299db55706229c9da4af (diff) | |
download | FreeBSD-src-f8385663eeba2c10cd82a51c0a461a4f932458a3.zip FreeBSD-src-f8385663eeba2c10cd82a51c0a461a4f932458a3.tar.gz |
Introduce a RMAN_IS_DEFAULT_RANGE() macro, and use it.
This simplifies checking for default resource range for bus_alloc_resource(),
and improves readability.
This is part of, and related to, the migration of rman_res_t from u_long to
uintmax_t.
Discussed with: jhb
Suggested by: marcel
Diffstat (limited to 'sys/sparc64/pci')
-rw-r--r-- | sys/sparc64/pci/apb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/sparc64/pci/apb.c b/sys/sparc64/pci/apb.c index c2fe508..ba3643c 100644 --- a/sys/sparc64/pci/apb.c +++ b/sys/sparc64/pci/apb.c @@ -238,7 +238,7 @@ apb_alloc_resource(device_t dev, device_t child, int type, int *rid, * out where it's coming from (we should actually never see these) so * we just have to punt. */ - if (start == 0 && end == ~0) { + if (RMAN_IS_DEFAULT_RANGE(start, end)) { device_printf(dev, "can't decode default resource id %d for " "%s, bypassing\n", *rid, device_get_nameunit(child)); goto passup; |