2 *****************************************************************************
4 * Copyright (c) 2011, Advanced Micro Devices, Inc.
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions are met:
9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer.
11 * * Redistributions in binary form must reproduce the above copyright
12 * notice, this list of conditions and the following disclaimer in the
13 * documentation and/or other materials provided with the distribution.
14 * * Neither the name of Advanced Micro Devices, Inc. nor the names of
15 * its contributors may be used to endorse or promote products derived
16 * from this software without specific prior written permission.
18 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
19 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
20 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21 * DISCLAIMED. IN NO EVENT SHALL ADVANCED MICRO DEVICES, INC. BE LIABLE FOR ANY
22 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
24 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
25 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
27 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 * ***************************************************************************
34 #define BIOS_SIZE 0x04 //04 - 1MB
36 #define LEGACY_FREE 0x00
37 //#define ACPI_SLEEP_TRAP 0x01
38 //#define SPREAD_SPECTRUM_EPROM_LOAD 0x01
41 * Module Specific Defines for platform BIOS
46 * PCIEX_BASE_ADDRESS - Define PCIE base address
48 * @param[Option] MOVE_PCIEBAR_TO_F0000000 Set PCIe base address to 0xF7000000
50 #ifdef MOVE_PCIEBAR_TO_F0000000
51 #define PCIEX_BASE_ADDRESS 0xF7000000
53 #define PCIEX_BASE_ADDRESS CONFIG_MMCONF_BASE_ADDRESS
57 * SMBUS0_BASE_ADDRESS - Smbus base address
60 #ifndef SMBUS0_BASE_ADDRESS
61 #define SMBUS0_BASE_ADDRESS 0xB00
65 * SMBUS1_BASE_ADDRESS - Smbus1 (ASF) base address
68 #ifndef SMBUS1_BASE_ADDRESS
69 #define SMBUS1_BASE_ADDRESS 0xB20
73 * GEC_BASE_ADDRESS - Gec Shadow ROM base address
76 #ifndef GEC_BASE_ADDRESS
77 #define GEC_BASE_ADDRESS 0xFED61000
82 * SIO_PME_BASE_ADDRESS - Super IO PME base address
85 #ifndef SIO_PME_BASE_ADDRESS
86 #define SIO_PME_BASE_ADDRESS 0xE00
90 * SIO_HWM_BASE_ADDRESS - Super IO HWM base address
93 #ifndef SIO_HWM_BASE_ADDRESS
94 #define SIO_HWM_BASE_ADDRESS 0x290
98 * SPI_BASE_ADDRESS - SPI controller (ROM) base address
101 #ifndef SPI_BASE_ADDRESS
102 #define SPI_BASE_ADDRESS 0xFEC10000
106 * WATCHDOG_TIMER_BASE_ADDRESS - WATCHDOG timer base address
109 #ifndef WATCHDOG_TIMER_BASE_ADDRESS
110 #define WATCHDOG_TIMER_BASE_ADDRESS 0xFEC000F0 // Watchdog Timer Base Address
114 * HPET_BASE_ADDRESS - HPET base address
117 #ifndef HPET_BASE_ADDRESS
118 #define HPET_BASE_ADDRESS 0xFED00000 // HPET Base address
122 * ALT_ADDR_400 - For some BIOS codebases which use 0x400 as ACPI base address
126 #define ACPI_BLK_BASE 0x400
128 #define ACPI_BLK_BASE 0x800
131 #define PM1_STATUS_OFFSET 0x00
132 #define PM1_ENABLE_OFFSET 0x02
133 #define PM1_CONTROL_OFFSET 0x04
134 #define PM_TIMER_OFFSET 0x08
135 #define CPU_CONTROL_OFFSET 0x10
136 #define EVENT_STATUS_OFFSET 0x20
137 #define EVENT_ENABLE_OFFSET 0x24
140 * PM1_EVT_BLK_ADDRESS - ACPI power management Event Block base address
143 #define PM1_EVT_BLK_ADDRESS ACPI_BLK_BASE + PM1_STATUS_OFFSET // AcpiPm1EvtBlkAddr
146 * PM1_CNT_BLK_ADDRESS - ACPI power management Control block base address
149 #define PM1_CNT_BLK_ADDRESS ACPI_BLK_BASE + PM1_CONTROL_OFFSET // AcpiPm1CntBlkAddr
152 * PM1_TMR_BLK_ADDRESS - ACPI power management Timer block base address
155 #define PM1_TMR_BLK_ADDRESS ACPI_BLK_BASE + PM_TIMER_OFFSET // AcpiPmTmrBlkAddr
158 * CPU_CNT_BLK_ADDRESS - ACPI power management CPU Control block base address
161 #define CPU_CNT_BLK_ADDRESS ACPI_BLK_BASE + CPU_CONTROL_OFFSET // CpuControlBlkAddr
164 * GPE0_BLK_ADDRESS - ACPI power management General Purpose Event block base address
167 #define GPE0_BLK_ADDRESS ACPI_BLK_BASE + EVENT_STATUS_OFFSET // AcpiGpe0BlkAddr
170 * SMI_CMD_PORT - ACPI SMI Command block base address
173 #define SMI_CMD_PORT 0xB0 // SmiCmdPortAddr
176 * ACPI_PMA_CNT_BLK_ADDRESS - ACPI power management additional control block base address
179 #define ACPI_PMA_CNT_BLK_ADDRESS 0xFE00 // AcpiPmaCntBlkAddr
182 * SATA_IDE_MODE_SSID - Sata controller IDE mode SSID.
183 * Define value for SSID while SATA controller set to IDE mode.
185 #ifndef SATA_IDE_MODE_SSID
186 #define SATA_IDE_MODE_SSID 0x43901002
190 * SATA_RAID_MODE_SSID - Sata controller RAID mode SSID.
191 * Define value for SSID while SATA controller set to RAID mode.
193 #ifndef SATA_RAID_MODE_SSID
194 #define SATA_RAID_MODE_SSID 0x43921002
198 * SATA_RAID5_MODE_SSID - Sata controller RAID5 mode SSID.
199 * Define value for SSID while SATA controller set to RAID5 mode.
201 #ifndef SATA_RAID5_MODE_SSID
202 #define SATA_RAID5_MODE_SSID 0x43931002
206 * SATA_AHCI_MODE_SSID - Sata controller AHCI mode SSID.
207 * Define value for SSID while SATA controller set to AHCI mode.
209 #ifndef SATA_AHCI_SSID
210 #define SATA_AHCI_SSID 0x43911002
214 * OHCI_SSID - All SB OHCI controllers SSID value.
218 #define OHCI_SSID 0x43971002
222 * EHCI_SSID - All SB EHCI controllers SSID value.
226 #define EHCI_SSID 0x43961002
230 * OHCI4_SSID - OHCI (USB 1.1 mode *HW force) controllers SSID value.
234 #define OHCI4_SSID 0x43991002
238 * SMBUS_SSID - Smbus controller (South Bridge device 0x14 function 0) SSID value.
242 #define SMBUS_SSID 0x43851002
246 * IDE_SSID - SATA IDE controller (South Bridge device 0x14 function 1) SSID value.
250 #define IDE_SSID 0x439C1002
254 * AZALIA_SSID - AZALIA controller (South Bridge device 0x14 function 2) SSID value.
258 #define AZALIA_SSID 0x43831002
262 * LPC_SSID - LPC controller (South Bridge device 0x14 function 3) SSID value.
266 #define LPC_SSID 0x439D1002
270 * PCIB_SSID - PCIB controller (South Bridge device 0x14 function 4) SSID value.
274 #define PCIB_SSID 0x43841002
278 * USB_PLL_Voltage - CG2 Clock voltage setting.
281 #ifndef USB_PLL_Voltage
282 #define USB_PLL_Voltage 0x10
286 * Spread_Spectrum_Type
288 * - 0 : Normal platform
289 * - 1 : Ontario platform
291 #ifndef Spread_Spectrum_Type
292 #define Spread_Spectrum_Type 0x00