]> git.ipfire.org Git - people/ms/u-boot.git/blob - board/toradex/common/Kconfig
toradex: config block handling
[people/ms/u-boot.git] / board / toradex / common / Kconfig
1 # Copyright (c) 2016 Toradex, Inc.
2 # SPDX-License-Identifier: GPL-2.0+
3
4 menuconfig TDX_CFG_BLOCK
5 bool "Enable Toradex config block support"
6 select OF_BOARD_SETUP
7 help
8 The Toradex config block stored production data on the on-module
9 flash device (NAND, NOR or eMMC). The area is normally preserved by
10 software and contains the serial number (out of which the MAC
11 address is generated) and the exact module type.
12
13 # Helper config to determine the correct default location of the cfg block
14 config TDX_HAVE_MMC
15 bool
16
17 config TDX_HAVE_NAND
18 bool
19
20 config TDX_HAVE_NOR
21 bool
22
23 if TDX_CFG_BLOCK
24
25 config TDX_CFG_BLOCK_IS_IN_MMC
26 bool
27 depends on TDX_HAVE_MMC
28 default y
29
30 config TDX_CFG_BLOCK_IS_IN_NAND
31 bool
32 depends on TDX_HAVE_NAND
33 default y
34
35 config TDX_CFG_BLOCK_IS_IN_NOR
36 bool
37 depends on TDX_HAVE_NOR
38 default y
39
40 config TDX_CFG_BLOCK_DEV
41 int "Toradex config block eMMC device ID"
42 depends on TDX_CFG_BLOCK_IS_IN_MMC
43
44 config TDX_CFG_BLOCK_PART
45 int "Toradex config block eMMC partition ID"
46 depends on TDX_CFG_BLOCK_IS_IN_MMC
47
48 config TDX_CFG_BLOCK_OFFSET
49 int "Toradex config block offset"
50 help
51 Specify the byte offset of the Toradex config block within the flash
52 device the config block is stored on.
53
54 config TDX_CFG_BLOCK_OFFSET2
55 int "Toradex config block offset, second instance"
56 default 0
57 help
58 Specify the byte offset of the 2nd instance of the Toradex config block
59 within the flash device the config block is stored on.
60 Set to 0 on modules which have no 2nd instance.
61
62 config TDX_CFG_BLOCK_2ND_ETHADDR
63 bool "Set the second Ethernet address"
64 help
65 For each serial number two Ethernet addresses are available for dual
66 Ethernet carrier boards. This options enables the code to set the
67 second Ethernet address as environment variable (eth1addr).
68
69 endif