blob: 769a61533bd2f474f235fa9fd80e6f76d0aedadf [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
Chris Ching6fc39d42017-12-20 16:06:03 -070016 select DRIVERS_I2C_DESIGNWARE
Marc Jones9156cac2017-07-12 11:05:38 -060017 select GENERIC_GPIO_LIB
Aaron Durbin51e4c1a2018-01-24 17:42:51 -070018 select GENERIC_UDELAY
Angel Ponsb74975e2020-07-13 01:12:57 +020019 select HAVE_CF9_RESET
Felix Heldc07c7c92020-12-04 18:50:53 +010020 select HAVE_SMI_HANDLER
Marc Jones24484842017-05-04 21:17:45 -060021 select HAVE_USBDEBUG_OPTIONS
Marc Jones33eef132017-10-26 16:50:42 -060022 select PARALLEL_MP_AP_WORK
Marc Jones17e85ad2017-12-20 16:21:25 -070023 select RTC
Felix Heldc07c7c92020-12-04 18:50:53 +010024 select SOC_AMD_PI
25 select SOC_AMD_COMMON
26 select SOC_AMD_COMMON_BLOCK_ACPI
Felix Held0bc46842021-11-23 10:19:28 +010027 select SOC_AMD_COMMON_BLOCK_ACPI_GPIO
Felix Heldc07c7c92020-12-04 18:50:53 +010028 select SOC_AMD_COMMON_BLOCK_ACPIMMIO
Felix Held31364242021-07-23 19:18:02 +020029 select SOC_AMD_COMMON_BLOCK_ACPIMMIO_BIOSRAM
Felix Heldc07c7c92020-12-04 18:50:53 +010030 select SOC_AMD_COMMON_BLOCK_AOAC
31 select SOC_AMD_COMMON_BLOCK_BANKED_GPIOS
32 select SOC_AMD_COMMON_BLOCK_CAR
33 select SOC_AMD_COMMON_BLOCK_HDA
Karthikeyan Ramasubramanian0dbea482021-03-08 23:23:50 -070034 select SOC_AMD_COMMON_BLOCK_I2C
Felix Heldc07c7c92020-12-04 18:50:53 +010035 select SOC_AMD_COMMON_BLOCK_IOMMU
36 select SOC_AMD_COMMON_BLOCK_LPC
Felix Held1e1d4902021-07-14 00:05:39 +020037 select SOC_AMD_COMMON_BLOCK_MCA
Felix Heldc07c7c92020-12-04 18:50:53 +010038 select SOC_AMD_COMMON_BLOCK_PCI
Felix Heldc0538d42021-04-13 19:56:10 +020039 select SOC_AMD_COMMON_BLOCK_PM
Felix Heldc07c7c92020-12-04 18:50:53 +010040 select SOC_AMD_COMMON_BLOCK_PSP_GEN1
Felix Heldc07c7c92020-12-04 18:50:53 +010041 select SOC_AMD_COMMON_BLOCK_SATA
42 select SOC_AMD_COMMON_BLOCK_SMBUS
43 select SOC_AMD_COMMON_BLOCK_SMI
Felix Heldbc134812021-02-10 02:26:10 +010044 select SOC_AMD_COMMON_BLOCK_SMM
Felix Heldc07c7c92020-12-04 18:50:53 +010045 select SOC_AMD_COMMON_BLOCK_SPI
Felix Held91ef9252021-01-12 23:44:05 +010046 select SOC_AMD_COMMON_BLOCK_UART
Felix Heldc07c7c92020-12-04 18:50:53 +010047 select SSE2
48 select TSC_SYNC_LFENCE
49 select X86_AMD_FIXED_MTRRS
Marc Jones24484842017-05-04 21:17:45 -060050
Marshall Dawson12294d02019-11-25 07:21:18 -070051config AMD_APU_STONEYRIDGE
52 bool
53 help
54 AMD Stoney Ridge APU
55
Marshall Dawsone1988f52019-11-25 11:15:35 -070056config AMD_APU_PRAIRIEFALCON
57 bool
58 help
59 AMD Embedded Prairie Falcon APU
60
Marshall Dawson12294d02019-11-25 07:21:18 -070061config AMD_APU_MERLINFALCON
62 bool
63 help
Marshall Dawsone1988f52019-11-25 11:15:35 -070064 AMD Embedded Merlin Falcon APU
Marshall Dawson12294d02019-11-25 07:21:18 -070065
Marshall Dawson3ac0ab52019-11-24 19:03:56 -070066config AMD_APU_PKG_FP4
67 bool
68 help
69 AMD FP4 package
70
71config AMD_APU_PKG_FT4
72 bool
73 help
74 AMD FT4 package
75
76config AMD_SOC_PACKAGE
77 string
78 default "FP4" if AMD_APU_PKG_FP4
79 default "FT4" if AMD_APU_PKG_FT4
80
Marshall Dawsone7557de2017-06-09 16:35:14 -060081config VBOOT
Marshall Dawsone7557de2017-06-09 16:35:14 -060082 select VBOOT_SEPARATE_VERSTAGE
83 select VBOOT_STARTS_IN_BOOTBLOCK
Marc Jones4c887ea2018-04-25 16:43:18 -060084 select VBOOT_VBNV_CMOS
85 select VBOOT_VBNV_CMOS_BACKUP_TO_FLASH
Marshall Dawsone7557de2017-06-09 16:35:14 -060086
Marc Jones21cde8b2017-05-07 16:47:36 -060087# TODO: Sync these with definitions in PI vendorcode.
88# DCACHE_RAM_BASE must equal BSP_STACK_BASE_ADDR.
89# DCACHE_RAM_SIZE must equal BSP_STACK_SIZE.
90
91config DCACHE_RAM_BASE
92 hex
93 default 0x30000
94
95config DCACHE_RAM_SIZE
96 hex
97 default 0x10000
98
Marshall Dawson9df969a2017-07-25 18:46:46 -060099config DCACHE_BSP_STACK_SIZE
Marshall Dawson9df969a2017-07-25 18:46:46 -0600100 hex
101 default 0x4000
102 help
103 The amount of anticipated stack usage in CAR by bootblock and
104 other stages.
105
Marshall Dawson7c3f1e72017-08-24 09:59:10 -0600106config PRERAM_CBMEM_CONSOLE_SIZE
107 hex
Marshall Dawson1df6bc62017-12-19 20:41:29 -0700108 default 0x1600
Marshall Dawson7c3f1e72017-08-24 09:59:10 -0600109 help
110 Increase this value if preram cbmem console is getting truncated
111
Marc Jones1587dc82017-05-15 18:55:11 -0600112config BOTTOMIO_POSITION
113 hex "Bottom of 32-bit IO space"
114 default 0xD0000000
115 help
116 If PCI peripherals with big BARs are connected to the system
117 the bottom of the IO must be decreased to allocate such
118 devices.
119
120 Declare the beginning of the 128MB-aligned MMIO region. This
121 option is useful when PCI peripherals requesting large address
122 ranges are present.
123
Shelley Chen4e9bb332021-10-20 15:43:45 -0700124config ECAM_MMCONF_BASE_ADDRESS
Marc Jones1587dc82017-05-15 18:55:11 -0600125 default 0xF8000000
126
Shelley Chen4e9bb332021-10-20 15:43:45 -0700127config ECAM_MMCONF_BUS_NUMBER
Marc Jones1587dc82017-05-15 18:55:11 -0600128 default 64
129
130config VGA_BIOS_ID
131 string
Marshall Dawson12294d02019-11-25 07:21:18 -0700132 default "1002,9874" if AMD_APU_MERLINFALCON
Marc Jones1587dc82017-05-15 18:55:11 -0600133 default "1002,98e4"
134 help
135 The default VGA BIOS PCI vendor/device ID should be set to the
136 result of the map_oprom_vendev() function in northbridge.c.
137
138config VGA_BIOS_FILE
139 string
Marshall Dawson7987c1c2019-11-25 08:29:28 -0700140 default "3rdparty/amd_blobs/stoneyridge/CarrizoGenericVbios.bin" if AMD_APU_MERLINFALCON
Marshall Dawsone1988f52019-11-25 11:15:35 -0700141 default "3rdparty/amd_blobs/stoneyridge/StoneyGenericVbios.bin" if AMD_APU_PRAIRIEFALCON
142 default "3rdparty/amd_blobs/stoneyridge/StoneyGenericVbios.bin" if AMD_APU_STONEYRIDGE
Marc Jones1587dc82017-05-15 18:55:11 -0600143
Marshall Dawson668dea02017-11-29 09:57:15 -0700144config S3_VGA_ROM_RUN
145 bool
146 default n
147
Marc Jones1587dc82017-05-15 18:55:11 -0600148config HEAP_SIZE
149 hex
150 default 0xc0000
151
Marc Jones24484842017-05-04 21:17:45 -0600152config EHCI_BAR
153 hex
154 default 0xfef00000
155
156config STONEYRIDGE_XHCI_ENABLE
157 bool "Enable Stoney Ridge XHCI Controller"
158 default y
159 help
160 The XHCI controller must be enabled and the XHCI firmware
161 must be added in order to have USB 3.0 support configured
162 by coreboot. The OS will be responsible for enabling the XHCI
Jonathan Neuschäfer45e6c822018-12-11 17:53:07 +0100163 controller if the XHCI firmware is available but the
Marc Jones24484842017-05-04 21:17:45 -0600164 XHCI controller is not enabled by coreboot.
165
166config STONEYRIDGE_XHCI_FWM
167 bool "Add xhci firmware"
168 default y
169 help
170 Add Stoney Ridge XHCI Firmware to support the onboard USB 3.0
171
Marc Jones24484842017-05-04 21:17:45 -0600172config STONEYRIDGE_GEC_FWM
173 bool
174 default n
175 help
176 Add Stoney Ridge GEC Firmware to support the onboard gigabit Ethernet MAC.
177 Must be connected to a Broadcom B50610 or B50610M PHY on the motherboard.
178
179config STONEYRIDGE_XHCI_FWM_FILE
180 string "XHCI firmware path and filename"
Marshall Dawson7987c1c2019-11-25 08:29:28 -0700181 default "3rdparty/amd_blobs/stoneyridge/xhci.bin"
Marc Jones24484842017-05-04 21:17:45 -0600182 depends on STONEYRIDGE_XHCI_FWM
183
Marc Jones24484842017-05-04 21:17:45 -0600184config STONEYRIDGE_GEC_FWM_FILE
185 string "GEC firmware path and filename"
186 depends on STONEYRIDGE_GEC_FWM
187
Zheng Baoc5e28ab2020-10-28 11:38:09 +0800188config AMDFW_CONFIG_FILE
189 string
190 string "AMD PSP Firmware config file"
Zheng Baoc5e28ab2020-10-28 11:38:09 +0800191 default "src/soc/amd/stoneyridge/fw_cz.cfg" if AMD_APU_MERLINFALCON
192 default "src/soc/amd/stoneyridge/fw_st.cfg" if AMD_APU_PRAIRIEFALCON
193 default "src/soc/amd/stoneyridge/fw_st.cfg" if AMD_APU_STONEYRIDGE
Marc Jones24484842017-05-04 21:17:45 -0600194
195config STONEYRIDGE_SATA_MODE
196 int "SATA Mode"
197 default 0
198 range 0 6
199 help
200 Select the mode in which SATA should be driven.
201 The default is NATIVE.
202 0: NATIVE mode does not require a ROM.
203 2: AHCI may work with or without AHCI ROM. It depends on the payload support.
204 For example, seabios does not require the AHCI ROM.
205 3: LEGACY IDE
206 4: IDE to AHCI
207 5: AHCI7804: ROM Required, and AMD driver required in the OS.
208 6: IDE to AHCI7804: ROM Required, and AMD driver required in the OS.
209
210comment "NATIVE"
211 depends on STONEYRIDGE_SATA_MODE = 0
212
213comment "AHCI"
214 depends on STONEYRIDGE_SATA_MODE = 2
215
216comment "LEGACY IDE"
217 depends on STONEYRIDGE_SATA_MODE = 3
218
219comment "IDE to AHCI"
220 depends on STONEYRIDGE_SATA_MODE = 4
221
222comment "AHCI7804"
223 depends on STONEYRIDGE_SATA_MODE = 5
224
225comment "IDE to AHCI7804"
226 depends on STONEYRIDGE_SATA_MODE = 6
227
228if STONEYRIDGE_SATA_MODE = 2 || STONEYRIDGE_SATA_MODE = 5
229
230config AHCI_ROM_ID
231 string "AHCI device PCI IDs"
232 default "1022,7801" if STONEYRIDGE_SATA_MODE = 2
233 default "1022,7804" if STONEYRIDGE_SATA_MODE = 5
234
235endif # STONEYRIDGE_SATA_MODE = 2 || STONEYRIDGE_SATA_MODE = 5
236
237config STONEYRIDGE_LEGACY_FREE
238 bool "System is legacy free"
239 help
240 Select y if there is no keyboard controller in the system.
241 This sets variables in AGESA and ACPI.
242
Marc Jones24484842017-05-04 21:17:45 -0600243config SERIRQ_CONTINUOUS_MODE
244 bool
245 default n
246 help
247 Set this option to y for serial IRQ in continuous mode.
248 Otherwise it is in quiet mode.
249
Arthur Heymansb5e72b62018-01-02 23:41:24 +0100250config CONSOLE_UART_BASE_ADDRESS
251 depends on CONSOLE_SERIAL
252 hex
253 default 0xfedc6000
254
Marshall Dawsonc6ef9db2017-05-14 14:16:56 -0600255config SMM_TSEG_SIZE
256 hex
Felix Helde22eef72021-02-10 22:22:07 +0100257 default 0x800000 if HAVE_SMI_HANDLER
Marshall Dawsonc6ef9db2017-05-14 14:16:56 -0600258 default 0x0
259
Marshall Dawsonb6172112017-09-13 17:47:31 -0600260config SMM_RESERVED_SIZE
261 hex
Marshall Dawsonfceac7e2018-05-18 14:40:53 -0600262 default 0x150000
Marshall Dawsonb6172112017-09-13 17:47:31 -0600263
Raul E Rangel846b4942018-06-12 10:43:09 -0600264config SMM_MODULE_STACK_SIZE
265 hex
266 default 0x800
267
Marc Jonese013df92017-08-23 16:28:02 -0600268config ACPI_CPU_STRING
269 string
Matt DeVillierc08d4c52020-06-20 23:45:30 -0500270 default "\\_SB.P%03d"
Marc Jonese013df92017-08-23 16:28:02 -0600271
Marshall Dawson9a32c412018-09-04 13:29:12 -0600272config ACPI_BERT
273 bool "Build ACPI BERT Table"
274 default y
275 depends on HAVE_ACPI_TABLES
276 help
277 Report Machine Check errors identified in POST to the OS in an
278 ACPI Boot Error Record Table. This option reserves an 8MB region
279 for building the error structures.
280
Marshall Dawson25eb2bc2019-03-14 12:42:46 -0600281config USE_PSPSECUREOS
Martin Rothb617e322017-09-07 13:23:55 -0600282 bool "Include PSP SecureOS blobs in AMD firmware"
283 default y
284 help
285 Include the PspSecureOs, PspTrustlet and TrustletKey binaries
286 in the amdfw section.
287
288 If unsure, answer 'y'
289
Richard Spiegel1bc578a2019-06-18 18:19:47 -0700290config SOC_AMD_PSP_SELECTABLE_SMU_FW
291 bool
Marshall Dawson12294d02019-11-25 07:21:18 -0700292 default y if AMD_APU_STONEYRIDGE
Richard Spiegel1bc578a2019-06-18 18:19:47 -0700293 help
294 Some ST implementations allow storing SMU firmware into cbfs and
295 calling the PSP to load the blobs at the proper time.
296
297 Merlin Falcon does not support it. If you are using 00670F00 SOC,
298 ask your AMD representative if it supports it or not.
299
Marshall Dawson5f0520a2017-10-30 16:11:45 -0600300config SOC_AMD_SMU_FANLESS
301 bool
302 depends on SOC_AMD_PSP_SELECTABLE_SMU_FW
303 default n if SOC_AMD_SMU_NOTFANLESS
304 default y
305
306config SOC_AMD_SMU_FANNED
307 bool
308 depends on SOC_AMD_PSP_SELECTABLE_SMU_FW
309 default n
310 select SOC_AMD_SMU_NOTFANLESS
311
312config SOC_AMD_SMU_NOTFANLESS # helper symbol - do not use
313 bool
314 depends on SOC_AMD_PSP_SELECTABLE_SMU_FW
315
Martin Roth30f9b952017-10-03 15:54:45 -0600316config AMDFW_OUTSIDE_CBFS
317 bool "The AMD firmware is outside CBFS"
318 default n
319 help
320 The AMDFW (PSP) is typically locatable in cbfs. Select this
321 option to manually attach the generated amdfw.rom outside of
322 cbfs. The location is selected by the FWM position.
323
Martin Roth6d8ef242017-09-08 14:39:35 -0600324config AMD_FWM_POSITION_INDEX
325 int "Firmware Directory Table location (0 to 5)"
326 range 0 5
327 default 0 if BOARD_ROMSIZE_KB_512
328 default 1 if BOARD_ROMSIZE_KB_1024
329 default 2 if BOARD_ROMSIZE_KB_2048
330 default 3 if BOARD_ROMSIZE_KB_4096
331 default 4 if BOARD_ROMSIZE_KB_8192
332 default 5 if BOARD_ROMSIZE_KB_16384
333 help
334 Typically this is calculated by the ROM size, but there may
335 be situations where you want to put the firmware directory
336 table in a different location.
337 0: 512 KB - 0xFFFA0000
338 1: 1 MB - 0xFFF20000
339 2: 2 MB - 0xFFE20000
340 3: 4 MB - 0xFFC20000
341 4: 8 MB - 0xFF820000
342 5: 16 MB - 0xFF020000
343
344comment "AMD Firmware Directory Table set to location for 512KB ROM"
345 depends on AMD_FWM_POSITION_INDEX = 0
346comment "AMD Firmware Directory Table set to location for 1MB ROM"
347 depends on AMD_FWM_POSITION_INDEX = 1
348comment "AMD Firmware Directory Table set to location for 2MB ROM"
349 depends on AMD_FWM_POSITION_INDEX = 2
350comment "AMD Firmware Directory Table set to location for 4MB ROM"
351 depends on AMD_FWM_POSITION_INDEX = 3
352comment "AMD Firmware Directory Table set to location for 8MB ROM"
353 depends on AMD_FWM_POSITION_INDEX = 4
354comment "AMD Firmware Directory Table set to location for 16MB ROM"
355 depends on AMD_FWM_POSITION_INDEX = 5
356
Marc Jones17431ab2017-11-16 15:26:00 -0700357config DIMM_SPD_SIZE
Marc Jones17431ab2017-11-16 15:26:00 -0700358 default 512 # DDR4
359
Marc Jones578a79d2017-12-06 16:27:04 -0700360config RO_REGION_ONLY
361 string
362 depends on CHROMEOS
363 default "apu/amdfw"
364
Chris Ching6fc39d42017-12-20 16:06:03 -0700365config DRIVERS_I2C_DESIGNWARE_CLOCK_MHZ
366 int
367 default 133
368
Felix Held27b295b2021-03-25 01:20:41 +0100369config DISABLE_KEYBOARD_RESET_PIN
370 bool
371 help
372 Instruct the SoC to not use the state of GPIO_129 as keyboard reset
373 signal. When this pin is used as GPIO and the keyboard reset
374 functionality isn't disabled, configuring it as an output and driving
375 it as 0 will cause a reset.
376
Marshall Dawson68519222019-11-25 11:36:15 -0700377endif # SOC_AMD_STONEYRIDGE