blob: 2f3673878b099eff91ec907b3bb3810e87ffbb6e [file] [log] [blame]
Kyösti Mälkkie8b4da22014-10-21 18:22:32 +03001/*
2 * This file is part of the coreboot project.
3 *
4 * Copyright (C) 2007-2009 coresystems GmbH
5 * Copyright (C) 2011 The ChromiumOS Authors. All rights reserved.
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; version 2 of the License.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
Kyösti Mälkkie8b4da22014-10-21 18:22:32 +030015 */
16
Kyösti Mälkki390ba042017-08-07 21:42:46 +030017/* S1 support: bit 0, S2 Support: bit 1, etc. S0 & S5 assumed */
18#if IS_ENABLED(CONFIG_HAVE_ACPI_RESUME)
19Name (SSFG, 0x0D)
20#else
21Name (SSFG, 0x09)
22#endif
23
Kyösti Mälkkie8b4da22014-10-21 18:22:32 +030024/* Supported sleep states: */
25Name(\_S0, Package () {0x00, 0x00, 0x00, 0x00} ) /* (S0) - working state */
26
Kyösti Mälkki390ba042017-08-07 21:42:46 +030027If (And(SSFG, 0x01)) {
Kyösti Mälkkie8b4da22014-10-21 18:22:32 +030028 Name(\_S1, Package () {0x01, 0x01, 0x00, 0x00} ) /* (S1) - sleeping w/CPU context */
29}
Kyösti Mälkki390ba042017-08-07 21:42:46 +030030If (And(SSFG, 0x02)) {
Kyösti Mälkkie8b4da22014-10-21 18:22:32 +030031 Name(\_S2, Package () {0x02, 0x02, 0x00, 0x00} ) /* (S2) - "light" Suspend to RAM */
32}
Kyösti Mälkki390ba042017-08-07 21:42:46 +030033If (And(SSFG, 0x04)) {
Kyösti Mälkkie8b4da22014-10-21 18:22:32 +030034 Name(\_S3, Package () {0x03, 0x03, 0x00, 0x00} ) /* (S3) - Suspend to RAM */
35}
Kyösti Mälkki390ba042017-08-07 21:42:46 +030036If (And(SSFG, 0x08)) {
Kyösti Mälkkie8b4da22014-10-21 18:22:32 +030037 Name(\_S4, Package () {0x04, 0x04, 0x00, 0x00} ) /* (S4) - Suspend to Disk */
38}
39
40Name(\_S5, Package () {0x05, 0x05, 0x00, 0x00} ) /* (S5) - Soft Off */