blob: 0a22162fc2ef5eee22d752e731292c05f0e70a38 [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
Lee Leahy32471722015-04-20 15:20:28 -07003/* Intel LPC Bus Device - 0:1f.0 */
Lee Leahy77ff0b12015-05-05 15:07:29 -07004
5Device (LPCB)
6{
7 Name(_ADR, 0x001f0000)
8
9 #include "irqlinks.asl"
10
11 #include "acpi/ec.asl"
12
Lee Leahy32471722015-04-20 15:20:28 -070013 Device (DMAC) /* DMA Controller */
Lee Leahy77ff0b12015-05-05 15:07:29 -070014 {
15 Name(_HID, EISAID("PNP0200"))
16 Name(_CRS, ResourceTemplate()
17 {
18 IO (Decode16, 0x00, 0x00, 0x01, 0x20)
19 IO (Decode16, 0x81, 0x81, 0x01, 0x11)
20 IO (Decode16, 0x93, 0x93, 0x01, 0x0d)
21 IO (Decode16, 0xc0, 0xc0, 0x01, 0x20)
22 DMA (Compatibility, NotBusMaster, Transfer8_16) { 4 }
23 })
24 }
25
Lee Leahy32471722015-04-20 15:20:28 -070026 Device (FWH) /* Firmware Hub */
Lee Leahy77ff0b12015-05-05 15:07:29 -070027 {
28 Name (_HID, EISAID("INT0800"))
Frans Hendriks6665da82019-04-25 11:17:05 +020029 Name (RBUF, ResourceTemplate()
Lee Leahy77ff0b12015-05-05 15:07:29 -070030 {
Frans Hendriks6665da82019-04-25 11:17:05 +020031 Memory32Fixed(ReadOnly, 0, 0, FBAR)
Lee Leahy77ff0b12015-05-05 15:07:29 -070032 })
Frans Hendriks6665da82019-04-25 11:17:05 +020033
34 Method (_CRS)
35 {
36 CreateDwordField (^RBUF, ^FBAR._BAS, FBAS)
37 CreateDwordField (^RBUF, ^FBAR._LEN, FLEN)
38 Multiply(CONFIG_COREBOOT_ROMSIZE_KB, 1024, Local0)
39 Store(Local0, FLEN)
40 Add(Subtract(0xffffffff, Local0), 1, FBAS)
41 Return (^RBUF)
42 }
Lee Leahy77ff0b12015-05-05 15:07:29 -070043 }
44
Julius Wernercd49cce2019-03-05 16:53:33 -080045#if !CONFIG(DISABLE_HPET)
Lee Leahy77ff0b12015-05-05 15:07:29 -070046 Device (HPET)
47 {
48 Name (_HID, EISAID("PNP0103"))
49 Name (_CID, 0x010CD041)
50
Lee Leahy32471722015-04-20 15:20:28 -070051 Method (_STA, 0) /* Device Status */
Lee Leahy77ff0b12015-05-05 15:07:29 -070052 {
Lee Leahy32471722015-04-20 15:20:28 -070053 Return (0xf) /* Enable and show device */
Lee Leahy77ff0b12015-05-05 15:07:29 -070054 }
55
56 Name(_CRS, ResourceTemplate()
57 {
Elyes HAOUAS1644e482019-10-30 11:28:42 +010058 Memory32Fixed(ReadOnly, CONFIG_HPET_ADDRESS, 0x400)
Lee Leahy77ff0b12015-05-05 15:07:29 -070059 })
60 }
Frans Hendriksf2af7022018-11-16 12:08:41 +010061#endif
Lee Leahy77ff0b12015-05-05 15:07:29 -070062
Lee Leahy32471722015-04-20 15:20:28 -070063 Device(PIC) /* 8259 Interrupt Controller */
Lee Leahy77ff0b12015-05-05 15:07:29 -070064 {
65 Name(_HID,EISAID("PNP0000"))
66 Name(_CRS, ResourceTemplate()
67 {
68 IO (Decode16, 0x20, 0x20, 0x01, 0x02)
69 IO (Decode16, 0x24, 0x24, 0x01, 0x02)
70 IO (Decode16, 0x28, 0x28, 0x01, 0x02)
71 IO (Decode16, 0x2c, 0x2c, 0x01, 0x02)
72 IO (Decode16, 0x30, 0x30, 0x01, 0x02)
73 IO (Decode16, 0x34, 0x34, 0x01, 0x02)
74 IO (Decode16, 0x38, 0x38, 0x01, 0x02)
75 IO (Decode16, 0x3c, 0x3c, 0x01, 0x02)
76 IO (Decode16, 0xa0, 0xa0, 0x01, 0x02)
77 IO (Decode16, 0xa4, 0xa4, 0x01, 0x02)
78 IO (Decode16, 0xa8, 0xa8, 0x01, 0x02)
79 IO (Decode16, 0xac, 0xac, 0x01, 0x02)
80 IO (Decode16, 0xb0, 0xb0, 0x01, 0x02)
81 IO (Decode16, 0xb4, 0xb4, 0x01, 0x02)
82 IO (Decode16, 0xb8, 0xb8, 0x01, 0x02)
83 IO (Decode16, 0xbc, 0xbc, 0x01, 0x02)
84 IO (Decode16, 0x4d0, 0x4d0, 0x01, 0x02)
85 IRQNoFlags () { 2 }
86 })
87 }
88
Lee Leahy32471722015-04-20 15:20:28 -070089 Device(LDRC) /* LPC device: Resource consumption */
Lee Leahy77ff0b12015-05-05 15:07:29 -070090 {
91 Name (_HID, EISAID("PNP0C02"))
92 Name (_UID, 2)
93
94 Name (RBUF, ResourceTemplate()
95 {
Lee Leahy32471722015-04-20 15:20:28 -070096 IO (Decode16, 0x61, 0x61, 0x1, 0x01) /* NMI Status */
97 IO (Decode16, 0x63, 0x63, 0x1, 0x01) /* CPU Reserved */
98 IO (Decode16, 0x65, 0x65, 0x1, 0x01) /* CPU Reserved */
99 IO (Decode16, 0x67, 0x67, 0x1, 0x01) /* CPU Reserved */
100 IO (Decode16, 0x80, 0x80, 0x1, 0x01) /* Port 80 Post */
101 IO (Decode16, 0x92, 0x92, 0x1, 0x01) /* CPU Reserved */
102 IO (Decode16, 0xb2, 0xb2, 0x1, 0x02) /* SWSMI */
Frans Hendriksf01a1592018-10-31 10:07:11 +0100103 IO (Decode16, ACPI_BASE_ADDRESS, ACPI_BASE_ADDRESS,
104 0x1, ACPI_BASE_SIZE) /* ACPI Base */
105 IO (Decode16, GPIO_BASE_ADDRESS, GPIO_BASE_ADDRESS,
106 0x1, 0xff) /* GPIO Base */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700107 })
108
109 Method (_CRS, 0, NotSerialized)
110 {
111 Return (RBUF)
112 }
113 }
114
Lee Leahy32471722015-04-20 15:20:28 -0700115 Device (RTC) /* Real Time Clock */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700116 {
117 Name (_HID, EISAID("PNP0B00"))
118 Name (_CRS, ResourceTemplate()
119 {
120 IO (Decode16, 0x70, 0x70, 1, 8)
Lee Leahy77ff0b12015-05-05 15:07:29 -0700121 })
122 }
123
Lee Leahy32471722015-04-20 15:20:28 -0700124 Device (TIMR) /* Intel 8254 timer */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700125 {
126 Name(_HID, EISAID("PNP0100"))
127 Name(_CRS, ResourceTemplate()
128 {
129 IO (Decode16, 0x40, 0x40, 0x01, 0x04)
130 IO (Decode16, 0x50, 0x50, 0x10, 0x04)
131 IRQNoFlags() {0}
132 })
133 }
134
Lee Leahy32471722015-04-20 15:20:28 -0700135 /* Include mainboard's superio.asl file. */
Lee Leahy77ff0b12015-05-05 15:07:29 -0700136 #include "acpi/superio.asl"
Lee Leahy77ff0b12015-05-05 15:07:29 -0700137}