summaryrefslogtreecommitdiff
path: root/board/keymile
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2019-08-12 23:03:44 -0400
committerTom Rini <trini@konsulko.com>2019-08-12 23:03:44 -0400
commit88c7a0a8c2ce6b503ff5d5509effb2a9f844993e (patch)
treee3c57d6e9c0cdeb438ba8f96c19f93fe14336654 /board/keymile
parent60f38d82c45fef55ac04ee52b234e6dd07e31935 (diff)
parent193a1e9f196b7fb7e913a70936c8a49060a1859c (diff)
Merge https://gitlab.denx.de/u-boot/custodians/u-boot-marvell
- Various improvements to Keymile boards - mostly DT conversation (Pascal & Holger) - Removal of now unsupported Keymile boards (Pascal & Holger) - Small MVEBU PCI fix (Marek) - Turris Omnia defconfig update (Marek) - Misc Allied Telesis defconfig updates (Chris)
Diffstat (limited to 'board/keymile')
-rw-r--r--board/keymile/Kconfig101
-rw-r--r--board/keymile/common/common.h4
-rw-r--r--board/keymile/common/ivm.c5
-rw-r--r--board/keymile/km83xx/Kconfig19
-rw-r--r--board/keymile/km83xx/MAINTAINERS1
-rw-r--r--board/keymile/km83xx/km83xx.c81
-rw-r--r--board/keymile/km_arm/Kconfig31
-rw-r--r--board/keymile/km_arm/MAINTAINERS1
-rw-r--r--board/keymile/kmp204x/MAINTAINERS1
9 files changed, 132 insertions, 112 deletions
diff --git a/board/keymile/Kconfig b/board/keymile/Kconfig
index e30d64818c..acaa9289f7 100644
--- a/board/keymile/Kconfig
+++ b/board/keymile/Kconfig
@@ -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
diff --git a/board/keymile/common/common.h b/board/keymile/common/common.h
index 859d9130a9..42b760dc6e 100644
--- a/board/keymile/common/common.h
+++ b/board/keymile/common/common.h
@@ -120,10 +120,6 @@ struct bfticu_iomap {
u8 pb_dbug;
};
-#if !defined(CONFIG_PIGGY_MAC_ADRESS_OFFSET)
-#define CONFIG_PIGGY_MAC_ADRESS_OFFSET 0
-#endif
-
int ethernet_present(void);
int ivm_read_eeprom(unsigned char *buf, int len);
int ivm_analyze_eeprom(unsigned char *buf, int len);
diff --git a/board/keymile/common/ivm.c b/board/keymile/common/ivm.c
index da0634f01b..50df44d1c1 100644
--- a/board/keymile/common/ivm.c
+++ b/board/keymile/common/ivm.c
@@ -311,11 +311,6 @@ static int ivm_populate_env(unsigned char *buf, int len)
/* if an offset is defined, add it */
process_mac(valbuf, page2, CONFIG_PIGGY_MAC_ADRESS_OFFSET, true);
env_set((char *)"ethaddr", (char *)valbuf);
-#ifdef CONFIG_KMVECT1
-/* KMVECT1 has two ethernet interfaces */
- process_mac(valbuf, page2, 1, true);
- env_set((char *)"eth1addr", (char *)valbuf);
-#endif
#else
/* KMTEGR1 has a special setup. eth0 has no connection to the outside and
* gets an locally administred MAC address, eth1 is the debug interface and
diff --git a/board/keymile/km83xx/Kconfig b/board/keymile/km83xx/Kconfig
index 0a41be57f5..1011cc8b2c 100644
--- a/board/keymile/km83xx/Kconfig
+++ b/board/keymile/km83xx/Kconfig
@@ -38,25 +38,6 @@ config BOARD_SPECIFIC_OPTIONS # dummy
endif
-if TARGET_KMVECT1
-
-config SYS_BOARD
- default "km83xx"
-
-config SYS_VENDOR
- default "keymile"
-
-config SYS_CONFIG_NAME
- default "kmvect1"
-
-config BOARD_SPECIFIC_OPTIONS # dummy
- def_bool y
- select ARCH_MPC8309
- imply CMD_CRAMFS
- imply FS_CRAMFS
-
-endif
-
if TARGET_KMTEGR1
config SYS_BOARD
diff --git a/board/keymile/km83xx/MAINTAINERS b/board/keymile/km83xx/MAINTAINERS
index 94e0d572e2..d2af983073 100644
--- a/board/keymile/km83xx/MAINTAINERS
+++ b/board/keymile/km83xx/MAINTAINERS
@@ -10,7 +10,6 @@ F: configs/kmopti2_defconfig
F: configs/kmtepr2_defconfig
F: include/configs/suvd3.h
F: configs/kmtegr1_defconfig
-F: configs/kmvect1_defconfig
F: configs/suvd3_defconfig
F: configs/tuge1_defconfig
F: configs/tuxx1_defconfig
diff --git a/board/keymile/km83xx/km83xx.c b/board/keymile/km83xx/km83xx.c
index 51778368d9..8846b64f7d 100644
--- a/board/keymile/km83xx/km83xx.c
+++ b/board/keymile/km83xx/km83xx.c
@@ -125,19 +125,10 @@ static int piggy_present(void)
return in_8(&base->bprth) & PIGGY_PRESENT;
}
-#if defined(CONFIG_KMVECT1)
-int ethernet_present(void)
-{
- /* ethernet port connected to simple switch without piggy */
- return 1;
-}
-#else
int ethernet_present(void)
{
return piggy_present();
}
-#endif
-
int board_early_init_r(void)
{
@@ -198,80 +189,8 @@ int misc_init_r(void)
return 0;
}
-#if defined(CONFIG_KMVECT1)
-#include <mv88e6352.h>
-/* Marvell MV88E6122 switch configuration */
-static struct mv88e_sw_reg extsw_conf[] = {
- /* port 1, FRONT_MDI, autoneg */
- { PORT(1), PORT_PHY, NO_SPEED_FOR },
- { PORT(1), PORT_CTRL, FORWARDING | EGRS_FLD_ALL },
- { PHY(1), PHY_1000_CTRL, NO_ADV },
- { PHY(1), PHY_SPEC_CTRL, AUTO_MDIX_EN },
- { PHY(1), PHY_CTRL, PHY_100_MBPS | AUTONEG_EN | AUTONEG_RST |
- FULL_DUPLEX },
- /* port 2, unused */
- { PORT(2), PORT_CTRL, PORT_DIS },
- { PHY(2), PHY_CTRL, PHY_PWR_DOWN },
- { PHY(2), PHY_SPEC_CTRL, SPEC_PWR_DOWN },
- /* port 3, BP_MII (CPU), PHY mode, 100BASE */
- { PORT(3), PORT_CTRL, FORWARDING | EGRS_FLD_ALL },
- /* port 4, ESTAR to slot 11, SerDes, 1000BASE-X */
- { PORT(4), PORT_STATUS, NO_PHY_DETECT },
- { PORT(4), PORT_PHY, SPEED_1000_FOR },
- { PORT(4), PORT_CTRL, FORWARDING | EGRS_FLD_ALL },
- /* port 5, ESTAR to slot 13, SerDes, 1000BASE-X */
- { PORT(5), PORT_STATUS, NO_PHY_DETECT },
- { PORT(5), PORT_PHY, SPEED_1000_FOR },
- { PORT(5), PORT_CTRL, FORWARDING | EGRS_FLD_ALL },
- /*
- * Errata Fix: 1.9V Output from Internal 1.8V Regulator,
- * acc . MV-S300889-00D.pdf , clause 4.5
- */
- { PORT(5), 0x1A, 0xADB1 },
- /* port 6, unused, this port has no phy */
- { PORT(6), PORT_CTRL, PORT_DIS },
- /*
- * Errata Fix: 1.9V Output from Internal 1.8V Regulator,
- * acc . MV-S300889-00D.pdf , clause 4.5
- */
- { PORT(5), 0x1A, 0xADB1 },
-};
-#endif
-
int last_stage_init(void)
{
-#if defined(CONFIG_KMVECT1)
- struct km_bec_fpga __iomem *base =
- (struct km_bec_fpga __iomem *)CONFIG_SYS_KMBEC_FPGA_BASE;
- u8 tmp_reg;
-
- /* Release mv88e6122 from reset */
- tmp_reg = in_8(&base->res1[0]) | 0x10; /* DIRECT3 register */
- out_8(&base->res1[0], tmp_reg); /* GP28 as output */
- tmp_reg = in_8(&base->gprt3) | 0x10; /* GP28 to high */
- out_8(&base->gprt3, tmp_reg);
-
- /* configure MV88E6122 switch */
- char *name = "UEC2";
-
- if (miiphy_set_current_dev(name))
- return 0;
-
- mv88e_sw_program(name, CONFIG_KM_MVEXTSW_ADDR, extsw_conf,
- ARRAY_SIZE(extsw_conf));
-
- mv88e_sw_reset(name, CONFIG_KM_MVEXTSW_ADDR);
-
- if (piggy_present()) {
- env_set("ethact", "UEC2");
- env_set("netdev", "eth1");
- puts("using PIGGY for network boot\n");
- } else {
- env_set("netdev", "eth0");
- puts("using frontport for network boot\n");
- }
-#endif
-
#if defined(CONFIG_TARGET_KMCOGE5NE)
struct bfticu_iomap *base =
(struct bfticu_iomap *)CONFIG_SYS_BFTIC3_BASE;
diff --git a/board/keymile/km_arm/Kconfig b/board/keymile/km_arm/Kconfig
index 19c1db3bc2..be6b162815 100644
--- a/board/keymile/km_arm/Kconfig
+++ b/board/keymile/km_arm/Kconfig
@@ -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
@@ -13,6 +42,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
def_bool y
select BOARD_LATE_INIT
select DM
+ select DM_ETH
+ select DM_SERIAL
select DM_SPI
select DM_SPI_FLASH
imply CMD_CRAMFS
diff --git a/board/keymile/km_arm/MAINTAINERS b/board/keymile/km_arm/MAINTAINERS
index d156e8574b..d80589ded7 100644
--- a/board/keymile/km_arm/MAINTAINERS
+++ b/board/keymile/km_arm/MAINTAINERS
@@ -11,4 +11,3 @@ F: configs/kmnusa_defconfig
F: configs/kmsugp1_defconfig
F: configs/kmsuv31_defconfig
F: configs/mgcoge3un_defconfig
-F: configs/portl2_defconfig
diff --git a/board/keymile/kmp204x/MAINTAINERS b/board/keymile/kmp204x/MAINTAINERS
index c5170c97e7..fb3aefdd37 100644
--- a/board/keymile/kmp204x/MAINTAINERS
+++ b/board/keymile/kmp204x/MAINTAINERS
@@ -4,4 +4,3 @@ S: Maintained
F: board/keymile/kmp204x/
F: include/configs/kmp204x.h
F: configs/kmcoge4_defconfig
-F: configs/kmlion1_defconfig