Merge https://source.denx.de/u-boot/custodians/u-boot-riscv
[platform/kernel/u-boot.git] / lib / Kconfig
1 menu "Library routines"
2
3 config 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
9           This library only works in the post-relocation phase.
10
11 config 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
18 config PHYSMEM
19         bool "Access to physical memory region (> 4G)"
20         help
21           Some basic support is provided for operations on memory not
22           normally accessible to 32-bit U-Boot - e.g. some architectures
23           support access to more than 4G of memory on 32-bit
24           machines using physical address extension or similar.
25           Enable this to access this basic support, which only supports clearing
26           the memory.
27
28 config BCH
29         bool "Enable Software based BCH ECC"
30         help
31           Enables software based BCH ECC algorithm present in lib/bch.c
32           This is used by SoC platforms which do not have built-in ELM
33           hardware engine required for BCH ECC correction.
34
35 config BINMAN_FDT
36         bool "Allow access to binman information in the device tree"
37         depends on BINMAN && DM && OF_CONTROL
38         default y if OF_SEPARATE || OF_EMBED
39         help
40           This enables U-Boot to access information about binman entries,
41           stored in the device tree in a binman node. Typical uses are to
42           locate entries in the firmware image. See binman.h for the available
43           functionality.
44
45 config CC_OPTIMIZE_LIBS_FOR_SPEED
46         bool "Optimize libraries for speed"
47         help
48           Enabling this option will pass "-O2" to gcc when compiling
49           under "lib" directory.
50
51           If unsure, say N.
52
53 config CHARSET
54         bool
55
56 config DYNAMIC_CRC_TABLE
57         bool "Enable Dynamic tables for CRC"
58         help
59           Enable this option to calculate entries for CRC tables at runtime.
60           This can be helpful when reducing the size of the build image
61
62 config HAVE_ARCH_IOMAP
63         bool
64         help
65           Enable this option if architecture provides io{read,write}{8,16,32}
66           I/O accessor functions.
67
68 config HAVE_PRIVATE_LIBGCC
69         bool
70
71 config LIB_UUID
72         bool
73
74 config SEMIHOSTING
75         bool "Support semihosting"
76         depends on ARM || RISCV
77         help
78           Semihosting is a method for a target to communicate with a host
79           debugger. It uses special instructions which the debugger will trap
80           on and interpret. This allows U-Boot to read/write files, print to
81           the console, and execute arbitrary commands on the host system.
82
83           Enabling this option will add support for reading and writing files
84           on the host system. If you don't have a debugger attached then trying
85           to do this will likely cause U-Boot to hang. Say 'n' if you are unsure.
86
87 config SEMIHOSTING_FALLBACK
88         bool "Recover gracefully when semihosting fails"
89         depends on SEMIHOSTING && (ARM64 || RISCV)
90         default y
91         help
92           Normally, if U-Boot makes a semihosting call and no debugger is
93           attached, then it will panic due to a synchronous abort
94           exception. This config adds an exception handler which will allow
95           U-Boot to recover. Say 'y' if unsure.
96
97 config SPL_SEMIHOSTING
98         bool "Support semihosting in SPL"
99         depends on SPL && (ARM || RISCV)
100         help
101           Semihosting is a method for a target to communicate with a host
102           debugger. It uses special instructions which the debugger will trap
103           on and interpret. This allows U-Boot to read/write files, print to
104           the console, and execute arbitrary commands on the host system.
105
106           Enabling this option will add support for reading and writing files
107           on the host system. If you don't have a debugger attached then trying
108           to do this will likely cause U-Boot to hang. Say 'n' if you are unsure.
109
110 config SPL_SEMIHOSTING_FALLBACK
111         bool "Recover gracefully when semihosting fails in SPL"
112         depends on SPL_SEMIHOSTING && (ARM64 || RISCV)
113         select ARMV8_SPL_EXCEPTION_VECTORS if ARM64
114         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
121 config PRINTF
122         bool
123         default y
124
125 config SPL_PRINTF
126         bool
127         select SPL_SPRINTF
128         select SPL_STRTO if !SPL_USE_TINY_PRINTF
129
130 config TPL_PRINTF
131         bool
132         select TPL_SPRINTF
133         select TPL_STRTO if !TPL_USE_TINY_PRINTF
134
135 config VPL_PRINTF
136         bool
137         select VPL_SPRINTF
138         select VPL_STRTO if !VPL_USE_TINY_PRINTF
139
140 config SPRINTF
141         bool
142         default y
143
144 config SPL_SPRINTF
145         bool
146
147 config TPL_SPRINTF
148         bool
149
150 config VPL_SPRINTF
151         bool
152
153 config SSCANF
154         bool
155
156 config STRTO
157         bool
158         default y
159
160 config SPL_STRTO
161         bool
162
163 config TPL_STRTO
164         bool
165
166 config VPL_STRTO
167         bool
168
169 config IMAGE_SPARSE
170         bool
171
172 config IMAGE_SPARSE_FILLBUF_SIZE
173         hex "Android sparse image CHUNK_TYPE_FILL buffer size"
174         default 0x80000
175         depends on IMAGE_SPARSE
176         help
177           Set the size of the fill buffer used when processing CHUNK_TYPE_FILL
178           chunks.
179
180 config USE_PRIVATE_LIBGCC
181         bool "Use private libgcc"
182         depends on HAVE_PRIVATE_LIBGCC
183         default y if HAVE_PRIVATE_LIBGCC && ((ARM && !ARM64) || MIPS)
184         help
185           This option allows you to use the built-in libgcc implementation
186           of U-Boot instead of the one provided by the compiler.
187           If unsure, say N.
188
189 config SYS_HZ
190         int
191         default 1000
192         help
193           The frequency of the timer returned by get_timer().
194           get_timer() must operate in milliseconds and this option must be
195           set to 1000.
196
197 config SPL_USE_TINY_PRINTF
198         bool "Enable tiny printf() version in SPL"
199         depends on SPL
200         default y
201         help
202           This option enables a tiny, stripped down printf version.
203           This should only be used in space limited environments,
204           like SPL versions with hard memory limits. This version
205           reduces the code size by about 2.5KiB on armv7.
206
207           The supported format specifiers are %c, %s, %u/%d and %x.
208
209 config TPL_USE_TINY_PRINTF
210         bool "Enable tiny printf() version in TPL"
211         depends on TPL
212         default y if SPL_USE_TINY_PRINTF
213         help
214           This option enables a tiny, stripped down printf version.
215           This should only be used in space limited environments,
216           like SPL versions with hard memory limits. This version
217           reduces the code size by about 2.5KiB on armv7.
218
219           The supported format specifiers are %c, %s, %u/%d and %x.
220
221 config VPL_USE_TINY_PRINTF
222         bool "Enable tiny printf() version for VPL"
223         depends on VPL
224         help
225           This option enables a tiny, stripped down printf version.
226           This should only be used in space limited environments,
227           like SPL versions with hard memory limits. This version
228           reduces the code size by about 2.5KiB on armv7.
229
230           The supported format specifiers are %c, %s, %u/%d and %x.
231
232 config PANIC_HANG
233         bool "Do not reset the system on fatal error"
234         help
235           Define this option to stop the system in case of a fatal error,
236           so that you have to reset it manually. This is probably NOT a good
237           idea for an embedded system where you want the system to reboot
238           automatically as fast as possible, but it may be useful during
239           development since you can try to debug the conditions that lead to
240           the situation.
241
242 config REGEX
243         bool "Enable regular expression support"
244         default y if NET
245         help
246           If this variable is defined, U-Boot is linked against the
247           SLRE (Super Light Regular Expression) library, which adds
248           regex support to some commands, for example "env grep" and
249           "setexpr".
250
251 choice
252         prompt "Pseudo-random library support type"
253         depends on NET_RANDOM_ETHADDR || RANDOM_UUID || CMD_UUID || \
254                    RNG_SANDBOX || UT_LIB && AES || FAT_WRITE
255         default LIB_RAND
256         help
257           Select the library to provide pseudo-random number generator
258           functions.  LIB_HW_RAND supports certain hardware engines that
259           provide this functionality.  If in doubt, select LIB_RAND.
260
261 config LIB_RAND
262         bool "Pseudo-random library support"
263
264 config LIB_HW_RAND
265         bool "HW Engine for random library support"
266
267 endchoice
268
269 config SUPPORT_ACPI
270         bool
271         help
272           Enable this if your arch or board can support generating ACPI
273           (Advanced Configuration and Power Interface) tables. In this case
274           U-Boot can generate these tables and pass them to the Operating
275           System.
276
277 config GENERATE_ACPI_TABLE
278         bool "Generate an ACPI (Advanced Configuration and Power Interface) table"
279         depends on SUPPORT_ACPI
280         select QFW if QEMU
281         help
282           The Advanced Configuration and Power Interface (ACPI) specification
283           provides an open standard for device configuration and management
284           by the operating system. It defines platform-independent interfaces
285           for configuration and power management monitoring.
286
287 config SPL_TINY_MEMSET
288         bool "Use a very small memset() in SPL"
289         depends on SPL
290         help
291           The faster memset() is the arch-specific one (if available) enabled
292           by CONFIG_USE_ARCH_MEMSET. If that is not enabled, we can still get
293           better performance by writing a word at a time. But in very
294           size-constrained environments even this may be too big. Enable this
295           option to reduce code size slightly at the cost of some speed.
296
297 config TPL_TINY_MEMSET
298         bool "Use a very small memset() in TPL"
299         depends on TPL
300         help
301           The faster memset() is the arch-specific one (if available) enabled
302           by CONFIG_USE_ARCH_MEMSET. If that is not enabled, we can still get
303           better performance by writing a word at a time. But in very
304           size-constrained environments even this may be too big. Enable this
305           option to reduce code size slightly at the cost of some speed.
306
307 config RBTREE
308         bool
309
310 config BITREVERSE
311         bool "Bit reverse library from Linux"
312
313 config TRACE
314         bool "Support for tracing of function calls and timing"
315         imply CMD_TRACE
316         select TIMER_EARLY
317         help
318           Enables function tracing within U-Boot. This allows recording of call
319           traces including timing information. The command can write data to
320           memory for exporting for analysis (e.g. using bootchart).
321           See doc/README.trace for full details.
322
323 config TRACE_BUFFER_SIZE
324         hex "Size of trace buffer in U-Boot"
325         depends on TRACE
326         default 0x01000000
327         help
328           Sets the size of the trace buffer in U-Boot. This is allocated from
329           memory during relocation. If this buffer is too small, the trace
330           history will be truncated, with later records omitted.
331
332           If early trace is enabled (i.e. before relocation), this buffer must
333           be large enough to include all the data from the early trace buffer as
334           well, since this is copied over to the main buffer during relocation.
335
336           A trace record is emitted for each function call and each record is
337           12 bytes (see struct trace_call). A suggested minimum size is 1MB. If
338           the size is too small then 'trace stats' will show a message saying
339           how many records were dropped due to buffer overflow.
340
341 config TRACE_CALL_DEPTH_LIMIT
342         int "Trace call depth limit"
343         depends on TRACE
344         default 15
345         help
346           Sets the maximum call depth up to which function calls are recorded.
347
348 config TRACE_EARLY
349         bool "Enable tracing before relocation"
350         depends on TRACE
351         help
352           Sometimes it is helpful to trace execution of U-Boot before
353           relocation. This is possible by using a arch-specific, fixed buffer
354           position in memory. Enable this option to start tracing as early as
355           possible after U-Boot starts.
356
357 config TRACE_EARLY_SIZE
358         hex "Size of early trace buffer in U-Boot"
359         depends on TRACE_EARLY
360         default 0x00100000
361         help
362           Sets the size of the early trace buffer in bytes. This is used to hold
363           tracing information before relocation.
364
365 config TRACE_EARLY_CALL_DEPTH_LIMIT
366         int "Early trace call depth limit"
367         depends on TRACE_EARLY
368         default 200
369         help
370           Sets the maximum call depth up to which function calls are recorded
371           during early tracing.
372
373 config TRACE_EARLY_ADDR
374         hex "Address of early trace buffer in U-Boot"
375         depends on TRACE_EARLY
376         default 0x00100000
377         help
378           Sets the address of the early trace buffer in U-Boot. This memory
379           must be accessible before relocation.
380
381           A trace record is emitted for each function call and each record is
382           12 bytes (see struct trace_call). A suggested minimum size is 1MB. If
383           the size is too small then the message which says the amount of early
384           data being coped will the the same as the
385
386 config CIRCBUF
387         bool "Enable circular buffer support"
388
389 source lib/dhry/Kconfig
390
391 menu "Security support"
392
393 config AES
394         bool "Support the AES algorithm"
395         help
396           This provides a means to encrypt and decrypt data using the AES
397           (Advanced Encryption Standard). This algorithm uses a symetric key
398           and is widely used as a streaming cipher. Different key lengths are
399           supported by the algorithm but only a 128-bit key is supported at
400           present.
401
402 source lib/ecdsa/Kconfig
403 source lib/rsa/Kconfig
404 source lib/crypto/Kconfig
405 source lib/crypt/Kconfig
406
407 config TPM
408         bool "Trusted Platform Module (TPM) Support"
409         depends on DM
410         imply DM_RNG
411         help
412           This enables support for TPMs which can be used to provide security
413           features for your board. The TPM can be connected via LPC or I2C
414           and a sandbox TPM is provided for testing purposes. Use the 'tpm'
415           command to interactive the TPM. Driver model support is provided
416           for the low-level TPM interface, but only one TPM is supported at
417           a time by the TPM library.
418
419 config SPL_TPM
420         bool "Trusted Platform Module (TPM) Support in SPL"
421         depends on SPL_DM
422         help
423           This enables support for TPMs which can be used to provide security
424           features for your board. The TPM can be connected via LPC or I2C
425           and a sandbox TPM is provided for testing purposes. Use the 'tpm'
426           command to interactive the TPM. Driver model support is provided
427           for the low-level TPM interface, but only one TPM is supported at
428           a time by the TPM library.
429
430 config TPL_TPM
431         bool "Trusted Platform Module (TPM) Support in TPL"
432         depends on TPL_DM
433         help
434           This enables support for TPMs which can be used to provide security
435           features for your board. The TPM can be connected via LPC or I2C
436           and a sandbox TPM is provided for testing purposes. Use the 'tpm'
437           command to interactive the TPM. Driver model support is provided
438           for the low-level TPM interface, but only one TPM is supported at
439           a time by the TPM library.
440
441 config VPL_TPM
442         bool "Trusted Platform Module (TPM) Support in VPL"
443         depends on VPL_DM
444         help
445           This enables support for TPMs which can be used to provide security
446           features for your board. The TPM can be connected via LPC or I2C
447           and a sandbox TPM is provided for testing purposes. Use the 'tpm'
448           command to interactive the TPM. Driver model support is provided
449           for the low-level TPM interface, but only one TPM is supported at
450           a time by the TPM library.
451
452 endmenu
453
454 menu "Android Verified Boot"
455
456 config LIBAVB
457         bool "Android Verified Boot 2.0 support"
458         depends on ANDROID_BOOT_IMAGE
459         help
460           This enables support of Android Verified Boot 2.0 which can be used
461           to assure the end user of the integrity of the software running on a
462           device. Introduces such features as boot chain of trust, rollback
463           protection etc.
464
465 endmenu
466
467 menu "Hashing Support"
468
469 config BLAKE2
470         bool "Enable BLAKE2 support"
471         help
472           This option enables support of hashing using BLAKE2B algorithm.
473           The hash is calculated in software.
474           The BLAKE2 algorithm produces a hash value (digest) between 1 and
475           64 bytes.
476
477 config SHA1
478         bool "Enable SHA1 support"
479         help
480           This option enables support of hashing using SHA1 algorithm.
481           The hash is calculated in software.
482           The SHA1 algorithm produces a 160-bit (20-byte) hash value
483           (digest).
484
485 config SHA256
486         bool "Enable SHA256 support"
487         help
488           This option enables support of hashing using SHA256 algorithm.
489           The hash is calculated in software.
490           The SHA256 algorithm produces a 256-bit (32-byte) hash value
491           (digest).
492
493 config SHA512
494         bool "Enable SHA512 support"
495         help
496           This option enables support of hashing using SHA512 algorithm.
497           The hash is calculated in software.
498           The SHA512 algorithm produces a 512-bit (64-byte) hash value
499           (digest).
500
501 config SHA384
502         bool "Enable SHA384 support"
503         select SHA512
504         help
505           This option enables support of hashing using SHA384 algorithm.
506           The hash is calculated in software. This is also selects SHA512,
507           because these implementations share the bulk of the code..
508           The SHA384 algorithm produces a 384-bit (48-byte) hash value
509           (digest).
510
511 config SHA_HW_ACCEL
512         bool "Enable hardware acceleration for SHA hash functions"
513         help
514           This option enables hardware acceleration for the SHA1 and SHA256
515           hashing algorithms. This affects the 'hash' command and also the
516           hash_lookup_algo() function.
517
518 if SPL
519
520 config SPL_SHA1
521         bool "Enable SHA1 support in SPL"
522         default y if SHA1
523         help
524           This option enables support of hashing using SHA1 algorithm.
525           The hash is calculated in software.
526           The SHA1 algorithm produces a 160-bit (20-byte) hash value
527           (digest).
528
529 config SPL_SHA256
530         bool "Enable SHA256 support in SPL"
531         default y if SHA256
532         help
533           This option enables support of hashing using SHA256 algorithm.
534           The hash is calculated in software.
535           The SHA256 algorithm produces a 256-bit (32-byte) hash value
536           (digest).
537
538 config SPL_SHA512
539         bool "Enable SHA512 support in SPL"
540         default y if SHA512
541         help
542           This option enables support of hashing using SHA512 algorithm.
543           The hash is calculated in software.
544           The SHA512 algorithm produces a 512-bit (64-byte) hash value
545           (digest).
546
547 config SPL_SHA384
548         bool "Enable SHA384 support in SPL"
549         default y if SHA384
550         select SPL_SHA512
551         help
552           This option enables support of hashing using SHA384 algorithm.
553           The hash is calculated in software. This is also selects SHA512,
554           because these implementations share the bulk of the code..
555           The SHA384 algorithm produces a 384-bit (48-byte) hash value
556           (digest).
557
558 config SPL_SHA_HW_ACCEL
559         bool "Enable hardware acceleration for SHA hash functions"
560         default y if SHA_HW_ACCEL
561         help
562           This option enables hardware acceleration for the SHA1 and SHA256
563           hashing algorithms. This affects the 'hash' command and also the
564           hash_lookup_algo() function.
565
566 config SPL_SHA_PROG_HW_ACCEL
567         bool "Enable Progressive hashing support using hardware in SPL"
568         depends on SHA_PROG_HW_ACCEL
569         default y
570         help
571           This option enables hardware-acceleration for SHA progressive
572           hashing.
573           Data can be streamed in a block at a time and the hashing is
574           performed in hardware.
575
576 endif
577
578 if SHA_HW_ACCEL
579
580 config SHA512_HW_ACCEL
581         bool "Enable hardware acceleration for SHA512"
582         depends on SHA512
583         help
584           This option enables hardware acceleration for the SHA384 and SHA512
585           hashing algorithms. This affects the 'hash' command and also the
586           hash_lookup_algo() function.
587
588 config SHA_PROG_HW_ACCEL
589         bool "Enable Progressive hashing support using hardware"
590         help
591           This option enables hardware-acceleration for SHA progressive
592           hashing.
593           Data can be streamed in a block at a time and the hashing is
594           performed in hardware.
595
596 endif
597
598 config MD5
599         bool "Support MD5 algorithm"
600         help
601           This option enables MD5 support. MD5 is an algorithm designed
602           in 1991 that produces a 16-byte digest (or checksum) from its input
603           data. It has a number of vulnerabilities which preclude its use in
604           security applications, but it can be useful for providing a quick
605           checksum of a block of data.
606
607 config SPL_MD5
608         bool "Support MD5 algorithm in SPL"
609         depends on SPL
610         help
611           This option enables MD5 support in SPL. MD5 is an algorithm designed
612           in 1991 that produces a 16-byte digest (or checksum) from its input
613           data. It has a number of vulnerabilities which preclude its use in
614           security applications, but it can be useful for providing a quick
615           checksum of a block of data.
616
617 config CRC32
618         def_bool y
619         help
620           Enables CRC32 support in U-Boot. This is normally required.
621
622 config CRC32C
623         bool
624
625 config XXHASH
626         bool
627
628 endmenu
629
630 menu "Compression Support"
631
632 config LZ4
633         bool "Enable LZ4 decompression support"
634         help
635           If this option is set, support for LZ4 compressed images
636           is included. The LZ4 algorithm can run in-place as long as the
637           compressed image is loaded to the end of the output buffer, and
638           trades lower compression ratios for much faster decompression.
639
640           NOTE: This implements the release version of the LZ4 frame
641           format as generated by default by the 'lz4' command line tool.
642           This is not the same as the outdated, less efficient legacy
643           frame format currently (2015) implemented in the Linux kernel
644           (generated by 'lz4 -l'). The two formats are incompatible.
645
646 config LZMA
647         bool "Enable LZMA decompression support"
648         help
649           This enables support for LZMA (Lempel-Ziv-Markov chain algorithm),
650           a dictionary compression algorithm that provides a high compression
651           ratio and fairly fast decompression speed. See also
652           CONFIG_CMD_LZMADEC which provides a decode command.
653
654 config LZO
655         bool "Enable LZO decompression support"
656         help
657           This enables support for the LZO compression algorithm.
658
659 config GZIP
660         bool "Enable gzip decompression support"
661         select ZLIB
662         default y
663         help
664           This enables support for GZIP compression algorithm.
665
666 config ZLIB_UNCOMPRESS
667         bool "Enables zlib's uncompress() functionality"
668         help
669           This enables an extra zlib functionality: the uncompress() function,
670           which decompresses data from a buffer into another, knowing their
671           sizes. Unlike gunzip(), there is no header parsing.
672
673 config GZIP_COMPRESSED
674         bool
675         select ZLIB
676
677 config BZIP2
678         bool "Enable bzip2 decompression support"
679         help
680           This enables support for BZIP2 compression algorithm.
681
682 config ZLIB
683         bool
684         default y
685         help
686           This enables ZLIB compression lib.
687
688 config ZSTD
689         bool "Enable Zstandard decompression support"
690         select XXHASH
691         help
692           This enables Zstandard decompression library.
693
694 config SPL_LZ4
695         bool "Enable LZ4 decompression support in SPL"
696         depends on SPL
697         help
698           This enables support for the LZ4 decompression algorithm in SPL. LZ4
699           is a lossless data compression algorithm that is focused on
700           fast compression and decompression speed. It belongs to the LZ77
701           family of byte-oriented compression schemes.
702
703 config SPL_LZMA
704         bool "Enable LZMA decompression support for SPL build"
705         depends on SPL
706         help
707           This enables support for LZMA compression algorithm for SPL boot.
708
709 config VPL_LZMA
710         bool "Enable LZMA decompression support for VPL build"
711         default y if LZMA
712         help
713           This enables support for LZMA compression algorithm for VPL boot.
714
715 config SPL_LZO
716         bool "Enable LZO decompression support in SPL"
717         depends on SPL
718         help
719           This enables support for LZO compression algorithm in the SPL.
720
721 config SPL_GZIP
722         bool "Enable gzip decompression support for SPL build"
723         select SPL_ZLIB
724         help
725           This enables support for the GZIP compression algorithm for SPL boot.
726
727 config SPL_ZLIB
728         bool
729         help
730           This enables compression lib for SPL boot.
731
732 config SPL_ZSTD
733         bool "Enable Zstandard decompression support in SPL"
734         depends on SPL
735         select XXHASH
736         help
737           This enables Zstandard decompression library in the SPL.
738
739 endmenu
740
741 config ERRNO_STR
742         bool "Enable function for getting errno-related string message"
743         help
744           The function errno_str(int errno), returns a pointer to the errno
745           corresponding text message:
746           - if errno is null or positive number - a pointer to "Success" message
747           - if errno is negative - a pointer to errno related message
748
749 config HEXDUMP
750         bool "Enable hexdump"
751         help
752           This enables functions for printing dumps of binary data.
753
754 config SPL_HEXDUMP
755         bool "Enable hexdump in SPL"
756         depends on SPL && HEXDUMP
757         help
758           This enables functions for printing dumps of binary data in
759           SPL.
760
761 config GETOPT
762         bool "Enable getopt"
763         help
764           This enables functions for parsing command-line options.
765
766 config OF_LIBFDT
767         bool "Enable the FDT library"
768         default y if OF_CONTROL
769         help
770           This enables the FDT library (libfdt). It provides functions for
771           accessing binary device tree images in memory, such as adding and
772           removing nodes and properties, scanning through the tree and finding
773           particular compatible nodes. The library operates on a flattened
774           version of the device tree.
775
776 config OF_LIBFDT_ASSUME_MASK
777         hex "Mask of conditions to assume for libfdt"
778         depends on OF_LIBFDT || FIT
779         default 0
780         help
781           Use this to change the assumptions made by libfdt about the
782           device tree it is working with. A value of 0 means that no assumptions
783           are made, and libfdt is able to deal with malicious data. A value of
784           0xff means all assumptions are made and any invalid data may cause
785           unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
786
787 config OF_LIBFDT_OVERLAY
788         bool "Enable the FDT library overlay support"
789         depends on OF_LIBFDT
790         default y if ARCH_OMAP2PLUS || ARCH_KEYSTONE
791         help
792           This enables the FDT library (libfdt) overlay support.
793
794 config SYS_FDT_PAD
795         hex "Maximum size of the FDT memory area passeed to the OS"
796         depends on OF_LIBFDT
797         default 0x13000 if FMAN_ENET || QE || U_QE
798         default 0x3000
799         help
800           During OS boot, we allocate a region of memory within the bootmap
801           for the FDT. This is the size that we will expand the FDT that we
802           are using will be extended to be, in bytes.
803
804 config SPL_OF_LIBFDT
805         bool "Enable the FDT library for SPL"
806         depends on SPL_LIBGENERIC_SUPPORT
807         default y if SPL_OF_CONTROL
808         help
809           This enables the FDT library (libfdt). It provides functions for
810           accessing binary device tree images in memory, such as adding and
811           removing nodes and properties, scanning through the tree and finding
812           particular compatible nodes. The library operates on a flattened
813           version of the device tree.
814
815 config SPL_OF_LIBFDT_ASSUME_MASK
816         hex "Mask of conditions to assume for libfdt"
817         depends on SPL_OF_LIBFDT || (FIT && SPL)
818         default 0xff
819         help
820           Use this to change the assumptions made by libfdt in SPL about the
821           device tree it is working with. A value of 0 means that no assumptions
822           are made, and libfdt is able to deal with malicious data. A value of
823           0xff means all assumptions are made and any invalid data may cause
824           unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
825
826 config TPL_OF_LIBFDT
827         bool "Enable the FDT library for TPL"
828         depends on TPL_LIBGENERIC_SUPPORT
829         default y if TPL_OF_CONTROL
830         help
831           This enables the FDT library (libfdt). It provides functions for
832           accessing binary device tree images in memory, such as adding and
833           removing nodes and properties, scanning through the tree and finding
834           particular compatible nodes. The library operates on a flattened
835           version of the device tree.
836
837 config TPL_OF_LIBFDT_ASSUME_MASK
838         hex "Mask of conditions to assume for libfdt"
839         depends on TPL_OF_LIBFDT || (FIT && TPL)
840         default 0xff
841         help
842           Use this to change the assumptions made by libfdt in TPL about the
843           device tree it is working with. A value of 0 means that no assumptions
844           are made, and libfdt is able to deal with malicious data. A value of
845           0xff means all assumptions are made and any invalid data may cause
846           unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
847
848 config VPL_OF_LIBFDT
849         bool "Enable the FDT library for VPL"
850         depends on VPL
851         default y if VPL_OF_CONTROL && !VPL_OF_PLATDATA
852         help
853           This enables the FDT library (libfdt). It provides functions for
854           accessing binary device tree images in memory, such as adding and
855           removing nodes and properties, scanning through the tree and finding
856           particular compatible nodes. The library operates on a flattened
857           version of the device tree.
858
859 config VPL_OF_LIBFDT_ASSUME_MASK
860         hex "Mask of conditions to assume for libfdt"
861         depends on VPL_OF_LIBFDT || (FIT && VPL)
862         default 0xff
863         help
864           Use this to change the assumptions made by libfdt in SPL about the
865           device tree it is working with. A value of 0 means that no assumptions
866           are made, and libfdt is able to deal with malicious data. A value of
867           0xff means all assumptions are made and any invalid data may cause
868           unsafe execution. See FDT_ASSUME_PERFECT, etc. in libfdt_internal.h
869
870 config FDT_FIXUP_PARTITIONS
871         bool "overwrite MTD partitions in DTS through defined in 'mtdparts'"
872         depends on OF_LIBFDT
873         depends on CMD_MTDPARTS
874         help
875           Allow overwriting defined partitions in the device tree blob
876           using partition info defined in the 'mtdparts' environment
877           variable.
878
879 menu "System tables"
880         depends on (!EFI && !SYS_COREBOOT) || (ARM && EFI_LOADER)
881
882 config BLOBLIST_TABLES
883         bool "Put tables in a bloblist"
884         depends on X86 && BLOBLIST
885         help
886           Normally tables are placed at address 0xf0000 and can be up to 64KB
887           long. With this option, tables are instead placed in the bloblist
888           with a pointer from 0xf0000. The size can then be larger and the
889           tables can be placed high in memory.
890
891 config GENERATE_SMBIOS_TABLE
892         bool "Generate an SMBIOS (System Management BIOS) table"
893         default y
894         depends on X86 || EFI_LOADER
895         help
896           The System Management BIOS (SMBIOS) specification addresses how
897           motherboard and system vendors present management information about
898           their products in a standard format by extending the BIOS interface
899           on Intel architecture systems.
900
901           Check http://www.dmtf.org/standards/smbios for details.
902
903           See also SMBIOS_SYSINFO which allows SMBIOS values to be provided in
904           the devicetree.
905
906 config LIB_RATIONAL
907         bool "enable continued fraction calculation routines"
908
909 config SPL_LIB_RATIONAL
910         bool "enable continued fraction calculation routines for SPL"
911         depends on SPL
912
913 endmenu
914
915 config ASN1_COMPILER
916         bool
917         help
918           ASN.1 (Abstract Syntax Notation One) is a standard interface
919           description language for defining data structures that can be
920           serialized and deserialized in a cross-platform way. It is
921           broadly used in telecommunications and computer networking,
922           and especially in cryptography (https://en.wikipedia.org/wiki/ASN.1).
923           This option enables the support of the asn1 compiler.
924
925 config ASN1_DECODER
926         bool
927         help
928           ASN.1 (Abstract Syntax Notation One) is a standard interface
929           description language for defining data structures that can be
930           serialized and deserialized in a cross-platform way. It is
931           broadly used in telecommunications and computer networking,
932           and especially in cryptography (https://en.wikipedia.org/wiki/ASN.1).
933           This option enables the support of the asn1 decoder.
934
935 config SPL_ASN1_DECODER
936         bool
937         help
938           ASN.1 (Abstract Syntax Notation One) is a standard interface
939           description language for defining data structures that can be
940           serialized and deserialized in a cross-platform way. It is
941           broadly used in telecommunications and computer networking,
942           and especially in cryptography (https://en.wikipedia.org/wiki/ASN.1).
943           This option enables the support of the asn1 decoder in the SPL.
944
945 config OID_REGISTRY
946         bool
947         help
948           In computing, object identifiers or OIDs are an identifier mechanism
949           standardized by the International Telecommunication Union (ITU) and
950           ISO/IEC for naming any object, concept, or "thing" with a globally
951           unambiguous persistent name (https://en.wikipedia.org/wiki/Object_identifier).
952           Enable fast lookup object identifier registry.
953
954 config SPL_OID_REGISTRY
955         bool
956         help
957           In computing, object identifiers or OIDs are an identifier mechanism
958           standardized by the International Telecommunication Union (ITU) and
959           ISO/IEC for naming any object, concept, or "thing" with a globally
960           unambiguous persistent name (https://en.wikipedia.org/wiki/Object_identifier).
961           Enable fast lookup object identifier registry in the SPL.
962
963 config SMBIOS_PARSER
964         bool "SMBIOS parser"
965         help
966           A simple parser for SMBIOS data.
967
968 source lib/efi/Kconfig
969 source lib/efi_loader/Kconfig
970 source lib/optee/Kconfig
971
972 config TEST_FDTDEC
973         bool "enable fdtdec test"
974         depends on OF_LIBFDT
975
976 config LIB_DATE
977         bool
978
979 config LIB_ELF
980         bool
981         help
982           Support basic elf loading/validating functions.
983           This supports for 32 bit and 64 bit versions.
984
985 config LMB
986         bool "Enable the logical memory blocks library (lmb)"
987         default y if ARC || ARM || M68K || MICROBLAZE || MIPS || \
988                      NIOS2 || PPC || RISCV || SANDBOX || SH || X86 || XTENSA
989         help
990           Support the library logical memory blocks.
991
992 config LMB_USE_MAX_REGIONS
993         bool "Use a common number of memory and reserved regions in lmb lib"
994         depends on LMB
995         default y
996         help
997           Define the number of supported memory regions in the library logical
998           memory blocks.
999           This feature allow to reduce the lmb library size by using compiler
1000           optimization when LMB_MEMORY_REGIONS == LMB_RESERVED_REGIONS.
1001
1002 config LMB_MAX_REGIONS
1003         int "Number of memory and reserved regions in lmb lib"
1004         depends on LMB && LMB_USE_MAX_REGIONS
1005         default 8
1006         help
1007           Define the number of supported regions, memory and reserved, in the
1008           library logical memory blocks.
1009
1010 config LMB_MEMORY_REGIONS
1011         int "Number of memory regions in lmb lib"
1012         depends on LMB && !LMB_USE_MAX_REGIONS
1013         default 8
1014         help
1015           Define the number of supported memory regions in the library logical
1016           memory blocks.
1017           The minimal value is CONFIG_NR_DRAM_BANKS.
1018
1019 config LMB_RESERVED_REGIONS
1020         int "Number of reserved regions in lmb lib"
1021         depends on LMB && !LMB_USE_MAX_REGIONS
1022         default 8
1023         help
1024           Define the number of supported reserved regions in the library logical
1025           memory blocks.
1026
1027 endmenu
1028
1029 menu "FWU Multi Bank Updates"
1030
1031 source lib/fwu_updates/Kconfig
1032
1033 endmenu