diff options
author | jhb <jhb@FreeBSD.org> | 2007-04-25 16:22:18 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2007-04-25 16:22:18 +0000 |
commit | 497a6ff2fca60684e42d2147242dd7fcdb4abe8a (patch) | |
tree | 52ca98fd95321cb39411fa006ac4898529d4669a /sys/dev/acpica | |
parent | 8f120a42e013350b51a04c4251ccba1b28f3f753 (diff) | |
download | FreeBSD-src-497a6ff2fca60684e42d2147242dd7fcdb4abe8a.zip FreeBSD-src-497a6ff2fca60684e42d2147242dd7fcdb4abe8a.tar.gz |
Use a tighter check to see if a resource allocation request is for a
specific request and thus should first try to be allocated from the
sys_resource pool. This avoids using the sys_resource pool for wildcard
requests that have bounded ranges coming from cbb(4) and Host-PCI pcib(4)
drivers.
Tested by: Andrea Bittau <a.bittau of cs.ucl.ac.uk fame>
Sleuthing by: Andrea Bittau as well
Diffstat (limited to 'sys/dev/acpica')
-rw-r--r-- | sys/dev/acpica/acpi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index fde3b55..c0724bc 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -1034,7 +1034,7 @@ acpi_alloc_resource(device_t bus, device_t child, int type, int *rid, * the request from our system resource regions. If we can't, pass the * request up to the parent. */ - if (!(start == 0UL && end == ~0UL) && rm != NULL) + if (start + count - 1 == end && rm != NULL) res = rman_reserve_resource(rm, start, end, count, flags & ~RF_ACTIVE, child); if (res == NULL) { |