2 # For a description of the syntax of this configuration file,
3 # see the file Documentation/kbuild/kconfig-language.txt in the
4 # Linux kernel source tree.
6 mainmenu "U-Boot $(UBOOTVERSION) Configuration"
8 source "scripts/Kconfig.include"
10 # Allow defaults in arch-specific code to override any given here
18 This option cannot be enabled. It is used as dependency
19 for broken and incomplete features.
24 This option cannot be enabled. It it used as a dependency for
25 code that relies on deprecated features that will be removed and
26 the conversion deadline has passed.
29 string "Local version - append to U-Boot release"
31 Append an extra string to the end of your U-Boot version.
32 This will show up in your boot log, for example.
33 The string you set here will be appended after the contents of
34 any files with a filename matching localversion* in your
35 object and source tree, in that order. Your total string can
36 be a maximum of 64 characters.
38 config LOCALVERSION_AUTO
39 bool "Automatically append version information to the version string"
42 This will try to automatically determine if the current tree is a
43 release tree by looking for Git tags that belong to the current
46 A string of the format -gxxxxxxxx will be added to the localversion
47 if a Git-based tree is found. The string generated by this will be
48 appended after any matching localversion* files, and after the value
49 set in CONFIG_LOCALVERSION.
51 (The actual string used here is the first eight characters produced
52 by running the command:
54 $ git rev-parse --verify HEAD
56 which is done within the script "scripts/setlocalversion".)
58 config CC_OPTIMIZE_FOR_SIZE
59 bool "Optimize for size"
62 Enabling this option will pass "-Os" instead of "-O2" to gcc
63 resulting in a smaller U-Boot image.
65 This option is enabled by default for U-Boot.
67 config OPTIMIZE_INLINING
68 bool "Allow compiler to uninline functions marked 'inline' in full U-Boot"
71 This option determines if U-Boot forces gcc to inline the functions
72 developers have marked 'inline'. Doing so takes away freedom from gcc to
73 do what it thinks is best, which is desirable in some cases for size
76 config SPL_OPTIMIZE_INLINING
77 bool "Allow compiler to uninline functions marked 'inline' in SPL"
81 This option determines if U-Boot forces gcc to inline the functions
82 developers have marked 'inline'. Doing so takes away freedom from gcc to
83 do what it thinks is best, which is desirable in some cases for size
86 config TPL_OPTIMIZE_INLINING
87 bool "Allow compiler to uninline functions marked 'inline' in TPL"
91 This option determines if U-Boot forces gcc to inline the functions
92 developers have marked 'inline'. Doing so takes away freedom from gcc to
93 do what it thinks is best, which is desirable in some cases for size
97 bool "Enable code coverage analysis"
100 Enabling this option will pass "--coverage" to gcc to compile
101 and link code instrumented for coverage analysis.
103 config CC_HAS_ASM_INLINE
104 def_bool $(success,echo 'void foo(void) { asm inline (""); }' | $(CC) -x c - -c -o /dev/null)
106 config DISTRO_DEFAULTS
107 bool "Select defaults suitable for booting general purpose Linux distributions"
109 select CMDLINE_EDITING
110 select CMD_BOOTI if ARM64
111 select CMD_BOOTZ if ARM && !ARM64
112 select CMD_DHCP if CMD_NET
113 select CMD_ENV_EXISTS
117 select CMD_FS_GENERIC
118 select CMD_PART if PARTITIONS
119 select CMD_PING if CMD_NET
120 select CMD_PXE if NET
122 select ENV_VARS_UBOOT_CONFIG
124 select SUPPORT_RAW_INITRD
128 imply USE_BOOTCOMMAND
130 Select this to enable various options and commands which are suitable
131 for building u-boot for booting general purpose Linux distributions.
133 config ENV_VARS_UBOOT_CONFIG
134 bool "Add arch, board, vendor and soc variables to default environment"
136 Define this in order to add variables describing the
137 U-Boot build configuration to the default environment.
138 These will be named arch, cpu, board, vendor, and soc.
139 Enabling this option will cause the following to be defined:
147 int "Number of DRAM banks"
148 default 1 if ARCH_SUNXI || ARCH_OWL
151 This defines the number of DRAM banks.
153 config SYS_BOOT_GET_CMDLINE
154 bool "Enable kernel command line setup"
156 Enables allocating and saving kernel cmdline in space between
157 "bootm_low" and "bootm_low" + BOOTMAPSZ.
159 config SYS_BOOT_GET_KBD
160 bool "Enable kernel board information setup"
162 Enables allocating and saving a kernel copy of the bd_info in
163 space between "bootm_low" and "bootm_low" + BOOTMAPSZ.
166 bool "Enable malloc() pool before relocation"
170 Before relocation, memory is very limited on many platforms. Still,
171 we can provide a small malloc() pool if needed. Driver model in
172 particular needs this to operate, so that it can allocate the
173 initial serial device and any others that are needed.
175 config SYS_MALLOC_F_LEN
176 hex "Size of malloc() pool before relocation"
177 depends on SYS_MALLOC_F
178 default 0x1000 if AM33XX
179 default 0x2800 if SANDBOX
180 default 0x2000 if (ARCH_IMX8 || ARCH_IMX8M || ARCH_MX7 || \
181 ARCH_MX7ULP || ARCH_MX6 || ARCH_MX5 || \
182 ARCH_LS1012A || ARCH_LS1021A || ARCH_LS1043A || \
183 ARCH_LS1046A || ARCH_QEMU)
186 Before relocation, memory is very limited on many platforms. Still,
187 we can provide a small malloc() pool if needed. Driver model in
188 particular needs this to operate, so that it can allocate the
189 initial serial device and any others that are needed.
191 config SYS_MALLOC_LEN
192 hex "Define memory for Dynamic allocation"
193 depends on ARCH_ZYNQ || ARCH_VERSAL || ARCH_STM32MP || ARCH_ROCKCHIP
194 default 0x2000000 if ARCH_ROCKCHIP
196 This defines memory to be allocated for Dynamic allocation
197 TODO: Use for other architectures
199 config SPL_SYS_MALLOC_F_LEN
200 hex "Size of malloc() pool in SPL before relocation"
201 depends on SYS_MALLOC_F && SPL
202 default 0x2800 if RCAR_GEN3
203 default SYS_MALLOC_F_LEN
205 Before relocation, memory is very limited on many platforms. Still,
206 we can provide a small malloc() pool if needed. Driver model in
207 particular needs this to operate, so that it can allocate the
208 initial serial device and any others that are needed.
210 config TPL_SYS_MALLOC_F_LEN
211 hex "Size of malloc() pool in TPL before relocation"
212 depends on SYS_MALLOC_F && TPL
213 default SYS_MALLOC_F_LEN
215 Before relocation, memory is very limited on many platforms. Still,
216 we can provide a small malloc() pool if needed. Driver model in
217 particular needs this to operate, so that it can allocate the
218 initial serial device and any others that are needed.
221 bool "Configure standard U-Boot features (expert users)"
224 This option allows certain base U-Boot options and settings
225 to be disabled or tweaked. This is for specialized
226 environments which can tolerate a "non-standard" U-Boot.
227 Use this only if you really know what you are doing.
230 config SYS_MALLOC_CLEAR_ON_INIT
231 bool "Init with zeros the memory reserved for malloc (slow)"
234 This setting is enabled by default. The reserved malloc
235 memory is initialized with zeros, so first malloc calls
236 will return the pointer to the zeroed memory. But this
239 It is recommended to disable it, when CONFIG_SYS_MALLOC_LEN
240 value, has more than few MiB, e.g. when uses bzip2 or bmp logo.
241 Then the boot time can be significantly reduced.
243 When disabling this, please check if malloc calls, maybe
244 should be replaced by calloc - if one expects zeroed memory.
246 config SYS_MALLOC_DEFAULT_TO_INIT
247 bool "Default malloc to init while reserving the memory for it"
250 It may happen that one needs to move the dynamic allocation
251 from one to another memory range, eg. when moving the malloc
252 from the limited static to a potentially large dynamic (DDR)
255 If so then on top of setting the updated memory aside one
256 needs to bring the malloc init.
258 If such a scenario is sought choose yes.
261 bool "Enable debug information for tools"
263 Enable generation of debug information for tools such as mkimage.
264 This can be used for debugging purposes. With debug information
265 it is possible to set breakpoints on particular lines, single-step
266 debug through the source code, etc.
271 bool "64bit physical address support"
273 Say Y here to support 64bit physical memory address.
274 This can be used not only for 64bit SoCs, but also for
275 large physical address extension on 32bit SoCs.
278 bool "Build U-Boot as BIOS replacement"
281 This option allows to build a ROM version of U-Boot.
282 The build process generally requires several binary blobs
283 which are not shipped in the U-Boot source tree.
284 Please, see doc/arch/x86.rst for details.
287 string "SPL image used in the combined SPL+U-Boot image"
288 default "spl/boot.bin" if ARCH_AT91 && SPL_NAND_SUPPORT
289 default "spl/u-boot-spl.bin"
292 Select the SPL build target that shall be generated by the SPL
293 build process (default spl/u-boot-spl.bin). This image will be
294 used to generate a combined image with SPL and main U-Boot
295 proper as one single image.
298 string "Build target special images"
299 default "u-boot-with-spl.sfp" if TARGET_SOCFPGA_ARRIA10
300 default "u-boot-with-spl.sfp" if TARGET_SOCFPGA_GEN5
301 default "u-boot-spl.kwb" if ARCH_MVEBU && SPL
302 default "u-boot-elf.srec" if RCAR_GEN3
303 default "u-boot.itb" if SPL_LOAD_FIT && (ARCH_ROCKCHIP || \
304 ARCH_SUNXI || RISCV || ARCH_ZYNQMP)
305 default "u-boot.kwb" if ARCH_KIRKWOOD
306 default "u-boot-with-spl.bin" if ARCH_AT91 && SPL_NAND_SUPPORT
307 default "u-boot-with-spl.imx" if ARCH_MX6 && SPL
309 Some SoCs need special image types (e.g. U-Boot binary
310 with a special header) as build targets. By defining
311 CONFIG_BUILD_TARGET in the SoC / board header, this
312 special image will be automatically built upon calling
315 config SYS_CUSTOM_LDSCRIPT
316 bool "Use a custom location for the U-Boot linker script"
318 Normally when linking U-Boot we will look in the board directory,
319 the CPU directory and finally the "cpu" directory of the architecture
320 for the ile "u-boot.lds" and use that as our linker. However, in
321 some cases we need to provide a different linker script. To do so,
322 enable this option and then provide the location under
326 depends on SYS_CUSTOM_LDSCRIPT
327 string "Custom ldscript location"
329 Path within the source tree to the linker script to use for the
332 config ERR_PTR_OFFSET
336 Some U-Boot pointers have redundant information, so we can use a
337 scheme where we can return either an error code or a pointer with the
338 same return value. The default implementation just casts the pointer
339 to a number, however, this may fail on platforms where the end of the
340 address range is used for valid pointers (e.g. 0xffffff00 is a valid
341 heap pointer in socfpga SPL).
342 For such platforms, this value provides an upper range of those error
343 pointer values - up to 'MAX_ERRNO' bytes below this value must be
344 unused/invalid addresses.
346 config PLATFORM_ELFENTRY
348 default "__start" if MIPS
351 endmenu # General setup
355 config ANDROID_BOOT_IMAGE
356 bool "Enable support for Android Boot Images"
357 default y if FASTBOOT
359 This enables support for booting images which use the Android
363 bool "Support Flattened Image Tree"
367 This option allows you to boot the new uImage structure,
368 Flattened Image Tree. FIT is formally a FDT, which can include
369 images of various types (kernel, FDT blob, ramdisk, etc.)
370 in a single blob. To boot this new uImage structure,
371 pass the address of the blob to the "bootm" command.
372 FIT is very flexible, supporting compression, multiple images,
373 multiple configurations, verification through hashing and also
374 verified boot (secure boot using RSA).
378 config FIT_EXTERNAL_OFFSET
379 hex "FIT external data offset"
382 This specifies a data offset in fit image.
383 The offset is from data payload offset to the beginning of
384 fit image header. When specifies a offset, specific data
385 could be put in the hole between data payload and fit image
386 header, such as CSF data on i.MX platform.
388 config FIT_ENABLE_SHA256_SUPPORT
389 bool "Support SHA256 checksum of FIT image contents"
393 Enable this to support SHA256 checksum of FIT image contents. A
394 SHA256 checksum is a 256-bit (32-byte) hash value used to check that
395 the image contents have not been corrupted.
397 config FIT_ENABLE_SHA384_SUPPORT
398 bool "Support SHA384 checksum of FIT image contents"
402 Enable this to support SHA384 checksum of FIT image contents. A
403 SHA384 checksum is a 384-bit (48-byte) hash value used to check that
404 the image contents have not been corrupted. Use this for the highest
407 config FIT_ENABLE_SHA512_SUPPORT
408 bool "Support SHA512 checksum of FIT image contents"
412 Enable this to support SHA512 checksum of FIT image contents. A
413 SHA512 checksum is a 512-bit (64-byte) hash value used to check that
414 the image contents have not been corrupted.
417 bool "Enable signature verification of FIT uImages"
422 select IMAGE_SIGN_INFO
424 This option enables signature verification of FIT uImages,
425 using a hash signed and verified using RSA. If
426 CONFIG_SHA_PROG_HW_ACCEL is defined, i.e support for progressive
427 hashing is available using hardware, then the RSA library will use
428 it. See doc/uImage.FIT/signature.txt for more details.
430 WARNING: When relying on signed FIT images with a required signature
431 check the legacy image format is disabled by default, so that
432 unsigned images cannot be loaded. If a board needs the legacy image
433 format support in this case, enable it using
434 CONFIG_LEGACY_IMAGE_FORMAT.
436 config FIT_SIGNATURE_MAX_SIZE
437 hex "Max size of signed FIT structures"
438 depends on FIT_SIGNATURE
441 This option sets a max size in bytes for verified FIT uImages.
442 A sane value of 256MB protects corrupted DTB structures from overlapping
443 device memory. Assure this size does not extend past expected storage
446 config FIT_ENABLE_RSASSA_PSS_SUPPORT
447 bool "Support rsassa-pss signature scheme of FIT image contents"
448 depends on FIT_SIGNATURE
451 Enable this to support the pss padding algorithm as described
452 in the rfc8017 (https://tools.ietf.org/html/rfc8017).
455 bool "Enable ciphering data in a FIT uImages"
459 Enable the feature of data ciphering/unciphering in the tool mkimage
460 and in the u-boot support of the FIT image.
463 bool "Show verbose messages when FIT images fail"
465 Generally a system will have valid FIT images so debug messages
466 are a waste of code space. If you are debugging your images then
467 you can enable this option to get more verbose information about
470 config FIT_BEST_MATCH
471 bool "Select the best match for the kernel device tree"
473 When no configuration is explicitly selected, default to the
474 one whose fdt's compatibility field best matches that of
475 U-Boot itself. A match is considered "best" if it matches the
476 most specific compatibility entry of U-Boot's fdt's root node.
477 The order of entries in the configuration's fdt is ignored.
479 config FIT_IMAGE_POST_PROCESS
480 bool "Enable post-processing of FIT artifacts after loading by U-Boot"
481 depends on TI_SECURE_DEVICE
483 Allows doing any sort of manipulation to blobs after they got extracted
484 from FIT images like stripping off headers or modifying the size of the
485 blob, verification, authentication, decryption etc. in a platform or
486 board specific way. In order to use this feature a platform or board-
487 specific implementation of board_fit_image_post_process() must be
488 provided. Also, anything done during this post-processing step would
489 need to be comprehended in how the images were prepared before being
490 injected into the FIT creation (i.e. the blobs would have been pre-
491 processed before being added to the FIT image).
496 bool "Support Flattened Image Tree within SPL"
501 bool "Support FIT printing within SPL"
504 Support printing the content of the fitImage in a verbose manner in SPL.
506 config SPL_FIT_SIGNATURE
507 bool "Enable signature verification of FIT firmware within SPL"
511 select SPL_RSA_VERIFY
512 select SPL_IMAGE_SIGN_INFO
515 bool "Enable SPL loading U-Boot as a FIT (basic fitImage features)"
518 Normally with the SPL framework a legacy image is generated as part
519 of the build. This contains U-Boot along with information as to
520 where it should be loaded. This option instead enables generation
521 of a FIT (Flat Image Tree) which provides more flexibility. In
522 particular it can handle selecting from multiple device tree
523 and passing the correct one to U-Boot.
525 config SPL_LOAD_FIT_APPLY_OVERLAY
526 bool "Enable SPL applying DT overlays from FIT"
527 depends on SPL_LOAD_FIT
528 select OF_LIBFDT_OVERLAY
530 The device tree is loaded from the FIT image. Allow the SPL is to
531 also load device-tree overlays from the FIT image an apply them
532 over the device tree.
534 config SPL_LOAD_FIT_APPLY_OVERLAY_BUF_SZ
535 depends on SPL_LOAD_FIT_APPLY_OVERLAY
537 hex "size of temporary buffer used to load the overlays"
539 The size of the area where the overlays will be loaded and
540 uncompress. Must be at least as large as biggest overlay
543 config SPL_LOAD_FIT_FULL
544 bool "Enable SPL loading U-Boot as a FIT (full fitImage features)"
547 Normally with the SPL framework a legacy image is generated as part
548 of the build. This contains U-Boot along with information as to
549 where it should be loaded. This option instead enables generation
550 of a FIT (Flat Image Tree) which provides more flexibility. In
551 particular it can handle selecting from multiple device tree
552 and passing the correct one to U-Boot.
554 config SPL_FIT_IMAGE_POST_PROCESS
555 bool "Enable post-processing of FIT artifacts after loading by the SPL"
556 depends on SPL_LOAD_FIT
558 Allows doing any sort of manipulation to blobs after they got extracted
559 from the U-Boot FIT image like stripping off headers or modifying the
560 size of the blob, verification, authentication, decryption etc. in a
561 platform or board specific way. In order to use this feature a platform
562 or board-specific implementation of board_fit_image_post_process() must
563 be provided. Also, anything done during this post-processing step would
564 need to be comprehended in how the images were prepared before being
565 injected into the FIT creation (i.e. the blobs would have been pre-
566 processed before being added to the FIT image).
568 config SPL_FIT_SOURCE
569 string ".its source file for U-Boot FIT image"
572 Specifies a (platform specific) FIT source file to generate the
573 U-Boot FIT image. This could specify further image to load and/or
576 config SPL_FIT_GENERATOR
577 string ".its file generator script for U-Boot FIT image"
579 default "board/sunxi/mksunxi_fit_atf.sh" if SPL_LOAD_FIT && ARCH_SUNXI
580 default "arch/arm/mach-rockchip/make_fit_atf.py" if SPL_LOAD_FIT && ARCH_ROCKCHIP
581 default "arch/arm/mach-zynqmp/mkimage_fit_atf.sh" if SPL_LOAD_FIT && ARCH_ZYNQMP
582 default "arch/riscv/lib/mkimage_fit_opensbi.sh" if SPL_LOAD_FIT && RISCV
584 Specifies a (platform specific) script file to generate the FIT
585 source file used to build the U-Boot FIT image file. This gets
586 passed a list of supported device tree file stub names to
587 include in the generated image.
593 config LEGACY_IMAGE_FORMAT
594 bool "Enable support for the legacy image format"
595 default y if !FIT_SIGNATURE
597 This option enables the legacy image format. It is enabled by
598 default for backward compatibility, unless FIT_SIGNATURE is
599 set where it is disabled so that unsigned images cannot be
600 loaded. If a board needs the legacy image format support in this
601 case, enable it here.
603 config OF_BOARD_SETUP
604 bool "Set up board-specific details in device tree before boot"
607 This causes U-Boot to call ft_board_setup() before booting into
608 the Operating System. This function can set up various
609 board-specific information in the device tree for use by the OS.
610 The device tree is then passed to the OS.
612 config OF_SYSTEM_SETUP
613 bool "Set up system-specific details in device tree before boot"
616 This causes U-Boot to call ft_system_setup() before booting into
617 the Operating System. This function can set up various
618 system-specific information in the device tree for use by the OS.
619 The device tree is then passed to the OS.
621 config OF_STDOUT_VIA_ALIAS
622 bool "Update the device-tree stdout alias from U-Boot"
625 This uses U-Boot's serial alias from the aliases node to update
626 the device tree passed to the OS. The "linux,stdout-path" property
627 in the chosen node is set to point to the correct serial node.
628 This option currently references CONFIG_CONS_INDEX, which is
629 incorrect when used with device tree as this option does not
630 exist / should not be used.
632 config SYS_EXTRA_OPTIONS
633 string "Extra Options (DEPRECATED)"
635 The old configuration infrastructure (= mkconfig + boards.cfg)
636 provided the extra options field. If you have something like
637 "HAS_BAR,BAZ=64", the optional options
639 #define CONFIG_BAZ 64
640 will be defined in include/config.h.
641 This option was prepared for the smooth migration from the old
642 configuration to Kconfig. Since this option will be removed sometime,
643 new boards should not use this option.
645 config HAVE_SYS_TEXT_BASE
647 depends on !NIOS2 && !XTENSA
652 depends on HAVE_SYS_TEXT_BASE
653 default 0x80800000 if ARCH_OMAP2PLUS || ARCH_K3
654 default 0x4a000000 if ARCH_SUNXI && !MACH_SUN9I && !MACH_SUN8I_V3S
655 default 0x2a000000 if ARCH_SUNXI && MACH_SUN9I
656 default 0x42e00000 if ARCH_SUNXI && MACH_SUN8I_V3S
659 The address in memory that U-Boot will be running from, initially.
662 depends on ARC || ARCH_SUNXI || MPC83xx
663 int "CPU clock frequency"
665 TODO: Move CONFIG_SYS_CLK_FREQ for all the architecture
667 config ARCH_FIXUP_FDT_MEMORY
668 bool "Enable arch_fixup_memory_banks() call"
671 Enable FDT memory map syncup before OS boot. This feature can be
672 used for booting OS with different memory setup where the part of
673 the memory location should be used for different purpose.
675 endmenu # Boot images
679 source "common/Kconfig"
683 source "disk/Kconfig"
691 source "drivers/Kconfig"
697 source "test/Kconfig"