xref: /openbmc/u-boot/common/spl/Kconfig (revision 32f11829)
1menu "SPL / TPL"
2
3config SUPPORT_SPL
4	bool
5
6config SUPPORT_TPL
7	bool
8
9config SPL_DFU_NO_RESET
10	bool
11
12config SPL
13	bool
14	depends on SUPPORT_SPL
15	prompt "Enable SPL"
16	help
17	  If you want to build SPL as well as the normal image, say Y.
18
19if SPL
20
21config SPL_LDSCRIPT
22	string "Linker script for the SPL stage"
23	default "arch/$(ARCH)/cpu/u-boot-spl.lds"
24	depends on SPL
25	help
26	  The SPL stage will usually require a different linker-script
27	  (as it runs from a different memory region) than the regular
28	  U-Boot stage.	 Set this to the path of the linker-script to
29	  be used for SPL.
30
31config SPL_BOARD_INIT
32	bool "Call board-specific initialization in SPL"
33	help
34	  If this option is enabled, U-Boot will call the function
35	  spl_board_init() from board_init_r(). This function should be
36	  provided by the board.
37
38config SPL_BOOTROM_SUPPORT
39        bool "Support returning to the BOOTROM"
40	help
41	  Some platforms (e.g. the Rockchip RK3368) provide support in their
42	  ROM for loading the next boot-stage after performing basic setup
43	  from the SPL stage.
44
45	  Enable this option, to return to the BOOTROM through the
46	  BOOT_DEVICE_BOOTROM (or fall-through to the next boot device in the
47	  boot device list, if not implemented for a given board)
48
49config SPL_RAW_IMAGE_SUPPORT
50	bool "Support SPL loading and booting of RAW images"
51	default n if (ARCH_MX6 && (SPL_MMC_SUPPORT || SPL_SATA_SUPPORT))
52	default y if !TI_SECURE_DEVICE
53	help
54	  SPL will support loading and booting a RAW image when this option
55	  is y. If this is not set, SPL will move on to other available
56	  boot media to find a suitable image.
57
58config SPL_LEGACY_IMAGE_SUPPORT
59	bool "Support SPL loading and booting of Legacy images"
60	default y if !TI_SECURE_DEVICE
61	help
62	  SPL will support loading and booting Legacy images when this option
63	  is y. If this is not set, SPL will move on to other available
64	  boot media to find a suitable image.
65
66config SPL_SYS_MALLOC_SIMPLE
67	bool
68	prompt "Only use malloc_simple functions in the SPL"
69	help
70	  Say Y here to only use the *_simple malloc functions from
71	  malloc_simple.c, rather then using the versions from dlmalloc.c;
72	  this will make the SPL binary smaller at the cost of more heap
73	  usage as the *_simple malloc functions do not re-use free-ed mem.
74
75config TPL_SYS_MALLOC_SIMPLE
76	bool
77	prompt "Only use malloc_simple functions in the TPL"
78	help
79	  Say Y here to only use the *_simple malloc functions from
80	  malloc_simple.c, rather then using the versions from dlmalloc.c;
81	  this will make the TPL binary smaller at the cost of more heap
82	  usage as the *_simple malloc functions do not re-use free-ed mem.
83
84config SPL_STACK_R
85	bool "Enable SDRAM location for SPL stack"
86	help
87	  SPL starts off execution in SRAM and thus typically has only a small
88	  stack available. Since SPL sets up DRAM while in its board_init_f()
89	  function, it is possible for the stack to move there before
90	  board_init_r() is reached. This option enables a special SDRAM
91	  location for the SPL stack. U-Boot SPL switches to this after
92	  board_init_f() completes, and before board_init_r() starts.
93
94config SPL_STACK_R_ADDR
95	depends on SPL_STACK_R
96	hex "SDRAM location for SPL stack"
97	default 0x82000000 if ARCH_OMAP2PLUS
98	help
99	  Specify the address in SDRAM for the SPL stack. This will be set up
100	  before board_init_r() is called.
101
102config SPL_STACK_R_MALLOC_SIMPLE_LEN
103	depends on SPL_STACK_R && SPL_SYS_MALLOC_SIMPLE
104	hex "Size of malloc_simple heap after switching to DRAM SPL stack"
105	default 0x100000
106	help
107	  Specify the amount of the stack to use as memory pool for
108	  malloc_simple after switching the stack to DRAM. This may be set
109	  to give board_init_r() a larger heap then the initial heap in
110	  SRAM which is limited to SYS_MALLOC_F_LEN bytes.
111
112config SPL_SEPARATE_BSS
113	bool "BSS section is in a different memory region from text"
114	help
115	  Some platforms need a large BSS region in SPL and can provide this
116	  because RAM is already set up. In this case BSS can be moved to RAM.
117	  This option should then be enabled so that the correct device tree
118	  location is used. Normally we put the device tree at the end of BSS
119	  but with this option enabled, it goes at _image_binary_end.
120
121config SPL_DISPLAY_PRINT
122	bool "Display a board-specific message in SPL"
123	help
124	  If this option is enabled, U-Boot will call the function
125	  spl_display_print() immediately after displaying the SPL console
126	  banner ("U-Boot SPL ..."). This function should be provided by
127	  the board.
128
129config SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
130	bool "MMC raw mode: by sector"
131	default y if ARCH_SUNXI || ARCH_DAVINCI || ARCH_UNIPHIER ||ARCH_MX6 || \
132		     ARCH_ROCKCHIP || ARCH_MVEBU ||  ARCH_SOCFPGA || \
133		     ARCH_AT91 || ARCH_ZYNQ || ARCH_KEYSTONE || OMAP34XX || \
134		     OMAP44XX || OMAP54XX || AM33XX || AM43XX
135	help
136	  Use sector number for specifying U-Boot location on MMC/SD in
137	  raw mode.
138
139config SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
140	hex "Address on the MMC to load U-Boot from"
141	depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
142	default 0x50 if ARCH_SUNXI
143	default 0x75 if ARCH_DAVINCI
144	default 0x8a if ARCH_MX6
145	default 0x100 if ARCH_ROCKCHIP || ARCH_UNIPHIER
146	default 0x140 if ARCH_MVEBU
147	default 0x200 if ARCH_SOCFPGA || ARCH_AT91
148	default 0x300 if ARCH_ZYNQ || ARCH_KEYSTONE || OMAP34XX || OMAP44XX || \
149		         OMAP54XX || AM33XX || AM43XX
150	help
151	  Address on the MMC to load U-Boot from, when the MMC is being used
152	  in raw mode. Units: MMC sectors (1 sector = 512 bytes).
153
154config SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
155	bool "MMC Raw mode: by partition"
156	help
157	  Use a partition for loading U-Boot when using MMC/SD in raw mode.
158
159config SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION
160	hex "Partition to use to load U-Boot from"
161	depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
162	default 1
163	help
164	  Partition on the MMC to load U-Boot from when the MMC is being
165	  used in raw mode
166
167config SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION_TYPE
168	bool "MMC raw mode: by partition type"
169	depends on DOS_PARTITION && SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
170	help
171	  Use partition type for specifying U-Boot partition on MMC/SD in
172	  raw mode. U-Boot will be loaded from the first partition of this
173	  type to be found.
174
175config SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION_TYPE
176	hex "Partition Type on the MMC to load U-Boot from"
177	depends on SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION_TYPE
178	help
179	  Partition Type on the MMC to load U-Boot from, when the MMC is being
180	  used in raw mode.
181
182config SPL_CRC32_SUPPORT
183	bool "Support CRC32"
184	depends on SPL_FIT
185	help
186	  Enable this to support CRC32 in FIT images within SPL. This is a
187	  32-bit checksum value that can be used to verify images. This is
188	  the least secure type of checksum, suitable for detected
189	  accidental image corruption. For secure applications you should
190	  consider SHA1 or SHA256.
191
192config SPL_MD5_SUPPORT
193	bool "Support MD5"
194	depends on SPL_FIT
195	help
196	  Enable this to support MD5 in FIT images within SPL. An MD5
197	  checksum is a 128-bit hash value used to check that the image
198	  contents have not been corrupted. Note that MD5 is not considered
199	  secure as it is possible (with a brute-force attack) to adjust the
200	  image while still retaining the same MD5 hash value. For secure
201	  applications where images may be changed maliciously, you should
202	  consider SHA1 or SHA256.
203
204config SPL_SHA1_SUPPORT
205	bool "Support SHA1"
206	depends on SPL_FIT
207	select SHA1
208	help
209	  Enable this to support SHA1 in FIT images within SPL. A SHA1
210	  checksum is a 160-bit (20-byte) hash value used to check that the
211	  image contents have not been corrupted or maliciously altered.
212	  While SHA1 is fairly secure it is coming to the end of its life
213	  due to the expanding computing power avaiable to brute-force
214	  attacks. For more security, consider SHA256.
215
216config SPL_SHA256_SUPPORT
217	bool "Support SHA256"
218	depends on SPL_FIT
219	select SHA256
220	help
221	  Enable this to support SHA256 in FIT images within SPL. A SHA256
222	  checksum is a 256-bit (32-byte) hash value used to check that the
223	  image contents have not been corrupted. SHA256 is recommended for
224	  use in secure applications since (as at 2016) there is no known
225	  feasible attack that could produce a 'collision' with differing
226	  input data. Use this for the highest security. Note that only the
227	  SHA256 variant is supported: SHA512 and others are not currently
228	  supported in U-Boot.
229
230config SPL_CPU_SUPPORT
231	bool "Support CPU drivers"
232	help
233	  Enable this to support CPU drivers in SPL. These drivers can set
234	  up CPUs and provide information about them such as the model and
235	  name. This can be useful in SPL since setting up the CPUs earlier
236	  may improve boot performance. Enable this option to build the
237	  drivers in drivers/cpu as part of an SPL build.
238
239config SPL_CRYPTO_SUPPORT
240	bool "Support crypto drivers"
241	help
242	  Enable crypto drivers in SPL. These drivers can be used to
243	  accelerate secure boot processing in secure applications. Enable
244	  this option to build the drivers in drivers/crypto as part of an
245	  SPL build.
246
247config SPL_HASH_SUPPORT
248	bool "Support hashing drivers"
249	select SHA1
250	select SHA256
251	help
252	  Enable hashing drivers in SPL. These drivers can be used to
253	  accelerate secure boot processing in secure applications. Enable
254	  this option to build system-specific drivers for hash acceleration
255	  as part of an SPL build.
256
257config SPL_DMA_SUPPORT
258	bool "Support DMA drivers"
259	help
260	  Enable DMA (direct-memory-access) drivers in SPL. These drivers
261	  can be used to handle memory-to-peripheral data transfer without
262	  the CPU moving the data. Enable this option to build the drivers
263	  in drivers/dma as part of an SPL build.
264
265config SPL_DRIVERS_MISC_SUPPORT
266	bool "Support misc drivers"
267	help
268	  Enable miscellaneous drivers in SPL. These drivers perform various
269	  tasks that don't fall nicely into other categories, Enable this
270	  option to build the drivers in drivers/misc as part of an SPL
271	  build, for those that support building in SPL (not all drivers do).
272
273config SPL_ENV_SUPPORT
274	bool "Support an environment"
275	help
276	  Enable environment support in SPL. The U-Boot environment provides
277	  a number of settings (essentially name/value pairs) which can
278	  control many aspects of U-Boot's operation. Normally this is not
279	  needed in SPL as it has a much simpler task with less
280	  configuration. But some boards use this to support 'Falcon' boot
281	  on EXT2 and FAT, where SPL boots directly into Linux without
282	  starting U-Boot first. Enabling this option will make env_get()
283	  and env_set() available in SPL.
284
285config SPL_SAVEENV
286	bool "Support save environment"
287	depends on SPL_ENV_SUPPORT
288	help
289	  Enable save environment support in SPL after setenv. By default
290	  the saveenv option is not provided in SPL, but some boards need
291	  this support in 'Falcon' boot, where SPL need to boot from
292	  different images based on environment variable set by OS. For
293	  example OS may set "reboot_image" environment variable to
294	  "recovery" inorder to boot recovery image by SPL. The SPL read
295	  "reboot_image" and act accordingly and change the reboot_image
296	  to default mode using setenv and save the environemnt.
297
298config SPL_ETH_SUPPORT
299	bool "Support Ethernet"
300	depends on SPL_ENV_SUPPORT
301	help
302	  Enable access to the network subsystem and associated Ethernet
303	  drivers in SPL. This permits SPL to load U-Boot over an Ethernet
304	  link rather than from an on-board peripheral. Environment support
305	  is required since the network stack uses a number of environment
306	  variables. See also SPL_NET_SUPPORT.
307
308config SPL_EXT_SUPPORT
309	bool "Support EXT filesystems"
310	help
311	  Enable support for EXT2/3/4 filesystems with SPL. This permits
312	  U-Boot (or Linux in Falcon mode) to be loaded from an EXT
313	  filesystem from within SPL. Support for the underlying block
314	  device (e.g. MMC or USB) must be enabled separately.
315
316config SPL_FAT_SUPPORT
317	bool "Support FAT filesystems"
318	select FS_FAT
319	help
320	  Enable support for FAT and VFAT filesystems with SPL. This
321	  permits U-Boot (or Linux in Falcon mode) to be loaded from a FAT
322	  filesystem from within SPL. Support for the underlying block
323	  device (e.g. MMC or USB) must be enabled separately.
324
325config SPL_FPGA_SUPPORT
326	bool "Support FPGAs"
327	help
328	  Enable support for FPGAs in SPL. Field-programmable Gate Arrays
329	  provide software-configurable hardware which is typically used to
330	  implement peripherals (such as UARTs, LCD displays, MMC) or
331	  accelerate custom processing functions, such as image processing
332	  or machine learning. Sometimes it is useful to program the FPGA
333	  as early as possible during boot, and this option can enable that
334	  within SPL.
335
336config SPL_GPIO_SUPPORT
337	bool "Support GPIO"
338	help
339	  Enable support for GPIOs (General-purpose Input/Output) in SPL.
340	  GPIOs allow U-Boot to read the state of an input line (high or
341	  low) and set the state of an output line. This can be used to
342	  drive LEDs, control power to various system parts and read user
343	  input. GPIOs can be useful in SPL to enable a 'sign-of-life' LED,
344	  for example. Enable this option to build the drivers in
345	  drivers/gpio as part of an SPL build.
346
347config SPL_I2C_SUPPORT
348	bool "Support I2C"
349	help
350	  Enable support for the I2C (Inter-Integrated Circuit) bus in SPL.
351	  I2C works with a clock and data line which can be driven by a
352	  one or more masters or slaves. It is a fairly complex bus but is
353	  widely used as it only needs two lines for communication. Speeds of
354	  400kbps are typical but up to 3.4Mbps is supported by some
355	  hardware. I2C can be useful in SPL to configure power management
356	  ICs (PMICs) before raising the CPU clock speed, for example.
357	  Enable this option to build the drivers in drivers/i2c as part of
358	  an SPL build.
359
360config SPL_LIBCOMMON_SUPPORT
361	bool "Support common libraries"
362	help
363	  Enable support for common U-Boot libraries within SPL. These
364	  libraries include common code to deal with U-Boot images,
365	  environment and USB, for example. This option is enabled on many
366	  boards. Enable this option to build the code in common/ as part of
367	  an SPL build.
368
369config SPL_LIBDISK_SUPPORT
370	bool "Support disk paritions"
371	help
372	  Enable support for disk partitions within SPL. 'Disk' is something
373	  of a misnomer as it includes non-spinning media such as flash (as
374	  used in MMC and USB sticks). Partitions provide a way for a disk
375	  to be split up into separate regions, with a partition table placed
376	  at the start or end which describes the location and size of each
377	  'partition'. These partitions are typically uses as individual block
378	  devices, typically with an EXT2 or FAT filesystem in each. This
379	  option enables whatever partition support has been enabled in
380	  U-Boot to also be used in SPL. It brings in the code in disk/.
381
382config SPL_LIBGENERIC_SUPPORT
383	bool "Support generic libraries"
384	help
385	  Enable support for generic U-Boot libraries within SPL. These
386	  libraries include generic code to deal with device tree, hashing,
387	  printf(), compression and the like. This option is enabled on many
388	  boards. Enable this option to build the code in lib/ as part of an
389	  SPL build.
390
391config SPL_MMC_SUPPORT
392	bool "Support MMC"
393	depends on MMC
394	help
395	  Enable support for MMC (Multimedia Card) within SPL. This enables
396	  the MMC protocol implementation and allows any enabled drivers to
397	  be used within SPL. MMC can be used with or without disk partition
398	  support depending on the application (SPL_LIBDISK_SUPPORT). Enable
399	  this option to build the drivers in drivers/mmc as part of an SPL
400	  build.
401
402config SPL_MPC8XXX_INIT_DDR_SUPPORT
403	bool "Support MPC8XXX DDR init"
404	help
405	  Enable support for DDR-SDRAM (double-data-rate synchronous dynamic
406	  random-access memory) on the MPC8XXX family within SPL. This
407	  allows DRAM to be set up before loading U-Boot into that DRAM,
408	  where it can run.
409
410config SPL_MTD_SUPPORT
411	bool "Support MTD drivers"
412	help
413	  Enable support for MTD (Memory Technology Device) within SPL. MTD
414	  provides a block interface over raw NAND and can also be used with
415	  SPI flash. This allows SPL to load U-Boot from supported MTD
416	  devices. See SPL_NAND_SUPPORT and SPL_ONENAND_SUPPORT for how
417	  to enable specific MTD drivers.
418
419config SPL_MUSB_NEW_SUPPORT
420	bool "Support new Mentor Graphics USB"
421	help
422	  Enable support for Mentor Graphics USB in SPL. This is a new
423	  driver used by some boards. Enable this option to build
424	  the drivers in drivers/usb/musb-new as part of an SPL build. The
425	  old drivers are in drivers/usb/musb.
426
427config SPL_NAND_SUPPORT
428	bool "Support NAND flash"
429	help
430	  Enable support for NAND (Negative AND) flash in SPL. NAND flash
431	  can be used to allow SPL to load U-Boot from supported devices.
432	  This enables the drivers in drivers/mtd/nand as part of an SPL
433	  build.
434
435config SPL_NET_SUPPORT
436	bool "Support networking"
437	help
438	  Enable support for network devices (such as Ethernet) in SPL.
439	  This permits SPL to load U-Boot over a network link rather than
440	  from an on-board peripheral. Environment support is required since
441	  the network stack uses a number of environment variables. See also
442	  SPL_ETH_SUPPORT.
443
444if SPL_NET_SUPPORT
445config SPL_NET_VCI_STRING
446	string "BOOTP Vendor Class Identifier string sent by SPL"
447	help
448	  As defined by RFC 2132 the vendor class identifier field can be
449	  sent by the client to identify the vendor type and configuration
450	  of a client.  This is often used in practice to allow for the DHCP
451	  server to specify different files to load depending on if the ROM,
452	  SPL or U-Boot itself makes the request
453endif   # if SPL_NET_SUPPORT
454
455config SPL_NO_CPU_SUPPORT
456	bool "Drop CPU code in SPL"
457	help
458	  This is specific to the ARM926EJ-S CPU. It disables the standard
459	  start.S start-up code, presumably so that a replacement can be
460	  used on that CPU. You should not enable it unless you know what
461	  you are doing.
462
463config SPL_NOR_SUPPORT
464	bool "Support NOR flash"
465	help
466	  Enable support for loading U-Boot from memory-mapped NOR (Negative
467	  OR) flash in SPL. NOR flash is slow to write but fast to read, and
468	  a memory-mapped device makes it very easy to access. Loading from
469	  NOR is typically achieved with just a memcpy().
470
471config SPL_XIP_SUPPORT
472	bool "Support XIP"
473	depends on SPL
474	help
475	  Enable support for execute in place of U-Boot or kernel image. There
476	  is no need to copy image from flash to ram if flash supports execute
477	  in place. Its very useful in systems having enough flash but not
478	  enough ram to load the image.
479
480config SPL_ONENAND_SUPPORT
481	bool "Support OneNAND flash"
482	help
483	  Enable support for OneNAND (Negative AND) flash in SPL. OneNAND is
484	  a type of NAND flash and therefore can be used to allow SPL to
485	  load U-Boot from supported devices. This enables the drivers in
486	  drivers/mtd/onenand as part of an SPL build.
487
488config SPL_OS_BOOT
489	bool "Activate Falcon Mode"
490	depends on !TI_SECURE_DEVICE
491	default n
492	help
493	  Enable booting directly to an OS from SPL.
494	  for more info read doc/README.falcon
495
496if SPL_OS_BOOT
497config SYS_OS_BASE
498	hex "addr, where OS is found"
499	depends on SPL_NOR_SUPPORT
500	help
501	  Specify the address, where the OS image is found, which
502	  gets booted.
503
504endif # SPL_OS_BOOT
505
506config SPL_PCI_SUPPORT
507	bool "Support PCI drivers"
508	help
509	  Enable support for PCI in SPL. For platforms that need PCI to boot,
510	  or must perform some init using PCI in SPL, this provides the
511	  necessary driver support. This enables the drivers in drivers/pci
512	  as part of an SPL build.
513
514config SPL_PCH_SUPPORT
515	bool "Support PCH drivers"
516	help
517	  Enable support for PCH (Platform Controller Hub) devices in SPL.
518	  These are used to set up GPIOs and the SPI peripheral early in
519	  boot. This enables the drivers in drivers/pch as part of an SPL
520	  build.
521
522config SPL_POST_MEM_SUPPORT
523	bool "Support POST drivers"
524	help
525	  Enable support for POST (Power-on Self Test) in SPL. POST is a
526	  procedure that checks that the hardware (CPU or board) appears to
527	  be functionally correctly. It is a sanity check that can be
528	  performed before booting. This enables the drivers in post/drivers
529	  as part of an SPL build.
530
531config SPL_POWER_SUPPORT
532	bool "Support power drivers"
533	help
534	  Enable support for power control in SPL. This includes support
535	  for PMICs (Power-management Integrated Circuits) and some of the
536	  features provided by PMICs. In particular, voltage regulators can
537	  be used to enable/disable power and vary its voltage. That can be
538	  useful in SPL to turn on boot peripherals and adjust CPU voltage
539	  so that the clock speed can be increased. This enables the drivers
540	  in drivers/power, drivers/power/pmic and drivers/power/regulator
541	  as part of an SPL build.
542
543config SPL_RAM_SUPPORT
544	bool "Support booting from RAM"
545	default y if MICROBLAZE || ARCH_SOCFPGA || TEGRA || ARCH_ZYNQ
546	help
547	  Enable booting of an image in RAM. The image can be preloaded or
548	  it can be loaded by SPL directly into RAM (e.g. using USB).
549
550config SPL_RAM_DEVICE
551	bool "Support booting from preloaded image in RAM"
552	depends on SPL_RAM_SUPPORT
553	default y if MICROBLAZE || ARCH_SOCFPGA || TEGRA || ARCH_ZYNQ
554	help
555	  Enable booting of an image already loaded in RAM. The image has to
556	  be already in memory when SPL takes over, e.g. loaded by the boot
557	  ROM.
558
559config SPL_RTC_SUPPORT
560	bool "Support RTC drivers"
561	help
562	  Enable RTC (Real-time Clock) support in SPL. This includes support
563	  for reading and setting the time. Some RTC devices also have some
564	  non-volatile (battery-backed) memory which is accessible if
565	  needed. This enables the drivers in drivers/rtc as part of an SPL
566	  build.
567
568config SPL_SATA_SUPPORT
569	bool "Support loading from SATA"
570	help
571	  Enable support for SATA (Serial AT attachment) in SPL. This allows
572	  use of SATA devices such as hard drives and flash drivers for
573	  loading U-Boot. SATA is used in higher-end embedded systems and
574	  can provide higher performance than MMC , at somewhat higher
575	  expense and power consumption. This enables loading from SATA
576	  using a configured device.
577
578config SPL_SERIAL_SUPPORT
579	bool "Support serial"
580	help
581	  Enable support for serial in SPL. This allows use of a serial UART
582	  for displaying messages while SPL is running. It also brings in
583	  printf() and panic() functions. This should normally be enabled
584	  unless there are space reasons not to. Even then, consider
585	  enabling USE_TINY_PRINTF which is a small printf() version.
586
587config SPL_SPI_FLASH_SUPPORT
588	bool "Support SPI flash drivers"
589	help
590	  Enable support for using SPI flash in SPL, and loading U-Boot from
591	  SPI flash. SPI flash (Serial Peripheral Bus flash) is named after
592	  the SPI bus that is used to connect it to a system. It is a simple
593	  but fast bidirectional 4-wire bus (clock, chip select and two data
594	  lines). This enables the drivers in drivers/mtd/spi as part of an
595	  SPL build. This normally requires SPL_SPI_SUPPORT.
596
597config SPL_SPI_SUPPORT
598	bool "Support SPI drivers"
599	help
600	  Enable support for using SPI in SPL. This is used for connecting
601	  to SPI flash for loading U-Boot. See SPL_SPI_FLASH_SUPPORT for
602	  more details on that. The SPI driver provides the transport for
603	  data between the SPI flash and the CPU. This option can be used to
604	  enable SPI drivers that are needed for other purposes also, such
605	  as a SPI PMIC.
606
607config SPL_USB_HOST_SUPPORT
608	bool "Support USB host drivers"
609	help
610	  Enable access to USB (Universal Serial Bus) host devices so that
611	  SPL can load U-Boot from a connected USB peripheral, such as a USB
612	  flash stick. While USB takes a little longer to start up than most
613	  buses, it is very flexible since many different types of storage
614	  device can be attached. This option enables the drivers in
615	  drivers/usb/host as part of an SPL build.
616
617config SPL_USB_SUPPORT
618	bool "Support loading from USB"
619	depends on SPL_USB_HOST_SUPPORT
620	help
621	  Enable support for USB devices in SPL. This allows use of USB
622	  devices such as hard drives and flash drivers for loading U-Boot.
623	  The actual drivers are enabled separately using the normal U-Boot
624	  config options. This enables loading from USB using a configured
625	  device.
626
627config SPL_USB_GADGET_SUPPORT
628	bool "Suppport USB Gadget drivers"
629	help
630	  Enable USB Gadget API which allows to enable USB device functions
631	  in SPL.
632
633if SPL_USB_GADGET_SUPPORT
634
635config SPL_USBETH_SUPPORT
636	bool "Support USB Ethernet drivers"
637	help
638	  Enable access to the USB network subsystem and associated
639	  drivers in SPL. This permits SPL to load U-Boot over a
640	  USB-connected Ethernet link (such as a USB Ethernet dongle) rather
641	  than from an onboard peripheral. Environment support is required
642	  since the network stack uses a number of environment variables.
643	  See also SPL_NET_SUPPORT and SPL_ETH_SUPPORT.
644
645config SPL_DFU_SUPPORT
646	bool "Support DFU (Device Firmware Upgarde)"
647	select SPL_HASH_SUPPORT
648	select SPL_DFU_NO_RESET
649	depends on SPL_RAM_SUPPORT
650	help
651	  This feature enables the DFU (Device Firmware Upgarde) in SPL with
652	  RAM memory device support. The ROM code will load and execute
653	  the SPL built with dfu. The user can load binaries (u-boot/kernel) to
654	  selected device partition from host-pc using dfu-utils.
655	  This feature is useful to flash the binaries to factory or bare-metal
656	  boards using USB interface.
657
658choice
659	bool "DFU device selection"
660	depends on SPL_DFU_SUPPORT
661
662config SPL_DFU_RAM
663	bool "RAM device"
664	depends on SPL_DFU_SUPPORT && SPL_RAM_SUPPORT
665	help
666	 select RAM/DDR memory device for loading binary images
667	 (u-boot/kernel) to the selected device partition using
668	 DFU and execute the u-boot/kernel from RAM.
669
670endchoice
671
672config SPL_USB_SDP_SUPPORT
673	bool "Support SDP (Serial Download Protocol)"
674	help
675	  Enable Serial Download Protocol (SDP) device support in SPL. This
676	  allows to download images into memory and execute (jump to) them
677	  using the same protocol as implemented by the i.MX family's boot ROM.
678endif
679
680config SPL_WATCHDOG_SUPPORT
681	bool "Support watchdog drivers"
682	help
683	  Enable support for watchdog drivers in SPL. A watchdog is
684	  typically a hardware peripheral which can reset the system when it
685	  detects no activity for a while (such as a software crash). This
686	  enables the drivers in drivers/watchdog as part of an SPL build.
687
688config SPL_YMODEM_SUPPORT
689	bool "Support loading using Ymodem"
690	help
691	  While loading from serial is slow it can be a useful backup when
692	  there is no other option. The Ymodem protocol provides a reliable
693	  means of transmitting U-Boot over a serial line for using in SPL,
694	  with a checksum to ensure correctness.
695
696config SPL_ATF_SUPPORT
697	bool "Support ARM Trusted Firmware"
698	depends on ARM64
699	help
700	  ATF(ARM Trusted Firmware) is a component for ARM arch64 which
701	  is loaded by SPL(which is considered as BL2 in ATF terminology).
702	  More detail at: https://github.com/ARM-software/arm-trusted-firmware
703
704config SPL_ATF_TEXT_BASE
705	depends on SPL_ATF_SUPPORT
706	hex "ATF BL31 base address"
707	help
708	  This is the base address in memory for ATF BL31 text and entry point.
709
710config TPL
711	bool
712	depends on SUPPORT_TPL
713	prompt "Enable TPL"
714	help
715	  If you want to build TPL as well as the normal image and SPL, say Y.
716
717if TPL
718
719config TPL_LDSCRIPT
720        string "Linker script for the TPL stage"
721	depends on TPL
722	help
723	  The TPL stage will usually require a different linker-script
724	  (as it runs from a different memory region) than the regular
725	  U-Boot stage.  Set this to the path of the linker-script to
726	  be used for TPL.
727
728	  May be left empty to trigger the Makefile infrastructure to
729	  fall back to the linker-script used for the SPL stage.
730
731config TPL_NEEDS_SEPARATE_TEXT_BASE
732        bool "TPL needs a separate text-base"
733	default n
734	depends on TPL
735	help
736	  Enable, if the TPL stage should not inherit its text-base
737	  from the SPL stage.  When enabled, a base address for the
738	  .text sections of the TPL stage has to be set below.
739
740config TPL_NEEDS_SEPARATE_STACK
741        bool "TPL needs a separate initial stack-pointer"
742	default n
743	depends on TPL
744	help
745	  Enable, if the TPL stage should not inherit its initial
746	  stack-pointer from the settings for the SPL stage.
747
748config TPL_TEXT_BASE
749        hex "Base address for the .text section of the TPL stage"
750	depends on TPL_NEEDS_SEPARATE_TEXT_BASE
751	help
752	  The base address for the .text section of the TPL stage.
753
754config TPL_MAX_SIZE
755        int "Maximum size (in bytes) for the TPL stage"
756	default 0
757	depends on TPL
758	help
759	  The maximum size (in bytes) of the TPL stage.
760
761config TPL_STACK
762        hex "Address of the initial stack-pointer for the TPL stage"
763	depends on TPL_NEEDS_SEPARATE_STACK
764	help
765	  The address of the initial stack-pointer for the TPL stage.
766	  Usually this will be the (aligned) top-of-stack.
767
768config TPL_BOOTROM_SUPPORT
769        bool "Support returning to the BOOTROM (from TPL)"
770	help
771	  Some platforms (e.g. the Rockchip RK3368) provide support in their
772	  ROM for loading the next boot-stage after performing basic setup
773	  from the TPL stage.
774
775	  Enable this option, to return to the BOOTROM through the
776	  BOOT_DEVICE_BOOTROM (or fall-through to the next boot device in the
777	  boot device list, if not implemented for a given board)
778
779config TPL_DRIVERS_MISC_SUPPORT
780	bool "Support misc drivers in TPL"
781	help
782	  Enable miscellaneous drivers in TPL. These drivers perform various
783	  tasks that don't fall nicely into other categories, Enable this
784	  option to build the drivers in drivers/misc as part of an TPL
785	  build, for those that support building in TPL (not all drivers do).
786
787config TPL_ENV_SUPPORT
788	bool "Support an environment"
789	help
790	  Enable environment support in TPL. See SPL_ENV_SUPPORT for details.
791
792config TPL_I2C_SUPPORT
793	bool "Support I2C"
794	help
795	  Enable support for the I2C bus in TPL. See SPL_I2C_SUPPORT for
796	  details.
797
798config TPL_LIBCOMMON_SUPPORT
799	bool "Support common libraries"
800	help
801	  Enable support for common U-Boot libraries within TPL. See
802	  SPL_LIBCOMMON_SUPPORT for details.
803
804config TPL_LIBGENERIC_SUPPORT
805	bool "Support generic libraries"
806	help
807	  Enable support for generic U-Boot libraries within TPL. See
808	  SPL_LIBGENERIC_SUPPORT for details.
809
810config TPL_MPC8XXX_INIT_DDR_SUPPORT
811	bool "Support MPC8XXX DDR init"
812	help
813	  Enable support for DDR-SDRAM on the MPC8XXX family within TPL. See
814	  SPL_MPC8XXX_INIT_DDR_SUPPORT for details.
815
816config TPL_MMC_SUPPORT
817	bool "Support MMC"
818	depends on MMC
819	help
820	  Enable support for MMC within TPL. See SPL_MMC_SUPPORT for details.
821
822config TPL_NAND_SUPPORT
823	bool "Support NAND flash"
824	help
825	  Enable support for NAND in TPL. See SPL_NAND_SUPPORT for details.
826
827config TPL_SERIAL_SUPPORT
828	bool "Support serial"
829	help
830	  Enable support for serial in TPL. See SPL_SERIAL_SUPPORT for
831	  details.
832
833config TPL_SPI_FLASH_SUPPORT
834	bool "Support SPI flash drivers"
835	help
836	  Enable support for using SPI flash in TPL. See SPL_SPI_FLASH_SUPPORT
837	  for details.
838
839config TPL_SPI_SUPPORT
840	bool "Support SPI drivers"
841	help
842	  Enable support for using SPI in TPL. See SPL_SPI_SUPPORT for
843	  details.
844
845endif # TPL
846
847endif # SPL
848endmenu
849