blob: cdf8f7ee0e8e5e5141c00c5b4de8fc5b0d32a0f2 [file] [log] [blame]
Masahiro Yamadaf3e12b72014-09-16 16:32:58 +09001menu "Library routines"
2
Marek Szyprowski795dc7d2020-06-03 14:43:40 +02003config ADDR_MAP
4 bool "Enable support for non-identity virtual-physical mappings"
5 help
6 Enables helper code for implementing non-identity virtual-physical
7 memory mappings for 32bit CPUs.
8
Bin Meng0a5fee52021-02-25 17:22:36 +08009 This library only works in the post-relocation phase.
10
Marek Szyprowski795dc7d2020-06-03 14:43:40 +020011config SYS_NUM_ADDR_MAP
12 int "Size of the address-map table"
13 depends on ADDR_MAP
14 default 16
15 help
16 Sets the number of entries in the virtual-physical mapping table.
17
Tom Rini1f173632022-11-16 13:10:38 -050018config SYS_TIMER_COUNTS_DOWN
Marek Vasut88e5a202023-03-19 04:13:02 +010019 bool "System timer counts down rather than up"
Tom Rini1f173632022-11-16 13:10:38 -050020
Simon Glassef9e7622021-11-24 09:26:42 -070021config PHYSMEM
22 bool "Access to physical memory region (> 4G)"
23 help
24 Some basic support is provided for operations on memory not
25 normally accessible to 32-bit U-Boot - e.g. some architectures
26 support access to more than 4G of memory on 32-bit
27 machines using physical address extension or similar.
28 Enable this to access this basic support, which only supports clearing
29 the memory.
30
Adam Ford02bf5362017-08-11 09:46:05 -050031config BCH
32 bool "Enable Software based BCH ECC"
33 help
34 Enables software based BCH ECC algorithm present in lib/bch.c
35 This is used by SoC platforms which do not have built-in ELM
36 hardware engine required for BCH ECC correction.
37
Simon Glassdd7fb9b2019-12-06 21:41:34 -070038config BINMAN_FDT
39 bool "Allow access to binman information in the device tree"
Bin Mengc5e8b312021-02-03 21:20:02 +080040 depends on BINMAN && DM && OF_CONTROL
Bin Mengc9155f12021-05-10 20:23:36 +080041 default y if OF_SEPARATE || OF_EMBED
Simon Glassdd7fb9b2019-12-06 21:41:34 -070042 help
43 This enables U-Boot to access information about binman entries,
44 stored in the device tree in a binman node. Typical uses are to
45 locate entries in the firmware image. See binman.h for the available
46 functionality.
47
Michal Simek15fa3a82024-11-01 10:17:54 +010048config BINMAN_DTB
49 string "binman DTB description"
50 depends on BINMAN
51 help
52 This enables option to point to different DTB file with binman node which
53 is outside of DTB used by the firmware. Use this option if information
54 about generated images shouldn't be the part of target binary. Or on system
55 with limited storage.
56
Masahiro Yamada3f053fe2014-09-16 16:32:59 +090057config CC_OPTIMIZE_LIBS_FOR_SPEED
58 bool "Optimize libraries for speed"
59 help
60 Enabling this option will pass "-O2" to gcc when compiling
61 under "lib" directory.
62
63 If unsure, say N.
64
Simon Glassc17db992021-07-02 12:36:17 -060065config CHARSET
66 bool
Simon Glassc17db992021-07-02 12:36:17 -060067
Faiz Abbas6199fb12018-02-06 19:15:58 +053068config DYNAMIC_CRC_TABLE
69 bool "Enable Dynamic tables for CRC"
70 help
71 Enable this option to calculate entries for CRC tables at runtime.
72 This can be helpful when reducing the size of the build image
73
Bin Mengb95e9db2018-10-15 02:21:15 -070074config HAVE_ARCH_IOMAP
75 bool
76 help
77 Enable this option if architecture provides io{read,write}{8,16,32}
78 I/O accessor functions.
79
Masahiro Yamada9520b712014-10-24 01:30:43 +090080config HAVE_PRIVATE_LIBGCC
81 bool
82
Adam Ford70c8f052018-02-06 12:14:28 -060083config LIB_UUID
84 bool
Caleb Connolly2f4f0be2024-08-30 13:34:32 +010085 select SHA1
Adam Ford70c8f052018-02-06 12:14:28 -060086
AKASHI Takahirod1e31582023-10-26 14:31:31 -040087config RANDOM_UUID
88 bool "GPT Random UUID generation"
89 select LIB_UUID
90 help
91 Enable the generation of partitions with random UUIDs if none
92 are provided.
93
Simon Glass8090d8d2023-02-22 09:34:11 -070094config SPL_LIB_UUID
95 depends on SPL
96 bool
97
Kautuk Consula51bb742022-12-07 17:12:34 +053098config SEMIHOSTING
99 bool "Support semihosting"
Kautuk Consulc86cb4a2022-12-07 17:12:35 +0530100 depends on ARM || RISCV
Kautuk Consula51bb742022-12-07 17:12:34 +0530101 help
102 Semihosting is a method for a target to communicate with a host
103 debugger. It uses special instructions which the debugger will trap
104 on and interpret. This allows U-Boot to read/write files, print to
105 the console, and execute arbitrary commands on the host system.
106
107 Enabling this option will add support for reading and writing files
108 on the host system. If you don't have a debugger attached then trying
109 to do this will likely cause U-Boot to hang. Say 'n' if you are unsure.
110
111config SEMIHOSTING_FALLBACK
112 bool "Recover gracefully when semihosting fails"
Sean Andersonbf641f22023-10-27 16:40:15 -0400113 depends on SEMIHOSTING
Kautuk Consula51bb742022-12-07 17:12:34 +0530114 default y
115 help
116 Normally, if U-Boot makes a semihosting call and no debugger is
117 attached, then it will panic due to a synchronous abort
118 exception. This config adds an exception handler which will allow
119 U-Boot to recover. Say 'y' if unsure.
120
121config SPL_SEMIHOSTING
122 bool "Support semihosting in SPL"
Kautuk Consulc86cb4a2022-12-07 17:12:35 +0530123 depends on SPL && (ARM || RISCV)
Kautuk Consula51bb742022-12-07 17:12:34 +0530124 help
125 Semihosting is a method for a target to communicate with a host
126 debugger. It uses special instructions which the debugger will trap
127 on and interpret. This allows U-Boot to read/write files, print to
128 the console, and execute arbitrary commands on the host system.
129
130 Enabling this option will add support for reading and writing files
131 on the host system. If you don't have a debugger attached then trying
132 to do this will likely cause U-Boot to hang. Say 'n' if you are unsure.
133
134config SPL_SEMIHOSTING_FALLBACK
135 bool "Recover gracefully when semihosting fails in SPL"
Sean Andersonbf641f22023-10-27 16:40:15 -0400136 depends on SPL_SEMIHOSTING
Kautuk Consulc86cb4a2022-12-07 17:12:35 +0530137 select ARMV8_SPL_EXCEPTION_VECTORS if ARM64
Kautuk Consula51bb742022-12-07 17:12:34 +0530138 default y
139 help
140 Normally, if U-Boot makes a semihosting call and no debugger is
141 attached, then it will panic due to a synchronous abort
142 exception. This config adds an exception handler which will allow
143 U-Boot to recover. Say 'y' if unsure.
144
Alex Kiernan5b404282018-04-19 04:32:54 +0000145config PRINTF
146 bool
147 default y
148
149config SPL_PRINTF
150 bool
151 select SPL_SPRINTF
Simon Glass7611ac62019-09-25 08:56:27 -0600152 select SPL_STRTO if !SPL_USE_TINY_PRINTF
Alex Kiernan5b404282018-04-19 04:32:54 +0000153
154config TPL_PRINTF
155 bool
156 select TPL_SPRINTF
Simon Glass7611ac62019-09-25 08:56:27 -0600157 select TPL_STRTO if !TPL_USE_TINY_PRINTF
Alex Kiernan5b404282018-04-19 04:32:54 +0000158
Simon Glasse7ca7da2022-04-30 00:56:53 -0600159config VPL_PRINTF
160 bool
161 select VPL_SPRINTF
162 select VPL_STRTO if !VPL_USE_TINY_PRINTF
163
Alex Kiernan5b404282018-04-19 04:32:54 +0000164config SPRINTF
165 bool
166 default y
167
168config SPL_SPRINTF
169 bool
170
171config TPL_SPRINTF
172 bool
173
Simon Glasse7ca7da2022-04-30 00:56:53 -0600174config VPL_SPRINTF
175 bool
176
Andrii Anisov6e29ac42020-08-06 12:42:52 +0300177config SSCANF
178 bool
Andrii Anisov6e29ac42020-08-06 12:42:52 +0300179
Alex Kiernan5b404282018-04-19 04:32:54 +0000180config STRTO
181 bool
182 default y
183
184config SPL_STRTO
185 bool
186
187config TPL_STRTO
188 bool
189
Simon Glasse7ca7da2022-04-30 00:56:53 -0600190config VPL_STRTO
191 bool
192
Alex Kiernanc568bcb2018-05-29 15:30:52 +0000193config IMAGE_SPARSE
194 bool
195
196config IMAGE_SPARSE_FILLBUF_SIZE
197 hex "Android sparse image CHUNK_TYPE_FILL buffer size"
198 default 0x80000
199 depends on IMAGE_SPARSE
200 help
201 Set the size of the fill buffer used when processing CHUNK_TYPE_FILL
202 chunks.
203
Masahiro Yamada9520b712014-10-24 01:30:43 +0900204config USE_PRIVATE_LIBGCC
205 bool "Use private libgcc"
206 depends on HAVE_PRIVATE_LIBGCC
Marek Vasut4e0126e2016-05-26 18:01:47 +0200207 default y if HAVE_PRIVATE_LIBGCC && ((ARM && !ARM64) || MIPS)
Masahiro Yamada9520b712014-10-24 01:30:43 +0900208 help
209 This option allows you to use the built-in libgcc implementation
Masahiro Yamada1c6a5e42016-03-30 20:17:42 +0900210 of U-Boot instead of the one provided by the compiler.
Masahiro Yamada9520b712014-10-24 01:30:43 +0900211 If unsure, say N.
212
Masahiro Yamadae301fa02014-10-24 01:30:40 +0900213config SYS_HZ
214 int
215 default 1000
216 help
217 The frequency of the timer returned by get_timer().
218 get_timer() must operate in milliseconds and this option must be
219 set to 1000.
220
Simon Glass7611ac62019-09-25 08:56:27 -0600221config SPL_USE_TINY_PRINTF
Thomas Hebb0c12fb52019-11-10 08:23:53 -0800222 bool "Enable tiny printf() version in SPL"
Simon Glass7611ac62019-09-25 08:56:27 -0600223 depends on SPL
Tom Rinid0502b72019-06-08 12:46:18 -0400224 default y
Stefan Roese363ab7b2015-11-23 07:00:22 +0100225 help
226 This option enables a tiny, stripped down printf version.
227 This should only be used in space limited environments,
228 like SPL versions with hard memory limits. This version
229 reduces the code size by about 2.5KiB on armv7.
230
231 The supported format specifiers are %c, %s, %u/%d and %x.
232
Simon Glass7611ac62019-09-25 08:56:27 -0600233config TPL_USE_TINY_PRINTF
Thomas Hebb0c12fb52019-11-10 08:23:53 -0800234 bool "Enable tiny printf() version in TPL"
Simon Glass7611ac62019-09-25 08:56:27 -0600235 depends on TPL
236 default y if SPL_USE_TINY_PRINTF
237 help
238 This option enables a tiny, stripped down printf version.
239 This should only be used in space limited environments,
240 like SPL versions with hard memory limits. This version
241 reduces the code size by about 2.5KiB on armv7.
242
243 The supported format specifiers are %c, %s, %u/%d and %x.
244
Simon Glasse7ca7da2022-04-30 00:56:53 -0600245config VPL_USE_TINY_PRINTF
246 bool "Enable tiny printf() version for VPL"
247 depends on VPL
248 help
249 This option enables a tiny, stripped down printf version.
250 This should only be used in space limited environments,
251 like SPL versions with hard memory limits. This version
252 reduces the code size by about 2.5KiB on armv7.
253
254 The supported format specifiers are %c, %s, %u/%d and %x.
255
Christoph Niedermaier6a227952025-05-08 13:57:25 +0200256config SPL_USE_TINY_PRINTF_POINTER_SUPPORT
257 bool "Extend tiny printf with the pointer formatting %p"
258 depends on SPL_USE_TINY_PRINTF
259 help
260 This option enables the formatting of pointers %p. It supports
261 %p and %pa / %pap. If this option is selected by SPL_NET
262 it also supports the formatting with %pm, %pM and %pI4.
263
Masahiro Yamadaacede7a2017-12-04 12:37:00 +0900264config PANIC_HANG
265 bool "Do not reset the system on fatal error"
266 help
267 Define this option to stop the system in case of a fatal error,
268 so that you have to reset it manually. This is probably NOT a good
269 idea for an embedded system where you want the system to reboot
270 automatically as fast as possible, but it may be useful during
271 development since you can try to debug the conditions that lead to
272 the situation.
273
Joe Hershberger937d3e82015-04-21 17:02:42 -0500274config REGEX
275 bool "Enable regular expression support"
Joe Hershberger8ab8b722015-06-22 17:57:36 -0500276 default y if NET
Joe Hershberger937d3e82015-04-21 17:02:42 -0500277 help
278 If this variable is defined, U-Boot is linked against the
279 SLRE (Super Light Regular Expression) library, which adds
280 regex support to some commands, for example "env grep" and
281 "setexpr".
282
Adam Ford38003a62018-02-06 10:18:18 -0600283choice
284 prompt "Pseudo-random library support type"
Heinrich Schuchardtb2e67a22020-01-19 19:28:12 +0100285 depends on NET_RANDOM_ETHADDR || RANDOM_UUID || CMD_UUID || \
Heinrich Schuchardtba9c44e2020-11-20 12:55:22 +0100286 RNG_SANDBOX || UT_LIB && AES || FAT_WRITE
Adam Ford38003a62018-02-06 10:18:18 -0600287 default LIB_RAND
Masahiro Yamada2743c072015-06-11 19:16:43 +0900288 help
Adam Ford38003a62018-02-06 10:18:18 -0600289 Select the library to provide pseudo-random number generator
290 functions. LIB_HW_RAND supports certain hardware engines that
291 provide this functionality. If in doubt, select LIB_RAND.
292
293config LIB_RAND
294 bool "Pseudo-random library support"
295
296config LIB_HW_RAND
Marcin Juszkiewicza360c2c2020-05-26 19:07:15 +0200297 bool "HW Engine for random library support"
Adam Ford38003a62018-02-06 10:18:18 -0600298
299endchoice
Michal Simek2c1b1db2015-05-25 11:37:22 +0200300
Simon Glassa6cee932021-12-01 09:02:36 -0700301config SUPPORT_ACPI
302 bool
303 help
304 Enable this if your arch or board can support generating ACPI
305 (Advanced Configuration and Power Interface) tables. In this case
306 U-Boot can generate these tables and pass them to the Operating
307 System.
308
Simon Glasse264be42023-05-04 16:54:57 -0600309config ACPI
310 bool "Enable support for ACPI libraries"
311 depends on SUPPORT_ACPI
312 help
313 Provides library functions for dealing with ACPI tables. This does
314 not necessarily include generation of tables
315 (see GENERATE_ACPI_TABLE), but allows for tables to be located.
316
Simon Glass1a2fcc22023-09-19 21:00:06 -0600317config SPL_ACPI
318 bool "Enable support for ACPI libraries in SPL"
319 depends on SPL && SUPPORT_ACPI
320 help
321 Provides library functions for dealing with ACPI tables in SPL. This
322 does not necessarily include generation of tables
323 (see GENERATE_ACPI_TABLE), but allows for tables to be located.
324
Simon Glassa6cee932021-12-01 09:02:36 -0700325config GENERATE_ACPI_TABLE
326 bool "Generate an ACPI (Advanced Configuration and Power Interface) table"
Simon Glasse264be42023-05-04 16:54:57 -0600327 depends on ACPI
Heinrich Schuchardt14541c62025-04-07 08:44:23 +0200328 select BLOBLIST
Simon Glassa6cee932021-12-01 09:02:36 -0700329 select QFW if QEMU
330 help
331 The Advanced Configuration and Power Interface (ACPI) specification
332 provides an open standard for device configuration and management
333 by the operating system. It defines platform-independent interfaces
334 for configuration and power management monitoring.
335
Patrick Rudolph2f6f8d92024-10-23 15:20:13 +0200336config ACPI_PARKING_PROTOCOL
337 bool "Support ACPI parking protocol method"
338 depends on GENERATE_ACPI_TABLE
339 depends on ARMV8_MULTIENTRY
340 depends on BLOBLIST_TABLES
341 default y if !SEC_FIRMWARE_ARMV8_PSCI && !ARMV8_PSCI
342 help
343 Say Y here to support "ACPI parking protocol" enable method
344 for booting Linux.
345
346 To use this feature, you must do:
347 - Bring secondary CPUs into U-Boot proper in a board-specific
348 manner. This must be done *after* relocation. Otherwise, the
349 secondary CPUs will spin in unprotected memory-area because the
350 master CPU protects the relocated spin code.
351
Simon Glasse2f94ae2017-04-02 09:50:28 -0600352config SPL_TINY_MEMSET
353 bool "Use a very small memset() in SPL"
Tom Rini0a83cc22022-06-10 23:03:09 -0400354 depends on SPL
Simon Glasse2f94ae2017-04-02 09:50:28 -0600355 help
356 The faster memset() is the arch-specific one (if available) enabled
357 by CONFIG_USE_ARCH_MEMSET. If that is not enabled, we can still get
358 better performance by writing a word at a time. But in very
Chris Packham1c3b7ba2019-01-13 22:13:28 +1300359 size-constrained environments even this may be too big. Enable this
Simon Glasse2f94ae2017-04-02 09:50:28 -0600360 option to reduce code size slightly at the cost of some speed.
361
Philipp Tomsichfefc4ec2017-08-03 22:52:04 +0200362config TPL_TINY_MEMSET
363 bool "Use a very small memset() in TPL"
Tom Rini36a4ca02022-06-08 08:24:39 -0400364 depends on TPL
Philipp Tomsichfefc4ec2017-08-03 22:52:04 +0200365 help
366 The faster memset() is the arch-specific one (if available) enabled
367 by CONFIG_USE_ARCH_MEMSET. If that is not enabled, we can still get
368 better performance by writing a word at a time. But in very
Chris Packham1c3b7ba2019-01-13 22:13:28 +1300369 size-constrained environments even this may be too big. Enable this
Philipp Tomsichfefc4ec2017-08-03 22:52:04 +0200370 option to reduce code size slightly at the cost of some speed.
371
Boris Brezillon627dc182017-02-27 18:22:05 +0100372config RBTREE
373 bool
374
Nandor Hand5ea84a2017-11-08 15:35:14 +0000375config BITREVERSE
376 bool "Bit reverse library from Linux"
377
Simon Glassbfce7fc2019-04-08 13:20:51 -0600378config TRACE
379 bool "Support for tracing of function calls and timing"
380 imply CMD_TRACE
Simon Glass6b5424a2022-12-21 16:08:26 -0700381 imply TIMER_EARLY
Simon Glassbfce7fc2019-04-08 13:20:51 -0600382 help
383 Enables function tracing within U-Boot. This allows recording of call
384 traces including timing information. The command can write data to
385 memory for exporting for analysis (e.g. using bootchart).
Vincent Stehlé28c23622024-04-11 18:44:02 +0200386 See doc/develop/trace.rst for full details.
Simon Glassbfce7fc2019-04-08 13:20:51 -0600387
Simon Glass445078e2019-04-08 13:20:52 -0600388config TRACE_BUFFER_SIZE
389 hex "Size of trace buffer in U-Boot"
390 depends on TRACE
391 default 0x01000000
392 help
393 Sets the size of the trace buffer in U-Boot. This is allocated from
394 memory during relocation. If this buffer is too small, the trace
395 history will be truncated, with later records omitted.
396
397 If early trace is enabled (i.e. before relocation), this buffer must
398 be large enough to include all the data from the early trace buffer as
399 well, since this is copied over to the main buffer during relocation.
400
401 A trace record is emitted for each function call and each record is
402 12 bytes (see struct trace_call). A suggested minimum size is 1MB. If
403 the size is too small then 'trace stats' will show a message saying
404 how many records were dropped due to buffer overflow.
405
Heinrich Schuchardtc1a73792019-06-02 13:30:09 +0200406config TRACE_CALL_DEPTH_LIMIT
407 int "Trace call depth limit"
408 depends on TRACE
409 default 15
410 help
411 Sets the maximum call depth up to which function calls are recorded.
412
Simon Glass445078e2019-04-08 13:20:52 -0600413config TRACE_EARLY
414 bool "Enable tracing before relocation"
415 depends on TRACE
416 help
417 Sometimes it is helpful to trace execution of U-Boot before
418 relocation. This is possible by using a arch-specific, fixed buffer
419 position in memory. Enable this option to start tracing as early as
420 possible after U-Boot starts.
421
422config TRACE_EARLY_SIZE
423 hex "Size of early trace buffer in U-Boot"
424 depends on TRACE_EARLY
425 default 0x00100000
426 help
427 Sets the size of the early trace buffer in bytes. This is used to hold
428 tracing information before relocation.
429
Heinrich Schuchardtc1a73792019-06-02 13:30:09 +0200430config TRACE_EARLY_CALL_DEPTH_LIMIT
431 int "Early trace call depth limit"
432 depends on TRACE_EARLY
Simon Glass971574d2023-01-15 14:15:44 -0700433 default 15
Heinrich Schuchardtc1a73792019-06-02 13:30:09 +0200434 help
435 Sets the maximum call depth up to which function calls are recorded
436 during early tracing.
437
Simon Glass445078e2019-04-08 13:20:52 -0600438config TRACE_EARLY_ADDR
439 hex "Address of early trace buffer in U-Boot"
440 depends on TRACE_EARLY
Sughosh Ganu3f768682024-08-26 17:29:32 +0530441 default 0x00200000
Simon Glass445078e2019-04-08 13:20:52 -0600442 help
443 Sets the address of the early trace buffer in U-Boot. This memory
444 must be accessible before relocation.
445
446 A trace record is emitted for each function call and each record is
447 12 bytes (see struct trace_call). A suggested minimum size is 1MB. If
448 the size is too small then the message which says the amount of early
449 data being coped will the the same as the
450
Loic Poulain12797e62021-11-25 18:16:14 +0100451config CIRCBUF
452 bool "Enable circular buffer support"
453
Michal Simekdd5000ef2024-04-16 08:55:16 +0200454source "lib/dhry/Kconfig"
Simon Glass99dbe4b2015-06-23 15:38:23 -0600455
Raymond Mao87010c32024-10-03 14:50:15 -0700456menu "Alternative crypto libraries"
Tom Rini6fdb77e2025-03-14 19:29:33 -0600457
458source "lib/mbedtls/Kconfig"
459
Raymond Mao87010c32024-10-03 14:50:15 -0700460endmenu
461
Simon Glass528fdd12017-04-26 22:27:49 -0600462menu "Security support"
463
464config AES
465 bool "Support the AES algorithm"
466 help
467 This provides a means to encrypt and decrypt data using the AES
468 (Advanced Encryption Standard). This algorithm uses a symetric key
469 and is widely used as a streaming cipher. Different key lengths are
470 supported by the algorithm but only a 128-bit key is supported at
471 present.
472
Michal Simekdd5000ef2024-04-16 08:55:16 +0200473source "lib/ecdsa/Kconfig"
474source "lib/rsa/Kconfig"
475source "lib/crypto/Kconfig"
476source "lib/crypt/Kconfig"
Ruchika Gupta2c3822e2015-01-23 16:01:51 +0530477
Simon Glass350497c2015-08-22 18:31:19 -0600478config TPM
479 bool "Trusted Platform Module (TPM) Support"
Simon Glasscf294b02015-10-03 06:39:36 -0600480 depends on DM
Sughosh Ganu9737fab2022-07-22 21:32:04 +0530481 imply DM_RNG
Eddie James8ed7bb32023-10-24 10:43:49 -0500482 select SHA1
Simon Glass350497c2015-08-22 18:31:19 -0600483 help
484 This enables support for TPMs which can be used to provide security
485 features for your board. The TPM can be connected via LPC or I2C
486 and a sandbox TPM is provided for testing purposes. Use the 'tpm'
487 command to interactive the TPM. Driver model support is provided
488 for the low-level TPM interface, but only one TPM is supported at
489 a time by the TPM library.
Ilias Apalodimas1e665f92024-06-23 14:48:18 +0300490 For size reasons only SHA1 is selected which is supported on TPM1.2.
491 If you want a fully functional TPM enable all hashing algorithms.
492 If you enabled measured boot all hashing algorithms are selected.
Simon Glass350497c2015-08-22 18:31:19 -0600493
Simon Glass93a45b12018-10-01 12:22:19 -0600494config SPL_TPM
495 bool "Trusted Platform Module (TPM) Support in SPL"
496 depends on SPL_DM
Simon Glass2b95b492023-01-07 14:57:20 -0700497 imply SPL_CRC8
Simon Glass93a45b12018-10-01 12:22:19 -0600498 help
499 This enables support for TPMs which can be used to provide security
500 features for your board. The TPM can be connected via LPC or I2C
501 and a sandbox TPM is provided for testing purposes. Use the 'tpm'
502 command to interactive the TPM. Driver model support is provided
503 for the low-level TPM interface, but only one TPM is supported at
504 a time by the TPM library.
505
506config TPL_TPM
507 bool "Trusted Platform Module (TPM) Support in TPL"
508 depends on TPL_DM
509 help
510 This enables support for TPMs which can be used to provide security
511 features for your board. The TPM can be connected via LPC or I2C
512 and a sandbox TPM is provided for testing purposes. Use the 'tpm'
513 command to interactive the TPM. Driver model support is provided
514 for the low-level TPM interface, but only one TPM is supported at
515 a time by the TPM library.
516
Simon Glasse7ca7da2022-04-30 00:56:53 -0600517config VPL_TPM
518 bool "Trusted Platform Module (TPM) Support in VPL"
519 depends on VPL_DM
520 help
521 This enables support for TPMs which can be used to provide security
522 features for your board. The TPM can be connected via LPC or I2C
523 and a sandbox TPM is provided for testing purposes. Use the 'tpm'
524 command to interactive the TPM. Driver model support is provided
525 for the low-level TPM interface, but only one TPM is supported at
526 a time by the TPM library.
527
Raymond Maof0c91252025-01-27 06:58:48 -0800528config TPM_PCR_ALLOCATE
529 bool "Re-configurate TPM algorithms in run-time (PCR allocate)"
530 depends on TPM_V2 && (MEASURED_BOOT || EFI_TCG2_PROTOCOL)
531 help
532 This enables a detection for the dismatches of algorithms among TPM
533 device, eventlog from previous boot stage and U-Boot support.
534 A PCR allocate command will be sent to reconfigurate the TPM device
535 in run-time to make sure algorithms in TPM device, eventlog and
536 U-Boot are aligned with each other.
537 A system reboot will be proceeded after then to activate the new
538 algorithms.
539
Simon Glass528fdd12017-04-26 22:27:49 -0600540endmenu
541
Igor Opaniuk525d1d82018-06-03 21:56:37 +0300542menu "Android Verified Boot"
543
544config LIBAVB
545 bool "Android Verified Boot 2.0 support"
546 depends on ANDROID_BOOT_IMAGE
Igor Opaniuk525d1d82018-06-03 21:56:37 +0300547 help
548 This enables support of Android Verified Boot 2.0 which can be used
549 to assure the end user of the integrity of the software running on a
550 device. Introduces such features as boot chain of trust, rollback
551 protection etc.
552
553endmenu
554
gaurav ranaef201592015-02-20 12:51:46 +0530555menu "Hashing Support"
556
Qu Wenruob98e8a22021-12-27 14:12:07 +0800557config BLAKE2
558 bool "Enable BLAKE2 support"
559 help
560 This option enables support of hashing using BLAKE2B algorithm.
561 The hash is calculated in software.
562 The BLAKE2 algorithm produces a hash value (digest) between 1 and
563 64 bytes.
564
gaurav ranaef201592015-02-20 12:51:46 +0530565config SHA1
566 bool "Enable SHA1 support"
567 help
568 This option enables support of hashing using SHA1 algorithm.
569 The hash is calculated in software.
570 The SHA1 algorithm produces a 160-bit (20-byte) hash value
571 (digest).
572
573config SHA256
574 bool "Enable SHA256 support"
575 help
576 This option enables support of hashing using SHA256 algorithm.
577 The hash is calculated in software.
578 The SHA256 algorithm produces a 256-bit (32-byte) hash value
579 (digest).
580
Reuben Dowle1908fd92020-04-16 17:36:52 +1200581config SHA512
582 bool "Enable SHA512 support"
Manorit Chawdhrya58132a2023-07-14 11:22:39 +0530583 default y if TI_SECURE_DEVICE && FIT_SIGNATURE
Reuben Dowle1908fd92020-04-16 17:36:52 +1200584 help
585 This option enables support of hashing using SHA512 algorithm.
586 The hash is calculated in software.
587 The SHA512 algorithm produces a 512-bit (64-byte) hash value
588 (digest).
589
590config SHA384
591 bool "Enable SHA384 support"
Alexandru Gagniuc5df5d692021-09-02 19:54:18 -0500592 select SHA512
Reuben Dowle1908fd92020-04-16 17:36:52 +1200593 help
594 This option enables support of hashing using SHA384 algorithm.
Alexandru Gagniuc5df5d692021-09-02 19:54:18 -0500595 The hash is calculated in software. This is also selects SHA512,
596 because these implementations share the bulk of the code..
Reuben Dowle1908fd92020-04-16 17:36:52 +1200597 The SHA384 algorithm produces a 384-bit (48-byte) hash value
598 (digest).
599
gaurav ranaef201592015-02-20 12:51:46 +0530600config SHA_HW_ACCEL
Heinrich Schuchardtd42f81f2021-05-14 07:08:27 +0200601 bool "Enable hardware acceleration for SHA hash functions"
gaurav ranaef201592015-02-20 12:51:46 +0530602 help
Heinrich Schuchardtd42f81f2021-05-14 07:08:27 +0200603 This option enables hardware acceleration for the SHA1 and SHA256
604 hashing algorithms. This affects the 'hash' command and also the
605 hash_lookup_algo() function.
606
Simon Glassf7b37c22021-09-25 19:43:17 -0600607if SPL
608
Oleksandr Suvorov15a23ca2023-08-03 19:05:40 +0300609config SPL_CRC32
610 bool "Enable CRC32 support in SPL"
611 default y if SPL_LEGACY_IMAGE_SUPPORT || SPL_EFI_PARTITION
612 default y if SPL_ENV_SUPPORT || TPL_BLOBLIST
613 help
614 This option enables support of hashing using CRC32 algorithm.
615 The CRC32 algorithm produces 32-bit checksum value. For FIT
616 images, this is the least secure type of checksum, suitable for
617 detected accidental image corruption. For secure applications you
618 should consider SHA256 or SHA384.
619
Simon Glassf7b37c22021-09-25 19:43:17 -0600620config SPL_SHA1
621 bool "Enable SHA1 support in SPL"
622 default y if SHA1
623 help
624 This option enables support of hashing using SHA1 algorithm.
625 The hash is calculated in software.
626 The SHA1 algorithm produces a 160-bit (20-byte) hash value
627 (digest).
628
629config SPL_SHA256
630 bool "Enable SHA256 support in SPL"
631 default y if SHA256
632 help
633 This option enables support of hashing using SHA256 algorithm.
634 The hash is calculated in software.
635 The SHA256 algorithm produces a 256-bit (32-byte) hash value
636 (digest).
637
638config SPL_SHA512
639 bool "Enable SHA512 support in SPL"
640 default y if SHA512
641 help
642 This option enables support of hashing using SHA512 algorithm.
643 The hash is calculated in software.
644 The SHA512 algorithm produces a 512-bit (64-byte) hash value
645 (digest).
646
647config SPL_SHA384
648 bool "Enable SHA384 support in SPL"
649 default y if SHA384
650 select SPL_SHA512
651 help
652 This option enables support of hashing using SHA384 algorithm.
653 The hash is calculated in software. This is also selects SHA512,
654 because these implementations share the bulk of the code..
655 The SHA384 algorithm produces a 384-bit (48-byte) hash value
656 (digest).
657
Simon Glass383dd572021-09-25 19:43:18 -0600658config SPL_SHA_HW_ACCEL
659 bool "Enable hardware acceleration for SHA hash functions"
660 default y if SHA_HW_ACCEL
661 help
662 This option enables hardware acceleration for the SHA1 and SHA256
663 hashing algorithms. This affects the 'hash' command and also the
664 hash_lookup_algo() function.
665
666config SPL_SHA_PROG_HW_ACCEL
667 bool "Enable Progressive hashing support using hardware in SPL"
668 depends on SHA_PROG_HW_ACCEL
669 default y
670 help
671 This option enables hardware-acceleration for SHA progressive
672 hashing.
673 Data can be streamed in a block at a time and the hashing is
674 performed in hardware.
675
Simon Glassf7b37c22021-09-25 19:43:17 -0600676endif
677
Simon Glass540883b2023-02-22 09:34:01 -0700678config VPL_SHA1
679 bool "Enable SHA1 support in VPL"
680 depends on VPL
681 default y if SHA1
682 help
683 This option enables support of hashing using SHA1 algorithm.
684 The hash is calculated in software.
685 The SHA1 algorithm produces a 160-bit (20-byte) hash value
686 (digest).
687
688config VPL_SHA256
689 bool "Enable SHA256 support in VPL"
690 depends on VPL
691 default y if SHA256
692 help
693 This option enables support of hashing using SHA256 algorithm.
694 The hash is calculated in software.
695 The SHA256 algorithm produces a 256-bit (32-byte) hash value
696 (digest).
697
Heinrich Schuchardtd42f81f2021-05-14 07:08:27 +0200698if SHA_HW_ACCEL
699
700config SHA512_HW_ACCEL
701 bool "Enable hardware acceleration for SHA512"
Alexandru Gagniuc5df5d692021-09-02 19:54:18 -0500702 depends on SHA512
Heinrich Schuchardtd42f81f2021-05-14 07:08:27 +0200703 help
704 This option enables hardware acceleration for the SHA384 and SHA512
705 hashing algorithms. This affects the 'hash' command and also the
706 hash_lookup_algo() function.
gaurav ranaef201592015-02-20 12:51:46 +0530707
708config SHA_PROG_HW_ACCEL
709 bool "Enable Progressive hashing support using hardware"
gaurav ranaef201592015-02-20 12:51:46 +0530710 help
Joel Stanley92efc1f2021-02-17 13:50:42 +1030711 This option enables hardware-acceleration for SHA progressive
712 hashing.
713 Data can be streamed in a block at a time and the hashing is
714 performed in hardware.
Andre Przywaraf0fa1132017-03-15 01:19:05 +0000715
Heinrich Schuchardtd42f81f2021-05-14 07:08:27 +0200716endif
717
Andre Przywaraf0fa1132017-03-15 01:19:05 +0000718config MD5
Simon Glassd33d0db2020-05-06 08:03:56 -0600719 bool "Support MD5 algorithm"
720 help
721 This option enables MD5 support. MD5 is an algorithm designed
722 in 1991 that produces a 16-byte digest (or checksum) from its input
723 data. It has a number of vulnerabilities which preclude its use in
724 security applications, but it can be useful for providing a quick
725 checksum of a block of data.
726
727config SPL_MD5
728 bool "Support MD5 algorithm in SPL"
Tom Rini0a83cc22022-06-10 23:03:09 -0400729 depends on SPL
Simon Glassd33d0db2020-05-06 08:03:56 -0600730 help
731 This option enables MD5 support in SPL. MD5 is an algorithm designed
732 in 1991 that produces a 16-byte digest (or checksum) from its input
733 data. It has a number of vulnerabilities which preclude its use in
734 security applications, but it can be useful for providing a quick
735 checksum of a block of data.
Andre Przywaraf0fa1132017-03-15 01:19:05 +0000736
Simon Glass2b95b492023-01-07 14:57:20 -0700737config CRC8
738 def_bool y
739 help
740 Enables CRC8 support in U-Boot. This is normally required. CRC8 is
741 a simple and fast checksumming algorithm which does a bytewise
742 checksum with feedback to produce an 8-bit result. The code is small
743 and it does not require a lookup table (unlike CRC32).
744
745config SPL_CRC8
746 bool "Support CRC8 in SPL"
747 depends on SPL
748 help
749 Enables CRC8 support in SPL. This is not normally required. CRC8 is
750 a simple and fast checksumming algorithm which does a bytewise
751 checksum with feedback to produce an 8-bit result. The code is small
752 and it does not require a lookup table (unlike CRC32).
753
Simon Glass4649af32024-12-19 11:29:05 -0700754config TPL_CRC8
755 bool "Support CRC8 in TPL"
756 depends on TPL
757 help
758 Enables CRC8 support in TPL. This is not normally required. CRC8 is
759 a simple and fast checksumming algorithm which does a bytewise
760 checksum with feedback to produce an 8-bit result. The code is small
761 and it does not require a lookup table (unlike CRC32).
762
763config VPL_CRC8
764 bool "Support CRC8 in VPL"
765 depends on VPL
766 help
767 Enables CRC8 support in VPL. This is not normally required. CRC8 is
768 a simple and fast checksumming algorithm which does a bytewise
769 checksum with feedback to produce an 8-bit result. The code is small
770 and it does not require a lookup table (unlike CRC32).
771
Simon Glass52b51ab2025-01-26 11:43:14 -0700772config CRC16
773 bool "Support CRC16"
774 default y
775 help
776 Enables CRC16 support. This is normally required. Two algorithms are
777 provided:
778
779 - CCITT, with a polynomical x^16 + x^12 + x^5 + 1
780 - standard, with polynomial x^16 + x^15 + x^2 + 1 (0x8005)
781
Sean Anderson01349c12023-10-14 16:47:49 -0400782config SPL_CRC16
783 bool "Support CRC16 in SPL"
784 depends on SPL
785 help
786 Enables CRC16 support in SPL. This is not normally required.
787
Simon Glass577226c2021-09-25 19:43:24 -0600788config CRC32
789 def_bool y
790 help
791 Enables CRC32 support in U-Boot. This is normally required.
792
Marek Behúncdccc032017-09-03 17:00:23 +0200793config CRC32C
794 bool
795
Marek Behúnb139a7f2019-04-29 22:40:43 +0200796config XXHASH
797 bool
798
gaurav ranaef201592015-02-20 12:51:46 +0530799endmenu
800
Julius Wernerf41a3ca2015-10-06 20:03:53 -0700801menu "Compression Support"
802
803config LZ4
804 bool "Enable LZ4 decompression support"
805 help
806 If this option is set, support for LZ4 compressed images
807 is included. The LZ4 algorithm can run in-place as long as the
808 compressed image is loaded to the end of the output buffer, and
809 trades lower compression ratios for much faster decompression.
Patrick Delaunaycd831af2021-03-10 10:16:28 +0100810
Julius Wernerf41a3ca2015-10-06 20:03:53 -0700811 NOTE: This implements the release version of the LZ4 frame
812 format as generated by default by the 'lz4' command line tool.
813 This is not the same as the outdated, less efficient legacy
814 frame format currently (2015) implemented in the Linux kernel
815 (generated by 'lz4 -l'). The two formats are incompatible.
816
Simon Glass264aa5f2017-05-17 03:25:42 -0600817config LZMA
818 bool "Enable LZMA decompression support"
819 help
820 This enables support for LZMA (Lempel-Ziv-Markov chain algorithm),
821 a dictionary compression algorithm that provides a high compression
822 ratio and fairly fast decompression speed. See also
823 CONFIG_CMD_LZMADEC which provides a decode command.
824
Boris Brezillonaa57d0f2017-02-27 18:22:06 +0100825config LZO
Tom Rinic20bb732017-07-22 18:36:16 -0400826 bool "Enable LZO decompression support"
827 help
Oleksandr Suvorov30a4c312021-09-01 16:05:08 +0300828 This enables support for the LZO compression algorithm.
York Suna6945fe2017-08-15 11:14:43 -0700829
Marek Vasutaeaa29d2019-03-08 16:06:55 +0100830config GZIP
Heiko Schocherb93cc602019-04-29 08:59:38 +0200831 bool "Enable gzip decompression support"
Marek Vasutaeaa29d2019-03-08 16:06:55 +0100832 select ZLIB
833 default y
834 help
835 This enables support for GZIP compression algorithm.
836
Joao Marcos Costaae8abb12020-07-30 15:33:49 +0200837config ZLIB_UNCOMPRESS
838 bool "Enables zlib's uncompress() functionality"
839 help
840 This enables an extra zlib functionality: the uncompress() function,
841 which decompresses data from a buffer into another, knowing their
842 sizes. Unlike gunzip(), there is no header parsing.
843
Michael Walle3a6e3512020-05-22 14:07:36 +0200844config GZIP_COMPRESSED
845 bool
846 select ZLIB
847
Atish Patra1fa79622020-03-05 16:24:21 -0800848config BZIP2
849 bool "Enable bzip2 decompression support"
850 help
851 This enables support for BZIP2 compression algorithm.
852
Marek Vasutaeaa29d2019-03-08 16:06:55 +0100853config ZLIB
854 bool
855 default y
856 help
857 This enables ZLIB compression lib.
858
Marek Behúne87e2002019-04-29 22:40:44 +0200859config ZSTD
860 bool "Enable Zstandard decompression support"
861 select XXHASH
862 help
863 This enables Zstandard decompression library.
864
Brandon Maierdbe88da2023-01-12 10:27:45 -0600865if ZSTD
866
867config ZSTD_LIB_MINIFY
868 bool "Minify Zstandard code"
869 default y
870 help
871 This disables various optional components and changes the
872 compilation flags to prioritize space-saving.
873
874 For detailed info, see zstd's lib/README.md
875
876 https://github.com/facebook/zstd/blob/dev/lib/README.md
877
878endif
879
Simon Glass1af8b152023-02-22 09:33:54 -0700880config SPL_BZIP2
881 bool "Enable bzip2 decompression support for SPL build"
882 depends on SPL
883 help
884 This enables support for bzip2 compression algorithm for SPL boot.
885
Simon Glasse107bcd2018-11-06 15:21:30 -0700886config SPL_LZ4
887 bool "Enable LZ4 decompression support in SPL"
Tom Rini0a83cc22022-06-10 23:03:09 -0400888 depends on SPL
Simon Glasse107bcd2018-11-06 15:21:30 -0700889 help
Marcin Juszkiewicza360c2c2020-05-26 19:07:15 +0200890 This enables support for the LZ4 decompression algorithm in SPL. LZ4
Simon Glasse107bcd2018-11-06 15:21:30 -0700891 is a lossless data compression algorithm that is focused on
892 fast compression and decompression speed. It belongs to the LZ77
893 family of byte-oriented compression schemes.
894
Simon Glass2d311212024-12-19 11:29:03 -0700895config TPL_LZ4
896 bool "Enable LZ4 decompression support in TPL"
897 depends on TPL
898 help
899 This enables support for the LZ4 decompression algorithm in TPL. LZ4
900 is a lossless data compression algorithm that is focused on
901 fast compression and decompression speed. It belongs to the LZ77
902 family of byte-oriented compression schemes.
903
904config VPL_LZ4
905 bool "Enable LZ4 decompression support in VPL"
906 depends on VPL
907 help
908 This enables support for the LZ4 decompression algorithm in VPL. LZ4
909 is a lossless data compression algorithm that is focused on
910 fast compression and decompression speed. It belongs to the LZ77
911 family of byte-oriented compression schemes.
912
developer6a4e1d32020-04-21 09:28:38 +0200913config SPL_LZMA
914 bool "Enable LZMA decompression support for SPL build"
Tom Rini0a83cc22022-06-10 23:03:09 -0400915 depends on SPL
developer6a4e1d32020-04-21 09:28:38 +0200916 help
Marcin Juszkiewicza360c2c2020-05-26 19:07:15 +0200917 This enables support for LZMA compression algorithm for SPL boot.
developer6a4e1d32020-04-21 09:28:38 +0200918
Simon Glass2d311212024-12-19 11:29:03 -0700919config TPL_LZMA
920 bool "Enable LZMA decompression support for TPL build"
921 depends on TPL
922 help
923 This enables support for LZMA compression algorithm for TPL boot.
924
Simon Glasse7ca7da2022-04-30 00:56:53 -0600925config VPL_LZMA
926 bool "Enable LZMA decompression support for VPL build"
927 default y if LZMA
928 help
929 This enables support for LZMA compression algorithm for VPL boot.
930
Jean-Jacques Hiblotdbde2882017-09-15 12:57:30 +0200931config SPL_LZO
932 bool "Enable LZO decompression support in SPL"
Tom Rini0a83cc22022-06-10 23:03:09 -0400933 depends on SPL
Jean-Jacques Hiblotdbde2882017-09-15 12:57:30 +0200934 help
935 This enables support for LZO compression algorithm in the SPL.
936
York Suna6945fe2017-08-15 11:14:43 -0700937config SPL_GZIP
938 bool "Enable gzip decompression support for SPL build"
939 select SPL_ZLIB
940 help
Oleksandr Suvorov30a4c312021-09-01 16:05:08 +0300941 This enables support for the GZIP compression algorithm for SPL boot.
York Suna6945fe2017-08-15 11:14:43 -0700942
Simon Glass2d311212024-12-19 11:29:03 -0700943config TPL_GZIP
944 bool "Enable gzip decompression support for SPL build"
945 select TPL_ZLIB
946 help
947 This enables support for the GZIP compression algorithm for TPL
948
York Suna6945fe2017-08-15 11:14:43 -0700949config SPL_ZLIB
950 bool
951 help
952 This enables compression lib for SPL boot.
953
Simon Glass2d311212024-12-19 11:29:03 -0700954config TPL_ZLIB
955 bool
956 help
957 This enables compression lib for TPL
958
Marek Behúne87e2002019-04-29 22:40:44 +0200959config SPL_ZSTD
960 bool "Enable Zstandard decompression support in SPL"
Tom Rini0a83cc22022-06-10 23:03:09 -0400961 depends on SPL
Marek Behúne87e2002019-04-29 22:40:44 +0200962 select XXHASH
963 help
964 This enables Zstandard decompression library in the SPL.
965
Julius Wernerf41a3ca2015-10-06 20:03:53 -0700966endmenu
967
Przemyslaw Marczak37550132015-04-20 20:07:40 +0200968config ERRNO_STR
969 bool "Enable function for getting errno-related string message"
970 help
971 The function errno_str(int errno), returns a pointer to the errno
972 corresponding text message:
973 - if errno is null or positive number - a pointer to "Success" message
974 - if errno is negative - a pointer to errno related message
975
Alexey Brodkin2d2fa492018-06-05 17:17:57 +0300976config HEXDUMP
977 bool "Enable hexdump"
978 help
979 This enables functions for printing dumps of binary data.
980
Simon Glassa37fd4d2020-09-12 11:13:35 -0600981config SPL_HEXDUMP
982 bool "Enable hexdump in SPL"
Heinrich Schuchardt11df0722021-07-24 17:35:46 +0200983 depends on SPL && HEXDUMP
Simon Glassa37fd4d2020-09-12 11:13:35 -0600984 help
985 This enables functions for printing dumps of binary data in
986 SPL.
987
Sean Anderson3b4a6f52020-10-27 19:55:36 -0400988config GETOPT
989 bool "Enable getopt"
990 help
991 This enables functions for parsing command-line options.
992
Simon Glassa66c5412016-02-22 22:55:42 -0700993config OF_LIBFDT
994 bool "Enable the FDT library"
995 default y if OF_CONTROL
996 help
997 This enables the FDT library (libfdt). It provides functions for
998 accessing binary device tree images in memory, such as adding and
Anatolij Gustschinda707d42017-08-18 17:58:51 +0200999 removing nodes and properties, scanning through the tree and finding
Simon Glassa66c5412016-02-22 22:55:42 -07001000 particular compatible nodes. The library operates on a flattened
1001 version of the device tree.
1002
Simon Glassc48044d2019-10-27 09:47:40 -06001003config OF_LIBFDT_ASSUME_MASK
1004 hex "Mask of conditions to assume for libfdt"
1005 depends on OF_LIBFDT || FIT
Tom Rinif18679c2023-08-02 11:09:43 -04001006 default 0x0
Simon Glassc48044d2019-10-27 09:47:40 -06001007 help
1008 Use this to change the assumptions made by libfdt about the
1009 device tree it is working with. A value of 0 means that no assumptions
1010 are made, and libfdt is able to deal with malicious data. A value of
1011 0xff means all assumptions are made and any invalid data may cause
1012 unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
1013
Maxime Ripard9e901ce2016-07-05 10:26:44 +02001014config OF_LIBFDT_OVERLAY
1015 bool "Enable the FDT library overlay support"
Tom Rinic1e49ba2018-05-08 08:52:17 -04001016 depends on OF_LIBFDT
Praneeth Bajjuri7b71a012018-04-25 16:03:23 -05001017 default y if ARCH_OMAP2PLUS || ARCH_KEYSTONE
Maxime Ripard9e901ce2016-07-05 10:26:44 +02001018 help
1019 This enables the FDT library (libfdt) overlay support.
1020
Tom Rinid2cd4312022-08-02 07:33:27 -04001021config SYS_FDT_PAD
Heinrich Schuchardt6f69e212025-03-02 16:02:31 +01001022 hex "Free space added to device-tree before booting"
Tom Rinid2cd4312022-08-02 07:33:27 -04001023 depends on OF_LIBFDT
1024 default 0x13000 if FMAN_ENET || QE || U_QE
1025 default 0x3000
1026 help
Heinrich Schuchardt6f69e212025-03-02 16:02:31 +01001027 The operating system may need a free area at the end of the device-
1028 tree for fix-ups. This setting defines by how many bytes U-Boot
1029 extends the device-tree before booting.
Tom Rinid2cd4312022-08-02 07:33:27 -04001030
Simon Glass8b426922016-02-22 22:55:45 -07001031config SPL_OF_LIBFDT
1032 bool "Enable the FDT library for SPL"
Simon Glasse7ca7da2022-04-30 00:56:53 -06001033 depends on SPL_LIBGENERIC_SUPPORT
Simon Glass8b426922016-02-22 22:55:45 -07001034 default y if SPL_OF_CONTROL
1035 help
1036 This enables the FDT library (libfdt). It provides functions for
1037 accessing binary device tree images in memory, such as adding and
Anatolij Gustschinda707d42017-08-18 17:58:51 +02001038 removing nodes and properties, scanning through the tree and finding
Simon Glass8b426922016-02-22 22:55:45 -07001039 particular compatible nodes. The library operates on a flattened
1040 version of the device tree.
1041
Simon Glassc48044d2019-10-27 09:47:40 -06001042config SPL_OF_LIBFDT_ASSUME_MASK
1043 hex "Mask of conditions to assume for libfdt"
Tom Rini0a83cc22022-06-10 23:03:09 -04001044 depends on SPL_OF_LIBFDT || (FIT && SPL)
Simon Glassc48044d2019-10-27 09:47:40 -06001045 default 0xff
1046 help
1047 Use this to change the assumptions made by libfdt in SPL about the
1048 device tree it is working with. A value of 0 means that no assumptions
1049 are made, and libfdt is able to deal with malicious data. A value of
1050 0xff means all assumptions are made and any invalid data may cause
1051 unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
1052
Simon Glassca8ec4b2018-10-01 12:22:21 -06001053config TPL_OF_LIBFDT
1054 bool "Enable the FDT library for TPL"
Simon Glasse7ca7da2022-04-30 00:56:53 -06001055 depends on TPL_LIBGENERIC_SUPPORT
Simon Glassca8ec4b2018-10-01 12:22:21 -06001056 default y if TPL_OF_CONTROL
1057 help
1058 This enables the FDT library (libfdt). It provides functions for
1059 accessing binary device tree images in memory, such as adding and
1060 removing nodes and properties, scanning through the tree and finding
1061 particular compatible nodes. The library operates on a flattened
1062 version of the device tree.
1063
Simon Glassc48044d2019-10-27 09:47:40 -06001064config TPL_OF_LIBFDT_ASSUME_MASK
1065 hex "Mask of conditions to assume for libfdt"
Tom Rini36a4ca02022-06-08 08:24:39 -04001066 depends on TPL_OF_LIBFDT || (FIT && TPL)
Simon Glassc48044d2019-10-27 09:47:40 -06001067 default 0xff
1068 help
1069 Use this to change the assumptions made by libfdt in TPL about the
1070 device tree it is working with. A value of 0 means that no assumptions
1071 are made, and libfdt is able to deal with malicious data. A value of
1072 0xff means all assumptions are made and any invalid data may cause
1073 unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
1074
Simon Glasse7ca7da2022-04-30 00:56:53 -06001075config VPL_OF_LIBFDT
1076 bool "Enable the FDT library for VPL"
Tom Rini7fb323b2022-06-08 08:24:40 -04001077 depends on VPL
Simon Glasse7ca7da2022-04-30 00:56:53 -06001078 default y if VPL_OF_CONTROL && !VPL_OF_PLATDATA
1079 help
1080 This enables the FDT library (libfdt). It provides functions for
1081 accessing binary device tree images in memory, such as adding and
1082 removing nodes and properties, scanning through the tree and finding
1083 particular compatible nodes. The library operates on a flattened
1084 version of the device tree.
1085
1086config VPL_OF_LIBFDT_ASSUME_MASK
1087 hex "Mask of conditions to assume for libfdt"
Tom Rini7fb323b2022-06-08 08:24:40 -04001088 depends on VPL_OF_LIBFDT || (FIT && VPL)
Simon Glasse7ca7da2022-04-30 00:56:53 -06001089 default 0xff
1090 help
1091 Use this to change the assumptions made by libfdt in SPL about the
1092 device tree it is working with. A value of 0 means that no assumptions
1093 are made, and libfdt is able to deal with malicious data. A value of
1094 0xff means all assumptions are made and any invalid data may cause
1095 unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
1096
Alexander Graffb228082016-08-19 01:23:23 +02001097menu "System tables"
Alexander Graf66f96e12016-08-19 01:23:29 +02001098 depends on (!EFI && !SYS_COREBOOT) || (ARM && EFI_LOADER)
Alexander Graffb228082016-08-19 01:23:23 +02001099
Simon Glass5d093f32020-11-04 09:57:25 -07001100config BLOBLIST_TABLES
1101 bool "Put tables in a bloblist"
Patrick Rudolphad392d52024-10-23 15:20:07 +02001102 depends on BLOBLIST
Simon Glass4d8c5202025-01-10 17:00:17 -07001103 default y if X86
Patrick Rudolphad392d52024-10-23 15:20:07 +02001104 default y if (ARM && EFI_LOADER && GENERATE_ACPI_TABLE)
1105 default n
Simon Glass5d093f32020-11-04 09:57:25 -07001106 help
Patrick Rudolphad392d52024-10-23 15:20:07 +02001107 On x86 normally tables are placed at address 0xf0000 and can be up
1108 to 64KB long. With this option, tables are instead placed in the
1109 bloblist with a pointer from 0xf0000. The size can then be larger
1110 and the tables can be placed high in memory.
1111 On other architectures the tables are always placed in high memory.
Simon Glass5d093f32020-11-04 09:57:25 -07001112
Alexander Graffb228082016-08-19 01:23:23 +02001113config GENERATE_SMBIOS_TABLE
1114 bool "Generate an SMBIOS (System Management BIOS) table"
Simon Glass5059dbe2023-09-19 21:00:13 -06001115 depends on SMBIOS
Alexander Graffb228082016-08-19 01:23:23 +02001116 default y
Alexander Graffb228082016-08-19 01:23:23 +02001117 help
1118 The System Management BIOS (SMBIOS) specification addresses how
1119 motherboard and system vendors present management information about
1120 their products in a standard format by extending the BIOS interface
1121 on Intel architecture systems.
1122
1123 Check http://www.dmtf.org/standards/smbios for details.
1124
Tom Rinid0dca222023-11-20 15:17:23 -05001125 See also SYSINFO_SMBIOS which allows SMBIOS values to be provided in
Simon Glass052a03e2020-11-05 06:32:11 -07001126 the devicetree.
1127
Raymond Maoa28ef802024-12-06 14:54:22 -08001128config GENERATE_SMBIOS_TABLE_VERBOSE
1129 bool "Generate a verbose SMBIOS (System Management BIOS) table"
1130 depends on GENERATE_SMBIOS_TABLE
1131 help
1132 Provide verbose SMBIOS information.
1133
Simon Glasse70648e2023-09-14 10:55:39 -06001134endmenu
1135
Tero Kristocfbe15c2021-06-11 11:45:02 +03001136config LIB_RATIONAL
1137 bool "enable continued fraction calculation routines"
1138
1139config SPL_LIB_RATIONAL
1140 bool "enable continued fraction calculation routines for SPL"
1141 depends on SPL
1142
AKASHI Takahirof7025262019-11-13 09:44:53 +09001143config ASN1_COMPILER
1144 bool
Philippe Reynes2aba9442022-03-28 22:56:54 +02001145 help
1146 ASN.1 (Abstract Syntax Notation One) is a standard interface
1147 description language for defining data structures that can be
1148 serialized and deserialized in a cross-platform way. It is
1149 broadly used in telecommunications and computer networking,
1150 and especially in cryptography (https://en.wikipedia.org/wiki/ASN.1).
1151 This option enables the support of the asn1 compiler.
AKASHI Takahirof7025262019-11-13 09:44:53 +09001152
AKASHI Takahiro3a888712019-11-13 09:44:55 +09001153config ASN1_DECODER
1154 bool
1155 help
Philippe Reynes2aba9442022-03-28 22:56:54 +02001156 ASN.1 (Abstract Syntax Notation One) is a standard interface
1157 description language for defining data structures that can be
1158 serialized and deserialized in a cross-platform way. It is
1159 broadly used in telecommunications and computer networking,
1160 and especially in cryptography (https://en.wikipedia.org/wiki/ASN.1).
1161 This option enables the support of the asn1 decoder.
AKASHI Takahiro3a888712019-11-13 09:44:55 +09001162
Philippe Reynescf538b52022-03-28 22:56:56 +02001163config SPL_ASN1_DECODER
1164 bool
1165 help
1166 ASN.1 (Abstract Syntax Notation One) is a standard interface
1167 description language for defining data structures that can be
1168 serialized and deserialized in a cross-platform way. It is
1169 broadly used in telecommunications and computer networking,
1170 and especially in cryptography (https://en.wikipedia.org/wiki/ASN.1).
1171 This option enables the support of the asn1 decoder in the SPL.
1172
AKASHI Takahiro54923642019-11-13 09:44:57 +09001173config OID_REGISTRY
1174 bool
1175 help
Philippe Reynese35c3a22022-03-28 22:56:55 +02001176 In computing, object identifiers or OIDs are an identifier mechanism
1177 standardized by the International Telecommunication Union (ITU) and
1178 ISO/IEC for naming any object, concept, or "thing" with a globally
1179 unambiguous persistent name (https://en.wikipedia.org/wiki/Object_identifier).
AKASHI Takahiro54923642019-11-13 09:44:57 +09001180 Enable fast lookup object identifier registry.
1181
Philippe Reynescf538b52022-03-28 22:56:56 +02001182config SPL_OID_REGISTRY
1183 bool
1184 help
1185 In computing, object identifiers or OIDs are an identifier mechanism
1186 standardized by the International Telecommunication Union (ITU) and
1187 ISO/IEC for naming any object, concept, or "thing" with a globally
1188 unambiguous persistent name (https://en.wikipedia.org/wiki/Object_identifier).
1189 Enable fast lookup object identifier registry in the SPL.
1190
Simon Glass5059dbe2023-09-19 21:00:13 -06001191config SMBIOS
1192 bool "SMBIOS support"
1193 depends on X86 || EFI_LOADER
1194 default y
Simon Glassaadec122023-09-20 07:29:51 -06001195 select LAST_STAGE_INIT
Simon Glass5059dbe2023-09-19 21:00:13 -06001196 help
1197 Indicates that this platform can support System Management BIOS
1198 (SMBIOS) tables. These provide various pieces of information about
1199 the board, such as the manufacturer and the model name.
1200
1201 See GENERATE_SMBIOS_TABLE which controls whether U-Boot actually
1202 creates these tables, rather than them coming from a previous firmware
1203 stage.
1204
Christian Gmeiner19859982020-11-03 15:34:51 +01001205config SMBIOS_PARSER
1206 bool "SMBIOS parser"
1207 help
1208 A simple parser for SMBIOS data.
1209
Michal Simekdd5000ef2024-04-16 08:55:16 +02001210source "lib/optee/Kconfig"
Simon Glass9539e692015-07-31 09:31:36 -06001211
Thierry Reding52c7f1f32019-03-21 19:10:04 +01001212config TEST_FDTDEC
1213 bool "enable fdtdec test"
1214 depends on OF_LIBFDT
1215
AKASHI Takahiro51ba5222019-11-13 09:44:49 +09001216config LIB_DATE
1217 bool
1218
Keerthy76f361a2020-02-12 13:55:03 +05301219config LIB_ELF
1220 bool
1221 help
Patrick Delaunayfb67df82021-01-04 15:33:28 +01001222 Support basic elf loading/validating functions.
1223 This supports for 32 bit and 64 bit versions.
Keerthy76f361a2020-02-12 13:55:03 +05301224
Patrick Delaunayd62063d2021-03-10 10:16:25 +01001225config LMB
1226 bool "Enable the logical memory blocks library (lmb)"
Tom Rini53320122022-04-06 09:21:25 -04001227 default y if ARC || ARM || M68K || MICROBLAZE || MIPS || \
Patrick Delaunayd62063d2021-03-10 10:16:25 +01001228 NIOS2 || PPC || RISCV || SANDBOX || SH || X86 || XTENSA
Sughosh Ganuad3b6e92024-08-26 17:29:29 +05301229 select ARCH_MISC_INIT if PPC
Patrick Delaunayd62063d2021-03-10 10:16:25 +01001230 help
Sughosh Ganu69db78f2024-08-26 17:29:21 +05301231 Support the library logical memory blocks. This will require
1232 a malloc() implementation for defining the data structures
1233 needed for maintaining the LMB memory map.
1234
1235config SPL_LMB
1236 bool "Enable LMB module for SPL"
1237 depends on SPL && SPL_FRAMEWORK && SPL_SYS_MALLOC
1238 help
1239 Enable support for Logical Memory Block library routines in
1240 SPL. This will require a malloc() implementation for defining
1241 the data structures needed for maintaining the LMB memory map.
Patrick Delaunayd62063d2021-03-10 10:16:25 +01001242
Sughosh Ganu1a36d442024-10-15 21:07:11 +05301243config LMB_ARCH_MEM_MAP
1244 bool "Add an architecture specific memory map"
1245 depends on LMB
Sughosh Ganu526eebd2024-10-15 21:07:13 +05301246 default y if FSL_LAYERSCAPE || X86
Sughosh Ganu1a36d442024-10-15 21:07:11 +05301247 help
1248 Some architectures have special or unique aspects which need
1249 consideration when adding memory ranges to the list of available
1250 memory map. Enable this config in such scenarios which allow
1251 architectures and boards to define their own memory map.
1252
1253config SPL_LMB_ARCH_MEM_MAP
1254 bool "Add an architecture specific memory map"
1255 depends on SPL_LMB
1256 help
1257 Some architectures have special or unique scenarios which need
1258 consideration when adding memory ranges to the list of available
1259 memory map. Enable this config in such scenarios which allow
1260 architectures and boards to define their own memory map.
1261
Simon Glass42d97e52022-12-21 16:08:28 -07001262config PHANDLE_CHECK_SEQ
1263 bool "Enable phandle check while getting sequence number"
1264 help
1265 When there are multiple device tree nodes with same name,
Anand Moon6c368f42024-06-23 23:10:21 +05301266 enable this config option to distinguish them using
Simon Glass42d97e52022-12-21 16:08:28 -07001267 phandles in fdtdec_get_alias_seq() function.
1268
Jerome Forissierc14cfee2025-04-18 16:09:34 +02001269config UTHREAD
1270 bool "Enable thread support"
1271 depends on HAVE_INITJMP
1272 help
1273 Implement a simple form of cooperative multi-tasking based on
1274 context-switching via initjmp(), setjmp() and longjmp(). The
1275 uthread_ interface enables the main thread of execution to create
1276 one or more secondary threads and schedule them until they all have
1277 returned. At any point a thread may suspend its execution and
1278 schedule another thread, which allows for the efficient multiplexing
1279 of leghthy operations.
1280
1281config UTHREAD_STACK_SIZE
1282 int "Default uthread stack size"
1283 depends on UTHREAD
1284 default 32768
1285 help
1286 The default stack size for uthreads. Each uthread has its own stack.
1287 When the stack_sz argument to uthread_create() is zero then this
1288 value is used.
1289
Eugen Hristevdb6bbcb2022-01-04 18:20:19 +02001290endmenu
Sughosh Ganu1cadae22022-10-21 18:16:03 +05301291
Michal Simekdd5000ef2024-04-16 08:55:16 +02001292source "lib/fwu_updates/Kconfig"