summaryrefslogtreecommitdiff
path: root/src/southbridge/intel/i82801gx/acpi/usb.asl
blob: 9ae9909a9e9c227232cef5542fddcfdb03a003b8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
/*
 * This file is part of the coreboot project.
 *
 * Copyright (C) 2007-2009 coresystems GmbH
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License as
 * published by the Free Software Foundation; version 2 of
 * the License.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
 * MA 02110-1301 USA
 */

/* Intel i82801G USB support */

// USB Controller 0:1d.0

Device (USB1)
{
	Name(_ADR, 0x001d0000)

	OperationRegion(U01P, PCI_Config, 0, 256)
	Field(U01P, DWordAcc, NoLock, Preserve)
	{
		Offset(0xc4),
		U1WE, 2		// USB Wake Enable
	}

	Name (_PRW, Package(){ 3, 4 }) // Power Resources for Wake

	Method (_PSW, 1)	// Power State Wake method
	{
		// USB Controller can wake OS from Sleep State
		If (Arg0) {
			Store (3, U1WE)
		} Else {
			Store (0, U1WE)
		}
	}

	// Leave USB ports on for to allow Wake from USB

	Method(_S3D,0)	// Highest D State in S3 State
	{
		Return (2)
	}

	Method(_S4D,0)	// Highest D State in S4 State
	{
		Return (2)
	}
}


// USB Controller 0:1d.1

Device (USB2)
{
	Name(_ADR, 0x001d0001)

	OperationRegion(U02P, PCI_Config, 0, 256)
	Field(U02P, DWordAcc, NoLock, Preserve)
	{
		Offset(0xc4),
		U2WE, 2		// USB Wake Enable
	}

	Name (_PRW, Package(){ 3, 4 }) // Power Resources for Wake

	Method (_PSW, 1)	// Power State Wake method
	{
		// USB Controller can wake OS from Sleep State
		If (Arg0) {
			Store (3, U2WE)
		} Else {
			Store (0, U2WE)
		}
	}

	// Leave USB ports on for to allow Wake from USB

	Method(_S3D,0)	// Highest D State in S3 State
	{
		Return (2)
	}

	Method(_S4D,0)	// Highest D State in S4 State
	{
		Return (2)
	}

}


// USB Controller 0:1d.2

Device (USB3)
{
	Name(_ADR, 0x001d0002)

	OperationRegion(U03P, PCI_Config, 0, 256)
	Field(U03P, DWordAcc, NoLock, Preserve)
	{
		Offset(0xc4),
		U3WE, 2		// USB Wake Enable
	}

	Name (_PRW, Package(){ 3, 4 }) // Power Resources for Wake

	Method (_PSW, 1)	// Power State Wake method
	{
		// USB Controller can wake OS from Sleep State
		If (Arg0) {
			Store (3, U3WE)
		} Else {
			Store (0, U3WE)
		}
	}

	// Leave USB ports on for to allow Wake from USB

	Method(_S3D,0)	// Highest D State in S3 State
	{
		Return (2)
	}

	Method(_S4D,0)	// Highest D State in S4 State
	{
		Return (2)
	}

}


// USB Controller 0:1d.3

Device (USB4)
{
	Name(_ADR, 0x001d0003)

	OperationRegion(U04P, PCI_Config, 0, 256)
	Field(U04P, DWordAcc, NoLock, Preserve)
	{
		Offset(0xc4),
		U4WE, 2		// USB Wake Enable
	}

	Name (_PRW, Package(){ 3, 4 }) // Power Resources for Wake

	Method (_PSW, 1)	// Power State Wake method
	{
		// USB Controller can wake OS from Sleep State
		If (Arg0) {
			Store (3, U4WE)
		} Else {
			Store (0, U4WE)
		}
	}

	// Leave USB ports on for to allow Wake from USB

	Method(_S3D,0)	// Highest D State in S3 State
	{
		Return (2)
	}

	Method(_S4D,0)	// Highest D State in S4 State
	{
		Return (2)
	}

}


// EHCI Controller 0:1d.7

Device (EHC1)
{
	Name(_ADR, 0x001d0007)

	Name (_PRW, Package(){ 13, 4 }) // Power Resources for Wake

	// Leave USB ports on for to allow Wake from USB

	Method(_S3D,0)	// Highest D State in S3 State
	{
		Return (2)
	}

	Method(_S4D,0)	// Highest D State in S4 State
	{
		Return (2)
	}

	Device (HUB7)
	{
		Name (_ADR, 0x00000000)

		// How many are there?
		Device (PRT1) { Name (_ADR, 1) } // USB Port 0
		Device (PRT2) { Name (_ADR, 2) } // USB Port 1
		Device (PRT3) { Name (_ADR, 3) } // USB Port 2
		Device (PRT4) { Name (_ADR, 4) } // USB Port 3
		Device (PRT5) { Name (_ADR, 5) } // USB Port 4
		Device (PRT6) { Name (_ADR, 6) } // USB Port 5
	}
}