boards: arc: em_starterkit: Convert to v2

Converts the board to hwmv2, documentation for this board needs to
be vastly updated

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
This commit is contained in:
Jamie McCrae
2024-02-02 07:57:46 +00:00
committed by Carles Cufi
parent 437a430fbe
commit e12719154a
33 changed files with 63 additions and 122 deletions

View File

@@ -1,4 +0,0 @@
# SPDX-License-Identifier: Apache-2.0
zephyr_sources(pmodmux.c)
zephyr_sources_ifdef(CONFIG_ARC_MPU_ENABLE arc_mpu_regions.c)

View File

@@ -1,17 +0,0 @@
# DesignWare ARC EM Starter Kit board configuration options
# Copyright (c) 2017 Synopsys, Inc. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
choice
prompt "Board Firmware Version"
default BOARD_EM_STARTERKIT_R23
depends on BOARD_EM_STARTERKIT
config BOARD_EM_STARTERKIT_R22
bool "2.2"
config BOARD_EM_STARTERKIT_R23
bool "2.3"
endchoice

View File

@@ -1,17 +0,0 @@
# SPDX-License-Identifier: Apache-2.0
CONFIG_SOC_EMSK=y
CONFIG_SOC_EMSK_EM11D=y
CONFIG_BOARD_EM_STARTERKIT=y
CONFIG_BOARD_EM_STARTERKIT_R23=y
CONFIG_XIP=n
CONFIG_SYS_CLOCK_TICKS_PER_SEC=100
CONFIG_BUILD_NO_GAP_FILL=y
CONFIG_BUILD_OUTPUT_BIN=n
CONFIG_ARCV2_INTERRUPT_UNIT=y
CONFIG_ARCV2_TIMER=y
CONFIG_CONSOLE=y
CONFIG_UART_CONSOLE=y
CONFIG_SERIAL=y
CONFIG_UART_INTERRUPT_DRIVEN=y
CONFIG_GPIO=y

View File

@@ -1,21 +0,0 @@
# SPDX-License-Identifier: Apache-2.0
CONFIG_SOC_EMSK=y
CONFIG_SOC_EMSK_EM7D=y
CONFIG_BOARD_EM_STARTERKIT=y
CONFIG_BOARD_EM_STARTERKIT_R23=y
CONFIG_XIP=n
CONFIG_SYS_CLOCK_TICKS_PER_SEC=100
CONFIG_BUILD_NO_GAP_FILL=y
CONFIG_BUILD_OUTPUT_BIN=n
CONFIG_ARCV2_INTERRUPT_UNIT=y
CONFIG_ARCV2_TIMER=y
CONFIG_CONSOLE=y
CONFIG_UART_CONSOLE=y
CONFIG_SERIAL=y
CONFIG_UART_INTERRUPT_DRIVEN=y
CONFIG_GPIO=y
CONFIG_ARC_MPU_ENABLE=y
CONFIG_ARC_HAS_SECURE=y
CONFIG_TRUSTED_EXECUTION_SECURE=y
CONFIG_INIT_ARCH_HW_AT_BOOT=y

View File

@@ -1,18 +0,0 @@
# SPDX-License-Identifier: Apache-2.0
CONFIG_SOC_EMSK=y
CONFIG_SOC_EMSK_EM7D=y
CONFIG_BOARD_EM_STARTERKIT=y
CONFIG_BOARD_EM_STARTERKIT_R22=y
CONFIG_XIP=n
CONFIG_SYS_CLOCK_TICKS_PER_SEC=100
CONFIG_BUILD_NO_GAP_FILL=y
CONFIG_BUILD_OUTPUT_BIN=n
CONFIG_ARCV2_INTERRUPT_UNIT=y
CONFIG_ARCV2_TIMER=y
CONFIG_CONSOLE=y
CONFIG_UART_CONSOLE=y
CONFIG_SERIAL=y
CONFIG_UART_INTERRUPT_DRIVEN=y
CONFIG_GPIO=y
CONFIG_ARC_MPU_ENABLE=y

View File

@@ -0,0 +1,8 @@
# SPDX-License-Identifier: Apache-2.0
if((CONFIG_BOARD_EM_STARTERKIT_EMSK_EM9D OR CONFIG_BOARD_EM_STARTERKIT_EMSK_EM11D) AND "${BOARD_REVISION}" STREQUAL "2.2")
message(FATAL_ERROR "Board revision 2.2 is not supported for this SoC")
endif()
zephyr_sources(pmodmux.c)
zephyr_sources_ifdef(CONFIG_ARC_MPU_ENABLE arc_mpu_regions.c)

View File

@@ -2,9 +2,6 @@
if BOARD_EM_STARTERKIT
config BOARD
default "em_starterkit"
if I2C_DW
config I2C_DW_CLOCK_SPEED

View File

@@ -4,8 +4,10 @@
# SPDX-License-Identifier: Apache-2.0
config BOARD_EM_STARTERKIT
bool "ARC EM Starter Kit"
depends on SOC_EMSK
select SOC_EMSK
select SOC_EMSK_EM7D if BOARD_EM_STARTERKIT_EMSK_EM7D
select SOC_EMSK_EM9D if BOARD_EM_STARTERKIT_EMSK_EM9D
select SOC_EMSK_EM11D if BOARD_EM_STARTERKIT_EMSK_EM11D
help
The DesignWare ARC EM Starter Kit board is a board
that can host up to 3 different SOC FPGA bit files.

View File

@@ -0,0 +1,13 @@
board:
name: em_starterkit
vendor: Synopsys
socs:
- name: emsk_em7d
- name: emsk_em9d
- name: emsk_em11d
revision:
format: major.minor.patch
default: "2.3"
revisions:
- name: "2.2"
- name: "2.3"

View File

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 34 KiB

View File

@@ -26,18 +26,18 @@ See also this URL for details about the board:
The latest version of EM Starter Kit is 2.3, developer can upgrade from
2.0/2.1/2.2 to 2.3 using latest firmware.
The default configuration for EM Starter Kit boards can be found in
:zephyr_file:`boards/arc/em_starterkit/em_starterkit_defconfig`.
:zephyr_file:`boards/synopsys/em_starterkit/em_starterkit_defconfig`.
The default SoC for this board supported in Zephyr is the EM9D.
This configuration is a Harvard Architecture, with a separate
instruction bus and data bus. Instruction memory is called ICCM
and data memory is called DCCM. The configuration file for EM9D
is found in :zephyr_file:`soc/arc/snps_emsk/Kconfig.defconfig.em9d`.
is found in :zephyr_file:`soc/synopsys/snps_emsk/Kconfig.defconfig.em9d`.
If you have a larger program, you can select the EM7D or EM11D, which gives
access to 128KB DRAM with i-cache and d-cache. The configuration file for EM7D
is found in :zephyr_file:`soc/arc/snps_emsk/Kconfig.defconfig.em7d` and EM11D is
found in :zephyr_file:`soc/arc/snps_emsk/Kconfig.defconfig.em11d`.
is found in :zephyr_file:`soc/synopsys/snps_emsk/Kconfig.defconfig.em7d` and EM11D is
found in :zephyr_file:`soc/synopsys/snps_emsk/Kconfig.defconfig.em11d`.
Hardware
@@ -65,19 +65,6 @@ The EM Starter Kit has different versions, such as 1.0, 1.1, 2.0, 2.1,
2.2 and 2.3.
In Zephyr, only firmware versions 2.2 and 2.3 are supported.
* For EM Starter Kit 2.2, EM7D, EM9D and EM11D core configurations are supported.
* Use :kconfig:option:`CONFIG_BOARD_EM_STARTERKIT_R22` to select 2.2 version.
* Use :kconfig:option:`CONFIG_SOC_EMSK_EM7D`, :kconfig:option:`CONFIG_SOC_EMSK_EM9D` or
:kconfig:option:`CONFIG_SOC_EMSK_EM11D` to select EM7D or EM9D or EM11D.
* For EM Starter Kit 2.3, EM7D, EM9D and EM11D core configurations are
supported.
* Use :kconfig:option:`CONFIG_BOARD_EM_STARTERKIT_R23` to select 2.3 version.
* Use :kconfig:option:`CONFIG_SOC_EMSK_EM7D`, :kconfig:option:`CONFIG_SOC_EMSK_EM9D` or
:kconfig:option:`CONFIG_SOC_EMSK_EM11D` to select EM7D or EM9D or EM11D.
Supported Features
==================

View File

@@ -1,9 +1,5 @@
# SPDX-License-Identifier: Apache-2.0
CONFIG_SOC_EMSK=y
CONFIG_SOC_EMSK_EM9D=y
CONFIG_BOARD_EM_STARTERKIT=y
CONFIG_BOARD_EM_STARTERKIT_R23=y
CONFIG_SYS_CLOCK_TICKS_PER_SEC=100
CONFIG_XIP=n
CONFIG_BUILD_NO_GAP_FILL=y

View File

@@ -19,7 +19,6 @@
uart-0 = &uart0;
uart-1 = &uart1;
uart-2 = &uart2;
spi-flash0 = &w25q128bv;
};
chosen {

View File

@@ -1,4 +1,4 @@
identifier: em_starterkit_em11d
identifier: em_starterkit/emsk_em11d
name: EM Starterkit EM11D
type: mcu
arch: arc

View File

@@ -0,0 +1,5 @@
/*
* Copyright (c) 2018, Synopsys, Inc. All rights reserved.
*
* SPDX-License-Identifier: Apache-2.0
*/

View File

@@ -1,4 +1,4 @@
identifier: em_starterkit_em7d
identifier: em_starterkit/emsk_em7d
name: EM Starterkit EM7D
type: mcu
arch: arc

View File

@@ -1,5 +1,5 @@
identifier: em_starterkit_em7d_v22
name: EM Starterkit V22 EM7D
identifier: em_starterkit@2.2/emsk_em7d
name: EM Starterkit EM7D
type: mcu
arch: arc
toolchain:

View File

@@ -0,0 +1,5 @@
# SPDX-License-Identifier: Apache-2.0
CONFIG_ARC_HAS_SECURE=y
CONFIG_TRUSTED_EXECUTION_SECURE=y
CONFIG_INIT_ARCH_HW_AT_BOOT=y

View File

@@ -0,0 +1,3 @@
# SPDX-License-Identifier: Apache-2.0
CONFIG_ARC_MPU_ENABLE=y

View File

@@ -19,7 +19,6 @@
uart-0 = &uart0;
uart-1 = &uart1;
uart-2 = &uart2;
spi-flash0 = &w25q128bv;
};
chosen {

View File

@@ -1,4 +1,4 @@
identifier: em_starterkit
identifier: em_starterkit/emsk_em9d
name: EM Starterkit
type: mcu
arch: arc

View File

@@ -5,6 +5,10 @@
*/
/ {
aliases {
spi-flash0 = &w25q128bv;
};
soc {
i2c@f0004000 {
interrupts = <25 1>;

View File

@@ -14,8 +14,8 @@ config NUM_IRQ_PRIO_LEVELS
config NUM_IRQS
# must be > the highest interrupt number used
default 38 if BOARD_EM_STARTERKIT_R23
default 36 if BOARD_EM_STARTERKIT_R22
default 38 if "$(BOARD_REVISION)" = "2.3"
default 36 if "$(BOARD_REVISION)" = "2.2"
config RGF_NUM_BANKS
default 2

View File

@@ -14,26 +14,26 @@ config NUM_IRQ_PRIO_LEVELS
config NUM_IRQS
# must be > the highest interrupt number used
default 38 if BOARD_EM_STARTERKIT_R23
default 36 if BOARD_EM_STARTERKIT_R22
default 38 if "$(BOARD_REVISION)" = "2.3"
default 36 if "$(BOARD_REVISION)" = "2.2"
config ARC_MPU_VER
default 4 if BOARD_EM_STARTERKIT_R23
default 2 if BOARD_EM_STARTERKIT_R22
default 4 if "$(BOARD_REVISION)" = "2.3"
default 2 if "$(BOARD_REVISION)" = "2.2"
config RGF_NUM_BANKS
default 1
config SYS_CLOCK_HW_CYCLES_PER_SEC
default 25000000 if BOARD_EM_STARTERKIT_R23
default 30000000 if BOARD_EM_STARTERKIT_R22
default 25000000 if "$(BOARD_REVISION)" = "2.3"
default 30000000 if "$(BOARD_REVISION)" = "2.2"
config HARVARD
default y
config ARC_FIRQ
default n if BOARD_EM_STARTERKIT_R23
default y if BOARD_EM_STARTERKIT_R22
default n if "$(BOARD_REVISION)" = "2.3"
default y if "$(BOARD_REVISION)" = "2.2"
config CACHE_MANAGEMENT
default y

View File

@@ -14,8 +14,8 @@ config NUM_IRQ_PRIO_LEVELS
config NUM_IRQS
# must be > the highest interrupt number used
default 38 if BOARD_EM_STARTERKIT_R23
default 36 if BOARD_EM_STARTERKIT_R22
default 38 if "$(BOARD_REVISION)" = "2.3"
default 36 if "$(BOARD_REVISION)" = "2.2"
config RGF_NUM_BANKS
default 2