]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
km: add Kconfig menus for KM boards
authorPascal Linder <pascal.linder@edu.hefr.ch>
Tue, 9 Jul 2019 07:28:20 +0000 (09:28 +0200)
committerStefan Roese <sr@denx.de>
Mon, 12 Aug 2019 07:12:38 +0000 (09:12 +0200)
To execute the conversion away from board specific header files, Kconfig
menus have been implemented for all KM boards and additionally for those
having an ARM architecture.

For the moment, the preprocessor definitions stay in the headers. The
boolean types, however, needed a modification (#define CONFIG_* 1).

The default configuration files of some boards required an update in order
to not change the currently defined values of the configurations.

Signed-off-by: Pascal Linder <pascal.linder@edu.hefr.ch>
Signed-off-by: Holger Brunck <holger.brunck@ch.abb.com>
Signed-off-by: Stefan Roese <sr@denx.de>
14 files changed:
board/keymile/Kconfig
board/keymile/km_arm/Kconfig
configs/km_kirkwood_pci_defconfig
configs/kmcoge5un_defconfig
configs/kmnusa_defconfig
configs/kmsugp1_defconfig
configs/kmsuv31_defconfig
configs/kmvect1_defconfig
configs/mgcoge3un_defconfig
configs/portl2_defconfig
include/configs/km/km-powerpc.h
include/configs/km/km_arm.h
include/configs/km_kirkwood.h
include/configs/kmvect1.h

index e30d64818ca93e4b3fad21cc92f909f6df97bd34..acaa9289f769fe3671dfafca36cf2266487bb014 100644 (file)
@@ -9,8 +9,109 @@ config VENDOR_KM
 
 if VENDOR_KM
 
+menu "KM Board Setup"
+
+config KM_PNVRAM
+       hex "Pseudo RAM"
+       default 0x80000
+       help
+         Start address of the pseudo non-volatile RAM for application.
+
+config KM_PHRAM
+       hex "Physical RAM"
+       default 0x17F000 if ARM
+       default 0x100000 if PPC
+       help
+         Start address of the physical RAM, which is the mounted /var folder.
+
+config KM_RESERVED_PRAM
+       hex "Reserved RAM"
+       default 0x801000 if KIRKWOOD
+       default 0x0 if MPC83xx
+       default 0x1000 if MPC85xx
+       help
+         Reserved physical RAM area at the end of memory for special purposes.
+
+config KM_CRAMFS_ADDR
+       hex "CRAMFS Address"
+       default 0x2400000 if KIRKWOOD
+       default 0xC00000 if MPC83xx
+       default 0x2000000 if MPC85xx
+       help
+         Start address of the CRAMFS containing the Linux kernel.
+
+config KM_KERNEL_ADDR
+       hex "Kernel Load Address"
+       default 0x2000000 if KIRKWOOD
+       default 0x400000 if MPC83xx
+       default 0x1000000 if MPC85xx
+       help
+         Address where to load Linux kernel in RAM.
+
+config KM_FDT_ADDR
+       hex "FDT Load Address"
+       default 0x23E0000 if KIRKWOOD
+       default 0xB80000 if MPC83xx
+       default 0x1F80000 if MPC85xx
+       help
+         Address where to load flattened device tree in RAM.
+
+config KM_CONSOLE_TTY
+       string "KM Console"
+       default "ttyS0"
+       help
+         TTY console to use on board.
+
+config KM_COMMON_ETH_INIT
+       bool "Common Ethernet Initialization"
+       default y if KIRKWOOD || MPC83xx
+       default n if MPC85xx
+       help
+         Use the Ethernet initialization implemented in common code, which
+         detects if a Piggy board is present.
+
+config PIGGY_MAC_ADRESS_OFFSET
+       int "Piggy Address Offset"
+       default 0
+       help
+         MAC address offset for the Piggy board.
+
+config KM_MVEXTSW_ADDR
+       hex "Marvell Switch Address"
+       depends on MV88E6352_SWITCH
+       default 0x10
+       help
+         Address of external Marvell switch.
+
+config KM_IVM_BUS
+       int "IVM I2C Bus"
+       default 1 if KIRKWOOD || MPC85xx
+       default 2 if MPC83xx
+       help
+         Identifier number of I2C bus, where the inventory EEPROM is connected to.
+
+config SYS_IVM_EEPROM_ADR
+       hex "IVM I2C Address"
+       default 0x50
+       help
+         I2C address of the EEPROM containing the inventory.
+
+config SYS_IVM_EEPROM_MAX_LEN
+       hex "IVM Length"
+       default 0x400
+       help
+         Maximum length of inventory in EEPROM.
+
+config SYS_IVM_EEPROM_PAGE_LEN
+       hex "IVM Page Size"
+       default 0x100
+       help
+         Page size of inventory in EEPROM.
+
 source "board/keymile/km83xx/Kconfig"
 source "board/keymile/kmp204x/Kconfig"
 source "board/keymile/km_arm/Kconfig"
 
+endmenu
+
 endif
index 19c1db3bc25b926649855c6fb80c70a88c44fcfe..7da052f4c4f4737b8dc669c25c1a5868581c394b 100644 (file)
@@ -1,3 +1,32 @@
+menu "KM ARM Options"
+       depends on ARM
+
+config KM_FPGA_CONFIG
+       bool "FPGA Configuration"
+       default n
+       help
+         Include capability to change FPGA configuration.
+
+config KM_ENV_IS_IN_SPI_NOR
+       bool "Environment in SPI NOR"
+       default n
+       help
+         Put the U-Boot environment in the SPI NOR flash.
+
+config KM_PIGGY4_88E6061
+       bool "Piggy via Switch 88E6061"
+       default n
+       help
+         The Piggy4 board is connected via a Marvell 88E6061 switch.
+
+config KM_PIGGY4_88E6352
+       bool "Piggy via Switch 88E6352"
+       default n
+       help
+         The Piggy4 board is connected via a Marvell 88E6352 switch.
+
+endmenu
+
 if TARGET_KM_KIRKWOOD
 
 config SYS_BOARD
index 5abf543270aa38a9b2efc6d994e3c4ac3b3d616b..b8c8445c34d4a16988b9de940970a0a056ec113a 100644 (file)
@@ -3,6 +3,7 @@ CONFIG_SYS_DCACHE_OFF=y
 CONFIG_KIRKWOOD=y
 CONFIG_SYS_TEXT_BASE=0x07d00000
 CONFIG_TARGET_KM_KIRKWOOD=y
+CONFIG_KM_FPGA_CONFIG=y
 CONFIG_IDENT_STRING="\nKeymile Kirkwood PCI"
 CONFIG_SYS_EXTRA_OPTIONS="KM_KIRKWOOD_PCI"
 CONFIG_MISC_INIT_R=y
index b6ac31e0ff7cf2709c06c8308861f9a6ba4fddc4..519402ed48e30ba54dfc6865e90b80bca9c37455 100644 (file)
@@ -3,6 +3,9 @@ CONFIG_SYS_DCACHE_OFF=y
 CONFIG_KIRKWOOD=y
 CONFIG_SYS_TEXT_BASE=0x07d00000
 CONFIG_TARGET_KM_KIRKWOOD=y
+CONFIG_PIGGY_MAC_ADRESS_OFFSET=3
+CONFIG_KM_ENV_IS_IN_SPI_NOR=y
+CONFIG_KM_PIGGY4_88E6352=y
 CONFIG_IDENT_STRING="\nKeymile COGE5UN"
 CONFIG_SYS_EXTRA_OPTIONS="KM_COGE5UN"
 CONFIG_MISC_INIT_R=y
index 08e9b7566ab87f3a507f08f68a5e9a52fbe81283..149688216395fee0fa862946a75557948970f70d 100644 (file)
@@ -3,6 +3,9 @@ CONFIG_SYS_DCACHE_OFF=y
 CONFIG_KIRKWOOD=y
 CONFIG_SYS_TEXT_BASE=0x07d00000
 CONFIG_TARGET_KM_KIRKWOOD=y
+CONFIG_KM_FPGA_CONFIG=y
+CONFIG_KM_ENV_IS_IN_SPI_NOR=y
+CONFIG_KM_PIGGY4_88E6352=y
 CONFIG_IDENT_STRING="\nKeymile NUSA"
 CONFIG_SYS_EXTRA_OPTIONS="KM_NUSA"
 CONFIG_MISC_INIT_R=y
@@ -38,6 +41,7 @@ CONFIG_BOOTCOUNT_BOOTLIMIT=3
 CONFIG_SPI_FLASH=y
 CONFIG_SF_DEFAULT_SPEED=8100000
 CONFIG_SPI_FLASH_STMICRO=y
+CONFIG_MV88E6352_SWITCH=y
 CONFIG_MVGBE=y
 CONFIG_MII=y
 CONFIG_SYS_NS16550=y
index cafc1f97cb4dc9827bf31e0f472426632b6de533..5da967ad2afbcff43d309054a776d01f7b52b828 100644 (file)
@@ -3,6 +3,9 @@ CONFIG_SYS_DCACHE_OFF=y
 CONFIG_KIRKWOOD=y
 CONFIG_SYS_TEXT_BASE=0x07d00000
 CONFIG_TARGET_KM_KIRKWOOD=y
+CONFIG_KM_FPGA_CONFIG=y
+CONFIG_KM_ENV_IS_IN_SPI_NOR=y
+CONFIG_KM_PIGGY4_88E6352=y
 CONFIG_IDENT_STRING="\nKeymile SUGP1"
 CONFIG_SYS_EXTRA_OPTIONS="KM_SUGP1"
 CONFIG_MISC_INIT_R=y
@@ -38,6 +41,7 @@ CONFIG_BOOTCOUNT_BOOTLIMIT=3
 CONFIG_SPI_FLASH=y
 CONFIG_SF_DEFAULT_SPEED=8100000
 CONFIG_SPI_FLASH_STMICRO=y
+CONFIG_MV88E6352_SWITCH=y
 CONFIG_MVGBE=y
 CONFIG_MII=y
 CONFIG_SYS_NS16550=y
index 14c1c168f68a111128affa47be860193ad5bd583..ced1be5c0be28f425090ebe3de54ac1be2cadbb6 100644 (file)
@@ -3,6 +3,8 @@ CONFIG_SYS_DCACHE_OFF=y
 CONFIG_KIRKWOOD=y
 CONFIG_SYS_TEXT_BASE=0x07d00000
 CONFIG_TARGET_KM_KIRKWOOD=y
+CONFIG_KM_FPGA_CONFIG=y
+CONFIG_KM_ENV_IS_IN_SPI_NOR=y
 CONFIG_IDENT_STRING="\nKeymile SUV31"
 CONFIG_SYS_EXTRA_OPTIONS="KM_SUV31"
 CONFIG_MISC_INIT_R=y
index 6f2f7329a279f6544b11ee8c2fe0275f17e1cf65..890c4138ecccf65a7702083452257db582291d58 100644 (file)
@@ -173,6 +173,7 @@ CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y
 CONFIG_FLASH_CFI_MTD=y
 CONFIG_SYS_FLASH_PROTECTION=y
 CONFIG_SYS_FLASH_CFI=y
+CONFIG_MV88E6352_SWITCH=y
 # CONFIG_PCI is not set
 CONFIG_QE=y
 CONFIG_SYS_QE_FMAN_FW_IN_NOR=y
index 6b36cf9ce88e124388d38e2e4bd5c4ffaddd0e66..6dd21bcdc1d05b77e6aa4ec8ed6d5110e1878e4d 100644 (file)
@@ -3,6 +3,8 @@ CONFIG_SYS_DCACHE_OFF=y
 CONFIG_KIRKWOOD=y
 CONFIG_SYS_TEXT_BASE=0x07d00000
 CONFIG_TARGET_KM_KIRKWOOD=y
+CONFIG_PIGGY_MAC_ADRESS_OFFSET=3
+CONFIG_KM_PIGGY4_88E6061=y
 CONFIG_IDENT_STRING="\nKeymile COGE3UN"
 CONFIG_SYS_EXTRA_OPTIONS="KM_MGCOGE3UN"
 CONFIG_MISC_INIT_R=y
index 918d27c331d5e76b84ef6f0625e8e2ecff91bcc0..a8981db956f649a4597625b1805ba3ba274d43ed 100644 (file)
@@ -3,6 +3,7 @@ CONFIG_SYS_DCACHE_OFF=y
 CONFIG_KIRKWOOD=y
 CONFIG_SYS_TEXT_BASE=0x07d00000
 CONFIG_TARGET_KM_KIRKWOOD=y
+CONFIG_KM_PIGGY4_88E6061=y
 CONFIG_IDENT_STRING="\nKeymile Port-L2"
 CONFIG_SYS_EXTRA_OPTIONS="KM_PORTL2"
 CONFIG_MISC_INIT_R=y
index 16b11d82a201e6baf2d3026a2b038ce6b9f8a3b1..74cd67456c8646667833bfb2075eb3ab5670c6e1 100644 (file)
@@ -12,7 +12,7 @@
 #define CONFIG_JFFS2_CMDLINE
 
 /* standard km ethernet_present for piggy */
-#define CONFIG_KM_COMMON_ETH_INIT
+#define CONFIG_KM_COMMON_ETH_INIT 1
 
 /* EEprom support 24C08, 24C16, 24C64 */
 #define CONFIG_SYS_EEPROM_PAGE_WRITE_ENABLE
index a381a9847028eaa1a1c403c9969d62c7de04479c..6faff0fdb31df73dda81123e3de4926da57a6f6c 100644 (file)
 #define CONFIG_MVGBE_PORTS     {1, 0}  /* enable port 0 only */
 #define CONFIG_PHY_BASE_ADR    0
 #define CONFIG_ENV_OVERWRITE   /* ethaddr can be reprogrammed */
-#define CONFIG_KM_COMMON_ETH_INIT /* standard km ethernet_present for piggy */
+#define CONFIG_KM_COMMON_ETH_INIT /* standard km ethernet_present for piggy */
 
 /*
  * I2C related stuff
index e7b12d0dca598953848cc32102967005a8887515..d0324573b17588a0de2f8115115619f403142879 100644 (file)
@@ -30,7 +30,7 @@
 #elif defined(CONFIG_KM_KIRKWOOD_PCI)
 #define CONFIG_HOSTNAME                        "km_kirkwood_pci"
 #define CONFIG_KM_IVM_BUS              1       /* I2C2 (Mux-Port 1)*/
-#define CONFIG_KM_FPGA_CONFIG
+#define CONFIG_KM_FPGA_CONFIG 1
 #define CONFIG_KM_UBI_PART_BOOT_OPTS           ",2048"
 #define CONFIG_SYS_NAND_NO_SUBPAGE_WRITE
 
 
 #undef CONFIG_SYS_KWD_CONFIG
 #define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage_128M16_1.cfg
-#define CONFIG_KM_ENV_IS_IN_SPI_NOR
-#define CONFIG_KM_FPGA_CONFIG
-#define CONFIG_KM_PIGGY4_88E6352
-#define CONFIG_MV88E6352_SWITCH
+#define CONFIG_KM_ENV_IS_IN_SPI_NOR 1
+#define CONFIG_KM_FPGA_CONFIG 1
+#define CONFIG_KM_PIGGY4_88E6352 1
+#define CONFIG_MV88E6352_SWITCH 1
 #define CONFIG_KM_MVEXTSW_ADDR         0x10
 
 /* KM_MGCOGE3UN */
 #define CONFIG_KM_BOARD_EXTRA_ENV      "waitforne=true\0"
 #define CONFIG_PIGGY_MAC_ADRESS_OFFSET  3
 #define CONFIG_KM_DISABLE_PCIE
-#define CONFIG_KM_PIGGY4_88E6061
+#define CONFIG_KM_PIGGY4_88E6061 1
 
 /* KMCOGE5UN */
 #elif defined(CONFIG_KM_COGE5UN)
 #define CONFIG_KM_IVM_BUS              1       /* I2C2 (Mux-Port 1)*/
 #undef CONFIG_SYS_KWD_CONFIG
 #define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage_256M8_1.cfg
-#define CONFIG_KM_ENV_IS_IN_SPI_NOR
+#define CONFIG_KM_ENV_IS_IN_SPI_NOR 1
 #define CONFIG_PIGGY_MAC_ADRESS_OFFSET 3
 #define CONFIG_HOSTNAME                        "kmcoge5un"
 #define CONFIG_KM_DISABLE_PCIE
-#define CONFIG_KM_PIGGY4_88E6352
+#define CONFIG_KM_PIGGY4_88E6352 1
 
 /* KM_PORTL2 */
 #elif defined(CONFIG_KM_PORTL2)
 #define CONFIG_HOSTNAME                        "portl2"
 #define CONFIG_KM_IVM_BUS              1       /* I2C2 (Mux-Port 1)*/
-#define CONFIG_KM_PIGGY4_88E6061
+#define CONFIG_KM_PIGGY4_88E6061 1
 
 /* KM_SUV31 */
 #elif defined(CONFIG_KM_SUV31)
@@ -95,8 +95,8 @@
 #define CONFIG_HOSTNAME                        "kmsuv31"
 #undef CONFIG_SYS_KWD_CONFIG
 #define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage_128M16_1.cfg
-#define CONFIG_KM_ENV_IS_IN_SPI_NOR
-#define CONFIG_KM_FPGA_CONFIG
+#define CONFIG_KM_ENV_IS_IN_SPI_NOR 1
+#define CONFIG_KM_FPGA_CONFIG 1
 #define CONFIG_KM_UBI_PART_BOOT_OPTS           ",2048"
 #define CONFIG_SYS_NAND_NO_SUBPAGE_WRITE
 #else
index 6e5d50700c07d359f0452cf462fd502b34ff21ac..30495217573efa5b50717e7649c955e70b643848 100644 (file)
@@ -37,7 +37,7 @@
 /*
  * QE UEC ethernet configuration
  */
-#define CONFIG_MV88E6352_SWITCH
+#define CONFIG_MV88E6352_SWITCH 1
 #define CONFIG_KM_MVEXTSW_ADDR         0x10
 
 /* ethernet port connected to simple switch 88e6122 (UEC0) */