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