diff options
author | jhb <jhb@FreeBSD.org> | 2010-12-23 18:50:14 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2010-12-23 18:50:14 +0000 |
commit | b99e14a3c709a03c560cd1d1c29e5edc7170eb2d (patch) | |
tree | a211be8f376d3d5586d7b82a3f397b91e1d797d6 | |
parent | bdcd5b684b7c24a1020cd522268e8883a3d6a281 (diff) | |
download | FreeBSD-src-b99e14a3c709a03c560cd1d1c29e5edc7170eb2d.zip FreeBSD-src-b99e14a3c709a03c560cd1d1c29e5edc7170eb2d.tar.gz |
Don't try to reserve a resource that is already allocated. If the ECDT
table is present, then the acpi_ec(4) driver will allocate its resources
from nexus0 before the acpi0 device reserves resources for child devices.
Reviewed by: jkim
-rw-r--r-- | sys/dev/acpica/acpi.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 3319952..585d1c5 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -1150,6 +1150,14 @@ acpi_reserve_resources(device_t dev) continue; /* + * Don't reserve the resource if it is already allocated. + * The acpi_ec(4) driver can allocate its resources early + * if ECDT is present. + */ + if (rle->res != NULL) + continue; + + /* * Try to reserve the resource from our parent. If this * fails because the resource is a system resource, just * let it be. The resource range is already reserved so |