summaryrefslogtreecommitdiffstats
path: root/sys/sys/bus.h
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2011-04-29 21:36:45 +0000
committerjhb <jhb@FreeBSD.org>2011-04-29 21:36:45 +0000
commitdeafe4e5935414f3eecacab7035e974aed41f689 (patch)
treea10e3ccb13df7df7d9773ae454c4eab95b57171c /sys/sys/bus.h
parentf99737eb7bcd6c02fdf8bafc61179eb2711a4ed7 (diff)
downloadFreeBSD-src-deafe4e5935414f3eecacab7035e974aed41f689.zip
FreeBSD-src-deafe4e5935414f3eecacab7035e974aed41f689.tar.gz
Add a new bus method, BUS_ADJUST_RESOURCE() that is intended to be a
wrapper around rman_adjust_resource(). Include a generic implementation, bus_generic_adjust_resource() which passes the request up to the parent bus. There is currently no default implementation. A bus_adjust_resource() wrapper is provided for use in drivers.
Diffstat (limited to 'sys/sys/bus.h')
-rw-r--r--sys/sys/bus.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/sys/bus.h b/sys/sys/bus.h
index abb4e64..e02bdd3 100644
--- a/sys/sys/bus.h
+++ b/sys/sys/bus.h
@@ -304,6 +304,9 @@ int bus_generic_activate_resource(device_t dev, device_t child, int type,
device_t
bus_generic_add_child(device_t dev, u_int order, const char *name,
int unit);
+int bus_generic_adjust_resource(device_t bus, device_t child, int type,
+ struct resource *r, u_long start,
+ u_long end);
struct resource *
bus_generic_alloc_resource(device_t bus, device_t child, int type,
int *rid, u_long start, u_long end,
@@ -374,6 +377,8 @@ int bus_alloc_resources(device_t dev, struct resource_spec *rs,
void bus_release_resources(device_t dev, const struct resource_spec *rs,
struct resource **res);
+int bus_adjust_resource(device_t child, int type, struct resource *r,
+ u_long start, u_long end);
struct resource *bus_alloc_resource(device_t dev, int type, int *rid,
u_long start, u_long end, u_long count,
u_int flags);
OpenPOWER on IntegriCloud