blob: f2422d28f9e228ebbcd41b9a351239948ad72d2a [file] [log] [blame]
Simon Glassc2ae7d82016-09-12 23:18:22 -06001config SUPPORT_SPL
2 bool
3
4config SUPPORT_TPL
5 bool
6
Simon Glassf86ca5a2022-04-30 00:56:52 -06007config SUPPORT_VPL
8 bool
9
B, Ravi66928af2017-05-04 15:45:29 +053010config SPL_DFU_NO_RESET
11 bool
12
Simon Glassc2ae7d82016-09-12 23:18:22 -060013config SPL
Tom Riniab0c5f12022-05-30 17:11:23 -040014 bool "Enable SPL"
Simon Glassc2ae7d82016-09-12 23:18:22 -060015 depends on SUPPORT_SPL
Simon Glassc2ae7d82016-09-12 23:18:22 -060016 help
17 If you want to build SPL as well as the normal image, say Y.
18
Tom Riniab0c5f12022-05-30 17:11:23 -040019menu "SPL configuration options"
20 depends on SPL
21
Tom Rini75670c82018-02-06 12:15:38 -050022config SPL_FRAMEWORK
23 bool "Support SPL based upon the common SPL framework"
Tom Rini75670c82018-02-06 12:15:38 -050024 default y
25 help
26 Enable the SPL framework under common/spl/. This framework
27 supports MMC, NAND and YMODEM and other methods loading of U-Boot
28 and the Linux Kernel. If unsure, say Y.
29
Philippe Reynesa9a3aad2019-09-19 16:18:39 +020030config SPL_FRAMEWORK_BOARD_INIT_F
31 bool "Define a generic function board_init_f"
32 depends on SPL_FRAMEWORK
33 help
34 Define a generic function board_init_f that:
35 - initialize the spl (spl_early_init)
36 - initialize the serial (preloader_console_init)
37 Unless you want to provide your own board_init_f, you should say Y.
38
Simon Goldschmidt25770152019-05-24 22:07:04 +020039config SPL_SIZE_LIMIT
Simon Glassb51882d2019-09-25 08:56:28 -060040 hex "Maximum size of SPL image"
Ovidiu Panait2dfdd0c2020-09-25 21:12:56 +030041 default 0x11000 if ARCH_MX6 && !MX6_OCRAM_256KB
42 default 0x31000 if ARCH_MX6 && MX6_OCRAM_256KB
Pali Rohár4a08c262022-09-14 18:48:16 +020043 default 0x30000 if ARCH_MVEBU && ARMADA_32BIT
Ovidiu Panait2dfdd0c2020-09-25 21:12:56 +030044 default 0x0
Simon Goldschmidt25770152019-05-24 22:07:04 +020045 help
46 Specifies the maximum length of the U-Boot SPL image.
47 If this value is zero, it is ignored.
48
49config SPL_SIZE_LIMIT_SUBTRACT_GD
50 bool "SPL image size check: provide space for global data"
51 depends on SPL_SIZE_LIMIT > 0
52 help
53 If enabled, aligned size of global data is reserved in
54 SPL_SIZE_LIMIT check to ensure such an image does not overflow SRAM
55 if SPL_SIZE_LIMIT describes the size of SRAM available for SPL when
56 pre-reloc global data is put into this SRAM, too.
57
58config SPL_SIZE_LIMIT_SUBTRACT_MALLOC
59 bool "SPL image size check: provide space for malloc() pool before relocation"
60 depends on SPL_SIZE_LIMIT > 0
61 help
62 If enabled, SPL_SYS_MALLOC_F_LEN is reserved in SPL_SIZE_LIMIT check
63 to ensure such an image does not overflow SRAM if SPL_SIZE_LIMIT
64 describes the size of SRAM available for SPL when pre-reloc malloc
65 pool is put into this SRAM, too.
66
67config SPL_SIZE_LIMIT_PROVIDE_STACK
68 hex "SPL image size check: provide stack space before relocation"
69 depends on SPL_SIZE_LIMIT > 0
70 default 0
71 help
72 If set, this size is reserved in SPL_SIZE_LIMIT check to ensure such
73 an image does not overflow SRAM if SPL_SIZE_LIMIT describes the size
74 of SRAM available for SPL when the stack required before reolcation
75 uses this SRAM, too.
76
Tom Rinica8a3292022-05-16 17:20:26 -040077config SPL_MAX_SIZE
78 hex "Maximum size of the SPL image, excluding BSS"
79 default 0x30000 if ARCH_MX6 && MX6_OCRAM_256KB
80 default 0x1b000 if AM33XX && !TI_SECURE_DEVICE
81 default 0x10000 if ARCH_MX6 && !MX6_OCRAM_256KB
82 default 0x7fa0 if SUNXI_SRAM_ADDRESS = 0x10000
83 default 0x7fa0 if SUNXI_SRAM_ADDRESS = 0x20000 && !MACH_SUN50I_H616
84 default 0x7000 if RCAR_GEN3
85 default 0x5fa0 if SUNXI_SRAM_ADDRESS = 0x0
Joel Stanleya1617532022-06-29 16:35:22 +093086 default 0x10000 if ASPEED_AST2600
Peng Fan658ff9d2022-07-26 16:40:31 +080087 default 0x27000 if IMX8MM && SPL_TEXT_BASE = 0x7E1000
Tom Rinica8a3292022-05-16 17:20:26 -040088 default 0x0
89 help
90 Maximum size of the SPL image (text, data, rodata, and linker lists
91 sections), BSS excluded. When defined, the linker checks that the
92 actual size does not exceed it.
93
94config SPL_PAD_TO
95 hex "Offset to which the SPL should be padded before appending the SPL payload"
96 default 0x31000 if ARCH_MX6 && MX6_OCRAM_256KB
97 default 0x11000 if ARCH_MX7 || (ARCH_MX6 && !MX6_OCRAM_256KB)
98 default 0x10000 if ARCH_KEYSTONE
99 default 0x8000 if ARCH_SUNXI && !MACH_SUN50I_H616
100 default TPL_MAX_SIZE if TPL_MAX_SIZE > SPL_MAX_SIZE
101 default SPL_MAX_SIZE
102 help
103 Image offset to which the SPL should be padded before appending the
104 SPL payload. By default, this is defined as CONFIG_SPL_MAX_SIZE, or 0 if
105 CONFIG_SPL_MAX_SIZE is undefined. CONFIG_SPL_PAD_TO must be either
106 0, meaning to append the SPL payload without any padding, or >=
107 CONFIG_SPL_MAX_SIZE.
108
Tom Rini6600b352022-05-27 10:19:45 -0400109config SPL_HAS_BSS_LINKER_SECTION
110 depends on SPL_FRAMEWORK
111 bool "Use a specific address for the BSS via the linker script"
Stefan Herbrechtsmeierfcbc43b2022-07-14 15:47:33 +0200112 default y if ARCH_SUNXI || ARCH_MX6 || ARCH_OMAP2PLUS || MIPS || RISCV || ARCH_ZYNQMP
Tom Rini6600b352022-05-27 10:19:45 -0400113
114config SPL_BSS_START_ADDR
115 hex "Link address for the BSS within the SPL binary"
116 depends on SPL_HAS_BSS_LINKER_SECTION
117 default 0x88200000 if (ARCH_MX6 && (MX6SX || MX6SL || MX6UL || MX6ULL)) || ARCH_MX7
118 default 0x18200000 if ARCH_MX6 && !(MX6SX || MX6SL || MX6UL || MX6ULL)
119 default 0x80a00000 if ARCH_OMAP2PLUS
120 default 0x81f80000 if ARCH_SUNXI && MACH_SUNIV
121 default 0x4ff80000 if ARCH_SUNXI && !(MACH_SUN9I || MACH_SUNIV)
122 default 0x2ff80000 if ARCH_SUNXI && MACH_SUN9I
Stefan Herbrechtsmeierfcbc43b2022-07-14 15:47:33 +0200123 default 0x1000 if ARCH_ZYNQMP
Tom Rini6600b352022-05-27 10:19:45 -0400124
Tom Rini9b5f9ae2022-05-19 15:09:22 -0400125choice
126 prompt "Enforce SPL BSS limit"
Tom Riniab0c5f12022-05-30 17:11:23 -0400127 depends on !PPC
Tom Rini9b5f9ae2022-05-19 15:09:22 -0400128 default SPL_BSS_LIMIT
129 help
130 In some platforms we only want to enforce a limit on the size of the
131 BSS in memory. On other platforms we need to enforce a limit on the
132 whole of the memory allocation as we're strictly limited to a small
133 typically non-DRAM location. Finally, other platforms do not enforce
134 a memory limit within SPL.
135
136config SPL_NO_BSS_LIMIT
137 bool "Do not enforce a build time limit on the size of the BSS"
138
139config SPL_BSS_LIMIT
140 bool "Enforce a limit on the size of the BSS only"
141
142config SPL_FOOTPRINT_LIMIT
143 bool "Enforce a limit on the whole of memory allocated to SPL, BSS included"
144
145endchoice
146
147config SPL_BSS_MAX_SIZE
148 hex "Maximum size in memory allocated to the SPL BSS"
149 depends on SPL_BSS_LIMIT
150 default 0x100000 if ARCH_MX6 || RISCV
151 default 0x80000 if ARCH_OMAP2PLUS || ARCH_SUNXI
152 help
153 When non-zero, the linker checks that the actual memory used by SPL
154 from __bss_start to __bss_end does not exceed it.
155
156config SPL_MAX_FOOTPRINT
157 hex "Maximum size in memory allocated to the SPL, BSS included"
158 depends on SPL_FOOTPRINT_LIMIT
159 help
160 When non-zero, the linker checks that the actual memory used by SPL
161 from _start to __bss_end does not exceed it.
162
Simon Goldschmidtd8c03322019-07-16 22:30:36 +0200163config SPL_SYS_STACK_F_CHECK_BYTE
164 hex
165 default 0xaa
166 help
167 Constant used to check the stack
168
169config SPL_SYS_REPORT_STACK_F_USAGE
170 depends on SPL_SIZE_LIMIT_PROVIDE_STACK != 0
171 bool "Check and report stack usage in SPL before relocation"
172 help
173 If this option is enabled, the initial SPL stack is filled with 0xaa
174 very early, up to the size configured with
175 SPL_SIZE_LIMIT_PROVIDE_STACK.
176 Later when SPL is done using this initial stack and switches to a
177 stack in DRAM, the actually used size of this initial stack is
178 reported by examining the memory and searching for the lowest
179 occurrence of non 0xaa bytes.
180 This default implementation works for stacks growing down only.
181
Simon Glass7d84fbb2021-07-05 16:32:57 -0600182config SPL_SHOW_ERRORS
183 bool "Show more information when something goes wrong"
184 help
185 This enabled more verbose error messages and checking when something
186 goes wrong in SPL. For example, it shows the error code when U-Boot
187 cannot be located. This can help to diagnose the problem and figure
188 out a fix, particularly during development.
189
190 This adds a small amount to SPL code size, perhaps 100 bytes.
191
Simon Glass38c04d82022-02-08 11:49:48 -0700192config SPL_BINMAN_SYMBOLS
193 bool "Declare binman symbols in SPL"
194 depends on SPL_FRAMEWORK && BINMAN
195 default y
196 help
Alper Nebi Yasakd8830cf2022-06-18 15:13:09 +0300197 This enables use of symbols in SPL which refer to other entries in
198 the same binman image as the SPL. These can be declared with the
199 binman_sym_declare(type, entry, prop) macro and accessed by the
200 binman_sym(type, entry, prop) macro defined in binman_sym.h.
Simon Glass38c04d82022-02-08 11:49:48 -0700201
Alper Nebi Yasakd8830cf2022-06-18 15:13:09 +0300202 See tools/binman/binman.rst for a detailed explanation.
203
204config SPL_BINMAN_UBOOT_SYMBOLS
205 bool "Declare binman symbols for U-Boot phases in SPL"
206 depends on SPL_BINMAN_SYMBOLS
Alper Nebi Yasak6516c9b2022-06-18 15:13:12 +0300207 default n if ARCH_IMX8M
Alper Nebi Yasakd8830cf2022-06-18 15:13:09 +0300208 default y
209 help
210 This enables use of symbols in SPL which refer to U-Boot phases,
211 enabling SPL to obtain the location and size of its next phase simply
212 by calling spl_get_image_pos() and spl_get_image_size().
213
214 For this to work, you must have all U-Boot phases in the same binman
215 image, so binman can update SPL with the locations of everything.
Simon Glass38c04d82022-02-08 11:49:48 -0700216
Tom Riniba787bb2022-05-30 17:01:22 -0400217source "common/spl/Kconfig.nxp"
Tom Rinib35316f2022-05-13 12:26:35 -0400218
Simon Glassb0edea32018-11-15 18:44:09 -0700219config HANDOFF
220 bool "Pass hand-off information from SPL to U-Boot proper"
Tom Riniab0c5f12022-05-30 17:11:23 -0400221 depends on BLOBLIST
Simon Glassb0edea32018-11-15 18:44:09 -0700222 help
223 It is useful to be able to pass information from SPL to U-Boot
224 proper to preserve state that is known in SPL and is needed in U-Boot.
225 Enable this to locate the handoff information in U-Boot proper, early
226 in boot. It is available in gd->handoff. The state state is set up
227 in SPL (or TPL if that is being used).
228
Simon Glassb0edea32018-11-15 18:44:09 -0700229config SPL_HANDOFF
230 bool "Pass hand-off information from SPL to U-Boot proper"
Simon Glassa7da3d92019-09-25 08:11:17 -0600231 depends on HANDOFF && SPL_BLOBLIST
Simon Glassb0edea32018-11-15 18:44:09 -0700232 default y
233 help
234 This option enables SPL to write handoff information. This can be
235 used to pass information like the size of SDRAM from SPL to U-Boot
236 proper. Also SPL can receive information from TPL in the same place
237 if that is enabled.
238
Philipp Tomsichdd6fbcb2017-07-28 19:20:49 +0200239config SPL_LDSCRIPT
240 string "Linker script for the SPL stage"
Tom Rini5858b902022-06-08 08:24:37 -0400241 default "arch/arm/cpu/arm926ejs/sunxi/u-boot-spl.lds" if MACH_SUNIV
242 default "arch/arm/cpu/armv7/sunxi/u-boot-spl.lds" if ARCH_SUNXI && !MACH_SUNIV && !ARM64
243 default "arch/arm/cpu/arm926ejs/mxs/u-boot-spl.lds" if (ARCH_MX23 || ARCH_MX28) && !SPL_FRAMEWORK
244 default "arch/arm/cpu/arm1136/u-boot-spl.lds" if CPU_ARM1136
245 default "arch/arm/cpu/armv8/u-boot-spl.lds" if ARCH_LS1043A || ARCH_LS1046A || ARCH_LS2080A
246 default "arch/arm/cpu/armv8/u-boot-spl.lds" if ARM64
247 default "arch/arm/mach-at91/arm926ejs/u-boot-spl.lds" if ARCH_AT91 && CPU_ARM926EJS
248 default "arch/arm/mach-at91/armv7/u-boot-spl.lds" if ARCH_AT91 && CPU_V7A
249 default "arch/arm/mach-omap2/u-boot-spl.lds" if ARCH_MX6 || ARCH_OMAP2PLUS || (ARCH_K3 && !ARM64)
250 default "arch/arm/mach-zynq/u-boot-spl.lds" if ARCH_ZYNQ
251 default "board/samsung/common/exynos-uboot-spl.lds" if ARCH_EXYNOS5 || ARCH_EXYNOS4
252 default "board/davinci/da8xxevm/u-boot-spl-da850evm.lds" if ARCH_DAVINCI
Tom Rinia356e7a2020-03-11 18:11:11 -0400253 default "arch/\$(ARCH)/cpu/u-boot-spl.lds"
Philipp Tomsichdd6fbcb2017-07-28 19:20:49 +0200254 help
255 The SPL stage will usually require a different linker-script
256 (as it runs from a different memory region) than the regular
257 U-Boot stage. Set this to the path of the linker-script to
258 be used for SPL.
259
Simon Goldschmidtf89d6132018-09-30 14:31:53 +0200260config SPL_TEXT_BASE
261 hex "SPL Text Base"
Andrew Davisa9ec2f62022-07-15 12:31:48 -0500262 default 0x402F4000 if AM43XX
263 default 0x402F0400 if AM33XX
264 default 0x40301350 if OMAP54XX
Andre Przywara9340d8f2019-05-27 01:45:11 +0100265 default 0x10060 if MACH_SUN50I || MACH_SUN50I_H5 || MACH_SUN9I
Jernej Skrabec44726092021-01-11 21:11:34 +0100266 default 0x20060 if SUN50I_GEN_H6
Andre Przywara9340d8f2019-05-27 01:45:11 +0100267 default 0x00060 if ARCH_SUNXI
Michal Simek0413f9c2019-09-11 08:49:31 +0200268 default 0xfffc0000 if ARCH_ZYNQMP
Simon Goldschmidtf89d6132018-09-30 14:31:53 +0200269 default 0x0
270 help
271 The address in memory that SPL will be running from.
272
Ley Foon Tan0680f1b2017-05-03 17:13:32 +0800273config SPL_BOARD_INIT
Ley Foon Tan0680f1b2017-05-03 17:13:32 +0800274 bool "Call board-specific initialization in SPL"
275 help
276 If this option is enabled, U-Boot will call the function
277 spl_board_init() from board_init_r(). This function should be
278 provided by the board.
279
Philipp Tomsich225d30b2017-06-22 23:38:36 +0200280config SPL_BOOTROM_SUPPORT
Michal Simekce869b52021-05-20 13:08:44 +0200281 bool "Support returning to the BOOTROM"
Philipp Tomsich225d30b2017-06-22 23:38:36 +0200282 help
283 Some platforms (e.g. the Rockchip RK3368) provide support in their
284 ROM for loading the next boot-stage after performing basic setup
285 from the SPL stage.
286
287 Enable this option, to return to the BOOTROM through the
288 BOOT_DEVICE_BOOTROM (or fall-through to the next boot device in the
289 boot device list, if not implemented for a given board)
290
Lukasz Majewskiafa96092018-05-02 16:10:50 +0200291config SPL_BOOTCOUNT_LIMIT
292 bool "Support bootcount in SPL"
Philippe Reynes4d145f22020-12-11 19:56:47 +0100293 depends on SPL_ENV_SUPPORT && !TPL_BOOTCOUNT_LIMIT
Lukasz Majewskiafa96092018-05-02 16:10:50 +0200294 help
295 On some boards, which use 'falcon' mode, it is necessary to check
296 and increment the number of boot attempts. Such boards do not
297 use proper U-Boot for normal boot flow and hence needs those
298 adjustments to be done in the SPL.
299
Andrew F. Davis24eb39b2017-02-16 11:18:38 -0600300config SPL_RAW_IMAGE_SUPPORT
301 bool "Support SPL loading and booting of RAW images"
Pali Rohár35ed1762022-05-24 10:58:42 +0200302 default n if ARCH_MVEBU
Simon Glassf7560372021-08-08 12:20:17 -0600303 default n if (ARCH_MX6 && (SPL_MMC || SPL_SATA))
Andrew Davis11f32da2022-05-04 15:52:26 -0500304 default y
305 depends on !TI_SECURE_DEVICE
Andrew F. Davis24eb39b2017-02-16 11:18:38 -0600306 help
307 SPL will support loading and booting a RAW image when this option
308 is y. If this is not set, SPL will move on to other available
309 boot media to find a suitable image.
310
Andrew Davis6665ab12022-05-04 15:52:25 -0500311config SPL_LEGACY_IMAGE_FORMAT
Andrew F. Davis722a6b12017-02-16 11:18:39 -0600312 bool "Support SPL loading and booting of Legacy images"
Pali Rohár35ed1762022-05-24 10:58:42 +0200313 default n if ARCH_MVEBU
Andrew Davis11f32da2022-05-04 15:52:26 -0500314 default y if !SPL_LOAD_FIT
315 depends on !TI_SECURE_DEVICE
Andrew F. Davis722a6b12017-02-16 11:18:39 -0600316 help
317 SPL will support loading and booting Legacy images when this option
318 is y. If this is not set, SPL will move on to other available
319 boot media to find a suitable image.
320
Simon Goldschmidtdae5c2d2019-02-10 21:34:37 +0100321config SPL_LEGACY_IMAGE_CRC_CHECK
322 bool "Check CRC of Legacy images"
Andrew Davis6665ab12022-05-04 15:52:25 -0500323 depends on SPL_LEGACY_IMAGE_FORMAT
Simon Glass1e52db62021-07-14 17:05:32 -0500324 select SPL_CRC32
Simon Goldschmidtdae5c2d2019-02-10 21:34:37 +0100325 help
326 Enable this to check the CRC of Legacy images. While this increases
327 reliability, it affects both code size and boot duration.
328 If disabled, Legacy images are booted if the image magic and size
329 are correct, without further integrity checks.
330
Simon Glassc2ae7d82016-09-12 23:18:22 -0600331config SPL_SYS_MALLOC_SIMPLE
Tom Riniab0c5f12022-05-30 17:11:23 -0400332 bool "Only use malloc_simple functions in the SPL"
Simon Glassc2ae7d82016-09-12 23:18:22 -0600333 help
334 Say Y here to only use the *_simple malloc functions from
335 malloc_simple.c, rather then using the versions from dlmalloc.c;
336 this will make the SPL binary smaller at the cost of more heap
337 usage as the *_simple malloc functions do not re-use free-ed mem.
338
Tom Rinif113d7d2022-05-26 13:13:21 -0400339config SPL_SHARES_INIT_SP_ADDR
340 bool "SPL and U-Boot use the same initial stack pointer location"
341 depends on (ARM || ARCH_JZ47XX || MICROBLAZE || RISCV) && SPL_FRAMEWORK
Tom Rini8b83b532022-05-26 13:46:32 -0400342 default n if ARCH_SUNXI || ARCH_MX6 || ARCH_MX7
Tom Rinif113d7d2022-05-26 13:13:21 -0400343 default y
344 help
345 In many cases, we can use the same initial stack pointer address for
346 both SPL and U-Boot itself. If you need to specify a different address
347 however, say N here and then set a different value in CONFIG_SPL_STACK.
348
349config SPL_STACK
350 hex "Initial stack pointer location"
351 depends on (ARM || ARCH_JZ47XX || MICROBLAZE || RISCV) && SPL_FRAMEWORK
352 depends on !SPL_SHARES_INIT_SP_ADDR
Tom Rini8b83b532022-05-26 13:46:32 -0400353 default 0x946bb8 if ARCH_MX7
Tom Rini23780392022-05-26 13:36:17 -0400354 default 0x93ffb8 if ARCH_MX6 && MX6_OCRAM_256KB
355 default 0x91ffb8 if ARCH_MX6 && !MX6_OCRAM_256KB
Tom Rinif113d7d2022-05-26 13:13:21 -0400356 help
357 Address of the start of the stack SPL will use before SDRAM is
358 initialized.
359
Simon Glassc2ae7d82016-09-12 23:18:22 -0600360config SPL_STACK_R
Simon Glassc2ae7d82016-09-12 23:18:22 -0600361 bool "Enable SDRAM location for SPL stack"
362 help
363 SPL starts off execution in SRAM and thus typically has only a small
364 stack available. Since SPL sets up DRAM while in its board_init_f()
365 function, it is possible for the stack to move there before
366 board_init_r() is reached. This option enables a special SDRAM
367 location for the SPL stack. U-Boot SPL switches to this after
368 board_init_f() completes, and before board_init_r() starts.
369
370config SPL_STACK_R_ADDR
371 depends on SPL_STACK_R
372 hex "SDRAM location for SPL stack"
Tom Riniff6c3122017-09-17 11:44:49 -0400373 default 0x82000000 if ARCH_OMAP2PLUS
Simon Glassc2ae7d82016-09-12 23:18:22 -0600374 help
375 Specify the address in SDRAM for the SPL stack. This will be set up
376 before board_init_r() is called.
377
378config SPL_STACK_R_MALLOC_SIMPLE_LEN
379 depends on SPL_STACK_R && SPL_SYS_MALLOC_SIMPLE
380 hex "Size of malloc_simple heap after switching to DRAM SPL stack"
381 default 0x100000
382 help
383 Specify the amount of the stack to use as memory pool for
384 malloc_simple after switching the stack to DRAM. This may be set
385 to give board_init_r() a larger heap then the initial heap in
386 SRAM which is limited to SYS_MALLOC_F_LEN bytes.
387
388config SPL_SEPARATE_BSS
Simon Glassc2ae7d82016-09-12 23:18:22 -0600389 bool "BSS section is in a different memory region from text"
390 help
391 Some platforms need a large BSS region in SPL and can provide this
392 because RAM is already set up. In this case BSS can be moved to RAM.
393 This option should then be enabled so that the correct device tree
394 location is used. Normally we put the device tree at the end of BSS
395 but with this option enabled, it goes at _image_binary_end.
396
Tom Rini10f6e4d2022-05-27 12:48:32 -0400397config SYS_SPL_MALLOC
398 bool "Enable malloc pool in SPL"
399 depends on SPL_FRAMEWORK
400
401config HAS_CUSTOM_SPL_MALLOC_START
402 bool "For the SPL malloc pool, define a custom starting address"
403 depends on SYS_SPL_MALLOC
404
405config CUSTOM_SYS_SPL_MALLOC_ADDR
406 hex "SPL malloc addr"
407 depends on HAS_CUSTOM_SPL_MALLOC_START
408
409config SYS_SPL_MALLOC_SIZE
410 hex "Size of the SPL malloc pool"
411 depends on SYS_SPL_MALLOC
412 default 0x100000
413
Simon Glass95a58252021-03-15 17:25:35 +1300414config SPL_READ_ONLY
415 bool
416 depends on SPL_OF_PLATDATA
417 # Bind cannot be supported because the udevice structs are in read-only
418 # memory so we cannot update the linked lists.
419 select SPL_OF_PLATDATA_NO_BIND
420 select SPL_OF_PLATDATA_RT
421 help
422 Some platforms (e.g. x86 Apollo Lake) load SPL into a read-only
423 section of memory. This means that of-platdata must make a copy (in
424 writeable memory) of anything it wants to modify, such as
425 device-private data.
426
Simon Glassaedc08b2018-11-15 18:43:57 -0700427config SPL_BANNER_PRINT
428 bool "Enable output of the SPL banner 'U-Boot SPL ...'"
429 default y
430 help
431 If this option is enabled, SPL will print the banner with version
Thomas Hebb32f2ca22019-11-13 18:18:03 -0800432 info. Disabling this option could be useful to reduce SPL boot time
Simon Glassaedc08b2018-11-15 18:43:57 -0700433 (e.g. approx. 6 ms faster, when output on i.MX6 with 115200 baud).
434
Andreas Dannenberga5a5d992019-06-04 17:55:45 -0500435config SPL_EARLY_BSS
436 depends on ARM && !ARM64
437 bool "Allows initializing BSS early before entering board_init_f"
438 help
439 On some platform we have sufficient memory available early on to
440 allow setting up and using a basic BSS prior to entering
441 board_init_f. Activating this option will also de-activate the
442 clearing of BSS during the SPL relocation process, thus allowing
443 to carry state from board_init_f to board_init_r by way of BSS.
444
Simon Glassa807ab32016-09-24 18:19:56 -0600445config SPL_DISPLAY_PRINT
Simon Glassa807ab32016-09-24 18:19:56 -0600446 bool "Display a board-specific message in SPL"
447 help
448 If this option is enabled, U-Boot will call the function
449 spl_display_print() immediately after displaying the SPL console
450 banner ("U-Boot SPL ..."). This function should be provided by
451 the board.
452
Semen Protsenko38fed8a2016-11-16 19:19:05 +0200453config SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
454 bool "MMC raw mode: by sector"
Fabio Estevam1da19382018-06-11 15:08:05 -0300455 default y if ARCH_SUNXI || ARCH_DAVINCI || ARCH_UNIPHIER || \
456 ARCH_MX6 || ARCH_MX7 || \
Semen Protsenko38fed8a2016-11-16 19:19:05 +0200457 ARCH_ROCKCHIP || ARCH_MVEBU || ARCH_SOCFPGA || \
458 ARCH_AT91 || ARCH_ZYNQ || ARCH_KEYSTONE || OMAP34XX || \
Bin Mengae2d9502021-03-17 11:10:58 +0800459 OMAP44XX || OMAP54XX || AM33XX || AM43XX || \
Green Wan70415e12021-05-27 06:52:13 -0700460 TARGET_SIFIVE_UNLEASHED || TARGET_SIFIVE_UNMATCHED
Semen Protsenko38fed8a2016-11-16 19:19:05 +0200461 help
462 Use sector number for specifying U-Boot location on MMC/SD in
463 raw mode.
464
465config SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
466 hex "Address on the MMC to load U-Boot from"
Tom Rini226498b2017-05-22 19:21:57 +0000467 depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
Andre Przywarac0b417b2021-01-11 21:11:39 +0100468 default 0x40 if ARCH_SUNXI
Semen Protsenko38fed8a2016-11-16 19:19:05 +0200469 default 0x75 if ARCH_DAVINCI
Fabio Estevam1da19382018-06-11 15:08:05 -0300470 default 0x8a if ARCH_MX6 || ARCH_MX7
Kever Yang8f4d62b2017-11-02 15:16:34 +0800471 default 0x100 if ARCH_UNIPHIER
Pali Rohár2226ca12021-07-23 11:14:29 +0200472 default 0x0 if ARCH_MVEBU
Semen Protsenko38fed8a2016-11-16 19:19:05 +0200473 default 0x200 if ARCH_SOCFPGA || ARCH_AT91
474 default 0x300 if ARCH_ZYNQ || ARCH_KEYSTONE || OMAP34XX || OMAP44XX || \
Lokesh Vutla586bde92018-08-27 15:57:08 +0530475 OMAP54XX || AM33XX || AM43XX || ARCH_K3
Kever Yang8f4d62b2017-11-02 15:16:34 +0800476 default 0x4000 if ARCH_ROCKCHIP
Green Wan70415e12021-05-27 06:52:13 -0700477 default 0x822 if TARGET_SIFIVE_UNLEASHED || TARGET_SIFIVE_UNMATCHED
Semen Protsenko38fed8a2016-11-16 19:19:05 +0200478 help
479 Address on the MMC to load U-Boot from, when the MMC is being used
480 in raw mode. Units: MMC sectors (1 sector = 512 bytes).
481
Baruch Siache42afd82020-01-15 09:08:08 +0200482config SYS_MMCSD_RAW_MODE_U_BOOT_DATA_PART_OFFSET
483 hex "U-Boot main hardware partition image offset"
484 depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
Andre Przywarac0b417b2021-01-11 21:11:39 +0100485 default 0x10 if ARCH_SUNXI
Baruch Siache42afd82020-01-15 09:08:08 +0200486 default 0x0
487 help
488 On some platforms SPL location depends on hardware partition. The ROM
489 code skips the MBR sector when loading SPL from main hardware data
490 partition. This adds offset to the main U-Boot image. Set this symbol
491 to the number of skipped sectors.
492
493 If unsure, leave the default.
494
Dalon Westergreen949123e2017-02-10 17:15:35 -0800495config SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
496 bool "MMC Raw mode: by partition"
Dalon Westergreen949123e2017-02-10 17:15:35 -0800497 help
498 Use a partition for loading U-Boot when using MMC/SD in raw mode.
499
500config SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION
501 hex "Partition to use to load U-Boot from"
Tom Rini226498b2017-05-22 19:21:57 +0000502 depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
Dalon Westergreen949123e2017-02-10 17:15:35 -0800503 default 1
504 help
505 Partition on the MMC to load U-Boot from when the MMC is being
506 used in raw mode
507
Dalon Westergreenf0fb4fa2017-02-10 17:15:34 -0800508config SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION_TYPE
509 bool "MMC raw mode: by partition type"
Tom Rini226498b2017-05-22 19:21:57 +0000510 depends on DOS_PARTITION && SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
Dalon Westergreenf0fb4fa2017-02-10 17:15:34 -0800511 help
512 Use partition type for specifying U-Boot partition on MMC/SD in
513 raw mode. U-Boot will be loaded from the first partition of this
514 type to be found.
515
516config SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION_TYPE
517 hex "Partition Type on the MMC to load U-Boot from"
Tom Rini226498b2017-05-22 19:21:57 +0000518 depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION_TYPE
Dalon Westergreenf0fb4fa2017-02-10 17:15:34 -0800519 help
520 Partition Type on the MMC to load U-Boot from, when the MMC is being
521 used in raw mode.
522
Anatolij Gustschin32ded502019-10-18 21:38:33 +0200523config SUPPORT_EMMC_BOOT_OVERRIDE_PART_CONFIG
524 bool "Override eMMC EXT_CSC_PART_CONFIG by user defined partition"
525 depends on SUPPORT_EMMC_BOOT
526 help
527 eMMC boot partition is normally configured by the bits of the EXT_CSD
528 register (EXT_CSC_PART_CONFIG), BOOT_PARTITION_ENABLE field. In some
529 cases it might be required in SPL to load the image from different
530 partition than the partition selected by EXT_CSC_PART_CONFIG register.
531 Enable this option if you intend to use an eMMC boot partition other
532 then selected via EXT_CSC_PART_CONFIG register and specify the custom
533 partition number by the CONFIG_SYS_MMCSD_RAW_MODE_EMMC_BOOT_PARTITION
534 option.
535
536config SYS_MMCSD_RAW_MODE_EMMC_BOOT_PARTITION
537 int "Number of the eMMC boot partition to use"
538 depends on SUPPORT_EMMC_BOOT_OVERRIDE_PART_CONFIG
539 default 1
540 help
541 eMMC boot partition number to use when the eMMC in raw mode and
542 the eMMC EXT_CSC_PART_CONFIG selection should be overridden in SPL
543 by user defined partition number.
544
Simon Glass1e52db62021-07-14 17:05:32 -0500545config SPL_CRC32
Simon Glass11bde1c2016-09-13 07:05:23 -0600546 bool "Support CRC32"
Andrew Davis6665ab12022-05-04 15:52:25 -0500547 default y if SPL_LEGACY_IMAGE_FORMAT || SPL_EFI_PARTITION
Simon Glasse7d285b2021-09-25 19:43:24 -0600548 default y if SPL_ENV_SUPPORT || TPL_BLOBLIST
Simon Glass11bde1c2016-09-13 07:05:23 -0600549 help
Simon Goldschmidtdae5c2d2019-02-10 21:34:37 +0100550 Enable this to support CRC32 in uImages or FIT images within SPL.
551 This is a 32-bit checksum value that can be used to verify images.
552 For FIT images, this is the least secure type of checksum, suitable
553 for detected accidental image corruption. For secure applications you
554 should consider SHA1 or SHA256.
Simon Glass11bde1c2016-09-13 07:05:23 -0600555
Simon Glass4b00fd12021-07-14 17:05:33 -0500556config SPL_MD5
Simon Glass11bde1c2016-09-13 07:05:23 -0600557 bool "Support MD5"
558 depends on SPL_FIT
559 help
560 Enable this to support MD5 in FIT images within SPL. An MD5
561 checksum is a 128-bit hash value used to check that the image
562 contents have not been corrupted. Note that MD5 is not considered
563 secure as it is possible (with a brute-force attack) to adjust the
564 image while still retaining the same MD5 hash value. For secure
565 applications where images may be changed maliciously, you should
Reuben Dowled16b38f2020-04-16 17:36:52 +1200566 consider SHA256 or SHA384.
Simon Glass11bde1c2016-09-13 07:05:23 -0600567
Philipp Tomsich337bbb62017-11-24 13:26:03 +0100568config SPL_FIT_IMAGE_TINY
569 bool "Remove functionality from SPL FIT loading to reduce size"
570 depends on SPL_FIT
Jernej Skrabec44726092021-01-11 21:11:34 +0100571 default y if MACH_SUN50I || MACH_SUN50I_H5 || SUN50I_GEN_H6
Peng Fan65c56bc2022-07-26 16:40:45 +0800572 default y if ARCH_IMX8M || ARCH_IMX9
Philipp Tomsich337bbb62017-11-24 13:26:03 +0100573 help
574 Enable this to reduce the size of the FIT image loading code
575 in SPL, if space for the SPL binary is very tight.
576
Samuel Hollandcf705532020-10-21 21:12:13 -0500577 This skips the recording of each loaded payload
Philipp Tomsich337bbb62017-11-24 13:26:03 +0100578 (i.e. loadable) into the FDT (modifying the loaded FDT to
579 ensure this information is available to the next image
580 invoked).
581
Simon Glassde213c72021-08-08 12:20:15 -0600582config SPL_CACHE
Rick Chen31dae222019-11-14 13:52:26 +0800583 bool "Support CACHE drivers"
584 help
585 Enable CACHE drivers in SPL. These drivers can keep data so that
586 future requests for that data can be served faster. Enable this option
587 to build the drivers in drivers/cache as part of an SPL build.
588
Simon Glass529d5f92021-03-15 18:11:18 +1300589config SPL_CPU
Simon Glass5e148df2017-01-16 07:03:29 -0700590 bool "Support CPU drivers"
Simon Glass5e148df2017-01-16 07:03:29 -0700591 help
592 Enable this to support CPU drivers in SPL. These drivers can set
593 up CPUs and provide information about them such as the model and
594 name. This can be useful in SPL since setting up the CPUs earlier
595 may improve boot performance. Enable this option to build the
596 drivers in drivers/cpu as part of an SPL build.
597
Simon Glass0c6bdbb2021-07-10 21:14:25 -0600598config SPL_CRYPTO
Simon Glass11bde1c2016-09-13 07:05:23 -0600599 bool "Support crypto drivers"
Simon Glass11bde1c2016-09-13 07:05:23 -0600600 help
601 Enable crypto drivers in SPL. These drivers can be used to
602 accelerate secure boot processing in secure applications. Enable
603 this option to build the drivers in drivers/crypto as part of an
604 SPL build.
605
Vignesh Raghavendra74326a32019-11-15 17:00:41 +0530606config SPL_DMA
Simon Glass11bde1c2016-09-13 07:05:23 -0600607 bool "Support DMA drivers"
Simon Glass11bde1c2016-09-13 07:05:23 -0600608 help
609 Enable DMA (direct-memory-access) drivers in SPL. These drivers
610 can be used to handle memory-to-peripheral data transfer without
611 the CPU moving the data. Enable this option to build the drivers
612 in drivers/dma as part of an SPL build.
613
Simon Glass9ca00682021-07-10 21:14:31 -0600614config SPL_DRIVERS_MISC
Simon Glass11bde1c2016-09-13 07:05:23 -0600615 bool "Support misc drivers"
Simon Glass11bde1c2016-09-13 07:05:23 -0600616 help
617 Enable miscellaneous drivers in SPL. These drivers perform various
618 tasks that don't fall nicely into other categories, Enable this
619 option to build the drivers in drivers/misc as part of an SPL
620 build, for those that support building in SPL (not all drivers do).
621
622config SPL_ENV_SUPPORT
623 bool "Support an environment"
Simon Glass11bde1c2016-09-13 07:05:23 -0600624 help
625 Enable environment support in SPL. The U-Boot environment provides
626 a number of settings (essentially name/value pairs) which can
627 control many aspects of U-Boot's operation. Normally this is not
628 needed in SPL as it has a much simpler task with less
629 configuration. But some boards use this to support 'Falcon' boot
630 on EXT2 and FAT, where SPL boots directly into Linux without
Simon Glass00caae62017-08-03 12:22:12 -0600631 starting U-Boot first. Enabling this option will make env_get()
Simon Glass382bee52017-08-03 12:22:09 -0600632 and env_set() available in SPL.
Simon Glass11bde1c2016-09-13 07:05:23 -0600633
B, Ravid2d9bdf2016-09-28 14:46:18 +0530634config SPL_SAVEENV
635 bool "Support save environment"
Tom Rini226498b2017-05-22 19:21:57 +0000636 depends on SPL_ENV_SUPPORT
Jean-Jacques Hiblotd6400c32018-01-04 15:23:32 +0100637 select SPL_MMC_WRITE if ENV_IS_IN_MMC
B, Ravid2d9bdf2016-09-28 14:46:18 +0530638 help
639 Enable save environment support in SPL after setenv. By default
640 the saveenv option is not provided in SPL, but some boards need
641 this support in 'Falcon' boot, where SPL need to boot from
642 different images based on environment variable set by OS. For
643 example OS may set "reboot_image" environment variable to
644 "recovery" inorder to boot recovery image by SPL. The SPL read
645 "reboot_image" and act accordingly and change the reboot_image
Shyam Saini919d25c2018-06-07 19:47:19 +0530646 to default mode using setenv and save the environment.
B, Ravid2d9bdf2016-09-28 14:46:18 +0530647
Simon Glassf2d7a362021-07-10 21:14:26 -0600648config SPL_ETH
Simon Glass11bde1c2016-09-13 07:05:23 -0600649 bool "Support Ethernet"
650 depends on SPL_ENV_SUPPORT
Simon Glass9f664922021-08-08 12:20:31 -0600651 depends on SPL_NET
Simon Glass11bde1c2016-09-13 07:05:23 -0600652 help
653 Enable access to the network subsystem and associated Ethernet
654 drivers in SPL. This permits SPL to load U-Boot over an Ethernet
655 link rather than from an on-board peripheral. Environment support
656 is required since the network stack uses a number of environment
Simon Glass5ed16a92021-08-08 12:20:30 -0600657 variables. See also SPL_NET.
Simon Glass11bde1c2016-09-13 07:05:23 -0600658
Tien Fong Cheef4b40922019-01-23 14:20:05 +0800659config SPL_FS_EXT4
Simon Glass11bde1c2016-09-13 07:05:23 -0600660 bool "Support EXT filesystems"
Simon Glass11bde1c2016-09-13 07:05:23 -0600661 help
662 Enable support for EXT2/3/4 filesystems with SPL. This permits
663 U-Boot (or Linux in Falcon mode) to be loaded from an EXT
664 filesystem from within SPL. Support for the underlying block
665 device (e.g. MMC or USB) must be enabled separately.
666
Joao Marcos Costac5100612020-07-30 15:33:47 +0200667config SPL_FS_SQUASHFS
668 bool "Support SquashFS filesystems"
669 select FS_SQUASHFS
670 help
671 Enable support for SquashFS filesystems with SPL. This permits
672 U-Boot (or Linux in Falcon mode) to be loaded from a SquashFS
673 filesystem from within SPL. Support for the underlying block
674 device (e.g. MMC or USB) must be enabled separately.
675
Tien Fong Chee0c3a9ed2019-01-23 14:20:03 +0800676config SPL_FS_FAT
Simon Glass11bde1c2016-09-13 07:05:23 -0600677 bool "Support FAT filesystems"
Sekhar Norieedfb892017-06-02 17:53:59 +0530678 select FS_FAT
Simon Glass11bde1c2016-09-13 07:05:23 -0600679 help
680 Enable support for FAT and VFAT filesystems with SPL. This
681 permits U-Boot (or Linux in Falcon mode) to be loaded from a FAT
682 filesystem from within SPL. Support for the underlying block
683 device (e.g. MMC or USB) must be enabled separately.
684
Tom Rini4a11e342022-05-13 17:12:35 -0400685config SPL_FS_LOAD_PAYLOAD_NAME
686 string "File to load for U-Boot from the filesystem"
687 depends on SPL_FS_EXT4 || SPL_FS_FAT || SPL_FS_SQUASHFS
688 default "tispl.bin" if SYS_K3_SPL_ATF
689 default "u-boot.itb" if SPL_LOAD_FIT
690 default "u-boot.img"
691 help
692 Filename to read to load U-Boot when reading from filesystem.
693
694config SPL_FS_LOAD_KERNEL_NAME
695 string "File to load for the OS kernel from the filesystem"
696 depends on (SPL_FS_EXT4 || SPL_FS_FAT || SPL_FS_SQUASHFS) && SPL_OS_BOOT
697 default "uImage"
698 help
699 Filename to read to load for the OS kernel when reading from the
700 filesystem.
701
702config SPL_FS_LOAD_ARGS_NAME
703 string "File to load for the OS kernel argument parameters from the filesystem"
704 depends on (SPL_FS_EXT4 || SPL_FS_FAT || SPL_FS_SQUASHFS) && SPL_OS_BOOT
705 default "args"
706 help
707 Filename to read to load for the OS kernel argument parameters from
708 the filesystem.
709
Tien Fong Cheed8c3ea92019-01-23 14:20:04 +0800710config SPL_FAT_WRITE
711 bool "Support write for FAT filesystems"
712 help
713 Enable write support for FAT and VFAT filesystems with SPL.
714 Support for the underlying block device (e.g. MMC or USB) must be
715 enabled separately.
716
Michal Simek29bd8ad2020-09-09 14:41:56 +0200717config SPL_FPGA
Simon Glass11bde1c2016-09-13 07:05:23 -0600718 bool "Support FPGAs"
Simon Glass11bde1c2016-09-13 07:05:23 -0600719 help
720 Enable support for FPGAs in SPL. Field-programmable Gate Arrays
721 provide software-configurable hardware which is typically used to
722 implement peripherals (such as UARTs, LCD displays, MMC) or
723 accelerate custom processing functions, such as image processing
724 or machine learning. Sometimes it is useful to program the FPGA
725 as early as possible during boot, and this option can enable that
726 within SPL.
727
Simon Glass83061db2021-07-10 21:14:30 -0600728config SPL_GPIO
Simon Glass2d424eb2018-11-15 18:43:55 -0700729 bool "Support GPIO in SPL"
Simon Glass11bde1c2016-09-13 07:05:23 -0600730 help
731 Enable support for GPIOs (General-purpose Input/Output) in SPL.
732 GPIOs allow U-Boot to read the state of an input line (high or
733 low) and set the state of an output line. This can be used to
734 drive LEDs, control power to various system parts and read user
735 input. GPIOs can be useful in SPL to enable a 'sign-of-life' LED,
736 for example. Enable this option to build the drivers in
737 drivers/gpio as part of an SPL build.
738
Simon Glass975e7cf2021-07-10 21:14:36 -0600739config SPL_I2C
Simon Glass11bde1c2016-09-13 07:05:23 -0600740 bool "Support I2C"
Simon Glass11bde1c2016-09-13 07:05:23 -0600741 help
742 Enable support for the I2C (Inter-Integrated Circuit) bus in SPL.
743 I2C works with a clock and data line which can be driven by a
744 one or more masters or slaves. It is a fairly complex bus but is
745 widely used as it only needs two lines for communication. Speeds of
746 400kbps are typical but up to 3.4Mbps is supported by some
747 hardware. I2C can be useful in SPL to configure power management
748 ICs (PMICs) before raising the CPU clock speed, for example.
749 Enable this option to build the drivers in drivers/i2c as part of
750 an SPL build.
751
752config SPL_LIBCOMMON_SUPPORT
753 bool "Support common libraries"
Simon Glass11bde1c2016-09-13 07:05:23 -0600754 help
755 Enable support for common U-Boot libraries within SPL. These
756 libraries include common code to deal with U-Boot images,
757 environment and USB, for example. This option is enabled on many
758 boards. Enable this option to build the code in common/ as part of
759 an SPL build.
760
761config SPL_LIBDISK_SUPPORT
Simon Goldschmidt00416702018-08-16 09:44:55 +0200762 bool "Support disk partitions"
Tom Rini91ff6862018-12-05 08:23:38 -0500763 select PARTITIONS
Simon Glass11bde1c2016-09-13 07:05:23 -0600764 help
765 Enable support for disk partitions within SPL. 'Disk' is something
766 of a misnomer as it includes non-spinning media such as flash (as
767 used in MMC and USB sticks). Partitions provide a way for a disk
768 to be split up into separate regions, with a partition table placed
769 at the start or end which describes the location and size of each
770 'partition'. These partitions are typically uses as individual block
771 devices, typically with an EXT2 or FAT filesystem in each. This
772 option enables whatever partition support has been enabled in
773 U-Boot to also be used in SPL. It brings in the code in disk/.
774
775config SPL_LIBGENERIC_SUPPORT
776 bool "Support generic libraries"
Simon Glass11bde1c2016-09-13 07:05:23 -0600777 help
778 Enable support for generic U-Boot libraries within SPL. These
779 libraries include generic code to deal with device tree, hashing,
780 printf(), compression and the like. This option is enabled on many
781 boards. Enable this option to build the code in lib/ as part of an
782 SPL build.
783
Lokesh Vutla88027412018-08-27 15:57:49 +0530784config SPL_DM_MAILBOX
785 bool "Support Mailbox"
Tom Rini4151f4f2022-05-31 10:24:55 -0400786 depends on SPL_DM
Lokesh Vutla88027412018-08-27 15:57:49 +0530787 help
788 Enable support for Mailbox within SPL. This enable the inter
789 processor communication protocols tobe used within SPL. Enable
790 this option to build the drivers in drivers/mailbox as part of
791 SPL build.
792
Simon Glass103c5f12021-08-08 12:20:09 -0600793config SPL_MMC
Simon Glass11bde1c2016-09-13 07:05:23 -0600794 bool "Support MMC"
Tom Rini226498b2017-05-22 19:21:57 +0000795 depends on MMC
Simon Glass11bde1c2016-09-13 07:05:23 -0600796 help
797 Enable support for MMC (Multimedia Card) within SPL. This enables
798 the MMC protocol implementation and allows any enabled drivers to
799 be used within SPL. MMC can be used with or without disk partition
800 support depending on the application (SPL_LIBDISK_SUPPORT). Enable
801 this option to build the drivers in drivers/mmc as part of an SPL
802 build.
803
Adam Fordacc415a2020-07-03 10:17:30 -0500804config SYS_MMCSD_FS_BOOT_PARTITION
805 int "MMC Boot Partition"
806 default 1
807 help
808 Partition on the MMC to load U-Boot from when the MMC is being
Jérôme Carretero5fa973e2022-03-15 16:34:51 -0400809 used in fs mode.
810 Use -1 as a special value to use the first bootable partition.
Adam Fordacc415a2020-07-03 10:17:30 -0500811
Ezequiel Garciabf7c01d2019-05-25 19:25:21 -0300812config SPL_MMC_TINY
813 bool "Tiny MMC framework in SPL"
Simon Glass103c5f12021-08-08 12:20:09 -0600814 depends on SPL_MMC
Ezequiel Garciabf7c01d2019-05-25 19:25:21 -0300815 help
816 Enable MMC framework tinification support. This option is useful if
817 if your SPL is extremely size constrained. Heed the warning, enable
818 this option if and only if you know exactly what you are doing, if
819 you are reading this help text, you most likely have no idea :-)
820
821 The MMC framework is reduced to bare minimum to be useful. No malloc
822 support is needed for the MMC framework operation with this option
823 enabled. The framework supports exactly one MMC device and exactly
824 one MMC driver. The MMC driver can be adjusted to avoid any malloc
825 operations too, which can remove the need for malloc support in SPL
826 and thus further reduce footprint.
827
Jean-Jacques Hiblotd6400c32018-01-04 15:23:32 +0100828config SPL_MMC_WRITE
829 bool "MMC/SD/SDIO card support for write operations in SPL"
Simon Glass103c5f12021-08-08 12:20:09 -0600830 depends on SPL_MMC
Jean-Jacques Hiblotd6400c32018-01-04 15:23:32 +0100831 help
832 Enable write access to MMC and SD Cards in SPL
833
834
Simon Glass6f004ad2021-08-08 12:20:16 -0600835config SPL_MPC8XXX_INIT_DDR
Simon Glass11bde1c2016-09-13 07:05:23 -0600836 bool "Support MPC8XXX DDR init"
Simon Glass11bde1c2016-09-13 07:05:23 -0600837 help
838 Enable support for DDR-SDRAM (double-data-rate synchronous dynamic
839 random-access memory) on the MPC8XXX family within SPL. This
840 allows DRAM to be set up before loading U-Boot into that DRAM,
841 where it can run.
842
843config SPL_MTD_SUPPORT
844 bool "Support MTD drivers"
Simon Glass11bde1c2016-09-13 07:05:23 -0600845 help
846 Enable support for MTD (Memory Technology Device) within SPL. MTD
847 provides a block interface over raw NAND and can also be used with
848 SPI flash. This allows SPL to load U-Boot from supported MTD
849 devices. See SPL_NAND_SUPPORT and SPL_ONENAND_SUPPORT for how
850 to enable specific MTD drivers.
851
Simon Glass89ddb0b2021-07-10 21:14:27 -0600852config SPL_MUSB_NEW
Simon Glass11bde1c2016-09-13 07:05:23 -0600853 bool "Support new Mentor Graphics USB"
Simon Glass11bde1c2016-09-13 07:05:23 -0600854 help
855 Enable support for Mentor Graphics USB in SPL. This is a new
856 driver used by some boards. Enable this option to build
857 the drivers in drivers/usb/musb-new as part of an SPL build. The
858 old drivers are in drivers/usb/musb.
859
860config SPL_NAND_SUPPORT
861 bool "Support NAND flash"
Simon Glass11bde1c2016-09-13 07:05:23 -0600862 help
863 Enable support for NAND (Negative AND) flash in SPL. NAND flash
864 can be used to allow SPL to load U-Boot from supported devices.
Miquel Raynala430fa02018-08-16 17:30:07 +0200865 This enables the drivers in drivers/mtd/nand/raw as part of an SPL
Simon Glass11bde1c2016-09-13 07:05:23 -0600866 build.
867
Tom Rinibab1b352022-05-13 12:46:23 -0400868config SPL_NAND_RAW_ONLY
869 bool "Support to boot only raw u-boot.bin images"
870 depends on SPL_NAND_SUPPORT
871 help
872 Use this only if you need to save space.
873
Adam Ford0c4a6342020-07-03 08:09:44 -0500874config SPL_NAND_DRIVERS
875 bool "Use standard NAND driver"
876 help
877 SPL uses normal NAND drivers, not minimal drivers.
878
879config SPL_NAND_ECC
Tom Rinibab1b352022-05-13 12:46:23 -0400880 bool "Include standard ECC in SPL"
881
882config SPL_NAND_SOFTECC
883 bool "Use software ECC in SPL"
884 depends on SPL_NAND_ECC
Adam Ford0c4a6342020-07-03 08:09:44 -0500885
886config SPL_NAND_SIMPLE
887 bool "Support simple NAND drivers in SPL"
888 help
889 Support for NAND boot using simple NAND drivers that
890 expose the cmd_ctrl() interface.
891
Adam Ford38791062020-07-03 08:09:45 -0500892config SPL_NAND_BASE
Weijie Gao4c4bf042022-05-20 11:23:53 +0800893 depends on SPL_NAND_SUPPORT
Adam Ford38791062020-07-03 08:09:45 -0500894 bool "Use Base NAND Driver"
Michal Simekce869b52021-05-20 13:08:44 +0200895 help
896 Include nand_base.c in the SPL.
Adam Ford38791062020-07-03 08:09:45 -0500897
898config SPL_NAND_IDENT
899 depends on SPL_NAND_BASE
900 bool "Use chip ID to identify NAND flash"
901 help
902 SPL uses the chip ID list to identify the NAND flash.
903
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200904config SPL_UBI
905 bool "Support UBI"
906 help
907 Enable support for loading payloads from UBI. See
908 README.ubispl for more info.
909
Tom Rini4151f4f2022-05-31 10:24:55 -0400910menu "UBI configuration for SPL"
911 depends on SPL_UBI
Lukasz Majewskif18845c2019-09-09 12:06:46 +0200912
Hamish Guthrie6ea31cc2019-05-15 15:15:59 +0200913config SPL_UBI_LOAD_BY_VOLNAME
914 bool "Support loading volumes by name"
915 help
916 This enables support for loading UBI volumes by name. When this
917 is set, CONFIG_SPL_UBI_LOAD_MONITOR_VOLNAME can be used to
918 configure the volume name from which to load U-Boot.
919
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200920config SPL_UBI_MAX_VOL_LEBS
921 int "Maximum number of LEBs per volume"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200922 help
923 The maximum number of logical eraseblocks which a static volume
924 to load can contain. Used for sizing the scan data structure.
925
926config SPL_UBI_MAX_PEB_SIZE
927 int "Maximum PEB size"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200928 help
929 The maximum physical erase block size.
930
931config SPL_UBI_MAX_PEBS
932 int "Maximum number of PEBs"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200933 help
934 The maximum physical erase block size. If not overridden by
935 board code, this value will be used as the actual number of PEBs.
936
937config SPL_UBI_PEB_OFFSET
938 int "Offset to first UBI PEB"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200939 help
940 The offset in number of PEBs from the start of flash to the first
941 PEB part of the UBI image.
942
943config SPL_UBI_VID_OFFSET
944 int "Offset to VID header"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200945
946config SPL_UBI_LEB_START
947 int "Offset to LEB in PEB"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200948 help
949 The offset in bytes to the LEB within a PEB.
950
951config SPL_UBI_INFO_ADDR
952 hex "Address to place UBI scan info"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200953 help
954 Address for ubispl to place the scan info. Read README.ubispl to
955 determine the required size
956
957config SPL_UBI_VOL_IDS
958 int "Maximum volume id"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200959 help
960 The maximum volume id which can be loaded. Used for sizing the
961 scan data structure.
962
963config SPL_UBI_LOAD_MONITOR_ID
964 int "id of U-Boot volume"
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200965 help
966 The UBI volume id from which to load U-Boot
967
Hamish Guthrie6ea31cc2019-05-15 15:15:59 +0200968config SPL_UBI_LOAD_MONITOR_VOLNAME
969 string "volume name of U-Boot volume"
970 depends on SPL_UBI_LOAD_BY_VOLNAME
971 help
972 The UBI volume name from which to load U-Boot
973
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200974config SPL_UBI_LOAD_KERNEL_ID
975 int "id of kernel volume"
Tom Rini4151f4f2022-05-31 10:24:55 -0400976 depends on SPL_OS_BOOT
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200977 help
978 The UBI volume id from which to load the kernel
979
980config SPL_UBI_LOAD_ARGS_ID
981 int "id of kernel args volume"
Tom Rini4151f4f2022-05-31 10:24:55 -0400982 depends on SPL_OS_BOOT
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200983 help
984 The UBI volume id from which to load the device tree
985
Markus Klotzbuechera2257d32019-05-15 15:16:00 +0200986config UBI_SPL_SILENCE_MSG
987 bool "silence UBI SPL messages"
Markus Klotzbuechera2257d32019-05-15 15:16:00 +0200988 help
989 Disable messages from UBI SPL. This leaves warnings
990 and errors enabled.
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +0200991
Tom Rini4151f4f2022-05-31 10:24:55 -0400992endmenu
993
994config SPL_DM_SPI
995 bool "Support SPI DM drivers in SPL"
996 depends on SPL_DM
997 help
998 Enable support for SPI DM drivers in SPL.
999
1000config SPL_DM_SPI_FLASH
1001 bool "Support SPI DM FLASH drivers in SPL"
1002 depends on SPL_DM
1003 help
1004 Enable support for SPI DM flash drivers in SPL.
Markus Klotzbuecherc67c3492019-05-15 15:15:57 +02001005
Simon Glass5ed16a92021-08-08 12:20:30 -06001006config SPL_NET
Simon Glass11bde1c2016-09-13 07:05:23 -06001007 bool "Support networking"
Simon Glass11bde1c2016-09-13 07:05:23 -06001008 help
1009 Enable support for network devices (such as Ethernet) in SPL.
1010 This permits SPL to load U-Boot over a network link rather than
1011 from an on-board peripheral. Environment support is required since
1012 the network stack uses a number of environment variables. See also
Simon Glassf2d7a362021-07-10 21:14:26 -06001013 SPL_ETH.
Simon Glass11bde1c2016-09-13 07:05:23 -06001014
Simon Glass11bde1c2016-09-13 07:05:23 -06001015config SPL_NET_VCI_STRING
1016 string "BOOTP Vendor Class Identifier string sent by SPL"
Tom Rini4151f4f2022-05-31 10:24:55 -04001017 depends on SPL_NET
Simon Glass11bde1c2016-09-13 07:05:23 -06001018 help
1019 As defined by RFC 2132 the vendor class identifier field can be
1020 sent by the client to identify the vendor type and configuration
1021 of a client. This is often used in practice to allow for the DHCP
1022 server to specify different files to load depending on if the ROM,
1023 SPL or U-Boot itself makes the request
Simon Glass11bde1c2016-09-13 07:05:23 -06001024
1025config SPL_NO_CPU_SUPPORT
Tom Rini4151f4f2022-05-31 10:24:55 -04001026 def_bool y
1027 depends on (ARCH_MX23 || ARCH_MX28) && !SPL_FRAMEWORK
Simon Glass11bde1c2016-09-13 07:05:23 -06001028 help
1029 This is specific to the ARM926EJ-S CPU. It disables the standard
1030 start.S start-up code, presumably so that a replacement can be
1031 used on that CPU. You should not enable it unless you know what
1032 you are doing.
1033
1034config SPL_NOR_SUPPORT
1035 bool "Support NOR flash"
Simon Glass11bde1c2016-09-13 07:05:23 -06001036 help
1037 Enable support for loading U-Boot from memory-mapped NOR (Negative
1038 OR) flash in SPL. NOR flash is slow to write but fast to read, and
1039 a memory-mapped device makes it very easy to access. Loading from
1040 NOR is typically achieved with just a memcpy().
1041
Vikas Manochac6d9e9d2017-05-28 12:55:11 -07001042config SPL_XIP_SUPPORT
1043 bool "Support XIP"
Vikas Manochac6d9e9d2017-05-28 12:55:11 -07001044 help
1045 Enable support for execute in place of U-Boot or kernel image. There
1046 is no need to copy image from flash to ram if flash supports execute
1047 in place. Its very useful in systems having enough flash but not
1048 enough ram to load the image.
1049
Simon Glass11bde1c2016-09-13 07:05:23 -06001050config SPL_ONENAND_SUPPORT
1051 bool "Support OneNAND flash"
Simon Glass11bde1c2016-09-13 07:05:23 -06001052 help
1053 Enable support for OneNAND (Negative AND) flash in SPL. OneNAND is
1054 a type of NAND flash and therefore can be used to allow SPL to
1055 load U-Boot from supported devices. This enables the drivers in
1056 drivers/mtd/onenand as part of an SPL build.
1057
Heiko Schocherc20ae2f2016-10-06 07:55:15 +02001058config SPL_OS_BOOT
1059 bool "Activate Falcon Mode"
Tom Rini226498b2017-05-22 19:21:57 +00001060 depends on !TI_SECURE_DEVICE
Heiko Schocherc20ae2f2016-10-06 07:55:15 +02001061 help
1062 Enable booting directly to an OS from SPL.
1063 for more info read doc/README.falcon
1064
Tom Rinib4b9a002022-05-27 22:06:52 -04001065config SYS_SPL_ARGS_ADDR
1066 hex "Address in memory to load 'args' file for Falcon Mode to"
1067 depends on SPL_OS_BOOT
1068 default 0x88000000 if ARCH_OMAP2PLUS
1069 help
1070 Address in memory where the 'args' file, typically a device tree
1071 will be loaded in to memory.
1072
Tom Rini5fc1d582022-05-28 16:43:53 -04001073config SYS_NAND_SPL_KERNEL_OFFS
1074 hex "Address in memory to load the OS file for Falcon mode to"
1075 depends on SPL_OS_BOOT && SPL_NAND_SUPPORT
1076
Heiko Schocher29d3bc72016-10-06 07:55:16 +02001077config SYS_OS_BASE
1078 hex "addr, where OS is found"
Tom Rini4151f4f2022-05-31 10:24:55 -04001079 depends on SPL_OS_BOOT && SPL_NOR_SUPPORT
Heiko Schocher29d3bc72016-10-06 07:55:16 +02001080 help
1081 Specify the address, where the OS image is found, which
1082 gets booted.
1083
Alexandru Gagniuc22eb1522021-12-30 10:39:59 -06001084config SPL_FALCON_BOOT_MMCSD
1085 bool "Enable Falcon boot from MMC or SD media"
1086 depends on SPL_OS_BOOT && SPL_MMC
1087 help
1088 Select this if the Falcon mode OS image mode is on MMC or SD media.
1089
1090config SYS_MMCSD_RAW_MODE_KERNEL_SECTOR
1091 hex "Falcon mode: Sector to load kernel uImage from MMC"
1092 depends on SPL_FALCON_BOOT_MMCSD
1093 help
1094 When Falcon mode is used with an MMC or SD media, SPL needs to know
1095 where to look for the kernel uImage. The image is expected to begin
1096 at the raw MMC specified in this config.
1097 Note that the Falcon mode image can also be a FIT, if FIT support is
1098 enabled.
1099
Tom Rini103d1ae2022-05-28 17:21:03 -04001100config SYS_MMCSD_RAW_MODE_ARGS_SECTOR
1101 hex "Falcon mode: Sector to load 'args' from MMC"
1102 depends on SPL_FALCON_BOOT_MMCSD
1103 help
1104 When Falcon mode is used with an MMC or SD media, SPL needs to know
1105 where to look for the OS 'args', typically a device tree. The
1106 contents are expected to begin at the raw MMC specified in this config.
1107 Note that if using a FIT image, this and the next option can be set to
1108 0x0.
1109
1110config SYS_MMCSD_RAW_MODE_ARGS_SECTORS
1111 hex "Falcon mode: Number of sectors to load for 'args' from MMC"
1112 depends on SPL_FALCON_BOOT_MMCSD && SYS_MMCSD_RAW_MODE_ARGS_SECTOR != 0x0
1113
York Sun7550dbe2018-06-14 14:38:48 -07001114config SPL_PAYLOAD
1115 string "SPL payload"
1116 default "tpl/u-boot-with-tpl.bin" if TPL
1117 default "u-boot.bin"
1118 help
Chris Packham2dcfa052019-01-13 22:13:20 +13001119 Payload for SPL boot. For backward compatibility, default to
York Sun7550dbe2018-06-14 14:38:48 -07001120 u-boot.bin, i.e. RAW image without any header. In case of
1121 TPL, tpl/u-boot-with-tpl.bin. For new boards, suggest to
1122 use u-boot.img.
1123
Sekhar Norid50d6812018-12-06 15:40:08 +05301124config SPL_PCI
Simon Glass2446b6b2017-01-16 07:03:30 -07001125 bool "Support PCI drivers"
Simon Glass2446b6b2017-01-16 07:03:30 -07001126 help
1127 Enable support for PCI in SPL. For platforms that need PCI to boot,
1128 or must perform some init using PCI in SPL, this provides the
1129 necessary driver support. This enables the drivers in drivers/pci
1130 as part of an SPL build.
1131
Simon Glass15042e72021-08-08 12:20:10 -06001132config SPL_PCH
Simon Glassbbe41ab2017-01-16 07:03:33 -07001133 bool "Support PCH drivers"
Simon Glassbbe41ab2017-01-16 07:03:33 -07001134 help
1135 Enable support for PCH (Platform Controller Hub) devices in SPL.
1136 These are used to set up GPIOs and the SPI peripheral early in
1137 boot. This enables the drivers in drivers/pch as part of an SPL
1138 build.
1139
Simon Glass11bde1c2016-09-13 07:05:23 -06001140config SPL_POST_MEM_SUPPORT
1141 bool "Support POST drivers"
Simon Glass11bde1c2016-09-13 07:05:23 -06001142 help
1143 Enable support for POST (Power-on Self Test) in SPL. POST is a
1144 procedure that checks that the hardware (CPU or board) appears to
1145 be functionally correctly. It is a sanity check that can be
1146 performed before booting. This enables the drivers in post/drivers
1147 as part of an SPL build.
1148
Ley Foon Tanbfc6bae2018-06-14 18:45:19 +08001149config SPL_DM_RESET
Patrick Delaunay0e373c02018-03-12 10:46:05 +01001150 bool "Support reset drivers"
Tom Rini4151f4f2022-05-31 10:24:55 -04001151 depends on SPL_DM
Patrick Delaunay0e373c02018-03-12 10:46:05 +01001152 help
1153 Enable support for reset control in SPL.
1154 That can be useful in SPL to handle IP reset in driver, as in U-Boot,
1155 by using the generic reset API provided by driver model.
1156 This enables the drivers in drivers/reset as part of an SPL build.
1157
Simon Glass933b2f02021-07-10 21:14:24 -06001158config SPL_POWER
Simon Glass11bde1c2016-09-13 07:05:23 -06001159 bool "Support power drivers"
Simon Glass11bde1c2016-09-13 07:05:23 -06001160 help
1161 Enable support for power control in SPL. This includes support
1162 for PMICs (Power-management Integrated Circuits) and some of the
1163 features provided by PMICs. In particular, voltage regulators can
1164 be used to enable/disable power and vary its voltage. That can be
1165 useful in SPL to turn on boot peripherals and adjust CPU voltage
1166 so that the clock speed can be increased. This enables the drivers
1167 in drivers/power, drivers/power/pmic and drivers/power/regulator
1168 as part of an SPL build.
1169
Peng Fane13278c2018-07-27 10:20:37 +08001170config SPL_POWER_DOMAIN
1171 bool "Support power domain drivers"
Simon Glassa4faf1f2021-08-08 12:20:29 -06001172 select SPL_POWER
Peng Fane13278c2018-07-27 10:20:37 +08001173 help
1174 Enable support for power domain control in SPL. Many SoCs allow
1175 power to be applied to or removed from portions of the SoC (power
1176 domains). This may be used to save power. This API provides the
1177 means to control such power management hardware. This enables
1178 the drivers in drivers/power/domain as part of a SPL build.
1179
Stefan Agner22802f42016-12-23 07:51:53 +01001180config SPL_RAM_SUPPORT
1181 bool "Support booting from RAM"
Trevor Woerner18138ab2020-05-06 08:02:41 -04001182 default y if MICROBLAZE || ARCH_SOCFPGA || ARCH_TEGRA || ARCH_ZYNQ
Stefan Agner22802f42016-12-23 07:51:53 +01001183 help
1184 Enable booting of an image in RAM. The image can be preloaded or
1185 it can be loaded by SPL directly into RAM (e.g. using USB).
1186
Stefan Agnerf417d402016-12-23 07:51:52 +01001187config SPL_RAM_DEVICE
1188 bool "Support booting from preloaded image in RAM"
Stefan Agner22802f42016-12-23 07:51:53 +01001189 depends on SPL_RAM_SUPPORT
Trevor Woerner18138ab2020-05-06 08:02:41 -04001190 default y if MICROBLAZE || ARCH_SOCFPGA || ARCH_TEGRA || ARCH_ZYNQ
Stefan Agnerf417d402016-12-23 07:51:52 +01001191 help
1192 Enable booting of an image already loaded in RAM. The image has to
1193 be already in memory when SPL takes over, e.g. loaded by the boot
1194 ROM.
1195
Lokesh Vutla08c45312018-08-27 15:57:53 +05301196config SPL_REMOTEPROC
1197 bool "Support REMOTEPROCS"
1198 help
1199 Enable support for REMOTEPROCs in SPL. This permits to load
1200 a remote processor firmware in SPL.
1201
Simon Glass73c6ff62021-08-08 12:20:11 -06001202config SPL_RTC
Simon Glass30bf8a02017-01-16 07:03:31 -07001203 bool "Support RTC drivers"
Simon Glass30bf8a02017-01-16 07:03:31 -07001204 help
1205 Enable RTC (Real-time Clock) support in SPL. This includes support
1206 for reading and setting the time. Some RTC devices also have some
1207 non-volatile (battery-backed) memory which is accessible if
1208 needed. This enables the drivers in drivers/rtc as part of an SPL
1209 build.
1210
Simon Glassf7560372021-08-08 12:20:17 -06001211config SPL_SATA
Simon Glass11bde1c2016-09-13 07:05:23 -06001212 bool "Support loading from SATA"
Simon Glass11bde1c2016-09-13 07:05:23 -06001213 help
1214 Enable support for SATA (Serial AT attachment) in SPL. This allows
1215 use of SATA devices such as hard drives and flash drivers for
1216 loading U-Boot. SATA is used in higher-end embedded systems and
1217 can provide higher performance than MMC , at somewhat higher
1218 expense and power consumption. This enables loading from SATA
1219 using a configured device.
1220
Baruch Siach60ca9692019-07-14 17:54:21 +03001221config SPL_SATA_RAW_U_BOOT_USE_SECTOR
1222 bool "SATA raw mode: by sector"
Simon Glassf7560372021-08-08 12:20:17 -06001223 depends on SPL_SATA
Pali Rohár2226ca12021-07-23 11:14:29 +02001224 default y if ARCH_MVEBU
Baruch Siach60ca9692019-07-14 17:54:21 +03001225 help
1226 Use sector number for specifying U-Boot location on SATA disk in
1227 raw mode.
1228
1229config SPL_SATA_RAW_U_BOOT_SECTOR
1230 hex "Sector on the SATA disk to load U-Boot from"
1231 depends on SPL_SATA_RAW_U_BOOT_USE_SECTOR
Pali Rohár2226ca12021-07-23 11:14:29 +02001232 default 0x1 if ARCH_MVEBU
Baruch Siach60ca9692019-07-14 17:54:21 +03001233 help
1234 Sector on the SATA disk to load U-Boot from, when the SATA disk is being
1235 used in raw mode. Units: SATA disk sectors (1 sector = 512 bytes).
1236
Simon Glass2a736062021-08-08 12:20:12 -06001237config SPL_SERIAL
Simon Glass11bde1c2016-09-13 07:05:23 -06001238 bool "Support serial"
Alex Kiernan14ad44a2018-04-19 04:32:54 +00001239 select SPL_PRINTF
1240 select SPL_STRTO
Simon Glass11bde1c2016-09-13 07:05:23 -06001241 help
1242 Enable support for serial in SPL. This allows use of a serial UART
1243 for displaying messages while SPL is running. It also brings in
1244 printf() and panic() functions. This should normally be enabled
1245 unless there are space reasons not to. Even then, consider
Simon Glass27084c02019-09-25 08:56:27 -06001246 enabling SPL_USE_TINY_PRINTF which is a small printf() version.
Simon Glass11bde1c2016-09-13 07:05:23 -06001247
Simon Glassea2ca7e2021-08-08 12:20:14 -06001248config SPL_SPI
Simon Goldschmidtd024e992019-10-25 16:22:09 +02001249 bool "Support SPI drivers"
1250 help
1251 Enable support for using SPI in SPL. This is used for connecting
1252 to SPI flash for loading U-Boot. See SPL_SPI_FLASH_SUPPORT for
1253 more details on that. The SPI driver provides the transport for
1254 data between the SPI flash and the CPU. This option can be used to
1255 enable SPI drivers that are needed for other purposes also, such
1256 as a SPI PMIC.
1257
Simon Glass11bde1c2016-09-13 07:05:23 -06001258config SPL_SPI_FLASH_SUPPORT
1259 bool "Support SPI flash drivers"
Simon Glassea2ca7e2021-08-08 12:20:14 -06001260 depends on SPL_SPI
Simon Glass11bde1c2016-09-13 07:05:23 -06001261 help
1262 Enable support for using SPI flash in SPL, and loading U-Boot from
1263 SPI flash. SPI flash (Serial Peripheral Bus flash) is named after
1264 the SPI bus that is used to connect it to a system. It is a simple
1265 but fast bidirectional 4-wire bus (clock, chip select and two data
1266 lines). This enables the drivers in drivers/mtd/spi as part of an
Simon Glassea2ca7e2021-08-08 12:20:14 -06001267 SPL build. This normally requires SPL_SPI.
Simon Glass11bde1c2016-09-13 07:05:23 -06001268
Vignesh R0c6f1872019-02-05 11:29:20 +05301269if SPL_SPI_FLASH_SUPPORT
1270
Vignesh R778572d2019-02-05 11:29:25 +05301271config SPL_SPI_FLASH_TINY
1272 bool "Enable low footprint SPL SPI Flash support"
1273 depends on !SPI_FLASH_BAR
Vignesh R72875972019-02-05 11:29:26 +05301274 default y if SPI_FLASH
Vignesh R778572d2019-02-05 11:29:25 +05301275 help
1276 Enable lightweight SPL SPI Flash support that supports just reading
1277 data/images from flash. No support to write/erase flash. Enable
1278 this if you have SPL size limitations and don't need full
1279 fledged SPI flash support.
1280
Vignesh R0c6f1872019-02-05 11:29:20 +05301281config SPL_SPI_FLASH_SFDP_SUPPORT
1282 bool "SFDP table parsing support for SPI NOR flashes"
Vignesh R778572d2019-02-05 11:29:25 +05301283 depends on !SPI_FLASH_BAR && !SPL_SPI_FLASH_TINY
Vignesh R0c6f1872019-02-05 11:29:20 +05301284 help
1285 Enable support for parsing and auto discovery of parameters for
1286 SPI NOR flashes using Serial Flash Discoverable Parameters (SFDP)
1287 tables as per JESD216 standard in SPL.
1288
Lukasz Majewski56c40462020-06-04 23:11:53 +08001289config SPL_SPI_FLASH_MTD
1290 bool "Support for SPI flash MTD drivers in SPL"
1291 help
1292 Enable support for SPI flash MTD drivers in SPL.
1293
Marek Vasut55500432018-04-07 16:05:27 +02001294config SPL_SPI_LOAD
1295 bool "Support loading from SPI flash"
Marek Vasut55500432018-04-07 16:05:27 +02001296 help
1297 Enable support for loading next stage, U-Boot or otherwise, from
1298 SPI NOR in U-Boot SPL.
1299
Vignesh R0c6f1872019-02-05 11:29:20 +05301300endif # SPL_SPI_FLASH_SUPPORT
1301
Hannes Schmelzer1ee774d2019-08-22 15:41:46 +02001302config SYS_SPI_U_BOOT_OFFS
1303 hex "address of u-boot payload in SPI flash"
Andre Przywara671d64f2020-01-06 01:29:10 +00001304 default 0x8000 if ARCH_SUNXI
Hannes Schmelzer1ee774d2019-08-22 15:41:46 +02001305 default 0x0
1306 depends on SPL_SPI_LOAD || SPL_SPI_SUNXI
1307 help
1308 Address within SPI-Flash from where the u-boot payload is fetched
1309 from.
1310
Faiz Abbas8502f9f2017-11-14 16:12:31 +05301311config SPL_THERMAL
1312 bool "Driver support for thermal devices"
1313 help
1314 Enable support for temperature-sensing devices. Some SoCs have on-chip
1315 temperature sensors to permit warnings, speed throttling or even
1316 automatic power-off when the temperature gets too high or low. Other
1317 devices may be discrete but connected on a suitable bus.
1318
Simon Glass333e4a62021-07-10 21:14:29 -06001319config SPL_USB_HOST
Simon Glass11bde1c2016-09-13 07:05:23 -06001320 bool "Support USB host drivers"
Simon Glass11bde1c2016-09-13 07:05:23 -06001321 help
1322 Enable access to USB (Universal Serial Bus) host devices so that
1323 SPL can load U-Boot from a connected USB peripheral, such as a USB
1324 flash stick. While USB takes a little longer to start up than most
1325 buses, it is very flexible since many different types of storage
1326 device can be attached. This option enables the drivers in
1327 drivers/usb/host as part of an SPL build.
1328
Abel Vesa79536012019-02-01 16:40:07 +00001329config SPL_USB_STORAGE
Simon Glass11bde1c2016-09-13 07:05:23 -06001330 bool "Support loading from USB"
Simon Glass333e4a62021-07-10 21:14:29 -06001331 depends on SPL_USB_HOST && !(BLK && !DM_USB)
Simon Glass11bde1c2016-09-13 07:05:23 -06001332 help
1333 Enable support for USB devices in SPL. This allows use of USB
1334 devices such as hard drives and flash drivers for loading U-Boot.
1335 The actual drivers are enabled separately using the normal U-Boot
1336 config options. This enables loading from USB using a configured
1337 device.
1338
Tom Rini5dbf3202022-06-12 20:02:05 -04001339config SYS_USB_FAT_BOOT_PARTITION
1340 int "Partition on USB to use to load U-Boot from"
1341 depends on SPL_USB_STORAGE
1342 default 1
1343 help
1344 Partition on the USB storage device to load U-Boot from
1345
Jean-Jacques Hiblotf811e972019-01-10 15:44:13 +01001346config SPL_USB_GADGET
Stefan Agnere94793c2016-11-21 10:58:53 -08001347 bool "Suppport USB Gadget drivers"
Stefan Agnere94793c2016-11-21 10:58:53 -08001348 help
1349 Enable USB Gadget API which allows to enable USB device functions
1350 in SPL.
1351
Jean-Jacques Hiblotf811e972019-01-10 15:44:13 +01001352if SPL_USB_GADGET
Stefan Agnere94793c2016-11-21 10:58:53 -08001353
Faiz Abbasb432b1e2018-02-16 21:17:44 +05301354config SPL_USB_ETHER
Stefan Agnere94793c2016-11-21 10:58:53 -08001355 bool "Support USB Ethernet drivers"
Simon Glass9f664922021-08-08 12:20:31 -06001356 depends on SPL_NET
Stefan Agnere94793c2016-11-21 10:58:53 -08001357 help
1358 Enable access to the USB network subsystem and associated
1359 drivers in SPL. This permits SPL to load U-Boot over a
1360 USB-connected Ethernet link (such as a USB Ethernet dongle) rather
1361 than from an onboard peripheral. Environment support is required
1362 since the network stack uses a number of environment variables.
Simon Glass5ed16a92021-08-08 12:20:30 -06001363 See also SPL_NET and SPL_ETH.
Stefan Agnere94793c2016-11-21 10:58:53 -08001364
Andrew F. Davis6536ca42019-01-17 13:43:02 -06001365config SPL_DFU
Fabio Estevamc3c19c22018-08-31 10:02:28 -03001366 bool "Support DFU (Device Firmware Upgrade)"
Alexandru Gagniuc07212092021-09-02 19:54:19 -05001367 select SPL_HASH
B, Ravi66928af2017-05-04 15:45:29 +05301368 select SPL_DFU_NO_RESET
B, Ravi1b19cbd2017-05-04 15:45:28 +05301369 depends on SPL_RAM_SUPPORT
Stefan Agner59917032016-11-21 10:58:52 -08001370 help
Fabio Estevamc3c19c22018-08-31 10:02:28 -03001371 This feature enables the DFU (Device Firmware Upgrade) in SPL with
Stefan Agner59917032016-11-21 10:58:52 -08001372 RAM memory device support. The ROM code will load and execute
1373 the SPL built with dfu. The user can load binaries (u-boot/kernel) to
1374 selected device partition from host-pc using dfu-utils.
1375 This feature is useful to flash the binaries to factory or bare-metal
1376 boards using USB interface.
1377
1378choice
1379 bool "DFU device selection"
Andrew F. Davis6536ca42019-01-17 13:43:02 -06001380 depends on SPL_DFU
Stefan Agner59917032016-11-21 10:58:52 -08001381
1382config SPL_DFU_RAM
1383 bool "RAM device"
Andrew F. Davis6536ca42019-01-17 13:43:02 -06001384 depends on SPL_DFU && SPL_RAM_SUPPORT
Stefan Agner59917032016-11-21 10:58:52 -08001385 help
1386 select RAM/DDR memory device for loading binary images
1387 (u-boot/kernel) to the selected device partition using
1388 DFU and execute the u-boot/kernel from RAM.
1389
1390endchoice
1391
Stefan Agnera3774c12017-08-16 11:00:54 -07001392config SPL_USB_SDP_SUPPORT
1393 bool "Support SDP (Serial Download Protocol)"
Simon Glass2a736062021-08-08 12:20:12 -06001394 depends on SPL_SERIAL
Stefan Agnera3774c12017-08-16 11:00:54 -07001395 help
1396 Enable Serial Download Protocol (SDP) device support in SPL. This
1397 allows to download images into memory and execute (jump to) them
1398 using the same protocol as implemented by the i.MX family's boot ROM.
Ye Li407e3842020-04-29 10:35:12 +08001399
1400config SPL_SDP_USB_DEV
1401 int "SDP USB controller index"
1402 default 0
1403 depends on SPL_USB_SDP_SUPPORT
1404 help
1405 Some boards have USB controller other than 0. Define this option
1406 so it can be used in compiled environment.
Stefan Agnere94793c2016-11-21 10:58:53 -08001407endif
1408
Simon Glass078111b2021-07-10 21:14:28 -06001409config SPL_WATCHDOG
Simon Glass11bde1c2016-09-13 07:05:23 -06001410 bool "Support watchdog drivers"
Marek Vasut6874cb72019-06-09 03:46:21 +02001411 imply SPL_WDT if !HW_WATCHDOG
Simon Glass11bde1c2016-09-13 07:05:23 -06001412 help
1413 Enable support for watchdog drivers in SPL. A watchdog is
1414 typically a hardware peripheral which can reset the system when it
1415 detects no activity for a while (such as a software crash). This
1416 enables the drivers in drivers/watchdog as part of an SPL build.
1417
1418config SPL_YMODEM_SUPPORT
1419 bool "Support loading using Ymodem"
Simon Glass2a736062021-08-08 12:20:12 -06001420 depends on SPL_SERIAL
Simon Glass11bde1c2016-09-13 07:05:23 -06001421 help
1422 While loading from serial is slow it can be a useful backup when
1423 there is no other option. The Ymodem protocol provides a reliable
1424 means of transmitting U-Boot over a serial line for using in SPL,
1425 with a checksum to ensure correctness.
1426
Philipp Tomsichaa122f62017-09-13 21:29:36 +02001427config SPL_ATF
Kever Yangbcc17262017-05-05 11:47:45 +08001428 bool "Support ARM Trusted Firmware"
Michal Simek975bacc2020-09-03 11:23:39 +02001429 depends on ARM64 && SPL_FIT
Kever Yangbcc17262017-05-05 11:47:45 +08001430 help
Philipp Tomsichd21fb632018-01-02 21:16:43 +01001431 ATF(ARM Trusted Firmware) is a component for ARM AArch64 which
1432 is loaded by SPL (which is considered as BL2 in ATF terminology).
Kever Yangbcc17262017-05-05 11:47:45 +08001433 More detail at: https://github.com/ARM-software/arm-trusted-firmware
1434
Michael Walle7b866822020-11-18 17:45:58 +01001435config SPL_ATF_LOAD_IMAGE_V2
1436 bool "Use the new LOAD_IMAGE_V2 parameter passing"
1437 depends on SPL_ATF
1438 help
1439 Some platforms use the newer LOAD_IMAGE_V2 parameter passing.
1440
1441 If you want to load a bl31 image from the SPL and need the new
1442 method, say Y.
1443
Philipp Tomsichd21fb632018-01-02 21:16:43 +01001444config SPL_ATF_NO_PLATFORM_PARAM
Michal Simekce869b52021-05-20 13:08:44 +02001445 bool "Pass no platform parameter"
Philipp Tomsichd21fb632018-01-02 21:16:43 +01001446 depends on SPL_ATF
1447 help
1448 While we expect to call a pointer to a valid FDT (or NULL)
1449 as the platform parameter to an ATF, some ATF versions are
1450 not U-Boot aware and have an insufficiently robust parameter
1451 validation to gracefully reject a FDT being passed.
1452
1453 If this option is enabled, the spl_atf os-type handler will
1454 always pass NULL for the platform parameter.
1455
1456 If your ATF is affected, say Y.
1457
Alex Kiernan3bf5f132018-03-15 22:11:46 +00001458config SPL_AM33XX_ENABLE_RTC32K_OSC
1459 bool "Enable the RTC32K OSC on AM33xx based platforms"
Tom Rini4151f4f2022-05-31 10:24:55 -04001460 depends on AM33XX
Alex Kiernan3bf5f132018-03-15 22:11:46 +00001461 default y if AM33XX
1462 help
1463 Enable access to the AM33xx RTC and select the external 32kHz clock
1464 source.
1465
Patrick Delaunay51827f92021-09-02 11:56:16 +02001466config SPL_OPTEE_IMAGE
1467 bool "Support OP-TEE Trusted OS image in SPL"
Kever Yang70fe2872018-08-23 17:17:59 +08001468 depends on ARM
1469 help
Patrick Delaunay51827f92021-09-02 11:56:16 +02001470 OP-TEE is an open source Trusted OS which is loaded by SPL.
Kever Yang70fe2872018-08-23 17:17:59 +08001471 More detail at: https://github.com/OP-TEE/optee_os
1472
Lukas Auer5e30e452019-08-21 21:14:44 +02001473config SPL_OPENSBI
1474 bool "Support RISC-V OpenSBI"
1475 depends on RISCV && SPL_RISCV_MMODE && RISCV_SMODE
1476 help
1477 OpenSBI is an open-source implementation of the RISC-V Supervisor Binary
1478 Interface (SBI) specification. U-Boot supports the OpenSBI FW_DYNAMIC
1479 firmware. It is loaded and started by U-Boot SPL.
1480
1481 More details are available at https://github.com/riscv/opensbi and
1482 https://github.com/riscv/riscv-sbi-doc
1483
1484config SPL_OPENSBI_LOAD_ADDR
1485 hex "OpenSBI load address"
1486 depends on SPL_OPENSBI
1487 help
1488 Load address of the OpenSBI binary.
1489
Nikita Shubinaa0eda12022-08-08 13:28:52 +03001490config SPL_OPENSBI_SCRATCH_OPTIONS
1491 hex "Scratch options passed to OpenSBI"
1492 default 0x1
1493 depends on SPL_OPENSBI
1494 help
1495 Options passed to fw_dynamic, for example SBI_SCRATCH_NO_BOOT_PRINTS or
1496 SBI_SCRATCH_DEBUG_PRINTS.
1497
Tom Rinia62b7f02022-05-27 17:13:52 -04001498config SPL_TARGET
1499 string "Addtional build targets for 'make'"
1500 default "spl/u-boot-spl.srec" if RCAR_GEN2
1501 default "spl/u-boot-spl.scif" if RCAR_GEN3
1502 default ""
1503 help
1504 On some platforms we need to have 'make' run additional build target
1505 rules. If required on your platform, enter it here, otherwise leave blank.
1506
Simon Glass747093d2022-04-30 00:56:53 -06001507
Eugen Hristev0be07872019-05-24 09:38:10 +03001508config SPL_AT91_MCK_BYPASS
1509 bool "Use external clock signal as a source of main clock for AT91 platforms"
1510 depends on ARCH_AT91
Eugen Hristev0be07872019-05-24 09:38:10 +03001511 help
1512 Use external 8 to 24 Mhz clock signal as source of main clock instead
1513 of an external crystal oscillator.
1514 This option disables the internal driving on the XOUT pin.
1515 The external source has to provide a stable clock on the XIN pin.
1516 If this option is disabled, the SoC expects a crystal oscillator
1517 that needs driving on both XIN and XOUT lines.
Simon Glass11bde1c2016-09-13 07:05:23 -06001518endmenu
Tom Riniab0c5f12022-05-30 17:11:23 -04001519
1520config TPL
1521 depends on SUPPORT_TPL
1522 bool "Enable TPL"
1523 help
1524 If you want to build TPL as well as the normal image and SPL, say Y.
1525
1526source "common/spl/Kconfig.tpl"
1527
1528config VPL
1529 depends on SUPPORT_SPL
1530 bool "Enable VPL"
1531 help
1532 If you want to build VPL as well as the normal image, TPL and SPL,
1533 say Y.
1534
1535source "common/spl/Kconfig.vpl"