blob: 06d72bad1dcb73a4d46ae02f9424de93e86c676e [file] [log] [blame]
Simon Glass0649cd02017-08-03 12:21:49 -06001menu "Environment"
2
Rasmus Villemoesc8221682019-12-15 22:29:39 +00003config ENV_SUPPORT
4 def_bool y
5
Rasmus Villemoes1d0adee2020-02-19 09:47:39 +00006config SAVEENV
7 def_bool y if CMD_SAVEENV
8
Adam Forde91907a2020-07-03 06:48:56 -05009config ENV_OVERWRITE
10 bool "Enable overwriting environment"
11 help
12 Use this to permit overriding of certain environmental variables
13 like Ethernet and Serial
14
Simon Glassc1c3fe22017-08-03 12:21:59 -060015config ENV_IS_NOWHERE
16 bool "Environment is not stored"
Patrice Chotard208bd2b2019-05-07 11:24:02 +020017 default y if !ENV_IS_IN_EEPROM && !ENV_IS_IN_EXT4 && \
18 !ENV_IS_IN_FAT && !ENV_IS_IN_FLASH && \
19 !ENV_IS_IN_MMC && !ENV_IS_IN_NAND && \
20 !ENV_IS_IN_NVRAM && !ENV_IS_IN_ONENAND && \
21 !ENV_IS_IN_REMOTE && !ENV_IS_IN_SPI_FLASH && \
22 !ENV_IS_IN_UBI
Simon Glassc1c3fe22017-08-03 12:21:59 -060023 help
24 Define this if you don't want to or can't have an environment stored
Shyam Saini919d25c2018-06-07 19:47:19 +053025 on a storage medium. In this case the environment will still exist
Simon Glassc1c3fe22017-08-03 12:21:59 -060026 while U-Boot is running, but once U-Boot exits it will not be
27 stored. U-Boot will therefore always start up with a default
28 environment.
29
Simon Glass0649cd02017-08-03 12:21:49 -060030config ENV_IS_IN_EEPROM
31 bool "Environment in EEPROM"
32 depends on !CHAIN_OF_TRUST
33 help
34 Use this if you have an EEPROM or similar serial access
35 device and a driver for it.
36
37 - CONFIG_ENV_OFFSET:
38 - CONFIG_ENV_SIZE:
39
40 These two #defines specify the offset and size of the
41 environment area within the total memory of your EEPROM.
42
Simon Glass0649cd02017-08-03 12:21:49 -060043 Note that we consider the length of the address field to
44 still be one byte because the extra address bits are hidden
45 in the chip address.
46
Simon Glass0649cd02017-08-03 12:21:49 -060047 - CONFIG_I2C_ENV_EEPROM_BUS
48 if you have an Environment on an EEPROM reached over
49 I2C muxes, you can define here, how to reach this
50 EEPROM. For example:
51
52 #define CONFIG_I2C_ENV_EEPROM_BUS 1
53
54 EEPROM which holds the environment, is reached over
55 a pca9547 i2c mux with address 0x70, channel 3.
56
57config ENV_IS_IN_FAT
58 bool "Environment is in a FAT filesystem"
59 depends on !CHAIN_OF_TRUST
Maxime Ripardfb694642018-01-23 21:17:01 +010060 default y if ARCH_BCM283X
Maxime Ripard0163c912018-01-23 21:17:04 +010061 default y if ARCH_SUNXI && MMC
Maxime Ripardfb694642018-01-23 21:17:01 +010062 default y if MMC_OMAP_HS && TI_COMMON_CMD_OPTIONS
Tuomas Tynkkynen3cd084d2018-01-05 02:45:19 +020063 select FS_FAT
Simon Glass0649cd02017-08-03 12:21:49 -060064 select FAT_WRITE
65 help
Simon Glass91d3aa02017-08-03 12:21:50 -060066 Define this if you want to use the FAT file system for the environment.
Simon Glass0649cd02017-08-03 12:21:49 -060067
Jorge Ramirez-Ortiz1087a792018-01-10 11:33:48 +010068config ENV_IS_IN_EXT4
69 bool "Environment is in a EXT4 filesystem"
70 depends on !CHAIN_OF_TRUST
Michal Simek07661782020-08-19 10:44:23 +020071 select FS_EXT4
Jorge Ramirez-Ortiz1087a792018-01-10 11:33:48 +010072 select EXT4_WRITE
73 help
74 Define this if you want to use the EXT4 file system for the environment.
75
Simon Glass0649cd02017-08-03 12:21:49 -060076config ENV_IS_IN_FLASH
77 bool "Environment in flash memory"
78 depends on !CHAIN_OF_TRUST
Maxime Ripardfb694642018-01-23 21:17:01 +010079 default y if ARCH_CINTEGRATOR
80 default y if ARCH_INTEGRATOR_CP
Tom Rini9b7993b2021-05-14 21:34:10 -040081 default y if M548x || M547x || M5282
Maxime Ripardfb694642018-01-23 21:17:01 +010082 default y if MCF532x || MCF52x2
83 default y if MPC86xx || MPC83xx
Tom Rini1c588572021-05-14 21:34:26 -040084 default y if ARCH_MPC8548
Maxime Ripardfb694642018-01-23 21:17:01 +010085 default y if SH && !CPU_SH4
Simon Glass0649cd02017-08-03 12:21:49 -060086 help
87 Define this if you have a flash device which you want to use for the
88 environment.
89
90 a) The environment occupies one whole flash sector, which is
91 "embedded" in the text segment with the U-Boot code. This
92 happens usually with "bottom boot sector" or "top boot
93 sector" type flash chips, which have several smaller
94 sectors at the start or the end. For instance, such a
95 layout can have sector sizes of 8, 2x4, 16, Nx32 kB. In
96 such a case you would place the environment in one of the
97 4 kB sectors - with U-Boot code before and after it. With
98 "top boot sector" type flash chips, you would put the
99 environment in one of the last sectors, leaving a gap
100 between U-Boot and the environment.
101
102 CONFIG_ENV_OFFSET:
103
104 Offset of environment data (variable area) to the
105 beginning of flash memory; for instance, with bottom boot
106 type flash chips the second sector can be used: the offset
107 for this sector is given here.
108
109 CONFIG_ENV_OFFSET is used relative to CONFIG_SYS_FLASH_BASE.
110
111 CONFIG_ENV_ADDR:
112
113 This is just another way to specify the start address of
114 the flash sector containing the environment (instead of
115 CONFIG_ENV_OFFSET).
116
117 CONFIG_ENV_SECT_SIZE:
118
119 Size of the sector containing the environment.
120
121
122 b) Sometimes flash chips have few, equal sized, BIG sectors.
123 In such a case you don't want to spend a whole sector for
124 the environment.
125
126 CONFIG_ENV_SIZE:
127
128 If you use this in combination with CONFIG_ENV_IS_IN_FLASH
129 and CONFIG_ENV_SECT_SIZE, you can specify to use only a part
130 of this flash sector for the environment. This saves
131 memory for the RAM copy of the environment.
132
133 It may also save flash memory if you decide to use this
134 when your environment is "embedded" within U-Boot code,
135 since then the remainder of the flash sector could be used
136 for U-Boot code. It should be pointed out that this is
137 STRONGLY DISCOURAGED from a robustness point of view:
138 updating the environment in flash makes it always
139 necessary to erase the WHOLE sector. If something goes
140 wrong before the contents has been restored from a copy in
141 RAM, your target system will be dead.
142
143 CONFIG_ENV_ADDR_REDUND
Simon Glass0649cd02017-08-03 12:21:49 -0600144
145 These settings describe a second storage area used to hold
146 a redundant copy of the environment data, so that there is
147 a valid backup copy in case there is a power failure during
148 a "saveenv" operation.
149
150 BE CAREFUL! Any changes to the flash layout, and some changes to the
151 source code will make it necessary to adapt <board>/u-boot.lds*
152 accordingly!
153
154config ENV_IS_IN_MMC
155 bool "Environment in an MMC device"
156 depends on !CHAIN_OF_TRUST
Maxime Ripardd282a1d2018-01-23 21:17:00 +0100157 depends on MMC
Maxime Ripardfb694642018-01-23 21:17:01 +0100158 default y if ARCH_EXYNOS4
159 default y if MX6SX || MX7D
160 default y if TEGRA30 || TEGRA124
161 default y if TEGRA_ARMV8_COMMON
Simon Glass0649cd02017-08-03 12:21:49 -0600162 help
163 Define this if you have an MMC device which you want to use for the
164 environment.
165
166 CONFIG_SYS_MMC_ENV_DEV:
167
168 Specifies which MMC device the environment is stored in.
169
170 CONFIG_SYS_MMC_ENV_PART (optional):
171
172 Specifies which MMC partition the environment is stored in. If not
173 set, defaults to partition 0, the user area. Common values might be
174 1 (first MMC boot partition), 2 (second MMC boot partition).
175
176 CONFIG_ENV_OFFSET:
177 CONFIG_ENV_SIZE:
178
179 These two #defines specify the offset and size of the environment
180 area within the specified MMC device.
181
182 If offset is positive (the usual case), it is treated as relative to
183 the start of the MMC partition. If offset is negative, it is treated
184 as relative to the end of the MMC partition. This can be useful if
185 your board may be fitted with different MMC devices, which have
186 different sizes for the MMC partitions, and you always want the
187 environment placed at the very end of the partition, to leave the
188 maximum possible space before it, to store other data.
189
190 These two values are in units of bytes, but must be aligned to an
191 MMC sector boundary.
192
193 CONFIG_ENV_OFFSET_REDUND (optional):
194
195 Specifies a second storage area, of CONFIG_ENV_SIZE size, used to
196 hold a redundant copy of the environment data. This provides a
197 valid backup copy in case the other copy is corrupted, e.g. due
198 to a power failure during a "saveenv" operation.
199
200 This value may also be positive or negative; this is handled in the
201 same way as CONFIG_ENV_OFFSET.
202
Marek Vasutd11d1be2021-10-17 19:23:36 +0200203 In case CONFIG_SYS_MMC_ENV_PART is 1 (i.e. environment in eMMC boot
204 partition) then setting CONFIG_ENV_OFFSET_REDUND to the same value
205 as CONFIG_ENV_OFFSET makes use of the second eMMC boot partition for
206 the redundant environment copy.
207
Simon Glass0649cd02017-08-03 12:21:49 -0600208 This value is also in units of bytes, but must also be aligned to
209 an MMC sector boundary.
210
Simon Glass0649cd02017-08-03 12:21:49 -0600211config ENV_IS_IN_NAND
212 bool "Environment in a NAND device"
213 depends on !CHAIN_OF_TRUST
214 help
215 Define this if you have a NAND device which you want to use for the
216 environment.
217
218 - CONFIG_ENV_OFFSET:
219 - CONFIG_ENV_SIZE:
220
221 These two #defines specify the offset and size of the environment
222 area within the first NAND device. CONFIG_ENV_OFFSET must be
223 aligned to an erase block boundary.
224
225 - CONFIG_ENV_OFFSET_REDUND (optional):
226
227 This setting describes a second storage area of CONFIG_ENV_SIZE
228 size used to hold a redundant copy of the environment data, so
229 that there is a valid backup copy in case there is a power failure
230 during a "saveenv" operation. CONFIG_ENV_OFFSET_REDUND must be
231 aligned to an erase block boundary.
232
233 - CONFIG_ENV_RANGE (optional):
234
235 Specifies the length of the region in which the environment
236 can be written. This should be a multiple of the NAND device's
237 block size. Specifying a range with more erase blocks than
238 are needed to hold CONFIG_ENV_SIZE allows bad blocks within
239 the range to be avoided.
240
241 - CONFIG_ENV_OFFSET_OOB (optional):
242
243 Enables support for dynamically retrieving the offset of the
244 environment from block zero's out-of-band data. The
245 "nand env.oob" command can be used to record this offset.
246 Currently, CONFIG_ENV_OFFSET_REDUND is not supported when
247 using CONFIG_ENV_OFFSET_OOB.
248
249config ENV_IS_IN_NVRAM
250 bool "Environment in a non-volatile RAM"
251 depends on !CHAIN_OF_TRUST
252 help
253 Define this if you have some non-volatile memory device
254 (NVRAM, battery buffered SRAM) which you want to use for the
255 environment.
256
257 - CONFIG_ENV_ADDR:
258 - CONFIG_ENV_SIZE:
259
260 These two #defines are used to determine the memory area you
261 want to use for environment. It is assumed that this memory
262 can just be read and written to, without any special
263 provision.
264
265config ENV_IS_IN_ONENAND
266 bool "Environment is in OneNAND"
267 depends on !CHAIN_OF_TRUST
268 help
269 Define this if you want to put your local device's environment in
270 OneNAND.
271
272 - CONFIG_ENV_ADDR:
273 - CONFIG_ENV_SIZE:
274
275 These two #defines are used to determine the device range you
276 want to use for environment. It is assumed that this memory
277 can just be read and written to, without any special
278 provision.
279
280config ENV_IS_IN_REMOTE
Heinrich Schuchardt646f1ab2018-03-17 22:53:11 +0000281 bool "Environment is in remote memory space"
Simon Glass0649cd02017-08-03 12:21:49 -0600282 depends on !CHAIN_OF_TRUST
283 help
284 Define this if you have a remote memory space which you
285 want to use for the local device's environment.
286
287 - CONFIG_ENV_ADDR:
288 - CONFIG_ENV_SIZE:
289
290 These two #defines specify the address and size of the
291 environment area within the remote memory space. The
292 local device can get the environment from remote memory
293 space by SRIO or PCIE links.
294
295config ENV_IS_IN_SPI_FLASH
296 bool "Environment is in SPI flash"
Tom Rinia4298dd2019-05-29 17:01:28 -0400297 depends on !CHAIN_OF_TRUST && SPI
Maxime Ripardfb694642018-01-23 21:17:01 +0100298 default y if ARMADA_XP
299 default y if INTEL_BAYTRAIL
300 default y if INTEL_BRASWELL
301 default y if INTEL_BROADWELL
302 default y if NORTHBRIDGE_INTEL_IVYBRIDGE
303 default y if INTEL_QUARK
304 default y if INTEL_QUEENSBAY
Simon Glass0649cd02017-08-03 12:21:49 -0600305 help
306 Define this if you have a SPI Flash memory device which you
307 want to use for the environment.
308
309 - CONFIG_ENV_OFFSET:
310 - CONFIG_ENV_SIZE:
311
312 These two #defines specify the offset and size of the
313 environment area within the SPI Flash. CONFIG_ENV_OFFSET must be
314 aligned to an erase sector boundary.
315
316 - CONFIG_ENV_SECT_SIZE:
317
318 Define the SPI flash's sector size.
319
320 - CONFIG_ENV_OFFSET_REDUND (optional):
321
322 This setting describes a second storage area of CONFIG_ENV_SIZE
323 size used to hold a redundant copy of the environment data, so
324 that there is a valid backup copy in case there is a power failure
325 during a "saveenv" operation. CONFIG_ENV_OFFSET_REDUND must be
326 aligned to an erase sector boundary.
327
Rasmus Villemoesbcb44f62021-04-14 20:51:43 +0200328config ENV_SECT_SIZE_AUTO
329 bool "Use automatically detected sector size"
330 depends on ENV_IS_IN_SPI_FLASH
331 help
332 Some boards exist in multiple variants, with different
333 flashes having different sector sizes. In such cases, you
334 can select this option to make U-Boot use the actual sector
335 size when figuring out how much to erase, which can thus be
336 more efficient on the flashes with smaller erase size. Since
337 the environment must always be aligned on a sector boundary,
338 CONFIG_ENV_OFFSET must be aligned to the largest of the
339 different sector sizes, and CONFIG_ENV_SECT_SIZE should be
340 set to that value.
341
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100342config USE_ENV_SPI_BUS
343 bool "SPI flash bus for environment"
344 depends on ENV_IS_IN_SPI_FLASH
345 help
346 Force the SPI bus for environment.
347 If not defined, use CONFIG_SF_DEFAULT_BUS.
Simon Glass0649cd02017-08-03 12:21:49 -0600348
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100349config ENV_SPI_BUS
350 int "Value of SPI flash bus for environment"
351 depends on USE_ENV_SPI_BUS
352 help
353 Value the SPI bus and chip select for environment.
Simon Glass0649cd02017-08-03 12:21:49 -0600354
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100355config USE_ENV_SPI_CS
356 bool "SPI flash chip select for environment"
357 depends on ENV_IS_IN_SPI_FLASH
358 help
359 Force the SPI chip select for environment.
360 If not defined, use CONFIG_SF_DEFAULT_CS.
Simon Glass0649cd02017-08-03 12:21:49 -0600361
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100362config ENV_SPI_CS
363 int "Value of SPI flash chip select for environment"
364 depends on USE_ENV_SPI_CS
365 help
366 Value of the SPI chip select for environment.
Simon Glass0649cd02017-08-03 12:21:49 -0600367
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100368config USE_ENV_SPI_MAX_HZ
Marek Vasutdd309612019-05-04 19:10:05 +0200369 bool "SPI flash max frequency for environment"
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100370 depends on ENV_IS_IN_SPI_FLASH
371 help
372 Force the SPI max work clock for environment.
373 If not defined, use CONFIG_SF_DEFAULT_SPEED.
Simon Glass0649cd02017-08-03 12:21:49 -0600374
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100375config ENV_SPI_MAX_HZ
Marek Vasutdd309612019-05-04 19:10:05 +0200376 int "Value of SPI flash max frequency for environment"
Patrick Delaunayabe66b12019-02-27 15:20:38 +0100377 depends on USE_ENV_SPI_MAX_HZ
378 help
379 Value of the SPI max work clock for environment.
380
381config USE_ENV_SPI_MODE
382 bool "SPI flash mode for environment"
383 depends on ENV_IS_IN_SPI_FLASH
384 help
385 Force the SPI work mode for environment.
386
387config ENV_SPI_MODE
388 hex "Value of SPI flash work mode for environment"
389 depends on USE_ENV_SPI_MODE
390 help
391 Value of the SPI work mode for environment.
392 See include/spi.h for value.
Simon Glass0649cd02017-08-03 12:21:49 -0600393
Heiko Schocher92765f452020-10-10 10:28:05 +0200394config ENV_SPI_EARLY
395 bool "Access Environment in SPI flashes before relocation"
396 depends on ENV_IS_IN_SPI_FLASH
397 help
398 Enable this if you want to use Environment in SPI flash
399 before relocation. Call env_init() and than you can use
400 env_get_f() for accessing Environment variables.
401
Simon Glass0649cd02017-08-03 12:21:49 -0600402config ENV_IS_IN_UBI
403 bool "Environment in a UBI volume"
404 depends on !CHAIN_OF_TRUST
Miquel Raynal00e27042019-10-03 19:50:12 +0200405 depends on MTD_UBI
406 depends on CMD_UBI
Simon Glass0649cd02017-08-03 12:21:49 -0600407 help
408 Define this if you have an UBI volume that you want to use for the
409 environment. This has the benefit of wear-leveling the environment
410 accesses, which is important on NAND.
411
412 - CONFIG_ENV_UBI_PART:
413
414 Define this to a string that is the mtd partition containing the UBI.
415
416 - CONFIG_ENV_UBI_VOLUME:
417
418 Define this to the name of the volume that you want to store the
419 environment in.
420
421 - CONFIG_ENV_UBI_VOLUME_REDUND:
422
423 Define this to the name of another volume to store a second copy of
424 the environment in. This will enable redundant environments in UBI.
425 It is assumed that both volumes are in the same MTD partition.
426
Tom Rinicb6617a2019-11-10 11:28:03 -0500427config SYS_REDUNDAND_ENVIRONMENT
428 bool "Enable redundant environment support"
Tom Rinicb6617a2019-11-10 11:28:03 -0500429 help
430 Normally, the environemt is stored in a single location. By
431 selecting this option, you can then define where to hold a redundant
432 copy of the environment data, so that there is a valid backup copy in
433 case there is a power failure during a "saveenv" operation.
Michal Simek4e3fc5e2021-01-13 10:25:50 +0100434 Also this config changes the binary environment structure handling
435 which is used by env import/export commands which are independent of
436 storing variables to redundant location on a non volatile device.
Tom Rinicb6617a2019-11-10 11:28:03 -0500437
Simon Glass0649cd02017-08-03 12:21:49 -0600438config ENV_FAT_INTERFACE
439 string "Name of the block device for the environment"
440 depends on ENV_IS_IN_FAT
Michal Simek8d782112020-02-25 15:50:33 +0100441 default "mmc"
Simon Glass0649cd02017-08-03 12:21:49 -0600442 help
443 Define this to a string that is the name of the block device.
444
445config ENV_FAT_DEVICE_AND_PART
446 string "Device and partition for where to store the environemt in FAT"
447 depends on ENV_IS_IN_FAT
448 default "0:1" if TI_COMMON_CMD_OPTIONS
Ashok Reddy Soma4fb83c92021-02-23 08:07:46 -0700449 default "0:auto" if ARCH_ZYNQ || ARCH_ZYNQMP || ARCH_VERSAL
Samuel Holland1011ebc2021-04-18 22:16:21 -0500450 default ":auto" if ARCH_SUNXI
Simon Glass0649cd02017-08-03 12:21:49 -0600451 default "0" if ARCH_AT91
452 help
453 Define this to a string to specify the partition of the device. It can
454 be as following:
455
456 "D:P", "D:0", "D", "D:" or "D:auto" (D, P are integers. And P >= 1)
457 - "D:P": device D partition P. Error occurs if device D has no
458 partition table.
459 - "D:0": device D.
460 - "D" or "D:": device D partition 1 if device D has partition
461 table, or the whole device D if has no partition
462 table.
463 - "D:auto": first partition in device D with bootable flag set.
464 If none, first valid partition in device D. If no
465 partition table then means device D.
466
David Woodhouse6731bef2020-06-19 23:07:17 +0100467 If ENV_FAT_INTERFACE is set to "mmc" then device 'D' can be omitted,
468 leaving the string starting with a colon, and the boot device will
469 be used.
470
Simon Glass0649cd02017-08-03 12:21:49 -0600471config ENV_FAT_FILE
Shyam Saini919d25c2018-06-07 19:47:19 +0530472 string "Name of the FAT file to use for the environment"
Simon Glass0649cd02017-08-03 12:21:49 -0600473 depends on ENV_IS_IN_FAT
474 default "uboot.env"
475 help
476 It's a string of the FAT file name. This file use to store the
477 environment.
478
Brandon Maier2339f012021-01-16 15:14:43 -0600479config ENV_FAT_FILE_REDUND
480 string "Name of the FAT file to use for the environment"
481 depends on ENV_IS_IN_FAT && SYS_REDUNDAND_ENVIRONMENT
482 default "uboot-redund.env"
483 help
484 It's a string of the FAT file name. This file use to store the
485 redundant environment.
486
Jorge Ramirez-Ortiz1087a792018-01-10 11:33:48 +0100487config ENV_EXT4_INTERFACE
488 string "Name of the block device for the environment"
489 depends on ENV_IS_IN_EXT4
490 help
491 Define this to a string that is the name of the block device.
492
493config ENV_EXT4_DEVICE_AND_PART
494 string "Device and partition for where to store the environemt in EXT4"
495 depends on ENV_IS_IN_EXT4
496 help
497 Define this to a string to specify the partition of the device. It can
498 be as following:
499
500 "D:P", "D:0", "D", "D:" or "D:auto" (D, P are integers. And P >= 1)
501 - "D:P": device D partition P. Error occurs if device D has no
502 partition table.
503 - "D:0": device D.
504 - "D" or "D:": device D partition 1 if device D has partition
505 table, or the whole device D if has no partition
506 table.
507 - "D:auto": first partition in device D with bootable flag set.
508 If none, first valid partition in device D. If no
509 partition table then means device D.
510
David Woodhouseb0493bb2020-08-04 10:05:47 +0100511 If ENV_EXT4_INTERFACE is set to "mmc" then device 'D' can be omitted,
512 leaving the string starting with a colon, and the boot device will
513 be used.
514
Jorge Ramirez-Ortiz1087a792018-01-10 11:33:48 +0100515config ENV_EXT4_FILE
Shyam Saini919d25c2018-06-07 19:47:19 +0530516 string "Name of the EXT4 file to use for the environment"
Jorge Ramirez-Ortiz1087a792018-01-10 11:33:48 +0100517 depends on ENV_IS_IN_EXT4
Patrick Delaunay87dac742020-07-28 11:51:14 +0200518 default "/uboot.env"
Jorge Ramirez-Ortiz1087a792018-01-10 11:33:48 +0100519 help
520 It's a string of the EXT4 file name. This file use to store the
521 environment (explicit path to the file)
522
Tom Rinia09fea12019-11-18 20:02:10 -0500523config ENV_ADDR
524 hex "Environment address"
525 depends on ENV_IS_IN_FLASH || ENV_IS_IN_NVRAM || ENV_IS_IN_ONENAND || \
526 ENV_IS_IN_REMOTE || ENV_IS_IN_SPI_FLASH
527 default 0x0 if ENV_IS_IN_SPI_FLASH
528 help
529 Offset from the start of the device (or partition)
530
531config ENV_ADDR_REDUND
532 hex "Redundant environment address"
533 depends on ENV_IS_IN_FLASH && SYS_REDUNDAND_ENVIRONMENT
534 help
535 Offset from the start of the device (or partition) of the redundant
536 environment location.
Simon Glass0649cd02017-08-03 12:21:49 -0600537
538config ENV_OFFSET
Tom Rinia09fea12019-11-18 20:02:10 -0500539 hex "Environment offset"
540 depends on ENV_IS_IN_EEPROM || ENV_IS_IN_MMC || ENV_IS_IN_NAND || \
541 ENV_IS_IN_SPI_FLASH
Jagan Tekid7b433e2019-12-21 13:24:35 +0530542 default 0x3f8000 if ARCH_ROCKCHIP && ENV_IS_IN_MMC
Jagan Teki54b85a92019-12-21 13:24:36 +0530543 default 0x140000 if ARCH_ROCKCHIP && ENV_IS_IN_SPI_FLASH
Simon Glass0649cd02017-08-03 12:21:49 -0600544 default 0x88000 if ARCH_SUNXI
Michal Simek4aee6242018-07-19 08:45:45 +0200545 default 0xE0000 if ARCH_ZYNQ
546 default 0x1E00000 if ARCH_ZYNQMP
T Karthik Reddyf8c0f9f2019-08-05 16:18:57 +0530547 default 0x7F40000 if ARCH_VERSAL
Alexey Brodkin70b5ea72019-01-15 11:42:48 +0300548 default 0 if ARC
Markus Klotzbuechera9221f32019-05-15 15:15:54 +0200549 default 0x140000 if ARCH_AT91
550 default 0x260000 if ARCH_OMAP2PLUS
Varalaxmi Bingi63e988e2020-02-05 03:58:20 -0700551 default 0x1080000 if MICROBLAZE && ENV_IS_IN_SPI_FLASH
Simon Glass0649cd02017-08-03 12:21:49 -0600552 help
553 Offset from the start of the device (or partition)
554
Tom Rinia09fea12019-11-18 20:02:10 -0500555config ENV_OFFSET_REDUND
556 hex "Redundant environment offset"
557 depends on (ENV_IS_IN_EEPROM || ENV_IS_IN_MMC || ENV_IS_IN_NAND || \
558 ENV_IS_IN_SPI_FLASH) && SYS_REDUNDAND_ENVIRONMENT
Michal Simekec217212021-02-24 10:33:45 +0100559 default 0
Tom Rinia09fea12019-11-18 20:02:10 -0500560 help
561 Offset from the start of the device (or partition) of the redundant
562 environment location.
563
Simon Glass0649cd02017-08-03 12:21:49 -0600564config ENV_SIZE
565 hex "Environment Size"
Michal Simek4aee6242018-07-19 08:45:45 +0200566 default 0x40000 if ENV_IS_IN_SPI_FLASH && ARCH_ZYNQMP
Markus Klotzbuechera9221f32019-05-15 15:15:54 +0200567 default 0x20000 if ARCH_SUNXI || ARCH_ZYNQ || ARCH_OMAP2PLUS || ARCH_AT91
Jagan Tekid7b433e2019-12-21 13:24:35 +0530568 default 0x8000 if ARCH_ROCKCHIP && ENV_IS_IN_MMC
Jagan Teki54b85a92019-12-21 13:24:36 +0530569 default 0x2000 if ARCH_ROCKCHIP && ENV_IS_IN_SPI_FLASH
Jagan Tekid7b433e2019-12-21 13:24:35 +0530570 default 0x8000 if ARCH_ZYNQMP || ARCH_VERSAL
Alexey Brodkin70b5ea72019-01-15 11:42:48 +0300571 default 0x4000 if ARC
Markus Klotzbuechera9221f32019-05-15 15:15:54 +0200572 default 0x1f000
Simon Glass0649cd02017-08-03 12:21:49 -0600573 help
574 Size of the environment storage area
575
Michal Simek4aee6242018-07-19 08:45:45 +0200576config ENV_SECT_SIZE
577 hex "Environment Sector-Size"
Tom Rinia09fea12019-11-18 20:02:10 -0500578 depends on ENV_IS_IN_FLASH || ENV_IS_IN_SPI_FLASH
Jagan Teki54b85a92019-12-21 13:24:36 +0530579 default 0x2000 if ARCH_ROCKCHIP
T Karthik Reddyf8c0f9f2019-08-05 16:18:57 +0530580 default 0x40000 if ARCH_ZYNQMP || ARCH_VERSAL
Markus Klotzbuechera9221f32019-05-15 15:15:54 +0200581 default 0x20000 if ARCH_ZYNQ || ARCH_OMAP2PLUS || ARCH_AT91
Varalaxmi Bingi63e988e2020-02-05 03:58:20 -0700582 default 0x20000 if MICROBLAZE && ENV_IS_IN_SPI_FLASH
Michal Simek4aee6242018-07-19 08:45:45 +0200583 help
584 Size of the sector containing the environment.
585
Simon Glass0649cd02017-08-03 12:21:49 -0600586config ENV_UBI_PART
587 string "UBI partition name"
588 depends on ENV_IS_IN_UBI
589 help
590 MTD partition containing the UBI device
591
592config ENV_UBI_VOLUME
593 string "UBI volume name"
594 depends on ENV_IS_IN_UBI
595 help
596 Name of the volume that you want to store the environment in.
597
Markus Klotzbuecherff4818c2019-05-15 15:15:53 +0200598config ENV_UBI_VOLUME_REDUND
599 string "UBI redundant volume name"
Tom Rinicb6617a2019-11-10 11:28:03 -0500600 depends on ENV_IS_IN_UBI && SYS_REDUNDAND_ENVIRONMENT
Markus Klotzbuecherff4818c2019-05-15 15:15:53 +0200601 help
602 Name of the redundant volume that you want to store the environment in.
603
Hamish Guthrie985186d2019-05-15 15:15:55 +0200604config ENV_UBI_VID_OFFSET
605 int "ubi environment VID offset"
606 depends on ENV_IS_IN_UBI
607 default 0
608 help
609 UBI VID offset for environment. If 0, no custom VID offset is used.
610
Tom Rini8d8ee472019-11-12 22:46:36 -0500611config SYS_RELOC_GD_ENV_ADDR
Patrick Delaunay35c26832020-06-10 19:28:42 +0200612 bool "Relocate gd->env_addr"
Tom Rini8d8ee472019-11-12 22:46:36 -0500613 help
614 Relocate the early env_addr pointer so we know it is not inside
615 the binary. Some systems need this and for the rest, it doesn't hurt.
616
Tom Rini7d080772020-07-24 17:14:47 -0400617config SYS_MMC_ENV_DEV
618 int "mmc device number"
619 depends on ENV_IS_IN_MMC || ENV_IS_IN_FAT || SYS_LS_PPA_FW_IN_MMC || \
Kuldeep Singh9b90e0d2021-08-10 11:20:06 +0530620 CMD_MVEBU_BUBT || FMAN_ENET || QE || PHY_CORTINA
Tom Rini7d080772020-07-24 17:14:47 -0400621 default 0
622 help
623 MMC device number on the platform where the environment is stored.
624
625config SYS_MMC_ENV_PART
626 int "mmc partition number"
627 depends on ENV_IS_IN_MMC || ENV_IS_IN_FAT
628 default 0
629 help
630 MMC hardware partition device number on the platform where the
631 environment is stored. Note that this is not related to any software
632 defined partition table but instead if we are in the user area, which is
633 partition 0 or the first boot partition, which is 1 or some other defined
634 partition.
635
Rasmus Villemoesf3d8f7d2018-03-20 11:38:45 +0100636config USE_DEFAULT_ENV_FILE
637 bool "Create default environment from file"
638 help
639 Normally, the default environment is automatically generated
640 based on the settings of various CONFIG_* options, as well
641 as the CONFIG_EXTRA_ENV_SETTINGS. By selecting this option,
642 you can instead define the entire default environment in an
643 external file.
644
645config DEFAULT_ENV_FILE
646 string "Path to default environment file"
647 depends on USE_DEFAULT_ENV_FILE
648 help
649 The path containing the default environment. The format is
650 the same as accepted by the mkenvimage tool: lines
651 containing key=value pairs, blank lines and lines beginning
652 with # are ignored.
653
Alex Kiernand9101302018-04-01 16:37:53 +0000654config ENV_VARS_UBOOT_RUNTIME_CONFIG
655 bool "Add run-time information to the environment"
656 help
657 Enable this in order to add variables describing certain
658 run-time determined information about the hardware to the
659 environment. These will be named board_name, board_rev.
660
Ovidiu Panaitb8879f22020-05-06 20:38:42 +0300661config DELAY_ENVIRONMENT
662 bool "Delay environment loading"
663 depends on !OF_CONTROL
664 help
665 Enable this to inhibit loading the environment during board
666 initialization. This can address the security risk of untrusted data
667 being used during boot. Normally the environment is loaded when the
668 board is initialised so that it is available to U-Boot. This inhibits
669 that so that the environment is not available until explicitly loaded
670 later by U-Boot code. With CONFIG_OF_CONTROL this is instead
671 controlled by the value of /config/load-environment.
672
Rasmus Villemoes95fd9772021-04-21 11:06:54 +0200673config ENV_IMPORT_FDT
674 bool "Amend environment by FDT properties"
675 depends on OF_CONTROL
676 help
677 If selected, after the environment has been loaded from its
678 persistent location, the "env_fdt_path" variable is looked
679 up and used as a path to a node in the control DTB. The
680 property/value pairs in that node is then used to update the
681 run-time environment. This can be useful to use the same
682 U-Boot binary with different board variants.
683
684config ENV_FDT_PATH
685 string "Default value for env_fdt_path variable"
686 depends on ENV_IMPORT_FDT
687 default "/config/environment"
688 help
689 The initial value of the env_fdt_path variable.
690
Marek Vasut47f3b1f2020-07-07 20:51:38 +0200691config ENV_APPEND
692 bool "Always append the environment with new data"
Marek Vasut47f3b1f2020-07-07 20:51:38 +0200693 help
694 If defined, the environment hash table is only ever appended with new
695 data, but the existing hash table can never be dropped and reloaded
696 with newly imported data. This may be used in combination with static
697 flags to e.g. to protect variables which must not be modified.
698
Marek Vasutd045cba2020-07-07 20:51:39 +0200699config ENV_WRITEABLE_LIST
700 bool "Permit write access only to listed variables"
Marek Vasutd045cba2020-07-07 20:51:39 +0200701 help
702 If defined, only environment variables which explicitly set the 'w'
703 writeable flag can be written and modified at runtime. No variables
704 can be otherwise created, written or imported into the environment.
705
Marek Vasut3ec46992020-05-22 01:10:14 +0200706config ENV_ACCESS_IGNORE_FORCE
707 bool "Block forced environment operations"
Marek Vasut3ec46992020-05-22 01:10:14 +0200708 help
709 If defined, don't allow the -f switch to env set override variable
710 access flags.
711
York Sun474ecd22018-06-26 10:03:22 -0700712if SPL_ENV_SUPPORT
713config SPL_ENV_IS_NOWHERE
714 bool "SPL Environment is not stored"
715 default y if ENV_IS_NOWHERE
716 help
717 Similar to ENV_IS_NOWHERE, used for SPL environment.
718
719config SPL_ENV_IS_IN_MMC
720 bool "SPL Environment in an MMC device"
721 depends on !SPL_ENV_IS_NOWHERE
722 depends on ENV_IS_IN_MMC
723 default y
724 help
725 Similar to ENV_IS_IN_MMC, used for SPL environment.
726
727config SPL_ENV_IS_IN_FAT
728 bool "SPL Environment is in a FAT filesystem"
729 depends on !SPL_ENV_IS_NOWHERE
730 depends on ENV_IS_IN_FAT
731 default y
732 help
733 Similar to ENV_IS_IN_FAT, used for SPL environment.
734
735config SPL_ENV_IS_IN_EXT4
736 bool "SPL Environment is in a EXT4 filesystem"
737 depends on !SPL_ENV_IS_NOWHERE
738 depends on ENV_IS_IN_EXT4
739 default y
740 help
741 Similar to ENV_IS_IN_EXT4, used for SPL environment.
742
743config SPL_ENV_IS_IN_NAND
744 bool "SPL Environment in a NAND device"
745 depends on !SPL_ENV_IS_NOWHERE
746 depends on ENV_IS_IN_NAND
747 default y
748 help
749 Similar to ENV_IS_IN_NAND, used for SPL environment.
750
751config SPL_ENV_IS_IN_SPI_FLASH
752 bool "SPL Environment is in SPI flash"
753 depends on !SPL_ENV_IS_NOWHERE
754 depends on ENV_IS_IN_SPI_FLASH
755 default y
756 help
757 Similar to ENV_IS_IN_SPI_FLASH, used for SPL environment.
758
759config SPL_ENV_IS_IN_FLASH
760 bool "SPL Environment in flash memory"
761 depends on !SPL_ENV_IS_NOWHERE
762 depends on ENV_IS_IN_FLASH
763 default y
764 help
765 Similar to ENV_IS_IN_FLASH, used for SPL environment.
766
767endif
768
769if TPL_ENV_SUPPORT
770
771config TPL_ENV_IS_NOWHERE
772 bool "TPL Environment is not stored"
773 default y if ENV_IS_NOWHERE
774 help
775 Similar to ENV_IS_NOWHERE, used for TPL environment.
776
777config TPL_ENV_IS_IN_MMC
778 bool "TPL Environment in an MMC device"
779 depends on !TPL_ENV_IS_NOWHERE
780 depends on ENV_IS_IN_MMC
781 default y
782 help
783 Similar to ENV_IS_IN_MMC, used for TPL environment.
784
785config TPL_ENV_IS_IN_FAT
786 bool "TPL Environment is in a FAT filesystem"
787 depends on !TPL_ENV_IS_NOWHERE
788 depends on ENV_IS_IN_FAT
789 default y
790 help
791 Similar to ENV_IS_IN_FAT, used for TPL environment.
792
793config TPL_ENV_IS_IN_EXT4
794 bool "TPL Environment is in a EXT4 filesystem"
795 depends on !TPL_ENV_IS_NOWHERE
796 depends on ENV_IS_IN_EXT4
797 default y
798 help
799 Similar to ENV_IS_IN_EXT4, used for TPL environment.
800
801config TPL_ENV_IS_IN_NAND
802 bool "TPL Environment in a NAND device"
803 depends on !TPL_ENV_IS_NOWHERE
804 depends on ENV_IS_IN_NAND
805 default y
806 help
807 Similar to ENV_IS_IN_NAND, used for TPL environment.
808
809config TPL_ENV_IS_IN_SPI_FLASH
810 bool "TPL Environment is in SPI flash"
811 depends on !TPL_ENV_IS_NOWHERE
812 depends on ENV_IS_IN_SPI_FLASH
813 default y
814 help
815 Similar to ENV_IS_IN_SPI_FLASH, used for TPL environment.
816
817config TPL_ENV_IS_IN_FLASH
818 bool "TPL Environment in flash memory"
819 depends on !TPL_ENV_IS_NOWHERE
820 depends on ENV_IS_IN_FLASH
821 default y
822 help
823 Similar to ENV_IS_IN_FLASH, used for TPL environment.
824
825endif
826
Simon Glassbc438b62020-09-10 20:21:24 -0600827config VERSION_VARIABLE
828 bool "Add a 'ver' environment variable with the U-Boot version"
829 help
830 If this variable is defined, an environment variable
831 named "ver" is created by U-Boot showing the U-Boot
832 version as printed by the "version" command.
833 Any change to this variable will be reverted at the
834 next reset.
835
Simon Glass0649cd02017-08-03 12:21:49 -0600836endmenu