3 #ifndef SOUTHBRIDGE_INTEL_I82801GX_I82801GX_H
4 #define SOUTHBRIDGE_INTEL_I82801GX_I82801GX_H
7 #define DEFAULT_GPIOBASE 0x0480
8 #define DEFAULT_PMBASE 0x0500
13 #define DEBUG_PERIODIC_SMIS 0
24 #define MAINBOARD_POWER_OFF 0
25 #define MAINBOARD_POWER_ON 1
26 #define MAINBOARD_POWER_KEEP 2
34 #define ICH_PCIE_DEV_SLOT 28
38 #define SERIRQ_CNTL 0x64
40 #define GEN_PMCON_1 0xa0
41 #define GEN_PMCON_2 0xa2
42 #define GEN_PMCON_3 0xa4
44 #define GPIO_ROUT 0xb8
45 #define GPI_DISABLE 0x00
46 #define GPI_IS_SMI 0x01
47 #define GPI_IS_SCI 0x02
48 #define GPI_IS_NMI 0x03
51 #define PCIE_4_PORTS_MAX (1 << 7)
52 #define AHCI_UNSUPPORTED (1 << 3)
55 #define RTC_BATTERY_DEAD (1 << 2)
56 #define RTC_POWER_FAILED (1 << 1)
57 #define SLEEP_AFTER_POWER_FAIL (1 << 0)
59 #define ACPI_CNTL 0x44
60 #define ACPI_EN (1 << 7)
61 #define BIOS_CNTL 0xDC
62 #define GPIO_BASE 0x48
63 #define GPIO_CNTL 0x4C
64 #define GPIO_EN (1 << 4)
66 #define PIRQA_ROUT 0x60
67 #define PIRQB_ROUT 0x61
68 #define PIRQC_ROUT 0x62
69 #define PIRQD_ROUT 0x63
70 #define PIRQE_ROUT 0x68
71 #define PIRQF_ROUT 0x69
72 #define PIRQG_ROUT 0x6A
73 #define PIRQH_ROUT 0x6B
75 #define LPC_IO_DEC 0x80
77 #define CNF2_LPC_EN (1 << 13)
78 #define CNF1_LPC_EN (1 << 12)
79 #define MC_LPC_EN (1 << 11)
80 #define KBC_LPC_EN (1 << 10)
81 #define GAMEH_LPC_EN (1 << 9)
82 #define GAMEL_LPC_EN (1 << 8)
83 #define FDD_LPC_EN (1 << 3)
84 #define LPT_LPC_EN (1 << 2)
85 #define COMB_LPC_EN (1 << 1)
86 #define COMA_LPC_EN (1 << 0)
95 #define IDE_TIM_PRI 0x40
96 #define IDE_DECODE_ENABLE (1 << 15)
97 #define IDE_SITRE (1 << 14)
98 #define IDE_ISP_5_CLOCKS (0 << 12)
99 #define IDE_ISP_4_CLOCKS (1 << 12)
100 #define IDE_ISP_3_CLOCKS (2 << 12)
101 #define IDE_RCT_4_CLOCKS (0 << 8)
102 #define IDE_RCT_3_CLOCKS (1 << 8)
103 #define IDE_RCT_2_CLOCKS (2 << 8)
104 #define IDE_RCT_1_CLOCKS (3 << 8)
105 #define IDE_DTE1 (1 << 7)
106 #define IDE_PPE1 (1 << 6)
107 #define IDE_IE1 (1 << 5)
108 #define IDE_TIME1 (1 << 4)
109 #define IDE_DTE0 (1 << 3)
110 #define IDE_PPE0 (1 << 2)
111 #define IDE_IE0 (1 << 1)
112 #define IDE_TIME0 (1 << 0)
113 #define IDE_TIM_SEC 0x42
115 #define IDE_SDMA_CNT 0x48
116 #define IDE_SSDE1 (1 << 3)
117 #define IDE_SSDE0 (1 << 2)
118 #define IDE_PSDE1 (1 << 1)
119 #define IDE_PSDE0 (1 << 0)
121 #define IDE_SDMA_TIM 0x4a
123 #define IDE_CONFIG 0x54
124 #define SIG_MODE_SEC_NORMAL (0 << 18)
125 #define SIG_MODE_SEC_TRISTATE (1 << 18)
126 #define SIG_MODE_SEC_DRIVELOW (2 << 18)
127 #define SIG_MODE_PRI_NORMAL (0 << 16)
128 #define SIG_MODE_PRI_TRISTATE (1 << 16)
129 #define SIG_MODE_PRI_DRIVELOW (2 << 16)
130 #define FAST_SCB1 (1 << 15)
131 #define FAST_SCB0 (1 << 14)
132 #define FAST_PCB1 (1 << 13)
133 #define FAST_PCB0 (1 << 12)
134 #define SCB1 (1 << 3)
135 #define SCB0 (1 << 2)
136 #define PCB1 (1 << 1)
137 #define PCB0 (1 << 0)
140 #define SMB_BASE 0x20
144 #define I2C_EN (1 << 2)
145 #define SMB_SMI_EN (1 << 1)
146 #define HST_EN (1 << 0)
150 #define GPIOBASE 0x48
197 #define RPFN_FNGET(reg, port) (((reg) >> ((port) * 4)) & 7)
199 #define RPFN_FNSET(port, func) (((func) & 7) << ((port) * 4))
201 #define RPFN_FNMASK(port) (7 << ((port) * 4))
239 #define ICH_DISABLE_PCIE(x) (1 << (16 + (x)))
240 #define FD_EHCI (1 << 15)
241 #define FD_LPCB (1 << 14)
246 #define ICH_DISABLE_UHCI(x) (1 << (8 + (x)))
248 #define FD_INTLAN (1 << 7)
249 #define FD_ACMOD (1 << 6)
250 #define FD_ACAUD (1 << 5)
251 #define FD_HDAUD (1 << 4)
252 #define FD_SMBUS (1 << 3)
253 #define FD_SATA (1 << 2)
254 #define FD_PATA (1 << 1)
258 #define WAK_STS (1 << 15)
259 #define PCIEXPWAK_STS (1 << 14)
260 #define PRBTNOR_STS (1 << 11)
261 #define RTC_STS (1 << 10)
262 #define PWRBTN_STS (1 << 8)
263 #define GBL_STS (1 << 5)
264 #define BM_STS (1 << 4)
265 #define TMROF_STS (1 << 0)
267 #define PCIEXPWAK_DIS (1 << 14)
268 #define RTC_EN (1 << 10)
269 #define PWRBTN_EN (1 << 8)
270 #define GBL_EN (1 << 5)
271 #define TMROF_EN (1 << 0)
273 #define GBL_RLS (1 << 2)
274 #define BM_RLD (1 << 1)
275 #define SCI_EN (1 << 0)
277 #define PROC_CNT 0x10
282 #define GPE0_STS 0x28
283 #define USB4_STS (1 << 14)
284 #define PME_B0_STS (1 << 13)
285 #define USB3_STS (1 << 12)
286 #define PME_STS (1 << 11)
287 #define BATLOW_STS (1 << 10)
288 #define PCI_EXP_STS (1 << 9)
289 #define RI_STS (1 << 8)
290 #define SMB_WAK_STS (1 << 7)
291 #define TCOSCI_STS (1 << 6)
292 #define AC97_STS (1 << 5)
293 #define USB2_STS (1 << 4)
294 #define USB1_STS (1 << 3)
295 #define SWGPE_STS (1 << 2)
296 #define HOT_PLUG_STS (1 << 1)
297 #define THRM_STS (1 << 0)
299 #define PME_B0_EN (1 << 13)
300 #define PME_EN (1 << 11)
302 #define EL_SMI_EN (1 << 25)
303 #define INTEL_USB2_EN (1 << 18)
304 #define LEGACY_USB2_EN (1 << 17)
305 #define PERIODIC_EN (1 << 14)
306 #define TCO_EN (1 << 13)
307 #define MCSMI_EN (1 << 11)
308 #define BIOS_RLS (1 << 7)
309 #define SWSMI_TMR_EN (1 << 6)
310 #define APMC_EN (1 << 5)
311 #define SLP_SMI_EN (1 << 4)
312 #define LEGACY_USB_EN (1 << 3)
313 #define BIOS_EN (1 << 2)
315 #define GBL_SMI_EN (1 << 0)
317 #define ALT_GP_SMI_EN 0x38
318 #define ALT_GP_SMI_STS 0x3a
319 #define GPE_CNTL 0x42
320 #define DEVACT_STS 0x44
323 #define TCO1_CNT 0x68
void i82801gx_early_init(void)
void i82801gx_setup_bars(void)
void i82801gx_lpc_setup(void)
void ich7_setup_cir(void)
void i82801gx_enable(struct device *dev)