tree: drop last paragraph of GPL copyright header
[coreboot.git] / src / mainboard / bap / ode_e20XX / acpi / sleep.asl
blobdc3cc4964bc294594ba14d086f71ccd53eff6084
1 /*
2  * This file is part of the coreboot project.
3  *
4  * Copyright (C) 2013 Sage Electronic Engineering, LLC
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; version 2 of the License.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU General Public License for more details.
14  */
16 /* Wake status package */
17 Name(WKST,Package(){Zero, Zero})
20 * \_PTS - Prepare to Sleep method
22 *       Entry:
23 *               Arg0=The value of the sleeping state S1=1, S2=2, etc
25 * Exit:
26 *               -none-
28 * The _PTS control method is executed at the beginning of the sleep process
29 * for S1-S5. The sleeping value is passed to the _PTS control method.   This
30 * control method may be executed a relatively long time before entering the
31 * sleep state and the OS may abort      the operation without notification to
32 * the ACPI driver.  This method cannot modify the configuration or power
33 * state of any device in the system.
36 External(\_SB.APTS, MethodObj)
37 External(\_SB.AWAK, MethodObj)
39 Method(_PTS, 1) {
40         /* DBGO("\\_PTS\n") */
41         /* DBGO("From S0 to S") */
42         /* DBGO(Arg0) */
43         /* DBGO("\n") */
45         /* Clear wake status structure. */
46         Store(0, Index(WKST,0))
47         Store(0, Index(WKST,1))
48         Store(7, UPWS)
49         \_SB.APTS(Arg0)
50 } /* End Method(\_PTS) */
53 *       \_BFS OEM Back From Sleep method
55 *       Entry:
56 *               Arg0=The value of the sleeping state S1=1, S2=2
58 *       Exit:
59 *               -none-
61 Method(\_BFS, 1) {
62         /* DBGO("\\_BFS\n") */
63         /* DBGO("From S") */
64         /* DBGO(Arg0) */
65         /* DBGO(" to S0\n") */
69 *  \_WAK System Wake method
71 *       Entry:
72 *               Arg0=The value of the sleeping state S1=1, S2=2
74 *       Exit:
75 *               Return package of 2 DWords
76 *               Dword 1 - Status
77 *                       0x00000000      wake succeeded
78 *                       0x00000001      Wake was signaled but failed due to lack of power
79 *                       0x00000002      Wake was signaled but failed due to thermal condition
80 *               Dword 2 - Power Supply state
81 *                       if non-zero the effective S-state the power supply entered
83 Method(\_WAK, 1) {
84         /* DBGO("\\_WAK\n") */
85         /* DBGO("From S") */
86         /* DBGO(Arg0) */
87         /* DBGO(" to S0\n") */
88         Store(1,USBS)
90         \_SB.AWAK(Arg0)
92         Return(WKST)
93 } /* End Method(\_WAK) */