From 80ca3e064e21a7d29967c5987157d52c229aaa72 Mon Sep 17 00:00:00 2001 From: Watson Zeng Date: Mon, 5 Aug 2019 14:50:16 +0800 Subject: [PATCH] board: emsdp: doc update and bug fixes - update doc for different core configuration. - fix some bugs in dts related files. - add dts config and defconfig for different core configuration. - end files with a newline in boards/arc/emsdp/board.dtsi - remove unused head in boards/arc/emsdp/doc/index.rst - ARC_MPU_VER in different core is fixed. so remove some useless code for ARC_MPU_VER judgements in Kconfig.defconfig.* files for emsdp Signed-off-by: Watson Zeng --- boards/arc/emsdp/Kconfig.defconfig | 2 - boards/arc/emsdp/board.dtsi | 14 ++---- boards/arc/emsdp/doc/index.rst | 32 +++++++++++--- boards/arc/emsdp/emsdp.dts | 16 ++++++- boards/arc/emsdp/emsdp_defconfig | 1 + boards/arc/emsdp/emsdp_em4.dts | 44 +++++++++++++++++++ boards/arc/emsdp/emsdp_em4.yaml | 12 +++++ boards/arc/emsdp/emsdp_em4_defconfig | 19 ++++++++ boards/arc/emsdp/emsdp_em5d.dts | 44 +++++++++++++++++++ boards/arc/emsdp/emsdp_em5d.yaml | 12 +++++ boards/arc/emsdp/emsdp_em5d_defconfig | 19 ++++++++ boards/arc/emsdp/emsdp_em6.dts | 44 +++++++++++++++++++ boards/arc/emsdp/emsdp_em6.yaml | 12 +++++ boards/arc/emsdp/emsdp_em6_defconfig | 19 ++++++++ boards/arc/emsdp/emsdp_em7d.dts | 44 +++++++++++++++++++ boards/arc/emsdp/emsdp_em7d.yaml | 12 +++++ boards/arc/emsdp/emsdp_em7d_defconfig | 19 ++++++++ boards/arc/emsdp/emsdp_em7d_esp.dts | 44 +++++++++++++++++++ boards/arc/emsdp/emsdp_em7d_esp.yaml | 12 +++++ boards/arc/emsdp/emsdp_em7d_esp_defconfig | 19 ++++++++ boards/arc/emsdp/emsdp_em9d.dts | 44 +++++++++++++++++++ boards/arc/emsdp/emsdp_em9d.yaml | 12 +++++ boards/arc/emsdp/emsdp_em9d_defconfig | 19 ++++++++ dts/arc/emsdp.dtsi | 4 +- soc/arc/snps_emsdp/CMakeLists.txt | 3 -- soc/arc/snps_emsdp/Kconfig.defconfig | 3 -- soc/arc/snps_emsdp/Kconfig.defconfig.em11d | 7 ++- soc/arc/snps_emsdp/Kconfig.defconfig.em4 | 7 ++- soc/arc/snps_emsdp/Kconfig.defconfig.em5d | 7 ++- soc/arc/snps_emsdp/Kconfig.defconfig.em6 | 7 ++- soc/arc/snps_emsdp/Kconfig.defconfig.em7d | 7 ++- soc/arc/snps_emsdp/Kconfig.defconfig.em7d_esp | 20 ++------- soc/arc/snps_emsdp/Kconfig.defconfig.em9d | 7 ++- soc/arc/snps_emsdp/soc.c | 12 ----- soc/arc/snps_emsdp/soc.h | 9 +--- 35 files changed, 520 insertions(+), 88 deletions(-) create mode 100644 boards/arc/emsdp/emsdp_em4.dts create mode 100644 boards/arc/emsdp/emsdp_em4.yaml create mode 100644 boards/arc/emsdp/emsdp_em4_defconfig create mode 100644 boards/arc/emsdp/emsdp_em5d.dts create mode 100644 boards/arc/emsdp/emsdp_em5d.yaml create mode 100644 boards/arc/emsdp/emsdp_em5d_defconfig create mode 100644 boards/arc/emsdp/emsdp_em6.dts create mode 100644 boards/arc/emsdp/emsdp_em6.yaml create mode 100644 boards/arc/emsdp/emsdp_em6_defconfig create mode 100644 boards/arc/emsdp/emsdp_em7d.dts create mode 100644 boards/arc/emsdp/emsdp_em7d.yaml create mode 100644 boards/arc/emsdp/emsdp_em7d_defconfig create mode 100644 boards/arc/emsdp/emsdp_em7d_esp.dts create mode 100644 boards/arc/emsdp/emsdp_em7d_esp.yaml create mode 100644 boards/arc/emsdp/emsdp_em7d_esp_defconfig create mode 100644 boards/arc/emsdp/emsdp_em9d.dts create mode 100644 boards/arc/emsdp/emsdp_em9d.yaml create mode 100644 boards/arc/emsdp/emsdp_em9d_defconfig delete mode 100644 soc/arc/snps_emsdp/soc.c diff --git a/boards/arc/emsdp/Kconfig.defconfig b/boards/arc/emsdp/Kconfig.defconfig index afed25f0713..fa347d2bceb 100644 --- a/boards/arc/emsdp/Kconfig.defconfig +++ b/boards/arc/emsdp/Kconfig.defconfig @@ -10,8 +10,6 @@ if BOARD_EMSDP config BOARD default "emsdp" -config CPU_ARCEM - default y if GPIO diff --git a/boards/arc/emsdp/board.dtsi b/boards/arc/emsdp/board.dtsi index ad60ca91ebb..4275ba197ec 100644 --- a/boards/arc/emsdp/board.dtsi +++ b/boards/arc/emsdp/board.dtsi @@ -10,7 +10,6 @@ led5 = &led5; led6 = &led6; led7 = &led7; - led8 = &led8; sw0 = &switch0; sw1 = &switch1; sw2 = &switch2; @@ -41,21 +40,16 @@ }; led5: led_5 { gpios = <&gpio1 5 0>; - label = "LED 1"; + label = "LED 5"; }; led6: led_6 { gpios = <&gpio1 6 0>; - label = "LED 2"; + label = "LED 6"; }; led7: led_7 { gpios = <&gpio1 7 0>; - label = "LED 3"; + label = "LED 7"; }; - led8: led_8 { - gpios = <&gpio1 8 0>; - label = "LED 4"; - }; - }; buttons { @@ -82,4 +76,4 @@ }; }; -}; \ No newline at end of file +}; diff --git a/boards/arc/emsdp/doc/index.rst b/boards/arc/emsdp/doc/index.rst index ba21db65622..d63232bda06 100644 --- a/boards/arc/emsdp/doc/index.rst +++ b/boards/arc/emsdp/doc/index.rst @@ -24,6 +24,27 @@ For details about the board, see: `DesignWare ARC EM Software Development Platfo Hardware ******** +The EM Software Development Platform supports different core configurations, such as EM4, +EM5D, EM6, EM7D, EM9D, EM9D+ESP, EM11D, the default core configuration is EM11D. Use +:option:`CONFIG_SOC_EMSDP_EM4`, :option:`CONFIG_SOC_EMSDP_EM5D`, +:option:`CONFIG_SOC_EMSDP_EM6`, :option:`CONFIG_SOC_EMSDP_EM7D`, +:option:`CONFIG_SOC_EMSDP_EM7D_ESP`, :option:`CONFIG_SOC_EMSDP_EM9D` or +:option:`CONFIG_SOC_EMSDP_EM11D` to select different core configuration. + +The following table shows the hardware features supported for different core configuration: + ++-----------+-----+-----+------+------+----------+------+-------+ +| Features | EM4 | EM6 | EM5D | EM7D | EM7D_ESP | EM9D | EM11D | ++===========+=====+=====+======+======+==========+======+=======+ +| Caches | N | Y | N | Y | Y | N | Y | ++-----------+-----+-----+------+------+----------+------+-------+ +| DSP | N | N | Y | Y | Y | Y | Y | ++-----------+-----+-----+------+------+----------+------+-------+ +| XY Memory | N | N | N | N | N | Y | Y | ++-----------+-----+-----+------+------+----------+------+-------+ +| Secure | N | N | N | N | Y | N | N | ++-----------+-----+-----+------+------+----------+------+-------+ + For hardware feature details, refer to : `ARC EM Software Development Platform `__ @@ -177,12 +198,13 @@ Most of the time you will not be flashing your program but will instead debug it using openocd and gdb. The program can be download via the USB cable into the code and data memories. -Release Notes -************* - References ********** -.. _Digilent Pmod Modules: http://store.digilentinc.com/pmod-modules +.. target-notes:: -.. _Putty website: http://www.putty.org +.. _Digilent Pmod Modules: + http://store.digilentinc.com/pmod-modules + +.. _Putty website: + http://www.putty.org diff --git a/boards/arc/emsdp/emsdp.dts b/boards/arc/emsdp/emsdp.dts index de3c7310b53..2cec9c5eaa9 100644 --- a/boards/arc/emsdp/emsdp.dts +++ b/boards/arc/emsdp/emsdp.dts @@ -25,6 +25,20 @@ }; &uart0 { - status = "ok"; + status = "okay"; current-speed = <115200>; }; + +/ { + soc { + + uart@f0004000 { + interrupts = <107 1>; + }; + + gpio@f0002000 { + interrupts = <85 1>; + }; + + }; +}; diff --git a/boards/arc/emsdp/emsdp_defconfig b/boards/arc/emsdp/emsdp_defconfig index 064ff7f0a88..d2c745c0f69 100644 --- a/boards/arc/emsdp/emsdp_defconfig +++ b/boards/arc/emsdp/emsdp_defconfig @@ -1,6 +1,7 @@ # SPDX-License-Identifier: Apache-2.0 CONFIG_ARC=y +CONFIG_CPU_ARCEM=y CONFIG_SOC_ARC_EMSDP=y CONFIG_SOC_EMSDP_EM11D=y CONFIG_BOARD_EMSDP=y diff --git a/boards/arc/emsdp/emsdp_em4.dts b/boards/arc/emsdp/emsdp_em4.dts new file mode 100644 index 00000000000..f88e200d599 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em4.dts @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2019, Synopsys, Inc. All rights reserved. + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; + +#include +#include "board.dtsi" + +/ { + model = "emsdp"; + compatible = "snps,emsdp", "snps,emsdp"; + + aliases { + uart-0 = &uart0; + }; + + chosen { + zephyr,sram = &sram0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + }; +}; + +&uart0 { + status = "okay"; + current-speed = <115200>; +}; + +/ { + soc { + + uart@f0004000 { + interrupts = <108 1>; + }; + + gpio@f0002000 { + interrupts = <86 1>; + }; + + }; +}; diff --git a/boards/arc/emsdp/emsdp_em4.yaml b/boards/arc/emsdp/emsdp_em4.yaml new file mode 100644 index 00000000000..9e4fa0f7eea --- /dev/null +++ b/boards/arc/emsdp/emsdp_em4.yaml @@ -0,0 +1,12 @@ +identifier: emsdp_em4 +name: EM Software Development Platform +type: mcu +arch: arc +toolchain: + - zephyr + - xtools +ram: 128 +testing: + ignore_tags: + - net + - bluetooth diff --git a/boards/arc/emsdp/emsdp_em4_defconfig b/boards/arc/emsdp/emsdp_em4_defconfig new file mode 100644 index 00000000000..79dedad0250 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em4_defconfig @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: Apache-2.0 + +CONFIG_ARC=y +CONFIG_CPU_ARCEM=y +CONFIG_SOC_ARC_EMSDP=y +CONFIG_SOC_EMSDP_EM4=y +CONFIG_BOARD_EMSDP=y +CONFIG_SYS_CLOCK_TICKS_PER_SEC=100 +CONFIG_XIP=n +CONFIG_BUILD_OUTPUT_BIN=n +CONFIG_PRINTK=y +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_ARC_MPU_ENABLE=y +CONFIG_GPIO=y diff --git a/boards/arc/emsdp/emsdp_em5d.dts b/boards/arc/emsdp/emsdp_em5d.dts new file mode 100644 index 00000000000..2cec9c5eaa9 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em5d.dts @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2019, Synopsys, Inc. All rights reserved. + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; + +#include +#include "board.dtsi" + +/ { + model = "emsdp"; + compatible = "snps,emsdp", "snps,emsdp"; + + aliases { + uart-0 = &uart0; + }; + + chosen { + zephyr,sram = &sram0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + }; +}; + +&uart0 { + status = "okay"; + current-speed = <115200>; +}; + +/ { + soc { + + uart@f0004000 { + interrupts = <107 1>; + }; + + gpio@f0002000 { + interrupts = <85 1>; + }; + + }; +}; diff --git a/boards/arc/emsdp/emsdp_em5d.yaml b/boards/arc/emsdp/emsdp_em5d.yaml new file mode 100644 index 00000000000..129273aa435 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em5d.yaml @@ -0,0 +1,12 @@ +identifier: emsdp_em5d +name: EM Software Development Platform +type: mcu +arch: arc +toolchain: + - zephyr + - xtools +ram: 128 +testing: + ignore_tags: + - net + - bluetooth diff --git a/boards/arc/emsdp/emsdp_em5d_defconfig b/boards/arc/emsdp/emsdp_em5d_defconfig new file mode 100644 index 00000000000..3c380892291 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em5d_defconfig @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: Apache-2.0 + +CONFIG_ARC=y +CONFIG_CPU_ARCEM=y +CONFIG_SOC_ARC_EMSDP=y +CONFIG_SOC_EMSDP_EM5D=y +CONFIG_BOARD_EMSDP=y +CONFIG_SYS_CLOCK_TICKS_PER_SEC=100 +CONFIG_XIP=n +CONFIG_BUILD_OUTPUT_BIN=n +CONFIG_PRINTK=y +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_ARC_MPU_ENABLE=y +CONFIG_GPIO=y diff --git a/boards/arc/emsdp/emsdp_em6.dts b/boards/arc/emsdp/emsdp_em6.dts new file mode 100644 index 00000000000..f88e200d599 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em6.dts @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2019, Synopsys, Inc. All rights reserved. + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; + +#include +#include "board.dtsi" + +/ { + model = "emsdp"; + compatible = "snps,emsdp", "snps,emsdp"; + + aliases { + uart-0 = &uart0; + }; + + chosen { + zephyr,sram = &sram0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + }; +}; + +&uart0 { + status = "okay"; + current-speed = <115200>; +}; + +/ { + soc { + + uart@f0004000 { + interrupts = <108 1>; + }; + + gpio@f0002000 { + interrupts = <86 1>; + }; + + }; +}; diff --git a/boards/arc/emsdp/emsdp_em6.yaml b/boards/arc/emsdp/emsdp_em6.yaml new file mode 100644 index 00000000000..fb595122034 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em6.yaml @@ -0,0 +1,12 @@ +identifier: emsdp_em6 +name: EM Software Development Platform +type: mcu +arch: arc +toolchain: + - zephyr + - xtools +ram: 128 +testing: + ignore_tags: + - net + - bluetooth diff --git a/boards/arc/emsdp/emsdp_em6_defconfig b/boards/arc/emsdp/emsdp_em6_defconfig new file mode 100644 index 00000000000..db61f881c0f --- /dev/null +++ b/boards/arc/emsdp/emsdp_em6_defconfig @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: Apache-2.0 + +CONFIG_ARC=y +CONFIG_CPU_ARCEM=y +CONFIG_SOC_ARC_EMSDP=y +CONFIG_SOC_EMSDP_EM6=y +CONFIG_BOARD_EMSDP=y +CONFIG_SYS_CLOCK_TICKS_PER_SEC=100 +CONFIG_XIP=n +CONFIG_BUILD_OUTPUT_BIN=n +CONFIG_PRINTK=y +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_ARC_MPU_ENABLE=y +CONFIG_GPIO=y diff --git a/boards/arc/emsdp/emsdp_em7d.dts b/boards/arc/emsdp/emsdp_em7d.dts new file mode 100644 index 00000000000..2cec9c5eaa9 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em7d.dts @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2019, Synopsys, Inc. All rights reserved. + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; + +#include +#include "board.dtsi" + +/ { + model = "emsdp"; + compatible = "snps,emsdp", "snps,emsdp"; + + aliases { + uart-0 = &uart0; + }; + + chosen { + zephyr,sram = &sram0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + }; +}; + +&uart0 { + status = "okay"; + current-speed = <115200>; +}; + +/ { + soc { + + uart@f0004000 { + interrupts = <107 1>; + }; + + gpio@f0002000 { + interrupts = <85 1>; + }; + + }; +}; diff --git a/boards/arc/emsdp/emsdp_em7d.yaml b/boards/arc/emsdp/emsdp_em7d.yaml new file mode 100644 index 00000000000..877b6301562 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em7d.yaml @@ -0,0 +1,12 @@ +identifier: emsdp_em7d +name: EM Software Development Platform +type: mcu +arch: arc +toolchain: + - zephyr + - xtools +ram: 128 +testing: + ignore_tags: + - net + - bluetooth diff --git a/boards/arc/emsdp/emsdp_em7d_defconfig b/boards/arc/emsdp/emsdp_em7d_defconfig new file mode 100644 index 00000000000..6d6a86e8d05 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em7d_defconfig @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: Apache-2.0 + +CONFIG_ARC=y +CONFIG_CPU_ARCEM=y +CONFIG_SOC_ARC_EMSDP=y +CONFIG_SOC_EMSDP_EM7D=y +CONFIG_BOARD_EMSDP=y +CONFIG_SYS_CLOCK_TICKS_PER_SEC=100 +CONFIG_XIP=n +CONFIG_BUILD_OUTPUT_BIN=n +CONFIG_PRINTK=y +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_ARC_MPU_ENABLE=y +CONFIG_GPIO=y diff --git a/boards/arc/emsdp/emsdp_em7d_esp.dts b/boards/arc/emsdp/emsdp_em7d_esp.dts new file mode 100644 index 00000000000..f88e200d599 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em7d_esp.dts @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2019, Synopsys, Inc. All rights reserved. + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; + +#include +#include "board.dtsi" + +/ { + model = "emsdp"; + compatible = "snps,emsdp", "snps,emsdp"; + + aliases { + uart-0 = &uart0; + }; + + chosen { + zephyr,sram = &sram0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + }; +}; + +&uart0 { + status = "okay"; + current-speed = <115200>; +}; + +/ { + soc { + + uart@f0004000 { + interrupts = <108 1>; + }; + + gpio@f0002000 { + interrupts = <86 1>; + }; + + }; +}; diff --git a/boards/arc/emsdp/emsdp_em7d_esp.yaml b/boards/arc/emsdp/emsdp_em7d_esp.yaml new file mode 100644 index 00000000000..ddc48e00e5c --- /dev/null +++ b/boards/arc/emsdp/emsdp_em7d_esp.yaml @@ -0,0 +1,12 @@ +identifier: emsdp_em7d_esp +name: EM Software Development Platform +type: mcu +arch: arc +toolchain: + - zephyr + - xtools +ram: 128 +testing: + ignore_tags: + - net + - bluetooth diff --git a/boards/arc/emsdp/emsdp_em7d_esp_defconfig b/boards/arc/emsdp/emsdp_em7d_esp_defconfig new file mode 100644 index 00000000000..cced5569685 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em7d_esp_defconfig @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: Apache-2.0 + +CONFIG_ARC=y +CONFIG_CPU_ARCEM=y +CONFIG_SOC_ARC_EMSDP=y +CONFIG_SOC_EMSDP_EM7D_ESP=y +CONFIG_BOARD_EMSDP=y +CONFIG_SYS_CLOCK_TICKS_PER_SEC=100 +CONFIG_XIP=n +CONFIG_BUILD_OUTPUT_BIN=n +CONFIG_PRINTK=y +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_ARC_MPU_ENABLE=y +CONFIG_GPIO=y diff --git a/boards/arc/emsdp/emsdp_em9d.dts b/boards/arc/emsdp/emsdp_em9d.dts new file mode 100644 index 00000000000..2cec9c5eaa9 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em9d.dts @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2019, Synopsys, Inc. All rights reserved. + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; + +#include +#include "board.dtsi" + +/ { + model = "emsdp"; + compatible = "snps,emsdp", "snps,emsdp"; + + aliases { + uart-0 = &uart0; + }; + + chosen { + zephyr,sram = &sram0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + }; +}; + +&uart0 { + status = "okay"; + current-speed = <115200>; +}; + +/ { + soc { + + uart@f0004000 { + interrupts = <107 1>; + }; + + gpio@f0002000 { + interrupts = <85 1>; + }; + + }; +}; diff --git a/boards/arc/emsdp/emsdp_em9d.yaml b/boards/arc/emsdp/emsdp_em9d.yaml new file mode 100644 index 00000000000..7782c4e4a50 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em9d.yaml @@ -0,0 +1,12 @@ +identifier: emsdp_em9d +name: EM Software Development Platform +type: mcu +arch: arc +toolchain: + - zephyr + - xtools +ram: 128 +testing: + ignore_tags: + - net + - bluetooth diff --git a/boards/arc/emsdp/emsdp_em9d_defconfig b/boards/arc/emsdp/emsdp_em9d_defconfig new file mode 100644 index 00000000000..0b8494071c4 --- /dev/null +++ b/boards/arc/emsdp/emsdp_em9d_defconfig @@ -0,0 +1,19 @@ +# SPDX-License-Identifier: Apache-2.0 + +CONFIG_ARC=y +CONFIG_CPU_ARCEM=y +CONFIG_SOC_ARC_EMSDP=y +CONFIG_SOC_EMSDP_EM9D=y +CONFIG_BOARD_EMSDP=y +CONFIG_SYS_CLOCK_TICKS_PER_SEC=100 +CONFIG_XIP=n +CONFIG_BUILD_OUTPUT_BIN=n +CONFIG_PRINTK=y +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_ARC_MPU_ENABLE=y +CONFIG_GPIO=y diff --git a/dts/arc/emsdp.dtsi b/dts/arc/emsdp.dtsi index 95ef1328e85..872dd59ffed 100644 --- a/dts/arc/emsdp.dtsi +++ b/dts/arc/emsdp.dtsi @@ -19,7 +19,7 @@ cpu@0 { device_type = "cpu"; compatible = "snps,arcem"; - reg = <1>; + reg = <0>; }; intc: arcv2-intc { @@ -61,7 +61,6 @@ reg = <0xf0004000 0x1000>; label = "UART_0"; interrupt-parent = <&intc>; - interrupts = <107 1>; }; gpio0: gpio@f0002000 { @@ -70,7 +69,6 @@ bits = <4>; label = "GPIO_0"; interrupt-parent = <&intc>; - interrupts = <85 1>; gpio-controller; #gpio-cells = <2>; }; diff --git a/soc/arc/snps_emsdp/CMakeLists.txt b/soc/arc/snps_emsdp/CMakeLists.txt index 7d094ea4c76..5d12bf9fa9c 100644 --- a/soc/arc/snps_emsdp/CMakeLists.txt +++ b/soc/arc/snps_emsdp/CMakeLists.txt @@ -19,6 +19,3 @@ elseif(CONFIG_SOC_EMSDP_EM11D) zephyr_compile_options_ifdef(CONFIG_FLOAT -mfpu=fpuda_all) endif() -zephyr_sources( - soc.c - ) diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig b/soc/arc/snps_emsdp/Kconfig.defconfig index ff75e91d165..6180d55c8fd 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig +++ b/soc/arc/snps_emsdp/Kconfig.defconfig @@ -19,9 +19,6 @@ config NUM_IRQS # must be > the highest interrupt number used default 128 -config SYS_CLOCK_HW_CYCLES_PER_SEC - default 100000000 - source "soc/arc/snps_emsdp/Kconfig.defconfig.em4" source "soc/arc/snps_emsdp/Kconfig.defconfig.em5d" source "soc/arc/snps_emsdp/Kconfig.defconfig.em6" diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig.em11d b/soc/arc/snps_emsdp/Kconfig.defconfig.em11d index e83114b65df..aaa639e9b2e 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig.em11d +++ b/soc/arc/snps_emsdp/Kconfig.defconfig.em11d @@ -6,6 +6,9 @@ if SOC_EMSDP_EM11D +config SYS_CLOCK_HW_CYCLES_PER_SEC + default 40000000 + config CPU_EM4_FPUDA def_bool y @@ -27,8 +30,6 @@ config CACHE_FLUSHING config FP_FPU_DA def_bool y -if (ARC_MPU_VER = 2) - config MAIN_STACK_SIZE default 2048 @@ -42,6 +43,4 @@ config ZTEST_STACKSIZE endif # ZTEST -endif # ARC_MPU_VER - endif #SOC_EMSDP_EM11D diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig.em4 b/soc/arc/snps_emsdp/Kconfig.defconfig.em4 index 0fe7d0eb961..add3eb7817f 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig.em4 +++ b/soc/arc/snps_emsdp/Kconfig.defconfig.em4 @@ -6,6 +6,9 @@ if SOC_EMSDP_EM4 +config SYS_CLOCK_HW_CYCLES_PER_SEC + default 50000000 + config CPU_EM4 def_bool y @@ -27,8 +30,6 @@ config CACHE_FLUSHING config FP_FPU_DA def_bool n -if (ARC_MPU_VER = 2) - config MAIN_STACK_SIZE default 2048 @@ -42,6 +43,4 @@ config ZTEST_STACKSIZE endif # ZTEST -endif # ARC_MPU_VER - endif #SOC_EMSDP_EM4 diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig.em5d b/soc/arc/snps_emsdp/Kconfig.defconfig.em5d index 76d1ba97282..58473ab69f1 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig.em5d +++ b/soc/arc/snps_emsdp/Kconfig.defconfig.em5d @@ -6,6 +6,9 @@ if SOC_EMSDP_EM5D +config SYS_CLOCK_HW_CYCLES_PER_SEC + default 40000000 + config CPU_EM4_FPUDA def_bool y @@ -27,8 +30,6 @@ config CACHE_FLUSHING config FP_FPU_DA def_bool y -if (ARC_MPU_VER = 2) - config MAIN_STACK_SIZE default 2048 @@ -42,6 +43,4 @@ config ZTEST_STACKSIZE endif # ZTEST -endif # ARC_MPU_VER - endif #SOC_EMSDP_EM5D diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig.em6 b/soc/arc/snps_emsdp/Kconfig.defconfig.em6 index da554b19d46..4a6d58689a6 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig.em6 +++ b/soc/arc/snps_emsdp/Kconfig.defconfig.em6 @@ -6,6 +6,9 @@ if SOC_EMSDP_EM6 +config SYS_CLOCK_HW_CYCLES_PER_SEC + default 50000000 + config CPU_EM6 def_bool y @@ -27,8 +30,6 @@ config CACHE_FLUSHING config FP_FPU_DA def_bool n -if (ARC_MPU_VER = 2) - config MAIN_STACK_SIZE default 2048 @@ -42,6 +43,4 @@ config ZTEST_STACKSIZE endif # ZTEST -endif # ARC_MPU_VER - endif #SOC_EMSDP_EM6 diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig.em7d b/soc/arc/snps_emsdp/Kconfig.defconfig.em7d index e169e3e0ca7..984bce4b8ea 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig.em7d +++ b/soc/arc/snps_emsdp/Kconfig.defconfig.em7d @@ -6,6 +6,9 @@ if SOC_EMSDP_EM7D +config SYS_CLOCK_HW_CYCLES_PER_SEC + default 40000000 + config CPU_EM4_FPUDA def_bool y @@ -27,8 +30,6 @@ config CACHE_FLUSHING config FP_FPU_DA def_bool y -if (ARC_MPU_VER = 2) - config MAIN_STACK_SIZE default 2048 @@ -42,6 +43,4 @@ config ZTEST_STACKSIZE endif # ZTEST -endif # ARC_MPU_VER - endif #SOC_EMSDP_EM7D diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig.em7d_esp b/soc/arc/snps_emsdp/Kconfig.defconfig.em7d_esp index 1b91bee5aef..25b40647c95 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig.em7d_esp +++ b/soc/arc/snps_emsdp/Kconfig.defconfig.em7d_esp @@ -6,6 +6,9 @@ if SOC_EMSDP_EM7D_ESP +config SYS_CLOCK_HW_CYCLES_PER_SEC + default 50000000 + config CPU_EM4_FPUDA def_bool y @@ -27,21 +30,4 @@ config CACHE_FLUSHING config FP_FPU_DA def_bool y -if (ARC_MPU_VER = 2) - -config MAIN_STACK_SIZE - default 2048 - -config IDLE_STACK_SIZE - default 2048 - -if ZTEST - -config ZTEST_STACKSIZE - default 2048 - -endif # ZTEST - -endif # ARC_MPU_VER - endif #SOC_EMSDP_EM7D_ESP diff --git a/soc/arc/snps_emsdp/Kconfig.defconfig.em9d b/soc/arc/snps_emsdp/Kconfig.defconfig.em9d index e8d533d63db..035b626291b 100644 --- a/soc/arc/snps_emsdp/Kconfig.defconfig.em9d +++ b/soc/arc/snps_emsdp/Kconfig.defconfig.em9d @@ -6,6 +6,9 @@ if SOC_EMSDP_EM9D +config SYS_CLOCK_HW_CYCLES_PER_SEC + default 40000000 + config CPU_EM4_FPUDA def_bool y @@ -27,8 +30,6 @@ config CACHE_FLUSHING config FP_FPU_DA def_bool y -if (ARC_MPU_VER = 2) - config MAIN_STACK_SIZE default 2048 @@ -42,6 +43,4 @@ config ZTEST_STACKSIZE endif # ZTEST -endif # ARC_MPU_VER - endif #SOC_EMSDP_EM9D diff --git a/soc/arc/snps_emsdp/soc.c b/soc/arc/snps_emsdp/soc.c deleted file mode 100644 index a53360d7c70..00000000000 --- a/soc/arc/snps_emsdp/soc.c +++ /dev/null @@ -1,12 +0,0 @@ - -/* - * Copyright (c) 2019 Synopsys, Inc. All rights reserved. - * - * SPDX-License-Identifier: Apache-2.0 - */ - -/** - * This module provides routines to initialize and support soc-level hardware - * for the IoT Development Kit board. - * - */ diff --git a/soc/arc/snps_emsdp/soc.h b/soc/arc/snps_emsdp/soc.h index 6b414b942d5..704dce5b321 100644 --- a/soc/arc/snps_emsdp/soc.h +++ b/soc/arc/snps_emsdp/soc.h @@ -5,7 +5,7 @@ */ /** - * @brief Board configuration macros for EM Starter kit board + * @brief Board configuration macros for EM Software Development Platform board * * This header file is used to specify and describe board-level * aspects for the target. @@ -19,13 +19,6 @@ /* default system clock */ #define SYSCLK_DEFAULT_IOSC_HZ MHZ(100) -/* - * UART: use lr and sr to access subsystem uart IP - */ -// #define UART_NS16550_ACCESS_IOPORT -// #define UART_REG_ADDR_INTERVAL 4 - - /* ARC EM Core IRQs */ #define IRQ_TIMER0 16