blob: b1d9d6acb52fcc98a81d2e388e5e25ee26a4515c [file] [log] [blame]
Angel Ponsba38f372020-04-05 15:46:45 +02001/* SPDX-License-Identifier: GPL-2.0-only */
Lee Leahy77ff0b12015-05-05 15:07:29 -07002
3Device (LNKA)
4{
5 Name (_HID, EISAID("PNP0C0F"))
6 Name (_UID, 1)
7
Lee Leahy32471722015-04-20 15:20:28 -07008 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -07009 Method (_DIS, 0, Serialized)
10 {
Felix Singer84e61232022-12-12 07:39:15 +010011 PRTA = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -070012 }
13
Lee Leahy32471722015-04-20 15:20:28 -070014 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -070015 Name (_PRS, ResourceTemplate()
16 {
17 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +020018 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -070019 })
20
Lee Leahy32471722015-04-20 15:20:28 -070021 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -070022 Method (_CRS, 0, Serialized)
23 {
24 Name (RTLA, ResourceTemplate()
25 {
26 IRQ(Level, ActiveLow, Shared) {}
27 })
28 CreateWordField(RTLA, 1, IRQ0)
29
Lee Leahy32471722015-04-20 15:20:28 -070030 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +010031 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -070032
Lee Leahy32471722015-04-20 15:20:28 -070033 /* Set the bit from PRTA */
Felix Singerd2527762022-12-16 07:54:16 +010034 IRQ0 = 1 << (PRTA & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -070035
36 Return (RTLA)
37 }
38
Lee Leahy32471722015-04-20 15:20:28 -070039 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -070040 Method (_SRS, 1, Serialized)
41 {
42 CreateWordField(Arg0, 1, IRQ0)
43
Lee Leahy32471722015-04-20 15:20:28 -070044 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -070045 FindSetRightBit(IRQ0, Local0)
46
Felix Singer43b57302022-12-11 21:46:42 +010047 Local0--
Felix Singer84e61232022-12-12 07:39:15 +010048 PRTA = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -070049 }
50
Lee Leahy32471722015-04-20 15:20:28 -070051 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -070052 Method (_STA, 0, Serialized)
53 {
Felix Singerd2527762022-12-16 07:54:16 +010054 If (PRTA & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -070055 Return (0x9)
56 } Else {
57 Return (0xb)
58 }
59 }
60}
61
62Device (LNKB)
63{
64 Name (_HID, EISAID("PNP0C0F"))
65 Name (_UID, 2)
66
Lee Leahy32471722015-04-20 15:20:28 -070067 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -070068 Method (_DIS, 0, Serialized)
69 {
Felix Singer84e61232022-12-12 07:39:15 +010070 PRTB = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -070071 }
72
Lee Leahy32471722015-04-20 15:20:28 -070073 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -070074 Name (_PRS, ResourceTemplate()
75 {
76 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +020077 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -070078 })
79
Lee Leahy32471722015-04-20 15:20:28 -070080 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -070081 Method (_CRS, 0, Serialized)
82 {
83 Name (RTLB, ResourceTemplate()
84 {
85 IRQ(Level, ActiveLow, Shared) {}
86 })
87 CreateWordField(RTLB, 1, IRQ0)
88
Lee Leahy32471722015-04-20 15:20:28 -070089 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +010090 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -070091
Lee Leahy32471722015-04-20 15:20:28 -070092 /* Set the bit from PRTB */
Felix Singerd2527762022-12-16 07:54:16 +010093 IRQ0 = 1 << (PRTB & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -070094
95 Return (RTLB)
96 }
97
Lee Leahy32471722015-04-20 15:20:28 -070098 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -070099 Method (_SRS, 1, Serialized)
100 {
101 CreateWordField(Arg0, 1, IRQ0)
102
Lee Leahy32471722015-04-20 15:20:28 -0700103 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700104 FindSetRightBit(IRQ0, Local0)
105
Felix Singer43b57302022-12-11 21:46:42 +0100106 Local0--
Felix Singer84e61232022-12-12 07:39:15 +0100107 PRTB = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700108 }
109
Lee Leahy32471722015-04-20 15:20:28 -0700110 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700111 Method (_STA, 0, Serialized)
112 {
Felix Singerd2527762022-12-16 07:54:16 +0100113 If (PRTB & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -0700114 Return (0x9)
115 } Else {
116 Return (0xb)
117 }
118 }
119}
120
121Device (LNKC)
122{
123 Name (_HID, EISAID("PNP0C0F"))
124 Name (_UID, 3)
125
Lee Leahy32471722015-04-20 15:20:28 -0700126 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700127 Method (_DIS, 0, Serialized)
128 {
Felix Singer84e61232022-12-12 07:39:15 +0100129 PRTC = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -0700130 }
131
Lee Leahy32471722015-04-20 15:20:28 -0700132 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700133 Name (_PRS, ResourceTemplate()
134 {
135 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +0200136 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -0700137 })
138
Lee Leahy32471722015-04-20 15:20:28 -0700139 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700140 Method (_CRS, 0, Serialized)
141 {
142 Name (RTLC, ResourceTemplate()
143 {
144 IRQ(Level, ActiveLow, Shared) {}
145 })
146 CreateWordField(RTLC, 1, IRQ0)
147
Lee Leahy32471722015-04-20 15:20:28 -0700148 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +0100149 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700150
Lee Leahy32471722015-04-20 15:20:28 -0700151 /* Set the bit from PRTC */
Felix Singerd2527762022-12-16 07:54:16 +0100152 IRQ0 = 1 << (PRTC & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -0700153
154 Return (RTLC)
155 }
156
Lee Leahy32471722015-04-20 15:20:28 -0700157 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700158 Method (_SRS, 1, Serialized)
159 {
160 CreateWordField(Arg0, 1, IRQ0)
161
Lee Leahy32471722015-04-20 15:20:28 -0700162 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700163 FindSetRightBit(IRQ0, Local0)
164
Felix Singer43b57302022-12-11 21:46:42 +0100165 Local0--
Felix Singer84e61232022-12-12 07:39:15 +0100166 PRTC = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700167 }
168
Lee Leahy32471722015-04-20 15:20:28 -0700169 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700170 Method (_STA, 0, Serialized)
171 {
Felix Singerd2527762022-12-16 07:54:16 +0100172 If (PRTC & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -0700173 Return (0x9)
174 } Else {
175 Return (0xb)
176 }
177 }
178}
179
180Device (LNKD)
181{
182 Name (_HID, EISAID("PNP0C0F"))
183 Name (_UID, 4)
184
Lee Leahy32471722015-04-20 15:20:28 -0700185 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700186 Method (_DIS, 0, Serialized)
187 {
Felix Singer84e61232022-12-12 07:39:15 +0100188 PRTD = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -0700189 }
190
Lee Leahy32471722015-04-20 15:20:28 -0700191 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700192 Name (_PRS, ResourceTemplate()
193 {
194 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +0200195 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -0700196 })
197
Lee Leahy32471722015-04-20 15:20:28 -0700198 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700199 Method (_CRS, 0, Serialized)
200 {
201 Name (RTLD, ResourceTemplate()
202 {
203 IRQ(Level, ActiveLow, Shared) {}
204 })
205 CreateWordField(RTLD, 1, IRQ0)
206
Lee Leahy32471722015-04-20 15:20:28 -0700207 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +0100208 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700209
Lee Leahy32471722015-04-20 15:20:28 -0700210 /* Set the bit from PRTD */
Felix Singerd2527762022-12-16 07:54:16 +0100211 IRQ0 = 1 << (PRTD & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -0700212
213 Return (RTLD)
214 }
215
Lee Leahy32471722015-04-20 15:20:28 -0700216 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700217 Method (_SRS, 1, Serialized)
218 {
219 CreateWordField(Arg0, 1, IRQ0)
220
Lee Leahy32471722015-04-20 15:20:28 -0700221 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700222 FindSetRightBit(IRQ0, Local0)
223
Felix Singer43b57302022-12-11 21:46:42 +0100224 Local0--
Felix Singer84e61232022-12-12 07:39:15 +0100225 PRTD = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700226 }
227
Lee Leahy32471722015-04-20 15:20:28 -0700228 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700229 Method (_STA, 0, Serialized)
230 {
Felix Singerd2527762022-12-16 07:54:16 +0100231 If (PRTD & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -0700232 Return (0x9)
233 } Else {
234 Return (0xb)
235 }
236 }
237}
238
239Device (LNKE)
240{
241 Name (_HID, EISAID("PNP0C0F"))
242 Name (_UID, 5)
243
Lee Leahy32471722015-04-20 15:20:28 -0700244 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700245 Method (_DIS, 0, Serialized)
246 {
Felix Singer84e61232022-12-12 07:39:15 +0100247 PRTE = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -0700248 }
249
Lee Leahy32471722015-04-20 15:20:28 -0700250 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700251 Name (_PRS, ResourceTemplate()
252 {
253 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +0200254 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -0700255 })
256
Lee Leahy32471722015-04-20 15:20:28 -0700257 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700258 Method (_CRS, 0, Serialized)
259 {
260 Name (RTLE, ResourceTemplate()
261 {
262 IRQ(Level, ActiveLow, Shared) {}
263 })
264 CreateWordField(RTLE, 1, IRQ0)
265
Lee Leahy32471722015-04-20 15:20:28 -0700266 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +0100267 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700268
Lee Leahy32471722015-04-20 15:20:28 -0700269 /* Set the bit from PRTE */
Felix Singerd2527762022-12-16 07:54:16 +0100270 IRQ0 = 1 << (PRTE & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -0700271
272 Return (RTLE)
273 }
274
Lee Leahy32471722015-04-20 15:20:28 -0700275 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700276 Method (_SRS, 1, Serialized)
277 {
278 CreateWordField(Arg0, 1, IRQ0)
279
Lee Leahy32471722015-04-20 15:20:28 -0700280 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700281 FindSetRightBit(IRQ0, Local0)
282
Felix Singer43b57302022-12-11 21:46:42 +0100283 Local0--
Felix Singer84e61232022-12-12 07:39:15 +0100284 PRTE = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700285 }
286
Lee Leahy32471722015-04-20 15:20:28 -0700287 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700288 Method (_STA, 0, Serialized)
289 {
Felix Singerd2527762022-12-16 07:54:16 +0100290 If (PRTE & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -0700291 Return (0x9)
292 } Else {
293 Return (0xb)
294 }
295 }
296}
297
298Device (LNKF)
299{
300 Name (_HID, EISAID("PNP0C0F"))
301 Name (_UID, 6)
302
Lee Leahy32471722015-04-20 15:20:28 -0700303 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700304 Method (_DIS, 0, Serialized)
305 {
Felix Singer84e61232022-12-12 07:39:15 +0100306 PRTF = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -0700307 }
308
Lee Leahy32471722015-04-20 15:20:28 -0700309 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700310 Name (_PRS, ResourceTemplate()
311 {
312 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +0200313 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -0700314 })
315
Lee Leahy32471722015-04-20 15:20:28 -0700316 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700317 Method (_CRS, 0, Serialized)
318 {
319 Name (RTLF, ResourceTemplate()
320 {
321 IRQ(Level, ActiveLow, Shared) {}
322 })
323 CreateWordField(RTLF, 1, IRQ0)
324
Lee Leahy32471722015-04-20 15:20:28 -0700325 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +0100326 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700327
Lee Leahy32471722015-04-20 15:20:28 -0700328 /* Set the bit from PRTF */
Felix Singerd2527762022-12-16 07:54:16 +0100329 IRQ0 = 1 << (PRTF & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -0700330
331 Return (RTLF)
332 }
333
Lee Leahy32471722015-04-20 15:20:28 -0700334 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700335 Method (_SRS, 1, Serialized)
336 {
337 CreateWordField(Arg0, 1, IRQ0)
338
Lee Leahy32471722015-04-20 15:20:28 -0700339 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700340 FindSetRightBit(IRQ0, Local0)
341
Felix Singer43b57302022-12-11 21:46:42 +0100342 Local0--
Felix Singer84e61232022-12-12 07:39:15 +0100343 PRTF = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700344 }
345
Lee Leahy32471722015-04-20 15:20:28 -0700346 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700347 Method (_STA, 0, Serialized)
348 {
Felix Singerd2527762022-12-16 07:54:16 +0100349 If (PRTF & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -0700350 Return (0x9)
351 } Else {
352 Return (0xb)
353 }
354 }
355}
356
357Device (LNKG)
358{
359 Name (_HID, EISAID("PNP0C0F"))
360 Name (_UID, 7)
361
Lee Leahy32471722015-04-20 15:20:28 -0700362 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700363 Method (_DIS, 0, Serialized)
364 {
Felix Singer84e61232022-12-12 07:39:15 +0100365 PRTG = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -0700366 }
367
Lee Leahy32471722015-04-20 15:20:28 -0700368 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700369 Name (_PRS, ResourceTemplate()
370 {
371 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +0200372 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -0700373 })
374
Lee Leahy32471722015-04-20 15:20:28 -0700375 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700376 Method (_CRS, 0, Serialized)
377 {
378 Name (RTLG, ResourceTemplate()
379 {
380 IRQ(Level, ActiveLow, Shared) {}
381 })
382 CreateWordField(RTLG, 1, IRQ0)
383
Lee Leahy32471722015-04-20 15:20:28 -0700384 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +0100385 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700386
Lee Leahy32471722015-04-20 15:20:28 -0700387 /* Set the bit from PRTG */
Felix Singerd2527762022-12-16 07:54:16 +0100388 IRQ0 = 1 << (PRTG & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -0700389
390 Return (RTLG)
391 }
392
Lee Leahy32471722015-04-20 15:20:28 -0700393 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700394 Method (_SRS, 1, Serialized)
395 {
396 CreateWordField(Arg0, 1, IRQ0)
397
Lee Leahy32471722015-04-20 15:20:28 -0700398 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700399 FindSetRightBit(IRQ0, Local0)
400
Felix Singer43b57302022-12-11 21:46:42 +0100401 Local0--
Felix Singer84e61232022-12-12 07:39:15 +0100402 PRTG = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700403 }
404
Lee Leahy32471722015-04-20 15:20:28 -0700405 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700406 Method (_STA, 0, Serialized)
407 {
Felix Singerd2527762022-12-16 07:54:16 +0100408 If (PRTG & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -0700409 Return (0x9)
410 } Else {
411 Return (0xb)
412 }
413 }
414}
415
416Device (LNKH)
417{
418 Name (_HID, EISAID("PNP0C0F"))
419 Name (_UID, 8)
420
Lee Leahy32471722015-04-20 15:20:28 -0700421 /* Disable method */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700422 Method (_DIS, 0, Serialized)
423 {
Felix Singer84e61232022-12-12 07:39:15 +0100424 PRTH = 0x80
Lee Leahy77ff0b12015-05-05 15:07:29 -0700425 }
426
Lee Leahy32471722015-04-20 15:20:28 -0700427 /* Possible Resource Settings for this Link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700428 Name (_PRS, ResourceTemplate()
429 {
430 IRQ(Level, ActiveLow, Shared)
Frans Hendriks3e8504a2018-10-26 12:29:28 +0200431 { 1, 3, 4, 5, 6, 7, 10, 11, 12, 14, 15 }
Lee Leahy77ff0b12015-05-05 15:07:29 -0700432 })
433
Lee Leahy32471722015-04-20 15:20:28 -0700434 /* Current Resource Settings for this link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700435 Method (_CRS, 0, Serialized)
436 {
437 Name (RTLH, ResourceTemplate()
438 {
439 IRQ(Level, ActiveLow, Shared) {}
440 })
441 CreateWordField(RTLH, 1, IRQ0)
442
Lee Leahy32471722015-04-20 15:20:28 -0700443 /* Clear the WordField */
Felix Singer9df60d32022-12-26 09:43:07 +0100444 IRQ0 = 0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700445
Lee Leahy32471722015-04-20 15:20:28 -0700446 /* Set the bit from PRTH */
Felix Singerd2527762022-12-16 07:54:16 +0100447 IRQ0 = 1 << (PRTH & 0x0f)
Lee Leahy77ff0b12015-05-05 15:07:29 -0700448
449 Return (RTLH)
450 }
451
Lee Leahy32471722015-04-20 15:20:28 -0700452 /* Set Resource Setting for this IRQ link */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700453 Method (_SRS, 1, Serialized)
454 {
455 CreateWordField(Arg0, 1, IRQ0)
456
Lee Leahy32471722015-04-20 15:20:28 -0700457 /* Which bit is set? */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700458 FindSetRightBit(IRQ0, Local0)
459
Felix Singer43b57302022-12-11 21:46:42 +0100460 Local0--
Felix Singer84e61232022-12-12 07:39:15 +0100461 PRTH = Local0
Lee Leahy77ff0b12015-05-05 15:07:29 -0700462 }
463
Lee Leahy32471722015-04-20 15:20:28 -0700464 /* Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700465 Method (_STA, 0, Serialized)
466 {
Felix Singerd2527762022-12-16 07:54:16 +0100467 If (PRTH & 0x80) {
Lee Leahy77ff0b12015-05-05 15:07:29 -0700468 Return (0x9)
469 } Else {
470 Return (0xb)
471 }
472 }
473}