12 # define PMC_WDT_STS (1 << 15)
13 # define SEC_GBLRST_STS (1 << 7)
14 # define SEC_WDT_STS (1 << 6)
15 # define WOL_OVR_WK_STS (1 << 5)
16 # define PMC_WAKE_STS (1 << 4)
19 # define NO_REBOOT (1 << 4)
20 # define SX_ENT_TO_EN (1 << 3)
21 # define TIMING_T581_SHIFT (0)
22 # define TIMING_T581_MASK (3 << TIMING_T581_SHIFT)
23 # define TIMING_T581_10uS (0 << TIMING_T581_SHIFT)
24 # define TIMING_T581_100uS (1 << TIMING_T581_SHIFT)
25 # define TIMING_T581_1mS (2 << TIMING_T581_SHIFT)
26 # define TIMING_T581_10mS (3 << TIMING_T581_SHIFT)
27 #define VLV_PM_STS 0x0c
28 # define PMC_MSG_FULL_STS (1 << 24)
29 # define PMC_MSG_4_FULL_STS (1 << 23)
30 # define PMC_MSG_3_FULL_STS (1 << 22)
31 # define PMC_MSG_2_FULL_STS (1 << 21)
32 # define PMC_MSG_1_FULL_STS (1 << 20)
33 # define CODE_REQ (1 << 8)
34 # define HPR_ENT_TO (1 << 2)
35 # define SX_ENT_TO (1 << 1)
36 #define GEN_PMCON1 0x20
37 # define UART_EN (1 << 24)
38 # define DISB (1 << 23)
39 # define MEM_SR (1 << 21)
40 # define SRS (1 << 20)
41 # define CTS (1 << 19)
42 # define MS4V (1 << 18)
43 # define PWR_FLR (1 << 16)
44 # define PME_B0_S5_DIS (1 << 15)
45 # define SUS_PWR_FLR (1 << 14)
46 # define WOL_EN_OVRD (1 << 13)
47 # define DIS_SLP_X_STRCH_SUS_UP (1 << 12)
48 # define GEN_RST_STS (1 << 9)
50 # define AFTERG3_EN (1 << 0)
51 #define GEN_PMCON2 0x24
52 # define SLPSX_STR_POL_LOCK (1 << 18)
53 # define BIOS_PCI_EXP_EN (1 << 10)
54 # define PWRBTN_LVL (1 << 9)
55 # define SMI_LOCK (1 << 4)
57 # define CF9LOCK (1 << 31)
58 # define LTR_DEF (1 << 22)
59 # define IGNORE_HPET (1 << 21)
60 # define CF9GR (1 << 20)
61 # define CWORWRE (1 << 18)
63 # define SIO_DMA2_DIS (1 << 0)
64 # define PWM1_DIS (1 << 1)
65 # define PWM2_DIS (1 << 2)
66 # define HSUART1_DIS (1 << 3)
67 # define HSUART2_DIS (1 << 4)
68 # define SPI_DIS (1 << 5)
69 # define SDIO_DIS (1 << 9)
70 # define SD_DIS (1 << 10)
71 # define MMC_DIS (1 << 11)
72 # define HDA_DIS (1 << 12)
73 # define LPE_DIS (1 << 13)
74 # define OTG_DIS (1 << 14)
75 # define XHCI_DIS (1 << 15)
76 # define SATA_DIS (1 << 17)
77 # define EHCI_DIS (1 << 18)
78 # define TXE_DIS (1 << 19)
79 # define PCIE_PORT1_DIS (1 << 20)
80 # define PCIE_PORT2_DIS (1 << 21)
81 # define PCIE_PORT3_DIS (1 << 22)
82 # define PCIE_PORT4_DIS (1 << 23)
83 # define SIO_DMA1_DIS (1 << 24)
84 # define I2C1_DIS (1 << 25)
85 # define I2C2_DIS (1 << 26)
86 # define I2C3_DIS (1 << 27)
87 # define I2C4_DIS (1 << 28)
88 # define I2C5_DIS (1 << 29)
89 # define I2C6_DIS (1 << 30)
90 # define I2C7_DIS (1 << 31)
91 #define FUNC_DIS2 0x38
92 # define USH_SS_PHY_DIS (1 << 2)
93 # define OTG_SS_PHY_DIS (1 << 1)
94 # define SMBUS_DIS (1 << 0)
95 #define GPIO_ROUT 0x58
100 #define PLT_CLK_CTL_0 0x60
101 #define PLT_CLK_CTL_1 0x64
102 #define PLT_CLK_CTL_2 0x68
103 #define PLT_CLK_CTL_3 0x6c
104 #define PLT_CLK_CTL_4 0x70
105 #define PLT_CLK_CTL_5 0x74
106 # define CLK_SRC_XTAL (0x0 << 2)
107 # define CLK_SRC_PLL (0x1 << 2)
108 # define CLK_CTL_D3_LPE (0x0 << 0)
109 # define CLK_CTL_ON (0x1 << 0)
110 # define CLK_CTL_OFF (0x2 << 0)
112 #define GPE_LEVEL_EDGE 0xc4
115 #define GPE_POLARITY 0xc8
116 # define GPE_ACTIVE_HIGH 1
117 # define GPE_ACTIVE_LOW 0
122 #define WAK_STS (1 << 15)
123 #define PCIEXPWAK_STS (1 << 14)
124 #define USB_STS (1 << 13)
125 #define PRBTNOR_STS (1 << 11)
126 #define RTC_STS (1 << 10)
127 #define PWRBTN_STS (1 << 8)
128 #define GBL_STS (1 << 5)
129 #define TMROF_STS (1 << 0)
131 #define PCIEXPWAK_DIS (1 << 14)
132 #define USB_WAKE_EN (1 << 13)
133 #define RTC_EN (1 << 10)
134 #define PWRBTN_EN (1 << 8)
135 #define GBL_EN (1 << 5)
136 #define TMROF_EN (1 << 0)
138 #define GBL_RLS (1 << 2)
139 #define BM_RLD (1 << 1)
140 #define SCI_EN (1 << 0)
142 #define GPE0_STS 0x20
144 #define SUS_GPIO_EN7_BIT 23
145 #define SUS_GPIO_EN7 (1 << SUS_GPIO_EN7_BIT)
146 #define SUS_GPIO_EN6_BIT 22
147 #define SUS_GPIO_EN6 (1 << SUS_GPIO_EN6_BIT)
148 #define SUS_GPIO_EN5_BIT 21
149 #define SUS_GPIO_EN5 (1 << SUS_GPIO_EN5_BIT)
150 #define SUS_GPIO_EN4_BIT 20
151 #define SUS_GPIO_EN4 (1 << SUS_GPIO_EN4_BIT)
152 #define SUS_GPIO_EN3_BIT 19
153 #define SUS_GPIO_EN3 (1 << SUS_GPIO_EN3_BIT)
154 #define SUS_GPIO_EN2_BIT 18
155 #define SUS_GPIO_EN2 (1 << SUS_GPIO_EN2_BIT)
156 #define SUS_GPIO_EN1_BIT 17
157 #define SUS_GPIO_EN1 (1 << SUS_GPIO_EN1_BIT)
158 #define SUS_GPIO_EN0_BIT 16
159 #define SUS_GPIO_EN0 (1 << SUS_GPIO_EN0_BIT)
160 #define SUS_GPIO_STS0 (1 << 16)
161 #define PCIE_WAKE3_STS (1 << 8)
162 #define PCIE_WAKE2_STS (1 << 7)
163 #define PCIE_WAKE1_STS (1 << 6)
164 #define PCIE_WAKE0_STS (1 << 3)
165 #define PCI_EXP_STS (1 << 9)
166 #define PME_B0_EN (1 << 13)
167 #define _ACPI_ENABLE_WAKE_SUS_GPIO(x) SUS_GPIO_EN##x##_BIT
168 #define ACPI_ENABLE_WAKE_SUS_GPIO(x) _ACPI_ENABLE_WAKE_SUS_GPIO(x)
170 #define INTEL_USB2_EN (1 << 18)
171 #define USB_EN (1 << 17)
172 #define PERIODIC_EN (1 << 14)
173 #define TCO_EN (1 << 13)
174 #define BIOS_RLS (1 << 7)
175 #define SWSMI_TMR_EN (1 << 6)
176 #define APMC_EN (1 << 5)
177 #define SLP_SMI_EN (1 << 4)
178 #define BIOS_EN (1 << 2)
180 #define GBL_SMI_EN (1 << 0)
182 #define ALT_GPIO_SMI 0x38
184 # define UPRWC_WR_EN (1 << 1)
185 #define GPE_CTRL 0x40
186 #define PM2A_CNT_BLK 0x50
189 # define SECOND_TO_STS (1 << 17)
190 # define TCO_TIMEOUT (1 << 3)
191 #define TCO1_CNT 0x68
192 # define TCO_LOCK (1 << 12)
193 # define TCO_TMR_HALT (1 << 11)
196 #if !defined(__ASSEMBLER__) && !defined(__ACPI__)
uint16_t get_pmbase(void)
struct chipset_power_state __packed
void enable_pm1(uint16_t events)
uint16_t clear_pm1_status(void)
void enable_pm1_control(uint32_t mask)
void southcluster_log_state(void)
uint32_t clear_alt_status(void)
void disable_smi(uint32_t mask)
void enable_smi(uint32_t mask)
void enable_gpe(uint32_t mask)
void clear_pmc_status(void)
uint32_t clear_gpe_status(void)
void disable_pm1_control(uint32_t mask)
void disable_all_gpe(void)
uint32_t clear_tco_status(void)
uint32_t clear_smi_status(void)
void disable_gpe(uint32_t mask)
struct chipset_power_state * fill_power_state(void)