blob: c28d9e89f68bc76abdde6fc78585034769e47e4a [file] [log] [blame]
Simon Glass547cb402017-08-03 12:21:49 -06001menu "Environment"
2
Rasmus Villemoesecdf0742019-12-15 22:29:39 +00003config ENV_SUPPORT
4 def_bool y
5
Simon Glass7327fe72021-10-21 21:08:46 -06006config ENV_SOURCE_FILE
7 string "Environment file to use"
8 default ""
9 help
10 This sets the basename to use to generate the default environment.
11 This a text file as described in doc/usage/environment.rst
12
13 The file must be in the board directory and have a .env extension, so
14 the resulting filename is typically
15 board/<vendor>/<board>/<CONFIG_ENV_SOURCE_FILE>.env
16
17 If the file is not present, an error is produced.
18
19 If this CONFIG is empty, U-Boot uses CONFIG SYS_BOARD as a default, if
20 the file board/<vendor>/<board>/<SYS_BOARD>.env exists. Otherwise the
21 environment is assumed to come from the ad-hoc
22 CONFIG_EXTRA_ENV_SETTINGS #define
23
Rasmus Villemoes21294752020-02-19 09:47:39 +000024config SAVEENV
25 def_bool y if CMD_SAVEENV
26
Adam Ford710966e2020-07-03 06:48:56 -050027config ENV_OVERWRITE
28 bool "Enable overwriting environment"
29 help
30 Use this to permit overriding of certain environmental variables
31 like Ethernet and Serial
32
Tom Rini0459c6b2022-06-12 20:01:58 -040033config ENV_MIN_ENTRIES
34 int "Minimum number of entries in the environment hashtable"
35 default 64
36 help
37 Minimum number of entries in the hash table that is used internally
38 to store the environment settings.
39
40config ENV_MAX_ENTRIES
41 int "Maximumm number of entries in the environment hashtable"
42 default 512
43 help
44 Maximum number of entries in the hash table that is used internally
45 to store the environment settings. The default setting is supposed to
46 be generous and should work in most cases. This setting can be used
47 to tune behaviour; see lib/hashtable.c for details.
48
Simon Glass87551f12017-08-03 12:21:59 -060049config ENV_IS_NOWHERE
50 bool "Environment is not stored"
Patrice Chotardaf755812019-05-07 11:24:02 +020051 default y if !ENV_IS_IN_EEPROM && !ENV_IS_IN_EXT4 && \
52 !ENV_IS_IN_FAT && !ENV_IS_IN_FLASH && \
53 !ENV_IS_IN_MMC && !ENV_IS_IN_NAND && \
54 !ENV_IS_IN_NVRAM && !ENV_IS_IN_ONENAND && \
55 !ENV_IS_IN_REMOTE && !ENV_IS_IN_SPI_FLASH && \
56 !ENV_IS_IN_UBI
Simon Glass87551f12017-08-03 12:21:59 -060057 help
58 Define this if you don't want to or can't have an environment stored
Shyam Sainiefe757c2018-06-07 19:47:19 +053059 on a storage medium. In this case the environment will still exist
Simon Glass87551f12017-08-03 12:21:59 -060060 while U-Boot is running, but once U-Boot exits it will not be
61 stored. U-Boot will therefore always start up with a default
62 environment.
63
Simon Glass547cb402017-08-03 12:21:49 -060064config ENV_IS_IN_EEPROM
65 bool "Environment in EEPROM"
66 depends on !CHAIN_OF_TRUST
67 help
68 Use this if you have an EEPROM or similar serial access
69 device and a driver for it.
70
71 - CONFIG_ENV_OFFSET:
72 - CONFIG_ENV_SIZE:
73
74 These two #defines specify the offset and size of the
75 environment area within the total memory of your EEPROM.
76
Simon Glass547cb402017-08-03 12:21:49 -060077 Note that we consider the length of the address field to
78 still be one byte because the extra address bits are hidden
79 in the chip address.
80
Simon Glass547cb402017-08-03 12:21:49 -060081 EEPROM which holds the environment, is reached over
82 a pca9547 i2c mux with address 0x70, channel 3.
83
84config ENV_IS_IN_FAT
85 bool "Environment is in a FAT filesystem"
86 depends on !CHAIN_OF_TRUST
Maxime Ripard7569e182018-01-23 21:17:01 +010087 default y if ARCH_BCM283X
Maxime Ripard8b7dcd32018-01-23 21:17:04 +010088 default y if ARCH_SUNXI && MMC
Maxime Ripard7569e182018-01-23 21:17:01 +010089 default y if MMC_OMAP_HS && TI_COMMON_CMD_OPTIONS
Tuomas Tynkkynendc256cd2018-01-05 02:45:19 +020090 select FS_FAT
Simon Glass547cb402017-08-03 12:21:49 -060091 select FAT_WRITE
92 help
Simon Glassea8bf842017-08-03 12:21:50 -060093 Define this if you want to use the FAT file system for the environment.
Simon Glass547cb402017-08-03 12:21:49 -060094
Jorge Ramirez-Ortiz4a4c26d2018-01-10 11:33:48 +010095config ENV_IS_IN_EXT4
96 bool "Environment is in a EXT4 filesystem"
97 depends on !CHAIN_OF_TRUST
Michal Simek4b4ba3c2020-08-19 10:44:23 +020098 select FS_EXT4
Jorge Ramirez-Ortiz4a4c26d2018-01-10 11:33:48 +010099 select EXT4_WRITE
100 help
101 Define this if you want to use the EXT4 file system for the environment.
102
Simon Glass547cb402017-08-03 12:21:49 -0600103config ENV_IS_IN_FLASH
104 bool "Environment in flash memory"
105 depends on !CHAIN_OF_TRUST
Maxime Ripard7569e182018-01-23 21:17:01 +0100106 default y if ARCH_CINTEGRATOR
107 default y if ARCH_INTEGRATOR_CP
Tom Rini7ab2f5f2021-05-14 21:34:10 -0400108 default y if M548x || M547x || M5282
Maxime Ripard7569e182018-01-23 21:17:01 +0100109 default y if MCF532x || MCF52x2
110 default y if MPC86xx || MPC83xx
Tom Rinie5404982021-05-14 21:34:26 -0400111 default y if ARCH_MPC8548
Maxime Ripard7569e182018-01-23 21:17:01 +0100112 default y if SH && !CPU_SH4
Simon Glass547cb402017-08-03 12:21:49 -0600113 help
114 Define this if you have a flash device which you want to use for the
115 environment.
116
117 a) The environment occupies one whole flash sector, which is
118 "embedded" in the text segment with the U-Boot code. This
119 happens usually with "bottom boot sector" or "top boot
120 sector" type flash chips, which have several smaller
121 sectors at the start or the end. For instance, such a
122 layout can have sector sizes of 8, 2x4, 16, Nx32 kB. In
123 such a case you would place the environment in one of the
124 4 kB sectors - with U-Boot code before and after it. With
125 "top boot sector" type flash chips, you would put the
126 environment in one of the last sectors, leaving a gap
127 between U-Boot and the environment.
128
129 CONFIG_ENV_OFFSET:
130
131 Offset of environment data (variable area) to the
132 beginning of flash memory; for instance, with bottom boot
133 type flash chips the second sector can be used: the offset
134 for this sector is given here.
135
Tom Rini6a5dccc2022-11-16 13:10:41 -0500136 CONFIG_ENV_OFFSET is used relative to CFG_SYS_FLASH_BASE.
Simon Glass547cb402017-08-03 12:21:49 -0600137
138 CONFIG_ENV_ADDR:
139
140 This is just another way to specify the start address of
141 the flash sector containing the environment (instead of
142 CONFIG_ENV_OFFSET).
143
144 CONFIG_ENV_SECT_SIZE:
145
146 Size of the sector containing the environment.
147
148
149 b) Sometimes flash chips have few, equal sized, BIG sectors.
150 In such a case you don't want to spend a whole sector for
151 the environment.
152
153 CONFIG_ENV_SIZE:
154
155 If you use this in combination with CONFIG_ENV_IS_IN_FLASH
156 and CONFIG_ENV_SECT_SIZE, you can specify to use only a part
157 of this flash sector for the environment. This saves
158 memory for the RAM copy of the environment.
159
160 It may also save flash memory if you decide to use this
161 when your environment is "embedded" within U-Boot code,
162 since then the remainder of the flash sector could be used
163 for U-Boot code. It should be pointed out that this is
164 STRONGLY DISCOURAGED from a robustness point of view:
165 updating the environment in flash makes it always
166 necessary to erase the WHOLE sector. If something goes
167 wrong before the contents has been restored from a copy in
168 RAM, your target system will be dead.
169
170 CONFIG_ENV_ADDR_REDUND
Simon Glass547cb402017-08-03 12:21:49 -0600171
172 These settings describe a second storage area used to hold
173 a redundant copy of the environment data, so that there is
174 a valid backup copy in case there is a power failure during
175 a "saveenv" operation.
176
177 BE CAREFUL! Any changes to the flash layout, and some changes to the
178 source code will make it necessary to adapt <board>/u-boot.lds*
179 accordingly!
180
181config ENV_IS_IN_MMC
182 bool "Environment in an MMC device"
183 depends on !CHAIN_OF_TRUST
Maxime Ripard662a1ec2018-01-23 21:17:00 +0100184 depends on MMC
Maxime Ripard7569e182018-01-23 21:17:01 +0100185 default y if ARCH_EXYNOS4
186 default y if MX6SX || MX7D
187 default y if TEGRA30 || TEGRA124
188 default y if TEGRA_ARMV8_COMMON
Simon Glass547cb402017-08-03 12:21:49 -0600189 help
190 Define this if you have an MMC device which you want to use for the
191 environment.
192
193 CONFIG_SYS_MMC_ENV_DEV:
194
195 Specifies which MMC device the environment is stored in.
196
197 CONFIG_SYS_MMC_ENV_PART (optional):
198
199 Specifies which MMC partition the environment is stored in. If not
200 set, defaults to partition 0, the user area. Common values might be
201 1 (first MMC boot partition), 2 (second MMC boot partition).
202
203 CONFIG_ENV_OFFSET:
204 CONFIG_ENV_SIZE:
205
206 These two #defines specify the offset and size of the environment
207 area within the specified MMC device.
208
209 If offset is positive (the usual case), it is treated as relative to
210 the start of the MMC partition. If offset is negative, it is treated
211 as relative to the end of the MMC partition. This can be useful if
212 your board may be fitted with different MMC devices, which have
213 different sizes for the MMC partitions, and you always want the
214 environment placed at the very end of the partition, to leave the
215 maximum possible space before it, to store other data.
216
217 These two values are in units of bytes, but must be aligned to an
218 MMC sector boundary.
219
220 CONFIG_ENV_OFFSET_REDUND (optional):
221
222 Specifies a second storage area, of CONFIG_ENV_SIZE size, used to
223 hold a redundant copy of the environment data. This provides a
224 valid backup copy in case the other copy is corrupted, e.g. due
225 to a power failure during a "saveenv" operation.
226
227 This value may also be positive or negative; this is handled in the
228 same way as CONFIG_ENV_OFFSET.
229
Marek Vasut509f36e2021-10-17 19:23:36 +0200230 In case CONFIG_SYS_MMC_ENV_PART is 1 (i.e. environment in eMMC boot
231 partition) then setting CONFIG_ENV_OFFSET_REDUND to the same value
232 as CONFIG_ENV_OFFSET makes use of the second eMMC boot partition for
233 the redundant environment copy.
234
Simon Glass547cb402017-08-03 12:21:49 -0600235 This value is also in units of bytes, but must also be aligned to
236 an MMC sector boundary.
237
Simon Glass547cb402017-08-03 12:21:49 -0600238config ENV_IS_IN_NAND
239 bool "Environment in a NAND device"
240 depends on !CHAIN_OF_TRUST
241 help
242 Define this if you have a NAND device which you want to use for the
243 environment.
244
245 - CONFIG_ENV_OFFSET:
246 - CONFIG_ENV_SIZE:
247
248 These two #defines specify the offset and size of the environment
249 area within the first NAND device. CONFIG_ENV_OFFSET must be
250 aligned to an erase block boundary.
251
252 - CONFIG_ENV_OFFSET_REDUND (optional):
253
254 This setting describes a second storage area of CONFIG_ENV_SIZE
255 size used to hold a redundant copy of the environment data, so
256 that there is a valid backup copy in case there is a power failure
257 during a "saveenv" operation. CONFIG_ENV_OFFSET_REDUND must be
258 aligned to an erase block boundary.
259
Simon Glass547cb402017-08-03 12:21:49 -0600260 - CONFIG_ENV_OFFSET_OOB (optional):
261
262 Enables support for dynamically retrieving the offset of the
263 environment from block zero's out-of-band data. The
264 "nand env.oob" command can be used to record this offset.
265 Currently, CONFIG_ENV_OFFSET_REDUND is not supported when
266 using CONFIG_ENV_OFFSET_OOB.
267
Tom Rini0eeb1c72022-06-13 22:57:33 -0400268config ENV_RANGE
269 hex "Length of the region in which the environment can be written"
270 depends on ENV_IS_IN_NAND
271 range ENV_SIZE 0x7fffffff
272 default ENV_SIZE
273 help
274 This should be a multiple of the NAND device's block size.
275 Specifying a range with more erase blocks than are needed to hold
276 CONFIG_ENV_SIZE allows bad blocks within the range to be avoided.
277
Simon Glass547cb402017-08-03 12:21:49 -0600278config ENV_IS_IN_NVRAM
279 bool "Environment in a non-volatile RAM"
280 depends on !CHAIN_OF_TRUST
281 help
282 Define this if you have some non-volatile memory device
283 (NVRAM, battery buffered SRAM) which you want to use for the
284 environment.
285
286 - CONFIG_ENV_ADDR:
287 - CONFIG_ENV_SIZE:
288
289 These two #defines are used to determine the memory area you
290 want to use for environment. It is assumed that this memory
291 can just be read and written to, without any special
292 provision.
293
294config ENV_IS_IN_ONENAND
295 bool "Environment is in OneNAND"
296 depends on !CHAIN_OF_TRUST
297 help
298 Define this if you want to put your local device's environment in
299 OneNAND.
300
301 - CONFIG_ENV_ADDR:
302 - CONFIG_ENV_SIZE:
303
304 These two #defines are used to determine the device range you
305 want to use for environment. It is assumed that this memory
306 can just be read and written to, without any special
307 provision.
308
309config ENV_IS_IN_REMOTE
Heinrich Schuchardtaefbfe12018-03-17 22:53:11 +0000310 bool "Environment is in remote memory space"
Simon Glass547cb402017-08-03 12:21:49 -0600311 depends on !CHAIN_OF_TRUST
312 help
313 Define this if you have a remote memory space which you
314 want to use for the local device's environment.
315
316 - CONFIG_ENV_ADDR:
317 - CONFIG_ENV_SIZE:
318
319 These two #defines specify the address and size of the
320 environment area within the remote memory space. The
321 local device can get the environment from remote memory
322 space by SRIO or PCIE links.
323
324config ENV_IS_IN_SPI_FLASH
325 bool "Environment is in SPI flash"
Tom Rinie5289a72019-05-29 17:01:28 -0400326 depends on !CHAIN_OF_TRUST && SPI
Maxime Ripard7569e182018-01-23 21:17:01 +0100327 default y if ARMADA_XP
328 default y if INTEL_BAYTRAIL
329 default y if INTEL_BRASWELL
330 default y if INTEL_BROADWELL
331 default y if NORTHBRIDGE_INTEL_IVYBRIDGE
332 default y if INTEL_QUARK
333 default y if INTEL_QUEENSBAY
Andre Przywarae28ff722022-01-11 12:46:05 +0000334 default y if ARCH_SUNXI
Simon Glass547cb402017-08-03 12:21:49 -0600335 help
336 Define this if you have a SPI Flash memory device which you
337 want to use for the environment.
338
339 - CONFIG_ENV_OFFSET:
340 - CONFIG_ENV_SIZE:
341
342 These two #defines specify the offset and size of the
343 environment area within the SPI Flash. CONFIG_ENV_OFFSET must be
344 aligned to an erase sector boundary.
345
346 - CONFIG_ENV_SECT_SIZE:
347
348 Define the SPI flash's sector size.
349
350 - CONFIG_ENV_OFFSET_REDUND (optional):
351
352 This setting describes a second storage area of CONFIG_ENV_SIZE
353 size used to hold a redundant copy of the environment data, so
354 that there is a valid backup copy in case there is a power failure
355 during a "saveenv" operation. CONFIG_ENV_OFFSET_REDUND must be
356 aligned to an erase sector boundary.
357
Rasmus Villemoese535f5b2021-04-14 20:51:43 +0200358config ENV_SECT_SIZE_AUTO
359 bool "Use automatically detected sector size"
360 depends on ENV_IS_IN_SPI_FLASH
361 help
362 Some boards exist in multiple variants, with different
363 flashes having different sector sizes. In such cases, you
364 can select this option to make U-Boot use the actual sector
365 size when figuring out how much to erase, which can thus be
366 more efficient on the flashes with smaller erase size. Since
367 the environment must always be aligned on a sector boundary,
368 CONFIG_ENV_OFFSET must be aligned to the largest of the
369 different sector sizes, and CONFIG_ENV_SECT_SIZE should be
370 set to that value.
371
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100372config ENV_SPI_BUS
373 int "Value of SPI flash bus for environment"
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100374 depends on ENV_IS_IN_SPI_FLASH
Tom Rini119d2fb2021-12-11 14:55:48 -0500375 default SF_DEFAULT_BUS
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100376 help
Tom Rini119d2fb2021-12-11 14:55:48 -0500377 Value the SPI bus and chip select for environment.
Simon Glass547cb402017-08-03 12:21:49 -0600378
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100379config ENV_SPI_CS
380 int "Value of SPI flash chip select for environment"
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100381 depends on ENV_IS_IN_SPI_FLASH
Tom Rini119d2fb2021-12-11 14:55:48 -0500382 default SF_DEFAULT_CS
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100383 help
Tom Rini119d2fb2021-12-11 14:55:48 -0500384 Value of the SPI chip select for environment.
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100385
386config ENV_SPI_MAX_HZ
Marek Vasutdfe74622019-05-04 19:10:05 +0200387 int "Value of SPI flash max frequency for environment"
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100388 depends on ENV_IS_IN_SPI_FLASH
Tom Rini119d2fb2021-12-11 14:55:48 -0500389 default SF_DEFAULT_SPEED
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100390 help
Tom Rini119d2fb2021-12-11 14:55:48 -0500391 Value of the SPI max work clock for environment.
Simon Glass547cb402017-08-03 12:21:49 -0600392
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100393config ENV_SPI_MODE
394 hex "Value of SPI flash work mode for environment"
Tom Rini119d2fb2021-12-11 14:55:48 -0500395 depends on ENV_IS_IN_SPI_FLASH
396 default SF_DEFAULT_MODE
Patrick Delaunayf8e932e2019-02-27 15:20:38 +0100397 help
398 Value of the SPI work mode for environment.
399 See include/spi.h for value.
Simon Glass547cb402017-08-03 12:21:49 -0600400
Heiko Schocher704d21c2020-10-10 10:28:05 +0200401config ENV_SPI_EARLY
402 bool "Access Environment in SPI flashes before relocation"
403 depends on ENV_IS_IN_SPI_FLASH
404 help
405 Enable this if you want to use Environment in SPI flash
406 before relocation. Call env_init() and than you can use
407 env_get_f() for accessing Environment variables.
408
Simon Glass547cb402017-08-03 12:21:49 -0600409config ENV_IS_IN_UBI
410 bool "Environment in a UBI volume"
411 depends on !CHAIN_OF_TRUST
Miquel Raynal27271b62019-10-03 19:50:12 +0200412 depends on MTD_UBI
413 depends on CMD_UBI
Simon Glass547cb402017-08-03 12:21:49 -0600414 help
415 Define this if you have an UBI volume that you want to use for the
416 environment. This has the benefit of wear-leveling the environment
417 accesses, which is important on NAND.
418
419 - CONFIG_ENV_UBI_PART:
420
421 Define this to a string that is the mtd partition containing the UBI.
422
423 - CONFIG_ENV_UBI_VOLUME:
424
425 Define this to the name of the volume that you want to store the
426 environment in.
427
428 - CONFIG_ENV_UBI_VOLUME_REDUND:
429
430 Define this to the name of another volume to store a second copy of
431 the environment in. This will enable redundant environments in UBI.
432 It is assumed that both volumes are in the same MTD partition.
433
Tom Rini4bb26a42019-11-10 11:28:03 -0500434config SYS_REDUNDAND_ENVIRONMENT
435 bool "Enable redundant environment support"
Tom Rini4bb26a42019-11-10 11:28:03 -0500436 help
437 Normally, the environemt is stored in a single location. By
438 selecting this option, you can then define where to hold a redundant
439 copy of the environment data, so that there is a valid backup copy in
440 case there is a power failure during a "saveenv" operation.
Michal Simekcc780ec2021-01-13 10:25:50 +0100441 Also this config changes the binary environment structure handling
442 which is used by env import/export commands which are independent of
443 storing variables to redundant location on a non volatile device.
Tom Rini4bb26a42019-11-10 11:28:03 -0500444
Simon Glass547cb402017-08-03 12:21:49 -0600445config ENV_FAT_INTERFACE
446 string "Name of the block device for the environment"
447 depends on ENV_IS_IN_FAT
Michal Simek5227e1e2020-02-25 15:50:33 +0100448 default "mmc"
Simon Glass547cb402017-08-03 12:21:49 -0600449 help
450 Define this to a string that is the name of the block device.
451
452config ENV_FAT_DEVICE_AND_PART
453 string "Device and partition for where to store the environemt in FAT"
454 depends on ENV_IS_IN_FAT
455 default "0:1" if TI_COMMON_CMD_OPTIONS
Ashok Reddy Somafb6b3cd2021-02-23 08:07:46 -0700456 default "0:auto" if ARCH_ZYNQ || ARCH_ZYNQMP || ARCH_VERSAL
Samuel Hollandbc42abb2021-04-18 22:16:21 -0500457 default ":auto" if ARCH_SUNXI
Simon Glass547cb402017-08-03 12:21:49 -0600458 default "0" if ARCH_AT91
459 help
460 Define this to a string to specify the partition of the device. It can
461 be as following:
462
463 "D:P", "D:0", "D", "D:" or "D:auto" (D, P are integers. And P >= 1)
464 - "D:P": device D partition P. Error occurs if device D has no
465 partition table.
466 - "D:0": device D.
467 - "D" or "D:": device D partition 1 if device D has partition
468 table, or the whole device D if has no partition
469 table.
470 - "D:auto": first partition in device D with bootable flag set.
471 If none, first valid partition in device D. If no
472 partition table then means device D.
473
David Woodhouse93365392020-06-19 23:07:17 +0100474 If ENV_FAT_INTERFACE is set to "mmc" then device 'D' can be omitted,
475 leaving the string starting with a colon, and the boot device will
476 be used.
477
Simon Glass547cb402017-08-03 12:21:49 -0600478config ENV_FAT_FILE
Shyam Sainiefe757c2018-06-07 19:47:19 +0530479 string "Name of the FAT file to use for the environment"
Simon Glass547cb402017-08-03 12:21:49 -0600480 depends on ENV_IS_IN_FAT
481 default "uboot.env"
482 help
483 It's a string of the FAT file name. This file use to store the
484 environment.
485
Brandon Maierf2815462021-01-16 15:14:43 -0600486config ENV_FAT_FILE_REDUND
487 string "Name of the FAT file to use for the environment"
488 depends on ENV_IS_IN_FAT && SYS_REDUNDAND_ENVIRONMENT
489 default "uboot-redund.env"
490 help
491 It's a string of the FAT file name. This file use to store the
492 redundant environment.
493
Jorge Ramirez-Ortiz4a4c26d2018-01-10 11:33:48 +0100494config ENV_EXT4_INTERFACE
495 string "Name of the block device for the environment"
496 depends on ENV_IS_IN_EXT4
497 help
498 Define this to a string that is the name of the block device.
499
500config ENV_EXT4_DEVICE_AND_PART
501 string "Device and partition for where to store the environemt in EXT4"
502 depends on ENV_IS_IN_EXT4
503 help
504 Define this to a string to specify the partition of the device. It can
505 be as following:
506
507 "D:P", "D:0", "D", "D:" or "D:auto" (D, P are integers. And P >= 1)
508 - "D:P": device D partition P. Error occurs if device D has no
509 partition table.
510 - "D:0": device D.
511 - "D" or "D:": device D partition 1 if device D has partition
512 table, or the whole device D if has no partition
513 table.
514 - "D:auto": first partition in device D with bootable flag set.
515 If none, first valid partition in device D. If no
516 partition table then means device D.
517
David Woodhouse6815e2c2020-08-04 10:05:47 +0100518 If ENV_EXT4_INTERFACE is set to "mmc" then device 'D' can be omitted,
519 leaving the string starting with a colon, and the boot device will
520 be used.
521
Jorge Ramirez-Ortiz4a4c26d2018-01-10 11:33:48 +0100522config ENV_EXT4_FILE
Shyam Sainiefe757c2018-06-07 19:47:19 +0530523 string "Name of the EXT4 file to use for the environment"
Jorge Ramirez-Ortiz4a4c26d2018-01-10 11:33:48 +0100524 depends on ENV_IS_IN_EXT4
Patrick Delaunay955b6712020-07-28 11:51:14 +0200525 default "/uboot.env"
Jorge Ramirez-Ortiz4a4c26d2018-01-10 11:33:48 +0100526 help
527 It's a string of the EXT4 file name. This file use to store the
528 environment (explicit path to the file)
529
Tom Rini5cd7ece2019-11-18 20:02:10 -0500530config ENV_ADDR
531 hex "Environment address"
532 depends on ENV_IS_IN_FLASH || ENV_IS_IN_NVRAM || ENV_IS_IN_ONENAND || \
533 ENV_IS_IN_REMOTE || ENV_IS_IN_SPI_FLASH
534 default 0x0 if ENV_IS_IN_SPI_FLASH
535 help
536 Offset from the start of the device (or partition)
537
538config ENV_ADDR_REDUND
539 hex "Redundant environment address"
540 depends on ENV_IS_IN_FLASH && SYS_REDUNDAND_ENVIRONMENT
541 help
542 Offset from the start of the device (or partition) of the redundant
543 environment location.
Simon Glass547cb402017-08-03 12:21:49 -0600544
545config ENV_OFFSET
Tom Rini5cd7ece2019-11-18 20:02:10 -0500546 hex "Environment offset"
547 depends on ENV_IS_IN_EEPROM || ENV_IS_IN_MMC || ENV_IS_IN_NAND || \
548 ENV_IS_IN_SPI_FLASH
Jagan Tekic4ec2262019-12-21 13:24:35 +0530549 default 0x3f8000 if ARCH_ROCKCHIP && ENV_IS_IN_MMC
Jagan Teki68397572019-12-21 13:24:36 +0530550 default 0x140000 if ARCH_ROCKCHIP && ENV_IS_IN_SPI_FLASH
Andre Przywaracf844082022-01-11 12:46:03 +0000551 default 0xF0000 if ARCH_SUNXI
Michal Simeke93ef192018-07-19 08:45:45 +0200552 default 0xE0000 if ARCH_ZYNQ
553 default 0x1E00000 if ARCH_ZYNQMP
Michal Simek2e53eb22022-09-19 14:21:02 +0200554 default 0x7F40000 if ARCH_VERSAL || ARCH_VERSAL_NET
Alexey Brodkin07dfc092019-01-15 11:42:48 +0300555 default 0 if ARC
Markus Klotzbuecher7bd60e62019-05-15 15:15:54 +0200556 default 0x140000 if ARCH_AT91
557 default 0x260000 if ARCH_OMAP2PLUS
Varalaxmi Bingi52e79212020-02-05 03:58:20 -0700558 default 0x1080000 if MICROBLAZE && ENV_IS_IN_SPI_FLASH
Simon Glass547cb402017-08-03 12:21:49 -0600559 help
560 Offset from the start of the device (or partition)
561
Tom Rini5cd7ece2019-11-18 20:02:10 -0500562config ENV_OFFSET_REDUND
563 hex "Redundant environment offset"
564 depends on (ENV_IS_IN_EEPROM || ENV_IS_IN_MMC || ENV_IS_IN_NAND || \
565 ENV_IS_IN_SPI_FLASH) && SYS_REDUNDAND_ENVIRONMENT
T Karthik Reddy5bb3d912022-08-24 13:23:26 +0200566 default 0x10C0000 if MICROBLAZE
Michal Simek46d6b522021-02-24 10:33:45 +0100567 default 0
Tom Rini5cd7ece2019-11-18 20:02:10 -0500568 help
569 Offset from the start of the device (or partition) of the redundant
570 environment location.
571
Simon Glass547cb402017-08-03 12:21:49 -0600572config ENV_SIZE
573 hex "Environment Size"
Michal Simeke93ef192018-07-19 08:45:45 +0200574 default 0x40000 if ENV_IS_IN_SPI_FLASH && ARCH_ZYNQMP
Andre Przywaracf844082022-01-11 12:46:03 +0000575 default 0x20000 if ARCH_ZYNQ || ARCH_OMAP2PLUS || ARCH_AT91
576 default 0x10000 if ARCH_SUNXI
Jagan Tekic4ec2262019-12-21 13:24:35 +0530577 default 0x8000 if ARCH_ROCKCHIP && ENV_IS_IN_MMC
Jagan Teki68397572019-12-21 13:24:36 +0530578 default 0x2000 if ARCH_ROCKCHIP && ENV_IS_IN_SPI_FLASH
Michal Simek2e53eb22022-09-19 14:21:02 +0200579 default 0x8000 if ARCH_ZYNQMP || ARCH_VERSAL || ARCH_VERSAL_NET
Alexey Brodkin07dfc092019-01-15 11:42:48 +0300580 default 0x4000 if ARC
Markus Klotzbuecher7bd60e62019-05-15 15:15:54 +0200581 default 0x1f000
Simon Glass547cb402017-08-03 12:21:49 -0600582 help
583 Size of the environment storage area
584
Michal Simeke93ef192018-07-19 08:45:45 +0200585config ENV_SECT_SIZE
586 hex "Environment Sector-Size"
Tom Rini5cd7ece2019-11-18 20:02:10 -0500587 depends on ENV_IS_IN_FLASH || ENV_IS_IN_SPI_FLASH
Jagan Teki68397572019-12-21 13:24:36 +0530588 default 0x2000 if ARCH_ROCKCHIP
Michal Simek2e53eb22022-09-19 14:21:02 +0200589 default 0x40000 if ARCH_ZYNQMP || ARCH_VERSAL || ARCH_VERSAL_NET
Markus Klotzbuecher7bd60e62019-05-15 15:15:54 +0200590 default 0x20000 if ARCH_ZYNQ || ARCH_OMAP2PLUS || ARCH_AT91
Varalaxmi Bingi52e79212020-02-05 03:58:20 -0700591 default 0x20000 if MICROBLAZE && ENV_IS_IN_SPI_FLASH
Andre Przywaracf844082022-01-11 12:46:03 +0000592 default 0x10000 if ARCH_SUNXI && ENV_IS_IN_SPI_FLASH
Michal Simeke93ef192018-07-19 08:45:45 +0200593 help
594 Size of the sector containing the environment.
595
Simon Glass547cb402017-08-03 12:21:49 -0600596config ENV_UBI_PART
597 string "UBI partition name"
598 depends on ENV_IS_IN_UBI
599 help
600 MTD partition containing the UBI device
601
602config ENV_UBI_VOLUME
603 string "UBI volume name"
604 depends on ENV_IS_IN_UBI
605 help
606 Name of the volume that you want to store the environment in.
607
Markus Klotzbuecher975bcde2019-05-15 15:15:53 +0200608config ENV_UBI_VOLUME_REDUND
609 string "UBI redundant volume name"
Tom Rini4bb26a42019-11-10 11:28:03 -0500610 depends on ENV_IS_IN_UBI && SYS_REDUNDAND_ENVIRONMENT
Markus Klotzbuecher975bcde2019-05-15 15:15:53 +0200611 help
612 Name of the redundant volume that you want to store the environment in.
613
Hamish Guthrie674ab242019-05-15 15:15:55 +0200614config ENV_UBI_VID_OFFSET
615 int "ubi environment VID offset"
616 depends on ENV_IS_IN_UBI
617 default 0
618 help
619 UBI VID offset for environment. If 0, no custom VID offset is used.
620
Tom Rinica63e712019-11-12 22:46:36 -0500621config SYS_RELOC_GD_ENV_ADDR
Patrick Delaunay9f757532020-06-10 19:28:42 +0200622 bool "Relocate gd->env_addr"
Tom Rinica63e712019-11-12 22:46:36 -0500623 help
624 Relocate the early env_addr pointer so we know it is not inside
625 the binary. Some systems need this and for the rest, it doesn't hurt.
626
Tom Rinieb1f9092020-07-24 17:14:47 -0400627config SYS_MMC_ENV_DEV
628 int "mmc device number"
629 depends on ENV_IS_IN_MMC || ENV_IS_IN_FAT || SYS_LS_PPA_FW_IN_MMC || \
Kuldeep Singhd6cfb902021-08-10 11:20:06 +0530630 CMD_MVEBU_BUBT || FMAN_ENET || QE || PHY_CORTINA
Tom Rinieb1f9092020-07-24 17:14:47 -0400631 default 0
632 help
633 MMC device number on the platform where the environment is stored.
634
635config SYS_MMC_ENV_PART
636 int "mmc partition number"
637 depends on ENV_IS_IN_MMC || ENV_IS_IN_FAT
638 default 0
639 help
640 MMC hardware partition device number on the platform where the
641 environment is stored. Note that this is not related to any software
642 defined partition table but instead if we are in the user area, which is
643 partition 0 or the first boot partition, which is 1 or some other defined
644 partition.
645
Rasmus Villemoes14c71142018-03-20 11:38:45 +0100646config USE_DEFAULT_ENV_FILE
647 bool "Create default environment from file"
648 help
649 Normally, the default environment is automatically generated
650 based on the settings of various CONFIG_* options, as well
651 as the CONFIG_EXTRA_ENV_SETTINGS. By selecting this option,
652 you can instead define the entire default environment in an
653 external file.
654
655config DEFAULT_ENV_FILE
656 string "Path to default environment file"
657 depends on USE_DEFAULT_ENV_FILE
658 help
659 The path containing the default environment. The format is
660 the same as accepted by the mkenvimage tool: lines
661 containing key=value pairs, blank lines and lines beginning
662 with # are ignored.
663
Alex Kiernana410d6e2018-04-01 16:37:53 +0000664config ENV_VARS_UBOOT_RUNTIME_CONFIG
665 bool "Add run-time information to the environment"
666 help
667 Enable this in order to add variables describing certain
668 run-time determined information about the hardware to the
669 environment. These will be named board_name, board_rev.
670
Ovidiu Panait86ccd752020-05-06 20:38:42 +0300671config DELAY_ENVIRONMENT
672 bool "Delay environment loading"
673 depends on !OF_CONTROL
674 help
675 Enable this to inhibit loading the environment during board
676 initialization. This can address the security risk of untrusted data
677 being used during boot. Normally the environment is loaded when the
678 board is initialised so that it is available to U-Boot. This inhibits
679 that so that the environment is not available until explicitly loaded
680 later by U-Boot code. With CONFIG_OF_CONTROL this is instead
681 controlled by the value of /config/load-environment.
682
Rasmus Villemoescf8e5432021-04-21 11:06:54 +0200683config ENV_IMPORT_FDT
684 bool "Amend environment by FDT properties"
685 depends on OF_CONTROL
686 help
687 If selected, after the environment has been loaded from its
688 persistent location, the "env_fdt_path" variable is looked
689 up and used as a path to a node in the control DTB. The
690 property/value pairs in that node is then used to update the
691 run-time environment. This can be useful to use the same
692 U-Boot binary with different board variants.
693
694config ENV_FDT_PATH
695 string "Default value for env_fdt_path variable"
696 depends on ENV_IMPORT_FDT
697 default "/config/environment"
698 help
699 The initial value of the env_fdt_path variable.
700
Marek Vasuta7b82672020-07-07 20:51:38 +0200701config ENV_APPEND
702 bool "Always append the environment with new data"
Marek Vasuta7b82672020-07-07 20:51:38 +0200703 help
704 If defined, the environment hash table is only ever appended with new
705 data, but the existing hash table can never be dropped and reloaded
706 with newly imported data. This may be used in combination with static
707 flags to e.g. to protect variables which must not be modified.
708
Marek Vasut803549f2020-07-07 20:51:39 +0200709config ENV_WRITEABLE_LIST
710 bool "Permit write access only to listed variables"
Marek Vasut803549f2020-07-07 20:51:39 +0200711 help
712 If defined, only environment variables which explicitly set the 'w'
713 writeable flag can be written and modified at runtime. No variables
714 can be otherwise created, written or imported into the environment.
715
Marek Vasutb7f3f232020-05-22 01:10:14 +0200716config ENV_ACCESS_IGNORE_FORCE
717 bool "Block forced environment operations"
Marek Vasutb7f3f232020-05-22 01:10:14 +0200718 help
719 If defined, don't allow the -f switch to env set override variable
720 access flags.
721
York Sun187da8d2018-06-26 10:03:22 -0700722if SPL_ENV_SUPPORT
723config SPL_ENV_IS_NOWHERE
724 bool "SPL Environment is not stored"
725 default y if ENV_IS_NOWHERE
726 help
727 Similar to ENV_IS_NOWHERE, used for SPL environment.
728
729config SPL_ENV_IS_IN_MMC
730 bool "SPL Environment in an MMC device"
731 depends on !SPL_ENV_IS_NOWHERE
732 depends on ENV_IS_IN_MMC
733 default y
734 help
735 Similar to ENV_IS_IN_MMC, used for SPL environment.
736
737config SPL_ENV_IS_IN_FAT
738 bool "SPL Environment is in a FAT filesystem"
739 depends on !SPL_ENV_IS_NOWHERE
740 depends on ENV_IS_IN_FAT
741 default y
742 help
743 Similar to ENV_IS_IN_FAT, used for SPL environment.
744
745config SPL_ENV_IS_IN_EXT4
746 bool "SPL Environment is in a EXT4 filesystem"
747 depends on !SPL_ENV_IS_NOWHERE
748 depends on ENV_IS_IN_EXT4
749 default y
750 help
751 Similar to ENV_IS_IN_EXT4, used for SPL environment.
752
753config SPL_ENV_IS_IN_NAND
754 bool "SPL Environment in a NAND device"
755 depends on !SPL_ENV_IS_NOWHERE
756 depends on ENV_IS_IN_NAND
757 default y
758 help
759 Similar to ENV_IS_IN_NAND, used for SPL environment.
760
761config SPL_ENV_IS_IN_SPI_FLASH
762 bool "SPL Environment is in SPI flash"
763 depends on !SPL_ENV_IS_NOWHERE
764 depends on ENV_IS_IN_SPI_FLASH
765 default y
766 help
767 Similar to ENV_IS_IN_SPI_FLASH, used for SPL environment.
768
769config SPL_ENV_IS_IN_FLASH
770 bool "SPL Environment in flash memory"
771 depends on !SPL_ENV_IS_NOWHERE
772 depends on ENV_IS_IN_FLASH
773 default y
774 help
775 Similar to ENV_IS_IN_FLASH, used for SPL environment.
776
777endif
778
779if TPL_ENV_SUPPORT
780
781config TPL_ENV_IS_NOWHERE
782 bool "TPL Environment is not stored"
783 default y if ENV_IS_NOWHERE
784 help
785 Similar to ENV_IS_NOWHERE, used for TPL environment.
786
787config TPL_ENV_IS_IN_MMC
788 bool "TPL Environment in an MMC device"
789 depends on !TPL_ENV_IS_NOWHERE
790 depends on ENV_IS_IN_MMC
791 default y
792 help
793 Similar to ENV_IS_IN_MMC, used for TPL environment.
794
795config TPL_ENV_IS_IN_FAT
796 bool "TPL Environment is in a FAT filesystem"
797 depends on !TPL_ENV_IS_NOWHERE
798 depends on ENV_IS_IN_FAT
799 default y
800 help
801 Similar to ENV_IS_IN_FAT, used for TPL environment.
802
803config TPL_ENV_IS_IN_EXT4
804 bool "TPL Environment is in a EXT4 filesystem"
805 depends on !TPL_ENV_IS_NOWHERE
806 depends on ENV_IS_IN_EXT4
807 default y
808 help
809 Similar to ENV_IS_IN_EXT4, used for TPL environment.
810
811config TPL_ENV_IS_IN_NAND
812 bool "TPL Environment in a NAND device"
813 depends on !TPL_ENV_IS_NOWHERE
814 depends on ENV_IS_IN_NAND
815 default y
816 help
817 Similar to ENV_IS_IN_NAND, used for TPL environment.
818
819config TPL_ENV_IS_IN_SPI_FLASH
820 bool "TPL Environment is in SPI flash"
821 depends on !TPL_ENV_IS_NOWHERE
822 depends on ENV_IS_IN_SPI_FLASH
823 default y
824 help
825 Similar to ENV_IS_IN_SPI_FLASH, used for TPL environment.
826
827config TPL_ENV_IS_IN_FLASH
828 bool "TPL Environment in flash memory"
829 depends on !TPL_ENV_IS_NOWHERE
830 depends on ENV_IS_IN_FLASH
831 default y
832 help
833 Similar to ENV_IS_IN_FLASH, used for TPL environment.
834
835endif
836
Tom Rini5fb860c2022-02-25 11:19:48 -0500837config USE_BOOTFILE
838 bool "Add a 'bootfile' environment variable"
839 help
840 The "bootfile" variable is used in some cases to allow for
841 controlling what file U-Boot will attempt to load and boot. To set
842 this, enable this option and set the value in the next question.
843
844config BOOTFILE
845 string "'bootfile' environment variable value"
846 depends on USE_BOOTFILE
847 help
848 The value to set the "bootfile" variable to.
849
Tom Rinife586752022-03-11 09:12:07 -0500850config USE_ETHPRIME
851 bool "Add an 'ethprime' environment variable"
852 help
853 The "ethprime" variable is used in some cases to control which
854 network interface is used first.
855
856config ETHPRIME
857 string "'ethprime' environment variable value"
858 depends on USE_ETHPRIME
859 help
860 The value to set the "ethprime" variable to.
861
Tom Rini1479a832022-12-02 16:42:27 -0500862config USE_HOSTNAME
863 bool "Set a default 'hostname' value in the environment"
864 default y if X86
865
866config HOSTNAME
867 string "Value of the default 'hostname' value in the environment"
868 depends on USE_HOSTNAME
869 default "x86" if X86
870 default "unknown"
871
Simon Glass99298be2020-09-10 20:21:24 -0600872config VERSION_VARIABLE
873 bool "Add a 'ver' environment variable with the U-Boot version"
874 help
875 If this variable is defined, an environment variable
876 named "ver" is created by U-Boot showing the U-Boot
877 version as printed by the "version" command.
878 Any change to this variable will be reverted at the
879 next reset.
880
Simon Glass547cb402017-08-03 12:21:49 -0600881endmenu