diff options
author | njl <njl@FreeBSD.org> | 2007-09-13 01:37:17 +0000 |
---|---|---|
committer | njl <njl@FreeBSD.org> | 2007-09-13 01:37:17 +0000 |
commit | 94a43e7b479723fb5163ed6d45db086920a64055 (patch) | |
tree | 73e2da748648d49e6bc1e2b82f5c94580dcbb3bb | |
parent | 4e0d648ec925cad7877be30f25677e3505b3f5d0 (diff) | |
download | FreeBSD-src-94a43e7b479723fb5163ed6d45db086920a64055.zip FreeBSD-src-94a43e7b479723fb5163ed6d45db086920a64055.tar.gz |
Reject requests to start or ack a suspend sequence on platforms that do not
support suspend/resume, currently all except i386.
Tested by: jkim
Approved by: re
-rw-r--r-- | sys/dev/acpica/acpi.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 06de497..5e2105b 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -2173,6 +2173,11 @@ acpi_ReqSleepState(struct acpi_softc *sc, int state) return (ENXIO); } +#if !defined(__i386__) + /* This platform does not support acpi suspend/resume. */ + return (EOPNOTSUPP); +#endif + /* If a suspend request is already in progress, just return. */ ACPI_LOCK(acpi); if (sc->acpi_next_sstate != 0) { @@ -2218,6 +2223,11 @@ acpi_AckSleepState(struct apm_clone_data *clone, int error) struct acpi_softc *sc; int ret, sleeping; +#if !defined(__i386__) + /* This platform does not support acpi suspend/resume. */ + return (EOPNOTSUPP); +#endif + /* If no pending sleep state, return an error. */ ACPI_LOCK(acpi); sc = clone->acpi_sc; |