soc: Remove copyright notices
[coreboot.git] / src / soc / intel / cannonlake / acpi / lpit.asl
blob6ae4975ee16a29bfd30be6d9b7c277b355758c0f
1 /*
2  * This file is part of the coreboot project.
3  *
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
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 External(\_SB.MS0X, MethodObj)
17 External(\_SB.PCI0.LPCB.EC0.S0IX, MethodObj)
18 External(\_SB.PCI0.EGPM, MethodObj)
19 External(\_SB.PCI0.RGPM, MethodObj)
21 scope(\_SB)
23         Device(LPID) {
24         Name(_ADR, 0x00000000)
25         Name(_CID, EISAID("PNP0D80"))
26         Name(UUID,
27                 ToUUID("c4eb40a0-6cd2-11e2-bcfd-0800200c9a66"))
28                 Method(_DSM, 4) {
29                         If(Arg0 == ^UUID) {
30                         /*
31                          * Enum functions
32                          */
33                         If(Arg2 == Zero) {
34                                 Return(Buffer(One) {
35                                        0x60}
36                                 )
37                         }
38                         /*
39                          * Function 1 - Get Device Constraints
40                          */
41                         If(Arg2 == 1) {
42                                 Return(Package(5) {
43                                        0, Ones, Ones, Ones, Ones}
44                                 )
45                         }
46                         /*
47                          * Function 2 - Get Crash Dump Device
48                          */
49                         If(Arg2 == 2) {
50                                 Return(Buffer(One) {
51                                        0x0}
52                                 )
53                         }
54                         /*
55                          * Function 3 - Display Off Notification
56                          */
57                         If(Arg2 == 3) {
58                         }
59                         /*
60                          * Function 4 - Display On Notification
61                          */
62                         If(Arg2 == 4) {
63                         }
64                         /*
65                          * Function 5 - Low Power S0 Entry Notification
66                          */
67                         If(Arg2 == 5) {
68                                 /* Inform the EC */
69                                 If (CondRefOf (\_SB.PCI0.LPCB.EC0.S0IX)) {
70                                         \_SB.PCI0.LPCB.EC0.S0IX(1)
71                                 }
73                                 /* provide board level s0ix hook */
74                                 If (CondRefOf (\_SB.MS0X)) {
75                                         \_SB.MS0X(1)
76                                 }
78                                 /*
79                                  * Save the current PM bits then
80                                  * enable GPIO PM with MISCCFG_ENABLE_GPIO_PM_CONFIG
81                                  */
82                                 If (CondRefOf (\_SB.PCI0.EGPM))
83                                 {
84                                         \_SB.PCI0.EGPM ()
85                                 }
86                         }
87                         /*
88                          * Function 6 - Low Power S0 Exit Notification
89                          */
90                         If(Arg2 == 6) {
91                                 /* Inform the EC */
92                                 If (CondRefOf (\_SB.PCI0.LPCB.EC0.S0IX)) {
93                                         \_SB.PCI0.LPCB.EC0.S0IX(0)
94                                 }
96                                 /* provide board level s0ix hook */
97                                 If (CondRefOf (\_SB.MS0X)) {
98                                         \_SB.MS0X(0)
99                                 }
101                                 /* Restore GPIO all Community PM */
102                                 If (CondRefOf (\_SB.PCI0.RGPM))
103                                 {
104                                         \_SB.PCI0.RGPM ()
105                                 }
106                         }
107                 }
108                 Return(Buffer(One) {0x00})
109                 }               // Method(_DSM)
110         }                       // device (LPID)
111 }                               // End Scope(\_SB)