summaryrefslogtreecommitdiffstats
path: root/sys/isa/isa_common.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1999-11-20 14:56:55 +0000
committerpeter <peter@FreeBSD.org>1999-11-20 14:56:55 +0000
commit23264e706260a6b0c95f24137f7012b045b1d5c8 (patch)
tree5642b41a20062a39e1f394b18a8af675f2d0611a /sys/isa/isa_common.c
parent75d26bf57405e325ab98e1c789f13cfd1cbdb9a2 (diff)
downloadFreeBSD-src-23264e706260a6b0c95f24137f7012b045b1d5c8.zip
FreeBSD-src-23264e706260a6b0c95f24137f7012b045b1d5c8.tar.gz
Allow NULL for startp and/or countp in bus_get_resource() so that you can
get one of the two without having to use a dummy variable.
Diffstat (limited to 'sys/isa/isa_common.c')
-rw-r--r--sys/isa/isa_common.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/isa/isa_common.c b/sys/isa/isa_common.c
index 42d486e..9202754 100644
--- a/sys/isa/isa_common.c
+++ b/sys/isa/isa_common.c
@@ -869,8 +869,10 @@ isa_get_resource(device_t dev, device_t child, int type, int rid,
if (!rle)
return ENOENT;
- *startp = rle->start;
- *countp = rle->count;
+ if (startp)
+ *startp = rle->start;
+ if (countp)
+ *countp = rle->count;
return 0;
}
OpenPOWER on IntegriCloud