diff options
author | Tom Rini <trini@konsulko.com> | 2018-10-05 10:16:31 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2018-10-05 10:16:31 -0400 |
commit | 46031b3aa08814f797a379356750aa5fb94cd3f7 (patch) | |
tree | 79bc71a15a74863f4f3362d3b09c92efad35a1bf /arch | |
parent | ad8c9f614620ec77d3c0f8963d61535038c39f09 (diff) | |
parent | 5396e8b1dd0ad9741b04f506ef88b5fb49d4c82a (diff) |
Merge tag 'arc-updates-for-2018.11-rc2' of git://git.denx.de/u-boot-arc
Here we do a couple of impovements for all ARC boards
as well as introduce yet another developemnt board.
1. Now for ARC boards we print CPU and board info
which is useful for users and helps with
analysis of logs "post-mortem".
2. Synopsys IoT development kit support is added
This one might bw a bit too late as we're past RC1
but:
1) This doesn't affect any other arches etc
as we change purely ARC code.
2) I've got a chance to talk about U-Boot on
IoT platforms during ELCE (my proposal was on
a wait list and only this week I've got
an update and invitation to talk) so it would
be good to have this board as a primer in upstream
code-base by the time of ELCE 2018.
3) For complete support of IoT devkit I'm yet to
significantly rework regmap subsystem in U-Boot
but that's a different topic and hopefully it will
be done sometime soon... though not this release
cycle for sure.
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arc/Kconfig | 5 | ||||
-rw-r--r-- | arch/arc/config.mk | 6 | ||||
-rw-r--r-- | arch/arc/dts/Makefile | 1 | ||||
-rw-r--r-- | arch/arc/dts/abilis_tb100.dts | 2 | ||||
-rw-r--r-- | arch/arc/dts/axs101.dts | 2 | ||||
-rw-r--r-- | arch/arc/dts/axs103.dts | 2 | ||||
-rw-r--r-- | arch/arc/dts/emdk.dts | 2 | ||||
-rw-r--r-- | arch/arc/dts/hsdk.dts | 2 | ||||
-rw-r--r-- | arch/arc/dts/iot_devkit.dts | 45 | ||||
-rw-r--r-- | arch/arc/dts/nsim.dts | 2 | ||||
-rw-r--r-- | arch/arc/lib/cpu.c | 35 |
11 files changed, 97 insertions, 7 deletions
diff --git a/arch/arc/Kconfig b/arch/arc/Kconfig index d59aa3ae29..b24593e137 100644 --- a/arch/arc/Kconfig +++ b/arch/arc/Kconfig @@ -157,6 +157,10 @@ config TARGET_EMDK config TARGET_HSDK bool "Support Synpsys HS DevelopmentKit board" +config TARGET_IOT_DEVKIT + bool "Synopsys Brite IoT Development kit" + select CPU_ARCEM6 + endchoice source "board/abilis/tb100/Kconfig" @@ -164,5 +168,6 @@ source "board/synopsys/Kconfig" source "board/synopsys/axs10x/Kconfig" source "board/synopsys/emdk/Kconfig" source "board/synopsys/hsdk/Kconfig" +source "board/synopsys/iot_devkit/Kconfig" endmenu diff --git a/arch/arc/config.mk b/arch/arc/config.mk index 169e5d7fae..d255c90e35 100644 --- a/arch/arc/config.mk +++ b/arch/arc/config.mk @@ -9,21 +9,15 @@ CONFIG_SYS_BIG_ENDIAN = 1 endif ifdef CONFIG_SYS_LITTLE_ENDIAN -ARC_CROSS_COMPILE := arc-linux- PLATFORM_LDFLAGS += -EL PLATFORM_CPPFLAGS += -mlittle-endian endif ifdef CONFIG_SYS_BIG_ENDIAN -ARC_CROSS_COMPILE := arceb-linux- PLATFORM_LDFLAGS += -EB PLATFORM_CPPFLAGS += -mbig-endian endif -ifeq ($(CROSS_COMPILE),) -CROSS_COMPILE := $(ARC_CROSS_COMPILE) -endif - ifdef CONFIG_ARC_MMU_VER CONFIG_MMU = 1 endif diff --git a/arch/arc/dts/Makefile b/arch/arc/dts/Makefile index 491a4f40bb..17e1405c0c 100644 --- a/arch/arc/dts/Makefile +++ b/arch/arc/dts/Makefile @@ -6,6 +6,7 @@ dtb-$(CONFIG_TARGET_NSIM) += nsim.dtb dtb-$(CONFIG_TARGET_TB100) += abilis_tb100.dtb dtb-$(CONFIG_TARGET_EMDK) += emdk.dtb dtb-$(CONFIG_TARGET_HSDK) += hsdk.dtb +dtb-$(CONFIG_TARGET_IOT_DEVKIT) += iot_devkit.dtb targets += $(dtb-y) diff --git a/arch/arc/dts/abilis_tb100.dts b/arch/arc/dts/abilis_tb100.dts index de3e57d246..19e45b9c66 100644 --- a/arch/arc/dts/abilis_tb100.dts +++ b/arch/arc/dts/abilis_tb100.dts @@ -7,6 +7,8 @@ #include "skeleton.dtsi" / { + model = "abilis,tb100"; + aliases { console = &uart0; }; diff --git a/arch/arc/dts/axs101.dts b/arch/arc/dts/axs101.dts index 13873be320..fc9fa93b74 100644 --- a/arch/arc/dts/axs101.dts +++ b/arch/arc/dts/axs101.dts @@ -9,6 +9,8 @@ / { + model = "snps,axs101"; + chosen { stdout-path = &uart0; }; diff --git a/arch/arc/dts/axs103.dts b/arch/arc/dts/axs103.dts index 81778c8983..6e2dd00fc3 100644 --- a/arch/arc/dts/axs103.dts +++ b/arch/arc/dts/axs103.dts @@ -9,6 +9,8 @@ / { + model = "snps,axs103"; + chosen { stdout-path = &uart0; }; diff --git a/arch/arc/dts/emdk.dts b/arch/arc/dts/emdk.dts index 5e853e3a72..ebe538d06f 100644 --- a/arch/arc/dts/emdk.dts +++ b/arch/arc/dts/emdk.dts @@ -7,6 +7,8 @@ #include "skeleton.dtsi" / { + model = "snps,emdk"; + #address-cells = <1>; #size-cells = <1>; diff --git a/arch/arc/dts/hsdk.dts b/arch/arc/dts/hsdk.dts index 673bc5b26a..f024b96925 100644 --- a/arch/arc/dts/hsdk.dts +++ b/arch/arc/dts/hsdk.dts @@ -8,6 +8,8 @@ #include "dt-bindings/clock/snps,hsdk-cgu.h" / { + model = "snps,hsdk"; + #address-cells = <1>; #size-cells = <1>; diff --git a/arch/arc/dts/iot_devkit.dts b/arch/arc/dts/iot_devkit.dts new file mode 100644 index 0000000000..ebf5a950f0 --- /dev/null +++ b/arch/arc/dts/iot_devkit.dts @@ -0,0 +1,45 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright (C) 2018 Synopsys, Inc. All rights reserved. + */ +/dts-v1/; + +#include "skeleton.dtsi" + +/ { + #address-cells = <1>; + #size-cells = <1>; + + aliases { + console = &uart0; + }; + + cpu_card { + core_clk: core_clk { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <144000000>; + u-boot,dm-pre-reloc; + }; + }; + + uart0: serial0@80014000 { + compatible = "snps,dw-apb-uart"; + clock-frequency = <16000000>; + reg = <0x80014000 0x1000>; + reg-shift = <2>; + reg-io-width = <4>; + }; + + usb: usb@f0040000 { + compatible = "snps,dwc2"; + reg = <0xf0040000 0x10000>; + phys = <&usbphy>; + phy-names = "usb2-phy"; + }; + + usbphy: phy { + compatible = "nop-phy"; + #phy-cells = <0>; + }; +}; diff --git a/arch/arc/dts/nsim.dts b/arch/arc/dts/nsim.dts index 9c1c7aa0eb..243ecb178e 100644 --- a/arch/arc/dts/nsim.dts +++ b/arch/arc/dts/nsim.dts @@ -7,6 +7,8 @@ #include "skeleton.dtsi" / { + model = "snps,nsim"; + aliases { console = &arcuart0; }; diff --git a/arch/arc/lib/cpu.c b/arch/arc/lib/cpu.c index cb95e06e93..50cd7cdb61 100644 --- a/arch/arc/lib/cpu.c +++ b/arch/arc/lib/cpu.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0+ /* - * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved. + * Copyright (C) 2013-2014, 2018 Synopsys, Inc. All rights reserved. */ #include <common.h> @@ -33,3 +33,36 @@ int dram_init(void) { return 0; } + +#ifdef CONFIG_DISPLAY_CPUINFO +const char *decode_identity(void) +{ + int arcver = read_aux_reg(ARC_AUX_IDENTITY) & 0xff; + + switch (arcver) { + /* ARCompact cores */ + case 0x32: return "ARC 700 v4.4-4.5"; + case 0x33: return "ARC 700 v4.6-v4.9"; + case 0x34: return "ARC 700 v4.10"; + case 0x35: return "ARC 700 v4.11"; + + /* ARCv2 cores */ + case 0x41: return "ARC EM v1.1a"; + case 0x42: return "ARC EM v3.0"; + case 0x43: return "ARC EM v4.0"; + case 0x50: return "ARC HS v1.0"; + case 0x51: return "ARC EM v2.0"; + case 0x52: return "ARC EM v2.1"; + case 0x53: return "ARC HS v3.0"; + case 0x54: return "ARC HS v4.0"; + + default: return "Unknown ARC core"; + } +} + +int print_cpuinfo(void) +{ + printf("CPU: %s\n", decode_identity()); + return 0; +} +#endif /* CONFIG_DISPLAY_CPUINFO */ |