diff options
| author | Mitsuru IWASAKI <iwasaki@FreeBSD.org> | 2002-09-05 11:16:23 +0000 |
|---|---|---|
| committer | Mitsuru IWASAKI <iwasaki@FreeBSD.org> | 2002-09-05 11:16:23 +0000 |
| commit | 8380f272e653721cc4c2fe5dcb32583a8774f507 (patch) | |
| tree | 70d6cd1294faf6f46544b12184d4716f6b5197b2 | |
| parent | 8f767abf71d16a93a0a71addb67e48ce471a7a12 (diff) | |
Notes
| -rw-r--r-- | sys/boot/i386/libi386/i386_module.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/sys/boot/i386/libi386/i386_module.c b/sys/boot/i386/libi386/i386_module.c index f87972783b2d..a7f5d566e07c 100644 --- a/sys/boot/i386/libi386/i386_module.c +++ b/sys/boot/i386/libi386/i386_module.c @@ -44,16 +44,24 @@ int i386_autoload(void) { int error; + int disabled; + char *rv; /* XXX use PnP to locate stuff here */ /* autoload ACPI support */ /* XXX should be in 4th keyed off acpi_load */ - if ((getenv("acpi_load") && !getenv("hint.acpi.0.disabled"))) { + disabled = 0; + rv = getenv("hint.acpi.0.disabled"); + if (rv != NULL && strncmp(rv, "0", 1) != 0) { + disabled = 1; + } + + if (getenv("acpi_load") && (!disabled)) { error = mod_load("acpi", NULL, 0, NULL); if (error != 0) printf("ACPI autoload failed - %s\n", strerror(error)); } - + return(0); } |
