]> git.ipfire.org Git - people/ms/u-boot.git/blame - env/Kconfig
Merge git://git.denx.de/u-boot-fsl-qoriq
[people/ms/u-boot.git] / env / Kconfig
CommitLineData
0649cd0d
SG
1menu "Environment"
2
c1c3fe23
SG
3choice
4 prompt "Select the location of the environment"
5 default ENV_IS_IN_MMC if ARCH_SUNXI
c1c3fe23
SG
6 default ENV_IS_IN_MMC if ARCH_UNIPHIER
7 default ENV_IS_IN_MMC if ARCH_EXYNOS4
8 default ENV_IS_IN_MMC if MX6SX || MX7D
c1c3fe23
SG
9 default ENV_IS_IN_MMC if TEGRA30 || TEGRA124
10 default ENV_IS_IN_MMC if TEGRA_ARMV8_COMMON
e94c1268 11 default ENV_IS_IN_FLASH if ARCH_CINTEGRATOR
c1c3fe23
SG
12 default ENV_IS_IN_FLASH if ARCH_INTEGRATOR_CP
13 default ENV_IS_IN_FLASH if M548x || M547x || M5282 || MCF547x_8x
14 default ENV_IS_IN_FLASH if MCF532x || MCF52x2
15 default ENV_IS_IN_FLASH if MPC86xx || MPC83xx
16 default ENV_IS_IN_FLASH if ARCH_MPC8572 || ARCH_MPC8548 || ARCH_MPC8641
17 default ENV_IS_IN_FLASH if SH && !CPU_SH4
e94c1268 18 default ENV_IS_IN_SPI_FLASH if ARMADA_XP
c1c3fe23
SG
19 default ENV_IS_IN_SPI_FLASH if INTEL_BAYTRAIL
20 default ENV_IS_IN_SPI_FLASH if INTEL_BROADWELL
21 default ENV_IS_IN_SPI_FLASH if NORTHBRIDGE_INTEL_IVYBRIDGE
22 default ENV_IS_IN_SPI_FLASH if INTEL_QUARK
23 default ENV_IS_IN_SPI_FLASH if INTEL_QUEENSBAY
e94c1268 24 default ENV_IS_IN_FAT if ARCH_BCM283X
c1c3fe23
SG
25 default ENV_IS_IN_FAT if MMC_OMAP_HS && TI_COMMON_CMD_OPTIONS
26 default ENV_IS_NOWHERE
27 help
28 At present the environment can be stored in only one place. Use this
29 option to select the location. This is either a device (where the
30 environemnt information is simply written to a fixed location or
31 partition on the device) or a filesystem (where the environment
32 information is written to a file).
33
34config ENV_IS_NOWHERE
35 bool "Environment is not stored"
36 help
37 Define this if you don't want to or can't have an environment stored
38 on a storage medium. In this case the environemnt will still exist
39 while U-Boot is running, but once U-Boot exits it will not be
40 stored. U-Boot will therefore always start up with a default
41 environment.
42
0649cd0d
SG
43config ENV_IS_IN_DATAFLASH
44 bool "Environment in dataflash"
45 depends on !CHAIN_OF_TRUST
46 help
47 Define this if you have a DataFlash memory device which you
48 want to use for the environment.
49
50 - CONFIG_ENV_OFFSET:
51 - CONFIG_ENV_ADDR:
52 - CONFIG_ENV_SIZE:
53
54 These three #defines specify the offset and size of the
55 environment area within the total memory of your DataFlash placed
56 at the specified address.
57
58config ENV_IS_IN_EEPROM
59 bool "Environment in EEPROM"
60 depends on !CHAIN_OF_TRUST
61 help
62 Use this if you have an EEPROM or similar serial access
63 device and a driver for it.
64
65 - CONFIG_ENV_OFFSET:
66 - CONFIG_ENV_SIZE:
67
68 These two #defines specify the offset and size of the
69 environment area within the total memory of your EEPROM.
70
0649cd0d
SG
71 Note that we consider the length of the address field to
72 still be one byte because the extra address bits are hidden
73 in the chip address.
74
0649cd0d
SG
75 - CONFIG_ENV_EEPROM_IS_ON_I2C
76 define this, if you have I2C and SPI activated, and your
77 EEPROM, which holds the environment, is on the I2C bus.
78
79 - CONFIG_I2C_ENV_EEPROM_BUS
80 if you have an Environment on an EEPROM reached over
81 I2C muxes, you can define here, how to reach this
82 EEPROM. For example:
83
84 #define CONFIG_I2C_ENV_EEPROM_BUS 1
85
86 EEPROM which holds the environment, is reached over
87 a pca9547 i2c mux with address 0x70, channel 3.
88
89config ENV_IS_IN_FAT
90 bool "Environment is in a FAT filesystem"
91 depends on !CHAIN_OF_TRUST
92 select FAT_WRITE
93 help
91d3aa05 94 Define this if you want to use the FAT file system for the environment.
0649cd0d 95
91d3aa05
SG
96 - CONFIG_FAT_WRITE:
97 This must be enabled. Otherwise it cannot save the environment file.
0649cd0d
SG
98
99config ENV_IS_IN_FLASH
100 bool "Environment in flash memory"
101 depends on !CHAIN_OF_TRUST
102 help
103 Define this if you have a flash device which you want to use for the
104 environment.
105
106 a) The environment occupies one whole flash sector, which is
107 "embedded" in the text segment with the U-Boot code. This
108 happens usually with "bottom boot sector" or "top boot
109 sector" type flash chips, which have several smaller
110 sectors at the start or the end. For instance, such a
111 layout can have sector sizes of 8, 2x4, 16, Nx32 kB. In
112 such a case you would place the environment in one of the
113 4 kB sectors - with U-Boot code before and after it. With
114 "top boot sector" type flash chips, you would put the
115 environment in one of the last sectors, leaving a gap
116 between U-Boot and the environment.
117
118 CONFIG_ENV_OFFSET:
119
120 Offset of environment data (variable area) to the
121 beginning of flash memory; for instance, with bottom boot
122 type flash chips the second sector can be used: the offset
123 for this sector is given here.
124
125 CONFIG_ENV_OFFSET is used relative to CONFIG_SYS_FLASH_BASE.
126
127 CONFIG_ENV_ADDR:
128
129 This is just another way to specify the start address of
130 the flash sector containing the environment (instead of
131 CONFIG_ENV_OFFSET).
132
133 CONFIG_ENV_SECT_SIZE:
134
135 Size of the sector containing the environment.
136
137
138 b) Sometimes flash chips have few, equal sized, BIG sectors.
139 In such a case you don't want to spend a whole sector for
140 the environment.
141
142 CONFIG_ENV_SIZE:
143
144 If you use this in combination with CONFIG_ENV_IS_IN_FLASH
145 and CONFIG_ENV_SECT_SIZE, you can specify to use only a part
146 of this flash sector for the environment. This saves
147 memory for the RAM copy of the environment.
148
149 It may also save flash memory if you decide to use this
150 when your environment is "embedded" within U-Boot code,
151 since then the remainder of the flash sector could be used
152 for U-Boot code. It should be pointed out that this is
153 STRONGLY DISCOURAGED from a robustness point of view:
154 updating the environment in flash makes it always
155 necessary to erase the WHOLE sector. If something goes
156 wrong before the contents has been restored from a copy in
157 RAM, your target system will be dead.
158
159 CONFIG_ENV_ADDR_REDUND
160 CONFIG_ENV_SIZE_REDUND
161
162 These settings describe a second storage area used to hold
163 a redundant copy of the environment data, so that there is
164 a valid backup copy in case there is a power failure during
165 a "saveenv" operation.
166
167 BE CAREFUL! Any changes to the flash layout, and some changes to the
168 source code will make it necessary to adapt <board>/u-boot.lds*
169 accordingly!
170
171config ENV_IS_IN_MMC
172 bool "Environment in an MMC device"
173 depends on !CHAIN_OF_TRUST
0649cd0d
SG
174 help
175 Define this if you have an MMC device which you want to use for the
176 environment.
177
178 CONFIG_SYS_MMC_ENV_DEV:
179
180 Specifies which MMC device the environment is stored in.
181
182 CONFIG_SYS_MMC_ENV_PART (optional):
183
184 Specifies which MMC partition the environment is stored in. If not
185 set, defaults to partition 0, the user area. Common values might be
186 1 (first MMC boot partition), 2 (second MMC boot partition).
187
188 CONFIG_ENV_OFFSET:
189 CONFIG_ENV_SIZE:
190
191 These two #defines specify the offset and size of the environment
192 area within the specified MMC device.
193
194 If offset is positive (the usual case), it is treated as relative to
195 the start of the MMC partition. If offset is negative, it is treated
196 as relative to the end of the MMC partition. This can be useful if
197 your board may be fitted with different MMC devices, which have
198 different sizes for the MMC partitions, and you always want the
199 environment placed at the very end of the partition, to leave the
200 maximum possible space before it, to store other data.
201
202 These two values are in units of bytes, but must be aligned to an
203 MMC sector boundary.
204
205 CONFIG_ENV_OFFSET_REDUND (optional):
206
207 Specifies a second storage area, of CONFIG_ENV_SIZE size, used to
208 hold a redundant copy of the environment data. This provides a
209 valid backup copy in case the other copy is corrupted, e.g. due
210 to a power failure during a "saveenv" operation.
211
212 This value may also be positive or negative; this is handled in the
213 same way as CONFIG_ENV_OFFSET.
214
215 This value is also in units of bytes, but must also be aligned to
216 an MMC sector boundary.
217
218 CONFIG_ENV_SIZE_REDUND (optional):
219
220 This value need not be set, even when CONFIG_ENV_OFFSET_REDUND is
221 set. If this value is set, it must be set to the same value as
222 CONFIG_ENV_SIZE.
223
224config ENV_IS_IN_NAND
225 bool "Environment in a NAND device"
226 depends on !CHAIN_OF_TRUST
227 help
228 Define this if you have a NAND device which you want to use for the
229 environment.
230
231 - CONFIG_ENV_OFFSET:
232 - CONFIG_ENV_SIZE:
233
234 These two #defines specify the offset and size of the environment
235 area within the first NAND device. CONFIG_ENV_OFFSET must be
236 aligned to an erase block boundary.
237
238 - CONFIG_ENV_OFFSET_REDUND (optional):
239
240 This setting describes a second storage area of CONFIG_ENV_SIZE
241 size used to hold a redundant copy of the environment data, so
242 that there is a valid backup copy in case there is a power failure
243 during a "saveenv" operation. CONFIG_ENV_OFFSET_REDUND must be
244 aligned to an erase block boundary.
245
246 - CONFIG_ENV_RANGE (optional):
247
248 Specifies the length of the region in which the environment
249 can be written. This should be a multiple of the NAND device's
250 block size. Specifying a range with more erase blocks than
251 are needed to hold CONFIG_ENV_SIZE allows bad blocks within
252 the range to be avoided.
253
254 - CONFIG_ENV_OFFSET_OOB (optional):
255
256 Enables support for dynamically retrieving the offset of the
257 environment from block zero's out-of-band data. The
258 "nand env.oob" command can be used to record this offset.
259 Currently, CONFIG_ENV_OFFSET_REDUND is not supported when
260 using CONFIG_ENV_OFFSET_OOB.
261
262config ENV_IS_IN_NVRAM
263 bool "Environment in a non-volatile RAM"
264 depends on !CHAIN_OF_TRUST
265 help
266 Define this if you have some non-volatile memory device
267 (NVRAM, battery buffered SRAM) which you want to use for the
268 environment.
269
270 - CONFIG_ENV_ADDR:
271 - CONFIG_ENV_SIZE:
272
273 These two #defines are used to determine the memory area you
274 want to use for environment. It is assumed that this memory
275 can just be read and written to, without any special
276 provision.
277
278config ENV_IS_IN_ONENAND
279 bool "Environment is in OneNAND"
280 depends on !CHAIN_OF_TRUST
281 help
282 Define this if you want to put your local device's environment in
283 OneNAND.
284
285 - CONFIG_ENV_ADDR:
286 - CONFIG_ENV_SIZE:
287
288 These two #defines are used to determine the device range you
289 want to use for environment. It is assumed that this memory
290 can just be read and written to, without any special
291 provision.
292
293config ENV_IS_IN_REMOTE
294 bool "Environment is in remove memory space"
295 depends on !CHAIN_OF_TRUST
296 help
297 Define this if you have a remote memory space which you
298 want to use for the local device's environment.
299
300 - CONFIG_ENV_ADDR:
301 - CONFIG_ENV_SIZE:
302
303 These two #defines specify the address and size of the
304 environment area within the remote memory space. The
305 local device can get the environment from remote memory
306 space by SRIO or PCIE links.
307
308config ENV_IS_IN_SPI_FLASH
309 bool "Environment is in SPI flash"
310 depends on !CHAIN_OF_TRUST
311 help
312 Define this if you have a SPI Flash memory device which you
313 want to use for the environment.
314
315 - CONFIG_ENV_OFFSET:
316 - CONFIG_ENV_SIZE:
317
318 These two #defines specify the offset and size of the
319 environment area within the SPI Flash. CONFIG_ENV_OFFSET must be
320 aligned to an erase sector boundary.
321
322 - CONFIG_ENV_SECT_SIZE:
323
324 Define the SPI flash's sector size.
325
326 - CONFIG_ENV_OFFSET_REDUND (optional):
327
328 This setting describes a second storage area of CONFIG_ENV_SIZE
329 size used to hold a redundant copy of the environment data, so
330 that there is a valid backup copy in case there is a power failure
331 during a "saveenv" operation. CONFIG_ENV_OFFSET_REDUND must be
332 aligned to an erase sector boundary.
333
334 - CONFIG_ENV_SPI_BUS (optional):
335 - CONFIG_ENV_SPI_CS (optional):
336
337 Define the SPI bus and chip select. If not defined they will be 0.
338
339 - CONFIG_ENV_SPI_MAX_HZ (optional):
340
341 Define the SPI max work clock. If not defined then use 1MHz.
342
343 - CONFIG_ENV_SPI_MODE (optional):
344
345 Define the SPI work mode. If not defined then use SPI_MODE_3.
346
347config ENV_IS_IN_UBI
348 bool "Environment in a UBI volume"
349 depends on !CHAIN_OF_TRUST
350 help
351 Define this if you have an UBI volume that you want to use for the
352 environment. This has the benefit of wear-leveling the environment
353 accesses, which is important on NAND.
354
355 - CONFIG_ENV_UBI_PART:
356
357 Define this to a string that is the mtd partition containing the UBI.
358
359 - CONFIG_ENV_UBI_VOLUME:
360
361 Define this to the name of the volume that you want to store the
362 environment in.
363
364 - CONFIG_ENV_UBI_VOLUME_REDUND:
365
366 Define this to the name of another volume to store a second copy of
367 the environment in. This will enable redundant environments in UBI.
368 It is assumed that both volumes are in the same MTD partition.
369
370 - CONFIG_UBI_SILENCE_MSG
371 - CONFIG_UBIFS_SILENCE_MSG
372
373 You will probably want to define these to avoid a really noisy system
374 when storing the env in UBI.
375
c1c3fe23 376endchoice
0649cd0d 377
5eb35220
TR
378config ENV_AES
379 bool "AES-128 encryption for stored environment (DEPRECATED)"
380 help
381 Enable this to have the on-device stored environment be encrypted
382 with AES-128. The implementation here however has security
383 complications and is not recommended for use. Please see
384 CVE-2017-3225 and CVE-2017-3226 for more details.
385
0649cd0d
SG
386config ENV_FAT_INTERFACE
387 string "Name of the block device for the environment"
388 depends on ENV_IS_IN_FAT
389 default "mmc" if TI_COMMON_CMD_OPTIONS || ARCH_ZYNQMP || ARCH_AT91
390 help
391 Define this to a string that is the name of the block device.
392
393config ENV_FAT_DEVICE_AND_PART
394 string "Device and partition for where to store the environemt in FAT"
395 depends on ENV_IS_IN_FAT
396 default "0:1" if TI_COMMON_CMD_OPTIONS
397 default "0:auto" if ARCH_ZYNQMP
398 default "0" if ARCH_AT91
399 help
400 Define this to a string to specify the partition of the device. It can
401 be as following:
402
403 "D:P", "D:0", "D", "D:" or "D:auto" (D, P are integers. And P >= 1)
404 - "D:P": device D partition P. Error occurs if device D has no
405 partition table.
406 - "D:0": device D.
407 - "D" or "D:": device D partition 1 if device D has partition
408 table, or the whole device D if has no partition
409 table.
410 - "D:auto": first partition in device D with bootable flag set.
411 If none, first valid partition in device D. If no
412 partition table then means device D.
413
414config ENV_FAT_FILE
415 string "Name of the FAT file to use for the environemnt"
416 depends on ENV_IS_IN_FAT
417 default "uboot.env"
418 help
419 It's a string of the FAT file name. This file use to store the
420 environment.
421
422if ARCH_SUNXI
423
424config ENV_OFFSET
425 hex "Environment Offset"
426 depends on !ENV_IS_IN_UBI
427 depends on !ENV_IS_NOWHERE
428 default 0x88000 if ARCH_SUNXI
429 help
430 Offset from the start of the device (or partition)
431
432config ENV_SIZE
433 hex "Environment Size"
434 depends on !ENV_IS_NOWHERE
435 default 0x20000 if ARCH_SUNXI
436 help
437 Size of the environment storage area
438
439config ENV_UBI_PART
440 string "UBI partition name"
441 depends on ENV_IS_IN_UBI
442 help
443 MTD partition containing the UBI device
444
445config ENV_UBI_VOLUME
446 string "UBI volume name"
447 depends on ENV_IS_IN_UBI
448 help
449 Name of the volume that you want to store the environment in.
450
451endif
452
453endmenu