summaryrefslogtreecommitdiffstats
path: root/sys/dev/nsp
diff options
context:
space:
mode:
authorjhibbits <jhibbits@FreeBSD.org>2016-02-27 03:38:01 +0000
committerjhibbits <jhibbits@FreeBSD.org>2016-02-27 03:38:01 +0000
commit9da1c36d0a8d774c39703ec25190536771eaee70 (patch)
treebc27bca5a9b117f27964de1fbd3efe2e2ec151d3 /sys/dev/nsp
parent8db64542512568b735293ebaad1c652c899a02f1 (diff)
downloadFreeBSD-src-9da1c36d0a8d774c39703ec25190536771eaee70.zip
FreeBSD-src-9da1c36d0a8d774c39703ec25190536771eaee70.tar.gz
Migrate many bus_alloc_resource() calls to bus_alloc_resource_anywhere().
Most calls to bus_alloc_resource() use "anywhere" as the range, with a given count. Migrate these to use the new bus_alloc_resource_anywhere() API. Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D5370
Diffstat (limited to 'sys/dev/nsp')
-rw-r--r--sys/dev/nsp/nsp_pccard.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/nsp/nsp_pccard.c b/sys/dev/nsp/nsp_pccard.c
index 75fc076..a784cad 100644
--- a/sys/dev/nsp/nsp_pccard.c
+++ b/sys/dev/nsp/nsp_pccard.c
@@ -124,8 +124,9 @@ nsp_alloc_resource(device_t dev)
mtx_init(&sc->sc_sclow.sl_lock, "nsp", NULL, MTX_DEF);
sc->port_rid = 0;
- sc->port_res = bus_alloc_resource(dev, SYS_RES_IOPORT, &sc->port_rid,
- 0, ~0, NSP_IOSIZE, RF_ACTIVE);
+ sc->port_res = bus_alloc_resource_anywhere(dev, SYS_RES_IOPORT,
+ &sc->port_rid, NSP_IOSIZE,
+ RF_ACTIVE);
if (sc->port_res == NULL) {
nsp_release_resource(dev);
return(ENOMEM);
OpenPOWER on IntegriCloud