tree: drop last paragraph of GPL copyright header
[coreboot.git] / src / mainboard / amd / inagua / acpi / usb_oc.asl
blob299d4aa55c4acc11d3c1f846be5e200699ff69bd
1 /*
2  * This file is part of the coreboot project.
3  *
4  * Copyright (C) 2011 Advanced Micro Devices, Inc.
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 /* simple name description */
18 DefinitionBlock ("DSDT.AML","DSDT",0x01,"XXXXXX","XXXXXXXX",0x00010001
19                 )
20         {
21                 #include "usb.asl"
22         }
25 /* USB overcurrent mapping pins.   */
26 Name(UOM0, 0)
27 Name(UOM1, 2)
28 Name(UOM2, 0)
29 Name(UOM3, 7)
30 Name(UOM4, 2)
31 Name(UOM5, 2)
32 Name(UOM6, 6)
33 Name(UOM7, 2)
34 Name(UOM8, 6)
35 Name(UOM9, 6)
37 Method(UCOC, 0) {
38         Sleep(20)
39         Store(0x13,CMTI)
40         Store(0,GPSL)
43 /* USB Port 0 overcurrent uses Gpm 0 */
44 If(LLessEqual(UOM0,9)) {
45         Scope (\_GPE) {
46                 Method (_L13) {
47                         UCOC()
48                         if(LEqual(GPB0,PLC0)) {
49                                 Not(PLC0,PLC0)
50                                 Store(PLC0, \_SB.PT0D)
51                         }
52                 }
53         }
56 /* USB Port 1 overcurrent uses Gpm 1 */
57 If (LLessEqual(UOM1,9)) {
58         Scope (\_GPE) {
59                 Method (_L14) {
60                         UCOC()
61                         if (LEqual(GPB1,PLC1)) {
62                                 Not(PLC1,PLC1)
63                                 Store(PLC1, \_SB.PT1D)
64                         }
65                 }
66         }
69 /* USB Port 2 overcurrent uses Gpm 2 */
70 If (LLessEqual(UOM2,9)) {
71         Scope (\_GPE) {
72                 Method (_L15) {
73                         UCOC()
74                         if (LEqual(GPB2,PLC2)) {
75                                 Not(PLC2,PLC2)
76                                 Store(PLC2, \_SB.PT2D)
77                         }
78                 }
79         }
82 /* USB Port 3 overcurrent uses Gpm 3 */
83 If (LLessEqual(UOM3,9)) {
84         Scope (\_GPE) {
85                 Method (_L16) {
86                         UCOC()
87                         if (LEqual(GPB3,PLC3)) {
88                                 Not(PLC3,PLC3)
89                                 Store(PLC3, \_SB.PT3D)
90                         }
91                 }
92         }
95 /* USB Port 4 overcurrent uses Gpm 4 */
96 If (LLessEqual(UOM4,9)) {
97         Scope (\_GPE) {
98                 Method (_L19) {
99                         UCOC()
100                         if (LEqual(GPB4,PLC4)) {
101                                 Not(PLC4,PLC4)
102                                 Store(PLC4, \_SB.PT4D)
103                         }
104                 }
105         }
108 /* USB Port 5 overcurrent uses Gpm 5 */
109 If (LLessEqual(UOM5,9)) {
110         Scope (\_GPE) {
111                 Method (_L1A) {
112                         UCOC()
113                         if (LEqual(GPB5,PLC5)) {
114                                 Not(PLC5,PLC5)
115                                 Store(PLC5, \_SB.PT5D)
116                         }
117                 }
118         }
121 /* USB Port 6 overcurrent uses Gpm 6 */
122 If (LLessEqual(UOM6,9)) {
123         Scope (\_GPE) {
124                 /* Method (_L1C) { */
125                 Method (_L06) {
126                         UCOC()
127                         if (LEqual(GPB6,PLC6)) {
128                                 Not(PLC6,PLC6)
129                                 Store(PLC6, \_SB.PT6D)
130                         }
131                 }
132         }
135 /* USB Port 7 overcurrent uses Gpm 7 */
136 If (LLessEqual(UOM7,9)) {
137         Scope (\_GPE) {
138                 /* Method (_L1D) { */
139                 Method (_L07) {
140                         UCOC()
141                         if (LEqual(GPB7,PLC7)) {
142                                 Not(PLC7,PLC7)
143                                 Store(PLC7, \_SB.PT7D)
144                         }
145                 }
146         }
149 /* USB Port 8 overcurrent uses Gpm 8 */
150 If (LLessEqual(UOM8,9)) {
151         Scope (\_GPE) {
152                 Method (_L17) {
153                         if (LEqual(G8IS,PLC8)) {
154                                 Not(PLC8,PLC8)
155                                 Store(PLC8, \_SB.PT8D)
156                         }
157                 }
158         }
161 /* USB Port 9 overcurrent uses Gpm 9 */
162 If (LLessEqual(UOM9,9)) {
163         Scope (\_GPE) {
164                 Method (_L0E) {
165                         if (LEqual(G9IS,0)) {
166                         Store(1,\_SB.PT9D)
167                         }
168                 }
169         }