Frank Vibrans | 2b4c831 | 2011-02-14 18:30:54 +0000 | [diff] [blame] | 1 | /* |
| 2 | ***************************************************************************** |
| 3 | * |
| 4 | * Copyright (c) 2011, Advanced Micro Devices, Inc. |
| 5 | * All rights reserved. |
| 6 | * |
| 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. |
| 17 | * |
| 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. |
| 28 | * |
| 29 | * *************************************************************************** |
| 30 | * |
| 31 | */ |
| 32 | |
Kerry She | feed329 | 2011-08-18 18:03:44 +0800 | [diff] [blame^] | 33 | #ifndef BIOS_SIZE |
| 34 | #define BIOS_SIZE 0x04 //04 - 1MB |
| 35 | #endif |
Frank Vibrans | 2b4c831 | 2011-02-14 18:30:54 +0000 | [diff] [blame] | 36 | #define LEGACY_FREE 0x00 |
Scott Duplichan | 2b9143a | 2011-05-15 21:19:54 +0000 | [diff] [blame] | 37 | //#define ACPI_SLEEP_TRAP 0x01 |
Frank Vibrans | 2b4c831 | 2011-02-14 18:30:54 +0000 | [diff] [blame] | 38 | //#define SPREAD_SPECTRUM_EPROM_LOAD 0x01 |
| 39 | |
| 40 | /** |
| 41 | * Module Specific Defines for platform BIOS |
| 42 | * |
| 43 | */ |
| 44 | |
| 45 | /** |
| 46 | * PCIEX_BASE_ADDRESS - Define PCIE base address |
| 47 | * |
| 48 | * @param[Option] MOVE_PCIEBAR_TO_F0000000 Set PCIe base address to 0xF7000000 |
| 49 | */ |
| 50 | #ifdef MOVE_PCIEBAR_TO_F0000000 |
| 51 | #define PCIEX_BASE_ADDRESS 0xF7000000 |
| 52 | #else |
Marc Jones | 44d3c3d | 2011-05-15 23:13:54 +0000 | [diff] [blame] | 53 | #define PCIEX_BASE_ADDRESS CONFIG_MMCONF_BASE_ADDRESS |
Frank Vibrans | 2b4c831 | 2011-02-14 18:30:54 +0000 | [diff] [blame] | 54 | #endif |
| 55 | |
| 56 | /** |
| 57 | * SMBUS0_BASE_ADDRESS - Smbus base address |
| 58 | * |
| 59 | */ |
| 60 | #ifndef SMBUS0_BASE_ADDRESS |
| 61 | #define SMBUS0_BASE_ADDRESS 0xB00 |
| 62 | #endif |
| 63 | |
| 64 | /** |
| 65 | * SMBUS1_BASE_ADDRESS - Smbus1 (ASF) base address |
| 66 | * |
| 67 | */ |
| 68 | #ifndef SMBUS1_BASE_ADDRESS |
| 69 | #define SMBUS1_BASE_ADDRESS 0xB20 |
| 70 | #endif |
| 71 | |
| 72 | /** |
| 73 | * GEC_BASE_ADDRESS - Gec Shadow ROM base address |
| 74 | * |
| 75 | */ |
| 76 | #ifndef GEC_BASE_ADDRESS |
| 77 | #define GEC_BASE_ADDRESS 0xFED61000 |
| 78 | #endif |
| 79 | |
| 80 | |
| 81 | /** |
| 82 | * SIO_PME_BASE_ADDRESS - Super IO PME base address |
| 83 | * |
| 84 | */ |
| 85 | #ifndef SIO_PME_BASE_ADDRESS |
| 86 | #define SIO_PME_BASE_ADDRESS 0xE00 |
| 87 | #endif |
| 88 | |
| 89 | /** |
| 90 | * SPI_BASE_ADDRESS - SPI controller (ROM) base address |
| 91 | * |
| 92 | */ |
| 93 | #ifndef SPI_BASE_ADDRESS |
| 94 | #define SPI_BASE_ADDRESS 0xFEC10000 |
| 95 | #endif |
| 96 | |
| 97 | /** |
| 98 | * WATCHDOG_TIMER_BASE_ADDRESS - WATCHDOG timer base address |
| 99 | * |
| 100 | */ |
| 101 | #ifndef WATCHDOG_TIMER_BASE_ADDRESS |
| 102 | #define WATCHDOG_TIMER_BASE_ADDRESS 0xFEC000F0 // Watchdog Timer Base Address |
| 103 | #endif |
| 104 | |
| 105 | /** |
| 106 | * HPET_BASE_ADDRESS - HPET base address |
| 107 | * |
| 108 | */ |
| 109 | #ifndef HPET_BASE_ADDRESS |
| 110 | #define HPET_BASE_ADDRESS 0xFED00000 // HPET Base address |
| 111 | #endif |
| 112 | |
| 113 | /** |
| 114 | * ALT_ADDR_400 - For some BIOS codebases which use 0x400 as ACPI base address |
| 115 | * |
| 116 | */ |
| 117 | #ifdef ALT_ADDR_400 |
| 118 | #define ACPI_BLK_BASE 0x400 |
| 119 | #else |
| 120 | #define ACPI_BLK_BASE 0x800 |
| 121 | #endif |
| 122 | |
| 123 | #define PM1_STATUS_OFFSET 0x00 |
| 124 | #define PM1_ENABLE_OFFSET 0x02 |
| 125 | #define PM1_CONTROL_OFFSET 0x04 |
| 126 | #define PM_TIMER_OFFSET 0x08 |
| 127 | #define CPU_CONTROL_OFFSET 0x10 |
| 128 | #define EVENT_STATUS_OFFSET 0x20 |
| 129 | #define EVENT_ENABLE_OFFSET 0x24 |
| 130 | |
| 131 | /** |
| 132 | * PM1_EVT_BLK_ADDRESS - ACPI power management Event Block base address |
| 133 | * |
| 134 | */ |
| 135 | #define PM1_EVT_BLK_ADDRESS ACPI_BLK_BASE + PM1_STATUS_OFFSET // AcpiPm1EvtBlkAddr |
| 136 | |
| 137 | /** |
| 138 | * PM1_CNT_BLK_ADDRESS - ACPI power management Control block base address |
| 139 | * |
| 140 | */ |
| 141 | #define PM1_CNT_BLK_ADDRESS ACPI_BLK_BASE + PM1_CONTROL_OFFSET // AcpiPm1CntBlkAddr |
| 142 | |
| 143 | /** |
| 144 | * PM1_TMR_BLK_ADDRESS - ACPI power management Timer block base address |
| 145 | * |
| 146 | */ |
| 147 | #define PM1_TMR_BLK_ADDRESS ACPI_BLK_BASE + PM_TIMER_OFFSET // AcpiPmTmrBlkAddr |
| 148 | |
| 149 | /** |
| 150 | * CPU_CNT_BLK_ADDRESS - ACPI power management CPU Control block base address |
| 151 | * |
| 152 | */ |
| 153 | #define CPU_CNT_BLK_ADDRESS ACPI_BLK_BASE + CPU_CONTROL_OFFSET // CpuControlBlkAddr |
| 154 | |
| 155 | /** |
| 156 | * GPE0_BLK_ADDRESS - ACPI power management General Purpose Event block base address |
| 157 | * |
| 158 | */ |
| 159 | #define GPE0_BLK_ADDRESS ACPI_BLK_BASE + EVENT_STATUS_OFFSET // AcpiGpe0BlkAddr |
| 160 | |
| 161 | /** |
| 162 | * SMI_CMD_PORT - ACPI SMI Command block base address |
| 163 | * |
| 164 | */ |
| 165 | #define SMI_CMD_PORT 0xB0 // SmiCmdPortAddr |
| 166 | |
| 167 | /** |
| 168 | * ACPI_PMA_CNT_BLK_ADDRESS - ACPI power management additional control block base address |
| 169 | * |
| 170 | */ |
| 171 | #define ACPI_PMA_CNT_BLK_ADDRESS 0xFE00 // AcpiPmaCntBlkAddr |
| 172 | |
| 173 | /** |
| 174 | * SATA_IDE_MODE_SSID - Sata controller IDE mode SSID. |
| 175 | * Define value for SSID while SATA controller set to IDE mode. |
| 176 | */ |
| 177 | #ifndef SATA_IDE_MODE_SSID |
| 178 | #define SATA_IDE_MODE_SSID 0x43901002 |
| 179 | #endif |
| 180 | |
| 181 | /** |
| 182 | * SATA_RAID_MODE_SSID - Sata controller RAID mode SSID. |
| 183 | * Define value for SSID while SATA controller set to RAID mode. |
| 184 | */ |
| 185 | #ifndef SATA_RAID_MODE_SSID |
| 186 | #define SATA_RAID_MODE_SSID 0x43921002 |
| 187 | #endif |
| 188 | |
| 189 | /** |
| 190 | * SATA_RAID5_MODE_SSID - Sata controller RAID5 mode SSID. |
| 191 | * Define value for SSID while SATA controller set to RAID5 mode. |
| 192 | */ |
| 193 | #ifndef SATA_RAID5_MODE_SSID |
| 194 | #define SATA_RAID5_MODE_SSID 0x43931002 |
| 195 | #endif |
| 196 | |
| 197 | /** |
| 198 | * SATA_AHCI_MODE_SSID - Sata controller AHCI mode SSID. |
| 199 | * Define value for SSID while SATA controller set to AHCI mode. |
| 200 | */ |
| 201 | #ifndef SATA_AHCI_SSID |
| 202 | #define SATA_AHCI_SSID 0x43911002 |
| 203 | #endif |
| 204 | |
| 205 | /** |
| 206 | * OHCI_SSID - All SB OHCI controllers SSID value. |
| 207 | * |
| 208 | */ |
| 209 | #ifndef OHCI_SSID |
| 210 | #define OHCI_SSID 0x43971002 |
| 211 | #endif |
| 212 | |
| 213 | /** |
| 214 | * EHCI_SSID - All SB EHCI controllers SSID value. |
| 215 | * |
| 216 | */ |
| 217 | #ifndef EHCI_SSID |
| 218 | #define EHCI_SSID 0x43961002 |
| 219 | #endif |
| 220 | |
| 221 | /** |
| 222 | * OHCI4_SSID - OHCI (USB 1.1 mode *HW force) controllers SSID value. |
| 223 | * |
| 224 | */ |
| 225 | #ifndef OHCI4_SSID |
| 226 | #define OHCI4_SSID 0x43991002 |
| 227 | #endif |
| 228 | |
| 229 | /** |
| 230 | * SMBUS_SSID - Smbus controller (South Bridge device 0x14 function 0) SSID value. |
| 231 | * |
| 232 | */ |
| 233 | #ifndef SMBUS_SSID |
| 234 | #define SMBUS_SSID 0x43851002 |
| 235 | #endif |
| 236 | |
| 237 | /** |
| 238 | * IDE_SSID - SATA IDE controller (South Bridge device 0x14 function 1) SSID value. |
| 239 | * |
| 240 | */ |
| 241 | #ifndef IDE_SSID |
| 242 | #define IDE_SSID 0x439C1002 |
| 243 | #endif |
| 244 | |
| 245 | /** |
| 246 | * AZALIA_SSID - AZALIA controller (South Bridge device 0x14 function 2) SSID value. |
| 247 | * |
| 248 | */ |
| 249 | #ifndef AZALIA_SSID |
| 250 | #define AZALIA_SSID 0x43831002 |
| 251 | #endif |
| 252 | |
| 253 | /** |
| 254 | * LPC_SSID - LPC controller (South Bridge device 0x14 function 3) SSID value. |
| 255 | * |
| 256 | */ |
| 257 | #ifndef LPC_SSID |
| 258 | #define LPC_SSID 0x439D1002 |
| 259 | #endif |
| 260 | |
| 261 | /** |
| 262 | * PCIB_SSID - PCIB controller (South Bridge device 0x14 function 4) SSID value. |
| 263 | * |
| 264 | */ |
| 265 | #ifndef PCIB_SSID |
| 266 | #define PCIB_SSID 0x43841002 |
| 267 | #endif |
| 268 | |
| 269 | /** |
| 270 | * USB_PLL_Voltage - CG2 Clock voltage setting. |
| 271 | * |
| 272 | */ |
| 273 | #ifndef USB_PLL_Voltage |
| 274 | #define USB_PLL_Voltage 0x10 |
| 275 | #endif |
| 276 | |
| 277 | /** |
| 278 | * Spread_Spectrum_Type |
| 279 | * |
| 280 | * - 0 : Normal platform |
| 281 | * - 1 : Ontario platform |
| 282 | */ |
| 283 | #ifndef Spread_Spectrum_Type |
| 284 | #define Spread_Spectrum_Type 0x00 |
| 285 | #endif |