cl-som-am57x: initial support
Subsystems (3)
v3 cover cl-som-am57x: initial support
This patch series adds support for CompuLab CL-SOM-AM57X board and the SBC-AM57X evaluation kit.
CL-SOM-AM57x is a miniature System-on-Module (SoM) based on TI Sitara AM57x ARM Cortex-A15 System-on-Chip family.
SBC-AM57x is a single board computer, implemented with the CL-SOM-AM57x computer-on-module and the SB-SOM-AM57x carrier board. The CL-SOM-AM57x providing most of the functions and the SB-SOM-AM57x providing additional peripheral functions and connectors.
The SBC-AM57x has the following features:
CPU: Texas Instruments Sitara AM5728 dual-core ARM Cortex-A15, 1.5GHz or
Texas Instruments Sitara AM5718 single-core ARM Cortex-A15, 1.5GHz
RAM: DDR3, 512MB ? 4GB
Storage: NAND flash, 512MB - 1GB or eMMC flash, 4GB - 32GB
SPI-flash 2MB
Ethernet: Up to 2x 10/100/1000Mbps Ethernet ports (MAC+PHY)
WiFi/BT: 802.11b/g/n WiFi interface (TI WiLink 8 WL1801 chipset) or
Dual-band 2x2 802.11a/b/g/n WiFi interface (TI WiLink 8 WL1837 chipset)
Analog Audio: Audio codec with stereo output, stereo input and microphone support
More details can be found here:
https://www.compulab.co.il/products/sbcs/sbc-am57x-ti-am5728-am5718-single-board-computer/
Dmitry Lifshitz (3):
arm: am57xx: cl-som-am57x: add initial board support
arm: am57xx: cl-som-am57x: fetch board rev from EEPROM
arm: am57xx: cl-som-am57x: add ETH support
Uri Mashiach (1):
arm: am57xx: cl-som-am57x: update default env
arch/arm/mach-omap2/omap5/Kconfig | 4 + board/compulab/cl-som-am57x/Kconfig | 12 ++ board/compulab/cl-som-am57x/MAINTAINERS | 6 + board/compulab/cl-som-am57x/Makefile | 17 +++ board/compulab/cl-som-am57x/cl-som-am57x.c | 76 ++++++++++ board/compulab/cl-som-am57x/eth.c | 199 ++++++++++++++++++++++++++ board/compulab/cl-som-am57x/mux.c | 123 ++++++++++++++++ board/compulab/cl-som-am57x/spl.c | 222 +++++++++++++++++++++++++++++ configs/cl-som-am57x_defconfig | 41 ++++++ include/configs/cl-som-am57x.h | 197 +++++++++++++++++++++++++ 10 files changed, 897 insertions(+) create mode 100644 board/compulab/cl-som-am57x/Kconfig create mode 100644 board/compulab/cl-som-am57x/MAINTAINERS create mode 100644 board/compulab/cl-som-am57x/Makefile create mode 100644 board/compulab/cl-som-am57x/cl-som-am57x.c create mode 100644 board/compulab/cl-som-am57x/eth.c create mode 100644 board/compulab/cl-som-am57x/mux.c create mode 100644 board/compulab/cl-som-am57x/spl.c create mode 100644 configs/cl-som-am57x_defconfig create mode 100644 include/configs/cl-som-am57x.h
Signature · 1 line
2.7.4
PATCH v3 1/4 arm: am57xx: cl-som-am57x: add initial board support
From: Dmitry Lifshitz <[email protected]>
Features supported :
* Serial console
* SPI Flash
* MMC/SD Card
* eMMC storage
* SATA
* PCA9555 - GPIO expander over I2C5 bus
* USB
Use spl alternate boot device feature to define fallback to the main boot device as it is defined by hardware.
---
---
v2 -> v3: Remove CONFIG_SPL_OS_BOOT from board configuration file -
CONFIG_SPL_OS_BOOT included in Kconfig
v1 -> v2: Merged with commit "add MMC as a boot devices for spl".
Commit "add MMC as a boot devices for spl" converted to Kconfig
arch/arm/mach-omap2/omap5/Kconfig | 4 + board/compulab/cl-som-am57x/Kconfig | 12 ++ board/compulab/cl-som-am57x/MAINTAINERS | 6 + board/compulab/cl-som-am57x/Makefile | 15 ++ board/compulab/cl-som-am57x/cl-som-am57x.c | 62 ++++++++ board/compulab/cl-som-am57x/mux.c | 100 +++++++++++++ board/compulab/cl-som-am57x/spl.c | 222 +++++++++++++++++++++++++++++ configs/cl-som-am57x_defconfig | 41 ++++++ include/configs/cl-som-am57x.h | 105 ++++++++++++++ 9 files changed, 567 insertions(+) create mode 100644 board/compulab/cl-som-am57x/Kconfig create mode 100644 board/compulab/cl-som-am57x/MAINTAINERS create mode 100644 board/compulab/cl-som-am57x/Makefile create mode 100644 board/compulab/cl-som-am57x/cl-som-am57x.c create mode 100644 board/compulab/cl-som-am57x/mux.c create mode 100644 board/compulab/cl-som-am57x/spl.c create mode 100644 configs/cl-som-am57x_defconfig create mode 100644 include/configs/cl-som-am57x.h
arch/arm/mach-omap2/omap5/Kconfig +4 -0
@@ -40,6 +40,9 @@ choice prompt "OMAP5 board select" optional +config TARGET_CL_SOM_AM57X + bool "CompuLab CL-SOM-AM57x" + config TARGET_CM_T54 bool "CompuLab CM-T54"
@@ -86,6 +89,7 @@ config TI_SECURE_EMIF_PROTECTED_REGION_SIZE using hardware memory firewalls. This value must be smaller than the TI_SECURE_EMIF_TOTAL_REGION_SIZE value. +source "board/compulab/cl-som-am57x/Kconfig" source "board/compulab/cm_t54/Kconfig" source "board/ti/omap5_uevm/Kconfig" source "board/ti/dra7xx/Kconfig"
board/compulab/cl-som-am57x/Kconfig new file +12 -0
@@ -0,0 +1,12 @@ +if TARGET_CL_SOM_AM57X + +config SYS_BOARD + default "cl-som-am57x" + +config SYS_VENDOR + default "compulab" + +config SYS_CONFIG_NAME + default "cl-som-am57x" + +endif
board/compulab/cl-som-am57x/MAINTAINERS new file +6 -0
@@ -0,0 +1,6 @@ +CL-SOM-AM57x BOARD +M: Uri Mashiach <[email protected]> +S: Maintained +F: board/compulab/cl-som-am57x/ +F: include/configs/cl-som-am57x.h +F: configs/cl-som-am57x_defconfig
board/compulab/cl-som-am57x/Makefile new file +15 -0
@@ -0,0 +1,15 @@ +# +# Makefile +# +# (C) Copyright 2016 CompuLab, Ltd. <www.compulab.co.il> +# +# Author: Dmitry Lifshitz <[email protected]> +# +# SPDX-License-Identifier: GPL-2.0+ +# + +ifdef CONFIG_SPL_BUILD +obj-y += spl.o mux.o +else +obj-y += cl-som-am57x.o mux.o +endif
board/compulab/cl-som-am57x/cl-som-am57x.c new file +62 -0
62 lines not on this page · raw message
board/compulab/cl-som-am57x/mux.c new file +100 -0
100 lines not on this page · raw message
board/compulab/cl-som-am57x/spl.c new file +222 -0
222 lines not on this page · raw message
configs/cl-som-am57x_defconfig new file +41 -0
41 lines not on this page · raw message
include/configs/cl-som-am57x.h new file +105 -0
105 lines not on this page · raw message
Signature · 1 line
2.7.4
PATCH v3 1/4 arm: am57xx: cl-som-am57x: add initial board support
Quoted 12 lines · Uri Mashiach
From: Dmitry Lifshitz <[email protected]>
Features supported :
* Serial console
* SPI Flash
* MMC/SD Card
* eMMC storage
* SATA
* PCA9555 - GPIO expander over I2C5 bus
* USB
Quoted 7 lines
Use spl alternate boot device feature to define fallback to the main boot device as it is defined by hardware.
Signed-off-by Dmitry Lifshitz <[email protected]>[uri.mashiach at compulab.co.il: Adjust to v2016.11]Signed-off-by Uri Mashiach <[email protected]>Acked-by Igor Grinberg <[email protected]>
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161208/b347e1f6/attachment.sig>
PATCH v3 1/4 arm: am57xx: cl-som-am57x: add initial board support
In reply to Uri MashiachQuoted 12 lines · Uri Mashiach
From: Dmitry Lifshitz <[email protected]>
Features supported :
* Serial console
* SPI Flash
* MMC/SD Card
* eMMC storage
* SATA
* PCA9555 - GPIO expander over I2C5 bus
* USB
Quoted 8 lines
Use spl alternate boot device feature to define fallback to the main boot device as it is defined by hardware.
Signed-off-by Dmitry Lifshitz <[email protected]>[uri.mashiach at compulab.co.il: Adjust to v2016.11]Signed-off-by Uri Mashiach <[email protected]>Acked-by Igor Grinberg <[email protected]>Reviewed-by Tom Rini <[email protected]>
Please rebase onto master (and test, there's been a few related changes in this area), thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161227/f557ffda/attachment.sig>
PATCH v3 2/4 arm: am57xx: cl-som-am57x: fetch board rev from EEPROM
In reply to Uri MashiachFrom: Dmitry Lifshitz <[email protected]>
Add PCB revision message.
Implement board revision get_board_rev API.
Commit description update.
--- board/compulab/cl-som-am57x/cl-som-am57x.c | 14 ++++++++++++++ include/configs/cl-som-am57x.h | 14 ++++++++++++++ 2 files changed, 28 insertions(+)
board/compulab/cl-som-am57x/cl-som-am57x.c +14 -0
@@ -14,6 +14,8 @@#include <asm/gpio.h> #include <asm/arch/mmc_host_def.h> #include <asm/arch/sys_proto.h> +#include "../common/common.h" +#include "../common/eeprom.h" DECLARE_GLOBAL_DATA_PTR ;
@@ -60,3 +62,15 @@ int board_usb_init(int index, enum usb_init_type init) return 0; }#endif /* CONFIG_USB_XHCI_OMAP */ + +int misc_init_r (void ) +{ +cl_print_pcb_info (); + +return 0 ; +} + +u32 get_board_rev (void ) +{ +return cl_eeprom_get_board_rev (CONFIG_SYS_I2C_EEPROM_BUS ); +}
include/configs/cl-som-am57x.h +14 -0
@@ -24,6 +24,10 @@#include <configs/ti_omap5_common.h> +/* misc */ +#define CONFIG_MISC_INIT_R +#define CONFIG_REVISION_TAG +/* Status LED */ #define CONFIG_STATUS_LED /* Status LED enabled */ #define CONFIG_GPIO_LED
@@ -65,6 +69,16 @@#define CONFIG_ENV_OFFSET (768 * 1024)#define CONFIG_ENV_SPI_MAX_HZ 48000000 +/* EEPROM */ +#define CONFIG_SYS_I2C_EEPROM_ADDR 0x50 +#define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1 +#define CONFIG_SYS_I2C_EEPROM_BUS 3 + +#define CONFIG_CMD_EEPROM +#define CONFIG_CMD_EEPROM_LAYOUT +#define CONFIG_ENV_EEPROM_IS_ON_I2C +#define CONFIG_SYS_EEPROM_SIZE 256 +#ifndef CONFIG_SPL_BUILD /* SATA */ #define CONFIG_CMD_SCSI
Signature · 1 line
2.7.4
PATCH v3 3/4 arm: am57xx: cl-som-am57x: add ETH support
In reply to Uri MashiachFrom: Dmitry Lifshitz <[email protected]>
Add MAC support.
Use PHY, connected to RGMII1 as a default Eth adapter, by appropriate setting of 'cpsw_data.active_slave'.
'cpsw_phy' env variable can override this setting.
Set the MAC addresses in the U-Boot environment.
The addresses are retrieved from the on-board EEPROM or from the SOC's MAC fuses.
Set the following PHYs RGMII clock delays:
- Enable RX delay
- Disable TX delay
--- board/compulab/cl-som-am57x/Makefile | 2 + board/compulab/cl-som-am57x/eth.c | 199 +++++++++++++++++++++++++++++++++++ board/compulab/cl-som-am57x/mux.c | 23 ++++ include/configs/cl-som-am57x.h | 17 +++ 4 files changed, 241 insertions(+) create mode 100644 board/compulab/cl-som-am57x/eth.c
board/compulab/cl-som-am57x/Makefile +2 -0
@@ -13,3 +13,5 @@ obj-y += spl.o mux.o else obj-y += cl-som-am57x.o mux.o endif + +obj-$(CONFIG_DRIVER_TI_CPSW) += eth.o
board/compulab/cl-som-am57x/eth.c new file +199 -0
199 lines not on this page · raw message
board/compulab/cl-som-am57x/mux.c +23 -0
@@ -83,6 +83,28 @@ static const struct pad_conf_entry cl_som_am57x_padconf_usb[] = { {USB1_DRVVBUS, (M0 | FSC) }, /* USB1_DRVVBUS.USB1_DRVVBUS */ }; +/* Ethernet */ +static const struct pad_conf_entry cl_som_am57x_padconf_ethernet[] = { +/* MDIO bus */ + {VIN2A_D10 , (PDIS |PTU |M3 ) },/* VIN2A_D10.MDIO_MCLK */ + {VIN2A_D11 , (IEN |PDIS |PTU |M3 ) },/* VIN2A_D11.MDIO_D */ +/* EMAC Slave 1@addr 0x1 - Default interface */ + {VIN2A_D12 , (IDIS |PEN |M3 ) },/* VIN2A_D12.RGMII1_TXC */ + {VIN2A_D13 , (IDIS |PEN |M3 ) },/* VIN2A_D13.RGMII1_TXCTL */ + {VIN2A_D14 , (IDIS |PEN |M3 ) },/* VIN2A_D14.RGMII1_TXD3 */ + {VIN2A_D15 , (IDIS |PEN |M3 ) },/* VIN2A_D15.RGMII1_TXD2 */ + {VIN2A_D16 , (IDIS |PEN |M3 ) },/* VIN2A_D16.RGMII1_TXD1 */ + {VIN2A_D17 , (IDIS |PEN |M3 ) },/* VIN2A_D17.RGMII1_TXD0 */ + {VIN2A_D18 , (IEN |PDIS |PTD |M3 ) },/* VIN2A_D18.RGMII1_RXC */ + {VIN2A_D19 , (IEN |PDIS |PTD |M3 ) },/* VIN2A_D19.RGMII1_RXCTL */ + {VIN2A_D20 , (IEN |PDIS |PTD |M3 ) },/* VIN2A_D20.RGMII1_RXD3 */ + {VIN2A_D21 , (IEN |PDIS |PTD |M3 ) },/* VIN2A_D21.RGMII1_RXD2 */ + {VIN2A_D22 , (IEN |PDIS |PTD |M3 ) },/* VIN2A_D22.RGMII1_RXD1 */ + {VIN2A_D23 , (IEN |PDIS |PTD |M3 ) },/* VIN2A_D23.RGMII1_RXD0 */ +/* Eth PHY1 reset GPIOs*/ + {VIN1B_CLK1 , (IDIS |PDIS |PTD |M14 )},/* VIN1B_CLK1.GPIO2_31 */ +}; +#define SET_MUX (mux_array) do_set_mux32((*ctrl)->control_padconf_core_base, \ mux_array, ARRAY_SIZE(mux_array))
@@ -97,4 +119,5 @@ void set_muxconf_regs(void)SET_MUX (cl_som_am57x_padconf_i2c_gpio);SET_MUX (cl_som_am57x_padconf_emmc);SET_MUX (cl_som_am57x_padconf_usb); +SET_MUX (cl_som_am57x_padconf_ethernet); }
include/configs/cl-som-am57x.h +17 -0
@@ -114,6 +114,23 @@#define CONFIG_USB_ETHER_ASIX #define CONFIG_USB_ETHER_MCS7830 +/* CPSW Ethernet */ +#define CONFIG_DRIVER_TI_CPSW +#define CONFIG_MII +#define CONFIG_BOOTP_DEFAULT +#define CONFIG_BOOTP_SEND_HOSTNAME +#define CONFIG_BOOTP_GATEWAY +#define CONFIG_PHY_GIGE +#define CONFIG_PHY_ATHEROS +#define CONFIG_PHYLIB +#define CONFIG_SYS_RX_ETH_BUFFER 64 +#define PHY_ANEG_TIMEOUT 8000 + +#define CONFIG_BOOTP_DNS +#define CONFIG_BOOTP_DNS2 +#define CONFIG_BOOTP_SUBNETMASK +#define CONFIG_NET_RETRY_COUNT 10 +#endif /* !CONFIG_SPL_BUILD */ #endif /* __CONFIG_CL_SOM_AM57X_H */
Signature · 1 line
2.7.4
PATCH v3 4/4 arm: am57xx: cl-som-am57x: update default env
In reply to Uri MashiachModify U-Boot default env settings.
Boot sequence:
1. SD card boot script
2. SD card boot no script
3. SATA boot script
4. SATA boot no script
5. eMMC boot script
6. eMMC boot no script
--- include/configs/cl-som-am57x.h | 61 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+)
include/configs/cl-som-am57x.h +61 -0
@@ -133,4 +133,65 @@#endif /* !CONFIG_SPL_BUILD */ +/* Default environment */ +#undef CONFIG_EXTRA_ENV_SETTINGS +#define CONFIG_EXTRA_ENV_SETTINGS \ + DEFAULT_LINUX_BOOT_ENV \ + "autoload=no\0" \ + "baudrate=115200\0" \ + "console=ttyO2,115200n8\0" \ + "bootdelay=3\0" \ + "fdtfile=am57xx-sbc-am57x.dtb\0" \ + "kernel=zImage-cl-som-am57x\0" \ + "bootscr=bootscr.img\0" \ + "displaytype=hdmi\0" \ + "bootkernel=bootz ${loadaddr} - ${fdtaddr}\0" \ + "mmcloadfdt=load mmc ${mmcdev} ${fdtaddr} ${fdtfile}\0" \ + "mmcloadkernel=load mmc ${mmcdev} ${loadaddr} ${kernel}\0" \ + "load_mmc=mmc dev ${mmcdev} && mmc rescan && " \ + "run mmcloadkernel run mmcloadfdt\0" \ + "mmcroot=/dev/mmcblk1p2\0" \ + "mmcrootfstype=ext4 rw rootwait\0" \ + "mmcargs=setenv bootargs console=${console} root=${mmcroot} " \ + "rootfstype=${mmcrootfstype}\0" \ + "mmcbootscript=setenv mmcdev 0; mmc dev ${mmcdev} && mmc rescan && " \ + "load mmc ${mmcdev} ${loadaddr} ${bootscr} && " \ + "echo Running bootscript from MMC/SD Card ... && " \ + "source ${loadaddr}\0" \ + "mmcboot=setenv mmcdev 0 && run load_mmc && " \ + "run mmcargs && echo Booting from MMC/SD Card ... && " \ + "run bootkernel\0" \ + "emmcroot=/dev/mmcblk0p2\0" \ + "emmcrootfstype=ext4 rw rootwait\0" \ + "emmcargs=setenv bootargs console=${console} " \ + "root=${emmcroot} " \ + "rootfstype=${emmcrootfstype}\0" \ + "emmcbootscript=setenv mmcdev 1; mmc dev ${mmcdev} && mmc rescan && " \ + "load mmc ${mmcdev} ${loadaddr} ${bootscr} && " \ + "echo Running bootscript from eMMC ... && " \ + "source ${loadaddr}\0" \ + "emmcboot=setenv mmcdev 1 && run load_mmc && " \ + "run emmcargs && echo Booting from eMMC ... && " \ + "run bootkernel\0" \ + "sataroot=/dev/sda2\0" \ + "satarootfstype=ext4 rw rootwait\0" \ + "load_sata=load scsi 0 ${loadaddr} ${kernel} && " \ + "load scsi 0 ${fdtaddr} ${fdtfile}\0" \ + "sataargs=setenv bootargs console=${console} " \ + "root=${sataroot} " \ + "rootfstype=${satarootfstype}\0" \ + "satabootscript=load scsi 0 ${loadaddr} ${bootscr} && " \ + "echo Running bootscript from SATA ... && " \ + "source ${loadaddr}\0" \ + "sataboot=run load_sata && run sataargs && " \ + "echo Booting from SATA ... && " \ + "run bootkernel\0" \ + +#undef CONFIG_BOOTCOMMAND +#define CONFIG_BOOTCOMMAND \ + "run mmcbootscript || run mmcboot || " \ + "run satabootscript || run sataboot || " \ + "run emmcbootscript || run emmcboot" + +#endif /* __CONFIG_CL_SOM_AM57X_H */
Signature · 1 line
2.7.4