ARC: NSIM: switch to ns16550 UART model

Switch nSIM from custom ARC UART to ns16550 model. That will
allow us to use zephyr images built for nSIM on other platforms
like HAPS, QEMU, etc...

This patch do:
 * switch nSIM board to ns16550 UART usage
 * change nSIM simulator configuration to use ns16550 UART model
 * drop checks for CONFIG_UART_NSIM in ARC code
 * update nSIM documentation

Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
This commit is contained in:
Eugeniy Paltsev 2020-07-13 18:41:12 +03:00 committed by Anas Nashif
parent ac305149bb
commit 3eee762e08
13 changed files with 19 additions and 20 deletions

View file

@ -190,7 +190,7 @@ config FAULT_DUMP
0: Off.
config XIP
default y if !UART_NSIM
default y if !SOC_NSIM
config GEN_ISR_TABLES
default y

View file

@ -9,4 +9,4 @@ config BOARD_NSIM
help
The DesignWare ARC nSIM board is a virtual board based on
the ARC nSIM simulator. It demonstrates the ARC core features
and a console based on the legacy ARC UART model.
and a console based on the ns16550 UART model.

View file

@ -5,7 +5,7 @@ if BOARD_NSIM
config BOARD
default "nsim"
config UART_NSIM
config UART_NS16550
default y
depends on SERIAL

View file

@ -11,7 +11,7 @@ ARC EM or ARC HS based board including the following features:
* ARC EM or ARC HS processor
* ARC internal timer
* a virtual output only console (uart-nsim)
* a virtual console (ns16550 based UART model)
There are four supported board sub-configurations:
@ -39,7 +39,7 @@ The following hardware features are supported:
+===========+============+=====+=======+=====+=======================+
| INT | on-chip | Y | Y | Y | interrupt_controller |
+-----------+------------+-----+-------+-----+-----------------------+
| UART | nsim uart | Y | Y | Y | serial port-polling |
| UART | ns16550 | Y | Y | Y | serial port |
+-----------+------------+-----+-------+-----+-----------------------+
| TIMER | on-chip | Y | Y | Y | system clock |
+-----------+------------+-----+-------+-----+-----------------------+

View file

@ -50,9 +50,13 @@
};
uart0: uart@f0000000 {
compatible = "snps,nsim-uart";
reg = <0xf0000000 0x100>;
compatible = "ns16550";
clock-frequency = <10000000>;
reg = <0xf0000000 0x400>;
current-speed = <115200>;
label = "UART_0";
interrupt-parent = <&intc>;
interrupts = <24 1>;
};
chosen {

View file

@ -59,5 +59,5 @@
-dmac_registers=0
-dmac_fifo_depth=2
-dmac_int_config=single_internal
-prop=nsim_mem-dev=uart0,base=0xf0000000,irq=24
-prop=nsim_mem-dev=uart0,kind=dwuart,base=0xf0000000,irq=24
-noprofile

View file

@ -39,5 +39,5 @@
-dccm_mem_cycles=2
-iccm0_size=0x40000
-iccm0_base=0x70000000
-prop=nsim_mem-dev=uart0,base=0xf0000000,irq=24
-noprofile
-prop=nsim_mem-dev=uart0,kind=dwuart,base=0xf0000000,irq=24
-noprofile

View file

@ -45,7 +45,7 @@
-connect_gfrc=1
-connect_icd=2
-connect_ici=2
-prop=nsim_mem-dev=uart0,base=0xf0000000,irq=0,use_connect=1
-prop=nsim_mem-dev=uart0,kind=dwuart,base=0xf0000000,irq=0,use_connect=1
-on=nsim_print-sys-arch
-noprofile
-nogoifmain

View file

@ -50,5 +50,5 @@
-dmac_registers=0
-dmac_fifo_depth=2
-dmac_int_config=single_internal
-prop=nsim_mem-dev=uart0,base=0xf0000000,irq=24
-prop=nsim_mem-dev=uart0,kind=dwuart,base=0xf0000000,irq=24
-noprofile

View file

@ -66,5 +66,5 @@
nsim_isa_dmac_registers=0
nsim_isa_dmac_fifo_depth=2
nsim_isa_dmac_int_config=single_internal
nsim_mem-dev=uart0,base=0xf0000000,irq=24
nsim_mem-dev=uart0,kind=dwuart,base=0xf0000000,irq=24
nsim_isa_unaligned_option=1

View file

@ -43,4 +43,4 @@
nsim_isa_dccm_mem_cycles=2
iccm0_size=0x40000
iccm0_base=0x70000000
nsim_mem-dev=uart0,base=0xf0000000,irq=24
nsim_mem-dev=uart0,kind=dwuart,base=0xf0000000,irq=24

View file

@ -55,4 +55,4 @@
nsim_isa_dmac_registers=0
nsim_isa_dmac_fifo_depth=2
nsim_isa_dmac_int_config=single_internal
nsim_mem-dev=uart0,base=0xf0000000,irq=24
nsim_mem-dev=uart0,kind=dwuart,base=0xf0000000,irq=24

View file

@ -9,11 +9,6 @@
*/
#include <linker/sections.h>
#if defined(CONFIG_UART_NSIM)
EXTERN(_VectorTable)
#endif
#include <linker/linker-defs.h>
#include <linker/linker-tool.h>