blob: 26dca89fd2fb9f67cbc6705d96116cbe19d8e762 [file] [log] [blame]
Felix Held4a8cd722020-04-18 22:26:39 +02001# SPDX-License-Identifier: GPL-2.0-only
Marc Jones24484842017-05-04 21:17:45 -06002
Marshall Dawson68519222019-11-25 11:36:15 -07003config SOC_AMD_STONEYRIDGE
4 bool
5 help
6 AMD support for SOCs in Family 15h Models 60h-6Fh and Models 70h-7Fh.
7
8if SOC_AMD_STONEYRIDGE
9
Marc Jones21cde8b2017-05-07 16:47:36 -060010config CPU_SPECIFIC_OPTIONS
11 def_bool y
Kyösti Mälkki3139c8d2020-06-28 16:33:33 +030012 select ACPI_SOC_NVS
Angel Pons8e035e32021-06-22 12:58:20 +020013 select ARCH_X86
Felix Heldc07c7c92020-12-04 18:50:53 +010014 select BOOT_DEVICE_SUPPORTS_WRITES if BOOT_DEVICE_SPI_FLASH
Aaron Durbin51e4c1a2018-01-24 17:42:51 -070015 select COLLECT_TIMESTAMPS_NO_TSC
Marc Jones9156cac2017-07-12 11:05:38 -060016 select GENERIC_GPIO_LIB
Aaron Durbin51e4c1a2018-01-24 17:42:51 -070017 select GENERIC_UDELAY
Angel Ponsb74975e2020-07-13 01:12:57 +020018 select HAVE_CF9_RESET
Felix Heldc07c7c92020-12-04 18:50:53 +010019 select HAVE_SMI_HANDLER
Marc Jones24484842017-05-04 21:17:45 -060020 select HAVE_USBDEBUG_OPTIONS
Marc Jones33eef132017-10-26 16:50:42 -060021 select PARALLEL_MP_AP_WORK
Marc Jones17e85ad2017-12-20 16:21:25 -070022 select RTC
Felix Heldc07c7c92020-12-04 18:50:53 +010023 select SOC_AMD_PI
24 select SOC_AMD_COMMON
25 select SOC_AMD_COMMON_BLOCK_ACPI
Felix Held0bc46842021-11-23 10:19:28 +010026 select SOC_AMD_COMMON_BLOCK_ACPI_GPIO
Felix Heldc07c7c92020-12-04 18:50:53 +010027 select SOC_AMD_COMMON_BLOCK_ACPIMMIO
Felix Held31364242021-07-23 19:18:02 +020028 select SOC_AMD_COMMON_BLOCK_ACPIMMIO_BIOSRAM
Felix Heldc07c7c92020-12-04 18:50:53 +010029 select SOC_AMD_COMMON_BLOCK_AOAC
30 select SOC_AMD_COMMON_BLOCK_BANKED_GPIOS
31 select SOC_AMD_COMMON_BLOCK_CAR
32 select SOC_AMD_COMMON_BLOCK_HDA
Karthikeyan Ramasubramanian0dbea482021-03-08 23:23:50 -070033 select SOC_AMD_COMMON_BLOCK_I2C
Felix Heldc07c7c92020-12-04 18:50:53 +010034 select SOC_AMD_COMMON_BLOCK_IOMMU
35 select SOC_AMD_COMMON_BLOCK_LPC
Felix Held1e1d4902021-07-14 00:05:39 +020036 select SOC_AMD_COMMON_BLOCK_MCA
Felix Heldc07c7c92020-12-04 18:50:53 +010037 select SOC_AMD_COMMON_BLOCK_PCI
Felix Heldc0538d42021-04-13 19:56:10 +020038 select SOC_AMD_COMMON_BLOCK_PM
Felix Heldc07c7c92020-12-04 18:50:53 +010039 select SOC_AMD_COMMON_BLOCK_PSP_GEN1
Felix Heldc07c7c92020-12-04 18:50:53 +010040 select SOC_AMD_COMMON_BLOCK_SATA
41 select SOC_AMD_COMMON_BLOCK_SMBUS
42 select SOC_AMD_COMMON_BLOCK_SMI
Felix Heldbc134812021-02-10 02:26:10 +010043 select SOC_AMD_COMMON_BLOCK_SMM
Felix Heldc07c7c92020-12-04 18:50:53 +010044 select SOC_AMD_COMMON_BLOCK_SPI
Felix Held91ef9252021-01-12 23:44:05 +010045 select SOC_AMD_COMMON_BLOCK_UART
Felix Heldc07c7c92020-12-04 18:50:53 +010046 select SSE2
47 select TSC_SYNC_LFENCE
48 select X86_AMD_FIXED_MTRRS
Marc Jones24484842017-05-04 21:17:45 -060049
Marshall Dawson12294d02019-11-25 07:21:18 -070050config AMD_APU_STONEYRIDGE
51 bool
52 help
53 AMD Stoney Ridge APU
54
Marshall Dawsone1988f52019-11-25 11:15:35 -070055config AMD_APU_PRAIRIEFALCON
56 bool
57 help
58 AMD Embedded Prairie Falcon APU
59
Marshall Dawson12294d02019-11-25 07:21:18 -070060config AMD_APU_MERLINFALCON
61 bool
62 help
Marshall Dawsone1988f52019-11-25 11:15:35 -070063 AMD Embedded Merlin Falcon APU
Marshall Dawson12294d02019-11-25 07:21:18 -070064
Marshall Dawson3ac0ab52019-11-24 19:03:56 -070065config AMD_APU_PKG_FP4
66 bool
67 help
68 AMD FP4 package
69
70config AMD_APU_PKG_FT4
71 bool
72 help
73 AMD FT4 package
74
75config AMD_SOC_PACKAGE
76 string
77 default "FP4" if AMD_APU_PKG_FP4
78 default "FT4" if AMD_APU_PKG_FT4
79
Marshall Dawsone7557de2017-06-09 16:35:14 -060080config VBOOT
Marshall Dawsone7557de2017-06-09 16:35:14 -060081 select VBOOT_STARTS_IN_BOOTBLOCK
Marc Jones4c887ea2018-04-25 16:43:18 -060082 select VBOOT_VBNV_CMOS
83 select VBOOT_VBNV_CMOS_BACKUP_TO_FLASH
Marshall Dawsone7557de2017-06-09 16:35:14 -060084
Marc Jones21cde8b2017-05-07 16:47:36 -060085# TODO: Sync these with definitions in PI vendorcode.
86# DCACHE_RAM_BASE must equal BSP_STACK_BASE_ADDR.
87# DCACHE_RAM_SIZE must equal BSP_STACK_SIZE.
88
89config DCACHE_RAM_BASE
90 hex
91 default 0x30000
92
93config DCACHE_RAM_SIZE
94 hex
95 default 0x10000
96
Marshall Dawson9df969a2017-07-25 18:46:46 -060097config DCACHE_BSP_STACK_SIZE
Marshall Dawson9df969a2017-07-25 18:46:46 -060098 hex
99 default 0x4000
100 help
101 The amount of anticipated stack usage in CAR by bootblock and
102 other stages.
103
Marshall Dawson7c3f1e72017-08-24 09:59:10 -0600104config PRERAM_CBMEM_CONSOLE_SIZE
105 hex
Marshall Dawson1df6bc62017-12-19 20:41:29 -0700106 default 0x1600
Marshall Dawson7c3f1e72017-08-24 09:59:10 -0600107 help
108 Increase this value if preram cbmem console is getting truncated
109
Marc Jones1587dc82017-05-15 18:55:11 -0600110config BOTTOMIO_POSITION
111 hex "Bottom of 32-bit IO space"
112 default 0xD0000000
113 help
114 If PCI peripherals with big BARs are connected to the system
115 the bottom of the IO must be decreased to allocate such
116 devices.
117
118 Declare the beginning of the 128MB-aligned MMIO region. This
119 option is useful when PCI peripherals requesting large address
120 ranges are present.
121
Shelley Chen4e9bb332021-10-20 15:43:45 -0700122config ECAM_MMCONF_BASE_ADDRESS
Marc Jones1587dc82017-05-15 18:55:11 -0600123 default 0xF8000000
124
Shelley Chen4e9bb332021-10-20 15:43:45 -0700125config ECAM_MMCONF_BUS_NUMBER
Marc Jones1587dc82017-05-15 18:55:11 -0600126 default 64
127
128config VGA_BIOS_ID
129 string
Marshall Dawson12294d02019-11-25 07:21:18 -0700130 default "1002,9874" if AMD_APU_MERLINFALCON
Marc Jones1587dc82017-05-15 18:55:11 -0600131 default "1002,98e4"
132 help
133 The default VGA BIOS PCI vendor/device ID should be set to the
134 result of the map_oprom_vendev() function in northbridge.c.
135
136config VGA_BIOS_FILE
137 string
Marshall Dawson7987c1c2019-11-25 08:29:28 -0700138 default "3rdparty/amd_blobs/stoneyridge/CarrizoGenericVbios.bin" if AMD_APU_MERLINFALCON
Marshall Dawsone1988f52019-11-25 11:15:35 -0700139 default "3rdparty/amd_blobs/stoneyridge/StoneyGenericVbios.bin" if AMD_APU_PRAIRIEFALCON
140 default "3rdparty/amd_blobs/stoneyridge/StoneyGenericVbios.bin" if AMD_APU_STONEYRIDGE
Marc Jones1587dc82017-05-15 18:55:11 -0600141
Marshall Dawson668dea02017-11-29 09:57:15 -0700142config S3_VGA_ROM_RUN
143 bool
144 default n
145
Marc Jones1587dc82017-05-15 18:55:11 -0600146config HEAP_SIZE
147 hex
148 default 0xc0000
149
Marc Jones24484842017-05-04 21:17:45 -0600150config EHCI_BAR
151 hex
152 default 0xfef00000
153
154config STONEYRIDGE_XHCI_ENABLE
155 bool "Enable Stoney Ridge XHCI Controller"
156 default y
157 help
158 The XHCI controller must be enabled and the XHCI firmware
159 must be added in order to have USB 3.0 support configured
160 by coreboot. The OS will be responsible for enabling the XHCI
Jonathan Neuschäfer45e6c822018-12-11 17:53:07 +0100161 controller if the XHCI firmware is available but the
Marc Jones24484842017-05-04 21:17:45 -0600162 XHCI controller is not enabled by coreboot.
163
164config STONEYRIDGE_XHCI_FWM
165 bool "Add xhci firmware"
166 default y
167 help
168 Add Stoney Ridge XHCI Firmware to support the onboard USB 3.0
169
Marc Jones24484842017-05-04 21:17:45 -0600170config STONEYRIDGE_GEC_FWM
171 bool
172 default n
173 help
174 Add Stoney Ridge GEC Firmware to support the onboard gigabit Ethernet MAC.
175 Must be connected to a Broadcom B50610 or B50610M PHY on the motherboard.
176
177config STONEYRIDGE_XHCI_FWM_FILE
178 string "XHCI firmware path and filename"
Marshall Dawson7987c1c2019-11-25 08:29:28 -0700179 default "3rdparty/amd_blobs/stoneyridge/xhci.bin"
Marc Jones24484842017-05-04 21:17:45 -0600180 depends on STONEYRIDGE_XHCI_FWM
181
Marc Jones24484842017-05-04 21:17:45 -0600182config STONEYRIDGE_GEC_FWM_FILE
183 string "GEC firmware path and filename"
184 depends on STONEYRIDGE_GEC_FWM
185
Zheng Baoc5e28ab2020-10-28 11:38:09 +0800186config AMDFW_CONFIG_FILE
187 string
188 string "AMD PSP Firmware config file"
Zheng Baoc5e28ab2020-10-28 11:38:09 +0800189 default "src/soc/amd/stoneyridge/fw_cz.cfg" if AMD_APU_MERLINFALCON
190 default "src/soc/amd/stoneyridge/fw_st.cfg" if AMD_APU_PRAIRIEFALCON
191 default "src/soc/amd/stoneyridge/fw_st.cfg" if AMD_APU_STONEYRIDGE
Marc Jones24484842017-05-04 21:17:45 -0600192
193config STONEYRIDGE_SATA_MODE
194 int "SATA Mode"
195 default 0
196 range 0 6
197 help
198 Select the mode in which SATA should be driven.
199 The default is NATIVE.
200 0: NATIVE mode does not require a ROM.
201 2: AHCI may work with or without AHCI ROM. It depends on the payload support.
202 For example, seabios does not require the AHCI ROM.
203 3: LEGACY IDE
204 4: IDE to AHCI
205 5: AHCI7804: ROM Required, and AMD driver required in the OS.
206 6: IDE to AHCI7804: ROM Required, and AMD driver required in the OS.
207
208comment "NATIVE"
209 depends on STONEYRIDGE_SATA_MODE = 0
210
211comment "AHCI"
212 depends on STONEYRIDGE_SATA_MODE = 2
213
214comment "LEGACY IDE"
215 depends on STONEYRIDGE_SATA_MODE = 3
216
217comment "IDE to AHCI"
218 depends on STONEYRIDGE_SATA_MODE = 4
219
220comment "AHCI7804"
221 depends on STONEYRIDGE_SATA_MODE = 5
222
223comment "IDE to AHCI7804"
224 depends on STONEYRIDGE_SATA_MODE = 6
225
226if STONEYRIDGE_SATA_MODE = 2 || STONEYRIDGE_SATA_MODE = 5
227
228config AHCI_ROM_ID
229 string "AHCI device PCI IDs"
230 default "1022,7801" if STONEYRIDGE_SATA_MODE = 2
231 default "1022,7804" if STONEYRIDGE_SATA_MODE = 5
232
233endif # STONEYRIDGE_SATA_MODE = 2 || STONEYRIDGE_SATA_MODE = 5
234
235config STONEYRIDGE_LEGACY_FREE
236 bool "System is legacy free"
237 help
238 Select y if there is no keyboard controller in the system.
239 This sets variables in AGESA and ACPI.
240
Marc Jones24484842017-05-04 21:17:45 -0600241config SERIRQ_CONTINUOUS_MODE
242 bool
243 default n
244 help
245 Set this option to y for serial IRQ in continuous mode.
246 Otherwise it is in quiet mode.
247
Arthur Heymansb5e72b62018-01-02 23:41:24 +0100248config CONSOLE_UART_BASE_ADDRESS
249 depends on CONSOLE_SERIAL
250 hex
251 default 0xfedc6000
252
Marshall Dawsonc6ef9db2017-05-14 14:16:56 -0600253config SMM_TSEG_SIZE
254 hex
Felix Helde22eef72021-02-10 22:22:07 +0100255 default 0x800000 if HAVE_SMI_HANDLER
Marshall Dawsonc6ef9db2017-05-14 14:16:56 -0600256 default 0x0
257
Marshall Dawsonb6172112017-09-13 17:47:31 -0600258config SMM_RESERVED_SIZE
259 hex
Marshall Dawsonfceac7e2018-05-18 14:40:53 -0600260 default 0x150000
Marshall Dawsonb6172112017-09-13 17:47:31 -0600261
Raul E Rangel846b4942018-06-12 10:43:09 -0600262config SMM_MODULE_STACK_SIZE
263 hex
264 default 0x800
265
Marc Jonese013df92017-08-23 16:28:02 -0600266config ACPI_CPU_STRING
267 string
Matt DeVillierc08d4c52020-06-20 23:45:30 -0500268 default "\\_SB.P%03d"
Marc Jonese013df92017-08-23 16:28:02 -0600269
Marshall Dawson9a32c412018-09-04 13:29:12 -0600270config ACPI_BERT
271 bool "Build ACPI BERT Table"
272 default y
273 depends on HAVE_ACPI_TABLES
274 help
275 Report Machine Check errors identified in POST to the OS in an
276 ACPI Boot Error Record Table. This option reserves an 8MB region
277 for building the error structures.
278
Marshall Dawson25eb2bc2019-03-14 12:42:46 -0600279config USE_PSPSECUREOS
Martin Rothb617e322017-09-07 13:23:55 -0600280 bool "Include PSP SecureOS blobs in AMD firmware"
281 default y
282 help
283 Include the PspSecureOs, PspTrustlet and TrustletKey binaries
284 in the amdfw section.
285
286 If unsure, answer 'y'
287
Richard Spiegel1bc578a2019-06-18 18:19:47 -0700288config SOC_AMD_PSP_SELECTABLE_SMU_FW
289 bool
Marshall Dawson12294d02019-11-25 07:21:18 -0700290 default y if AMD_APU_STONEYRIDGE
Richard Spiegel1bc578a2019-06-18 18:19:47 -0700291 help
292 Some ST implementations allow storing SMU firmware into cbfs and
293 calling the PSP to load the blobs at the proper time.
294
295 Merlin Falcon does not support it. If you are using 00670F00 SOC,
296 ask your AMD representative if it supports it or not.
297
Marshall Dawson5f0520a2017-10-30 16:11:45 -0600298config SOC_AMD_SMU_FANLESS
299 bool
300 depends on SOC_AMD_PSP_SELECTABLE_SMU_FW
301 default n if SOC_AMD_SMU_NOTFANLESS
302 default y
303
304config SOC_AMD_SMU_FANNED
305 bool
306 depends on SOC_AMD_PSP_SELECTABLE_SMU_FW
307 default n
308 select SOC_AMD_SMU_NOTFANLESS
309
310config SOC_AMD_SMU_NOTFANLESS # helper symbol - do not use
311 bool
312 depends on SOC_AMD_PSP_SELECTABLE_SMU_FW
313
Martin Roth30f9b952017-10-03 15:54:45 -0600314config AMDFW_OUTSIDE_CBFS
315 bool "The AMD firmware is outside CBFS"
316 default n
317 help
318 The AMDFW (PSP) is typically locatable in cbfs. Select this
319 option to manually attach the generated amdfw.rom outside of
320 cbfs. The location is selected by the FWM position.
321
Martin Roth6d8ef242017-09-08 14:39:35 -0600322config AMD_FWM_POSITION_INDEX
323 int "Firmware Directory Table location (0 to 5)"
324 range 0 5
325 default 0 if BOARD_ROMSIZE_KB_512
326 default 1 if BOARD_ROMSIZE_KB_1024
327 default 2 if BOARD_ROMSIZE_KB_2048
328 default 3 if BOARD_ROMSIZE_KB_4096
329 default 4 if BOARD_ROMSIZE_KB_8192
330 default 5 if BOARD_ROMSIZE_KB_16384
331 help
332 Typically this is calculated by the ROM size, but there may
333 be situations where you want to put the firmware directory
334 table in a different location.
335 0: 512 KB - 0xFFFA0000
336 1: 1 MB - 0xFFF20000
337 2: 2 MB - 0xFFE20000
338 3: 4 MB - 0xFFC20000
339 4: 8 MB - 0xFF820000
340 5: 16 MB - 0xFF020000
341
342comment "AMD Firmware Directory Table set to location for 512KB ROM"
343 depends on AMD_FWM_POSITION_INDEX = 0
344comment "AMD Firmware Directory Table set to location for 1MB ROM"
345 depends on AMD_FWM_POSITION_INDEX = 1
346comment "AMD Firmware Directory Table set to location for 2MB ROM"
347 depends on AMD_FWM_POSITION_INDEX = 2
348comment "AMD Firmware Directory Table set to location for 4MB ROM"
349 depends on AMD_FWM_POSITION_INDEX = 3
350comment "AMD Firmware Directory Table set to location for 8MB ROM"
351 depends on AMD_FWM_POSITION_INDEX = 4
352comment "AMD Firmware Directory Table set to location for 16MB ROM"
353 depends on AMD_FWM_POSITION_INDEX = 5
354
Marc Jones17431ab2017-11-16 15:26:00 -0700355config DIMM_SPD_SIZE
Marc Jones17431ab2017-11-16 15:26:00 -0700356 default 512 # DDR4
357
Marc Jones578a79d2017-12-06 16:27:04 -0700358config RO_REGION_ONLY
359 string
Matt DeVillier1e54a182022-10-04 16:34:21 -0500360 depends on VBOOT_SLOTS_RW_AB || VBOOT_SLOTS_RW_A
Marc Jones578a79d2017-12-06 16:27:04 -0700361 default "apu/amdfw"
362
Chris Ching6fc39d42017-12-20 16:06:03 -0700363config DRIVERS_I2C_DESIGNWARE_CLOCK_MHZ
364 int
365 default 133
366
Felix Held27b295b2021-03-25 01:20:41 +0100367config DISABLE_KEYBOARD_RESET_PIN
368 bool
369 help
370 Instruct the SoC to not use the state of GPIO_129 as keyboard reset
371 signal. When this pin is used as GPIO and the keyboard reset
372 functionality isn't disabled, configuring it as an output and driving
373 it as 0 will cause a reset.
374
Arthur Heymansdd7ec092022-05-23 16:06:06 +0200375config ACPI_BERT_SIZE
376 hex
377 default 0x100000 if ACPI_BERT
378 default 0x0
379 help
380 Specify the amount of DRAM reserved for gathering the data used to
381 generate the ACPI table.
382
Marshall Dawson68519222019-11-25 11:36:15 -0700383endif # SOC_AMD_STONEYRIDGE