Skip to contentSkip to conversation

Add support for the ARC700 architecture

PATCH Superseded Alexey Brodkin 2 participants 13 messages Feb 4, 2014 – Feb 7, 2014

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

v4 cover Add support for the ARC700 architecture

This patch series adds support for the Synopsys DesignWare ARC700 architecture.

DesignWare ARC700 is family of 32-bit CPUs developed by Synopsys, Inc.

Since version 3.9 ARC architecture is supported in mainline Linux developemnt. And now to get better support in commonly used boot-loader we are introducing port of U-Boot for ARC700 CPUs.

Patches included in this series are also available on GitHub in the 'for-upstream-v4' branch:

git at github.com:foss-for-synopsys-dwc-arc-processors/u-boot.git

Also browsable here:

https://github.com/foss-for-synopsys-dwc-arc-processors/u-boot/tree/for-upstream-v4

NOTE: there's an acked by Tom Rini prerequisite for Arcangel4 board:

http://patchwork.ozlabs.org/patch/300901/

For those who are interested in building this port please download pre-built toolchains for x86_64 hosts.

For RedHat-based distros:
https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases/download/arc-4.8-R2/arc_gnu_4.8-R2_prebuilt_uclibc_le_rhel6_install.tar.gz

For Debian-based distros:
https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases/download/arc-4.8-R2/arc_gnu_4.8-R2_prebuilt_uclibc_le_ubuntu_install.tar.gz

Major changes for v4:

* Clean-up of board configurations.

Each patch that follows has detailed description of its changes.

Alexey Brodkin (9):
arc: add architecture header files
arc: add cpu files
arc: add library functions
arc: bdinfo, image and arc-specific init functions declarations
support
arc: add support for standalone programs
arc: add Arcangel4 board support
arc: add AXS101 board support
arc: add architecture to MAKEALL
arc: add README for architecture

 MAKEALL                                     |   6 +
 arch/arc/config.mk                          |  31 ++++
 arch/arc/cpu/arc700/Makefile                |  13 ++
 arch/arc/cpu/arc700/cache.c                 | 138 ++++++++++++++++
 arch/arc/cpu/arc700/config.mk               |   7 +
 arch/arc/cpu/arc700/cpu.c                   |  47 ++++++
 arch/arc/cpu/arc700/interrupts.c            | 142 ++++++++++++++++
 arch/arc/cpu/arc700/reset.c                 |  19 +++
 arch/arc/cpu/arc700/start.S                 | 241 ++++++++++++++++++++++++++++
 arch/arc/cpu/arc700/timer.c                 |  24 +++
 arch/arc/cpu/arc700/u-boot.lds              |  72 +++++++++
 arch/arc/include/asm/arch-arc700/hardware.h |  10 ++
 arch/arc/include/asm/arcregs.h              |  55 +++++++
 arch/arc/include/asm/bitops.h               |  19 +++
 arch/arc/include/asm/byteorder.h            |  23 +++
 arch/arc/include/asm/cache.h                |  23 +++
 arch/arc/include/asm/config.h               |  12 ++
 arch/arc/include/asm/errno.h                |   1 +
 arch/arc/include/asm/global_data.h          |  19 +++
 arch/arc/include/asm/io.h                   | 218 +++++++++++++++++++++++++
 arch/arc/include/asm/posix_types.h          |  39 +++++
 arch/arc/include/asm/ptrace.h               |  50 ++++++
 arch/arc/include/asm/sections.h             |  14 ++
 arch/arc/include/asm/string.h               |  27 ++++
 arch/arc/include/asm/types.h                |  55 +++++++
 arch/arc/include/asm/u-boot-arc.h           |  12 ++
 arch/arc/include/asm/u-boot.h               |  15 ++
 arch/arc/include/asm/unaligned.h            |   1 +
 arch/arc/lib/Makefile                       |  16 ++
 arch/arc/lib/bootm.c                        | 106 ++++++++++++
 arch/arc/lib/memcmp.S                       | 121 ++++++++++++++
 arch/arc/lib/memcpy-700.S                   |  63 ++++++++
 arch/arc/lib/memset.S                       |  62 +++++++
 arch/arc/lib/relocate.c                     |  72 +++++++++
 arch/arc/lib/sections.c                     |  21 +++
 arch/arc/lib/strchr-700.S                   | 141 ++++++++++++++++
 arch/arc/lib/strcmp.S                       |  97 +++++++++++
 arch/arc/lib/strcpy-700.S                   |  67 ++++++++
 arch/arc/lib/strlen.S                       |  80 +++++++++
 board/synopsys/arcangel4/Makefile           |  11 ++
 board/synopsys/axs101/Makefile              |   8 +
 board/synopsys/axs101/axs101.c              |  44 +++++
 board/synopsys/axs101/nand.c                | 226 ++++++++++++++++++++++++++
 boards.cfg                                  |   3 +
 common/cmd_bdinfo.c                         |  18 +++
 common/image.c                              |   1 +
 doc/README.ARC                              |  27 ++++
 examples/standalone/stubs.c                 |  13 ++
 include/common.h                            |   3 +
 include/configs/arcangel4-be.h              |  92 +++++++++++
 include/configs/arcangel4.h                 |  91 +++++++++++
 include/configs/axs101.h                    | 181 +++++++++++++++++++++
 include/image.h                             |   1 +
 53 files changed, 2898 insertions(+)
 create mode 100644 arch/arc/config.mk
 create mode 100644 arch/arc/cpu/arc700/Makefile
 create mode 100644 arch/arc/cpu/arc700/cache.c
 create mode 100644 arch/arc/cpu/arc700/config.mk
 create mode 100644 arch/arc/cpu/arc700/cpu.c
 create mode 100644 arch/arc/cpu/arc700/interrupts.c
 create mode 100644 arch/arc/cpu/arc700/reset.c
 create mode 100644 arch/arc/cpu/arc700/start.S
 create mode 100644 arch/arc/cpu/arc700/timer.c
 create mode 100644 arch/arc/cpu/arc700/u-boot.lds
 create mode 100644 arch/arc/include/asm/arch-arc700/hardware.h
 create mode 100644 arch/arc/include/asm/arcregs.h
 create mode 100644 arch/arc/include/asm/bitops.h
 create mode 100644 arch/arc/include/asm/byteorder.h
 create mode 100644 arch/arc/include/asm/cache.h
 create mode 100644 arch/arc/include/asm/config.h
 create mode 100644 arch/arc/include/asm/errno.h
 create mode 100644 arch/arc/include/asm/global_data.h
 create mode 100644 arch/arc/include/asm/io.h
 create mode 100644 arch/arc/include/asm/posix_types.h
 create mode 100644 arch/arc/include/asm/ptrace.h
 create mode 100644 arch/arc/include/asm/sections.h
 create mode 100644 arch/arc/include/asm/string.h
 create mode 100644 arch/arc/include/asm/types.h
 create mode 100644 arch/arc/include/asm/u-boot-arc.h
 create mode 100644 arch/arc/include/asm/u-boot.h
 create mode 100644 arch/arc/include/asm/unaligned.h
 create mode 100644 arch/arc/lib/Makefile
 create mode 100644 arch/arc/lib/bootm.c
 create mode 100644 arch/arc/lib/memcmp.S
 create mode 100644 arch/arc/lib/memcpy-700.S
 create mode 100644 arch/arc/lib/memset.S
 create mode 100644 arch/arc/lib/relocate.c
 create mode 100644 arch/arc/lib/sections.c
 create mode 100644 arch/arc/lib/strchr-700.S
 create mode 100644 arch/arc/lib/strcmp.S
 create mode 100644 arch/arc/lib/strcpy-700.S
 create mode 100644 arch/arc/lib/strlen.S
 create mode 100644 board/synopsys/arcangel4/Makefile
 create mode 100644 board/synopsys/axs101/Makefile
 create mode 100644 board/synopsys/axs101/axs101.c
 create mode 100644 board/synopsys/axs101/nand.c
 create mode 100644 doc/README.ARC
 create mode 100644 include/configs/arcangel4-be.h
 create mode 100644 include/configs/arcangel4.h
 create mode 100644 include/configs/axs101.h
Signature · 1 line
1.8.5.3
#1 lore raw

PATCH v4 1/9 arc: add architecture header files

These are header files used by ARC700 architecture.

Also note that "arch-arc700/hardware.h" is only required for compilation of "designware_i2c" driver which refers to "asm/arch/hardware.h". It would be good to fix mentioned driver sometime soon but it will cause changes in ARM board configs that use "designware_i2c".

Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
No changes for v4.

 arch/arc/include/asm/arch-arc700/hardware.h |  10 ++
 arch/arc/include/asm/arcregs.h              |  55 +++++++
 arch/arc/include/asm/bitops.h               |  19 +++
 arch/arc/include/asm/byteorder.h            |  23 +++
 arch/arc/include/asm/cache.h                |  23 +++
 arch/arc/include/asm/config.h               |  12 ++
 arch/arc/include/asm/errno.h                |   1 +
 arch/arc/include/asm/global_data.h          |  19 +++
 arch/arc/include/asm/io.h                   | 218 ++++++++++++++++++++++++++++
 arch/arc/include/asm/posix_types.h          |  39 +++++
 arch/arc/include/asm/ptrace.h               |  50 +++++++
 arch/arc/include/asm/sections.h             |  14 ++
 arch/arc/include/asm/string.h               |  27 ++++
 arch/arc/include/asm/types.h                |  55 +++++++
 arch/arc/include/asm/u-boot-arc.h           |  12 ++
 arch/arc/include/asm/u-boot.h               |  15 ++
 arch/arc/include/asm/unaligned.h            |   1 +
 17 files changed, 593 insertions(+)
 create mode 100644 arch/arc/include/asm/arch-arc700/hardware.h
 create mode 100644 arch/arc/include/asm/arcregs.h
 create mode 100644 arch/arc/include/asm/bitops.h
 create mode 100644 arch/arc/include/asm/byteorder.h
 create mode 100644 arch/arc/include/asm/cache.h
 create mode 100644 arch/arc/include/asm/config.h
 create mode 100644 arch/arc/include/asm/errno.h
 create mode 100644 arch/arc/include/asm/global_data.h
 create mode 100644 arch/arc/include/asm/io.h
 create mode 100644 arch/arc/include/asm/posix_types.h
 create mode 100644 arch/arc/include/asm/ptrace.h
 create mode 100644 arch/arc/include/asm/sections.h
 create mode 100644 arch/arc/include/asm/string.h
 create mode 100644 arch/arc/include/asm/types.h
 create mode 100644 arch/arc/include/asm/u-boot-arc.h
 create mode 100644 arch/arc/include/asm/u-boot.h
 create mode 100644 arch/arc/include/asm/unaligned.h
arch/arc/include/asm/arch-arc700/hardware.h new file +10 -0
new file mode 100644
index 0000000..8ec13a8
@@ -0,0 +1,10 @@
+/*
+ * Copyright (C) 2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+/*
+ * This file is only required to allow compilation of "designware_i2c" driver.
+ * Which explicitly includes <asm/arch/hardware.h>.
+ */
arch/arc/include/asm/arcregs.h new file +55 -0

55 lines not on this page · raw message

arch/arc/include/asm/bitops.h new file +19 -0
new file mode 100644
index 0000000..85721aa
@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_BITOPS_H
+#define __ASM_ARC_BITOPS_H
+
+/*
+ * hweightN: returns the hamming weight (i.e. the number
+ * of bits set) of a N-bit word
+ */
+
+#define hweight32(x) generic_hweight32(x)
+#define hweight16(x) generic_hweight16(x)
+#define hweight8(x) generic_hweight8(x)
+
+#endif /* __ASM_ARC_BITOPS_H */
arch/arc/include/asm/byteorder.h new file +23 -0
new file mode 100644
index 0000000..2fa9776
@@ -0,0 +1,23 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_BYTEORDER_H
+#define __ASM_ARC_BYTEORDER_H
+
+#include <asm/types.h>
+
+#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
+	#define __BYTEORDER_HAS_U64__
+	#define __SWAB_64_THRU_32__
+#endif
+
+#ifdef __LITTLE_ENDIAN__
+	#include <linux/byteorder/little_endian.h>
+#else
+	#include <linux/byteorder/big_endian.h>
+#endif	/* CONFIG_SYS_BIG_ENDIAN */
+
+#endif	/* ASM_ARC_BYTEORDER_H */
arch/arc/include/asm/cache.h new file +23 -0
new file mode 100644
index 0000000..16e7568
@@ -0,0 +1,23 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_CACHE_H
+#define __ASM_ARC_CACHE_H
+
+#include <config.h>
+
+/*
+ * The current upper bound for ARC L1 data cache line sizes is 128 bytes.
+ * We use that value for aligning DMA buffers unless the board config has
+ * specified an alternate cache line size.
+ */
+#ifdef CONFIG_SYS_CACHELINE_SIZE
+#define ARCH_DMA_MINALIGN	CONFIG_SYS_CACHELINE_SIZE
+#else
+#define ARCH_DMA_MINALIGN	128
+#endif
+
+#endif /* __ASM_ARC_CACHE_H */
arch/arc/include/asm/config.h new file +12 -0
new file mode 100644
index 0000000..5761def
@@ -0,0 +1,12 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_CONFIG_H_
+#define __ASM_ARC_CONFIG_H_
+
+#define CONFIG_LMB
+
+#endif /*__ASM_ARC_CONFIG_H_ */
arch/arc/include/asm/errno.h new file +1 -0
new file mode 100644
index 0000000..4c82b50
@@ -0,0 +1 @@
+#include <asm-generic/errno.h>
arch/arc/include/asm/global_data.h new file +19 -0
new file mode 100644
index 0000000..d644e80
@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef	__ASM_ARC_GLOBAL_DATA_H
+#define __ASM_ARC_GLOBAL_DATA_H
+
+/* Architecture-specific global data */
+struct arch_global_data {
+	int running_on_hw;
+};
+
+#include <asm-generic/global_data.h>
+
+#define DECLARE_GLOBAL_DATA_PTR		register volatile gd_t *gd asm ("r25")
+
+#endif /* __ASM_ARC_GLOBAL_DATA_H */
arch/arc/include/asm/io.h new file +218 -0

218 lines not on this page · raw message

arch/arc/include/asm/posix_types.h new file +39 -0
new file mode 100644
index 0000000..20415f0
@@ -0,0 +1,39 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_POSIX_TYPES_H
+#define __ASM_ARC_POSIX_TYPES_H
+
+typedef unsigned short		__kernel_dev_t;
+typedef unsigned long		__kernel_ino_t;
+typedef unsigned short		__kernel_mode_t;
+typedef unsigned short		__kernel_nlink_t;
+typedef long			__kernel_off_t;
+typedef int			__kernel_pid_t;
+typedef unsigned short		__kernel_ipc_pid_t;
+typedef unsigned short		__kernel_uid_t;
+typedef unsigned short		__kernel_gid_t;
+typedef unsigned int		__kernel_size_t;
+typedef int			__kernel_ssize_t;
+typedef int			__kernel_ptrdiff_t;
+typedef long			__kernel_time_t;
+typedef long			__kernel_suseconds_t;
+typedef long			__kernel_clock_t;
+typedef int			__kernel_daddr_t;
+typedef char			*__kernel_caddr_t;
+typedef unsigned short		__kernel_uid16_t;
+typedef unsigned short		__kernel_gid16_t;
+typedef unsigned int		__kernel_uid32_t;
+typedef unsigned int		__kernel_gid32_t;
+
+typedef unsigned short		__kernel_old_uid_t;
+typedef unsigned short		__kernel_old_gid_t;
+
+#ifdef __GNUC__
+typedef long long		__kernel_loff_t;
+#endif
+
+#endif	/* __ASM_ARC_POSIX_TYPES_H */
arch/arc/include/asm/ptrace.h new file +50 -0

50 lines not on this page · raw message

arch/arc/include/asm/sections.h new file +14 -0
new file mode 100644
index 0000000..18484a1
@@ -0,0 +1,14 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_SECTIONS_H
+#define __ASM_ARC_SECTIONS_H
+
+#include <asm-generic/sections.h>
+
+extern ulong __text_end;
+
+#endif /* __ASM_ARC_SECTIONS_H */
arch/arc/include/asm/string.h new file +27 -0
new file mode 100644
index 0000000..909129c
@@ -0,0 +1,27 @@
+/*
+ * Copyright (C) 2004, 2007-2010, 2011-2012 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_STRING_H
+#define __ASM_ARC_STRING_H
+
+#define __HAVE_ARCH_MEMSET
+#define __HAVE_ARCH_MEMCPY
+#define __HAVE_ARCH_MEMCMP
+#define __HAVE_ARCH_STRCHR
+#define __HAVE_ARCH_STRCPY
+#define __HAVE_ARCH_STRCMP
+#define __HAVE_ARCH_STRLEN
+
+extern void *memset(void *ptr, int, __kernel_size_t);
+extern void *memcpy(void *, const void *, __kernel_size_t);
+extern void memzero(void *ptr, __kernel_size_t n);
+extern int memcmp(const void *, const void *, __kernel_size_t);
+extern char *strchr(const char *s, int c);
+extern char *strcpy(char *dest, const char *src);
+extern int strcmp(const char *cs, const char *ct);
+extern __kernel_size_t strlen(const char *);
+
+#endif /* __ASM_ARC_STRING_H */
arch/arc/include/asm/types.h new file +55 -0

55 lines not on this page · raw message

arch/arc/include/asm/u-boot-arc.h new file +12 -0
new file mode 100644
index 0000000..0c0e8e6
@@ -0,0 +1,12 @@
+/*
+ * Copyright (C) 2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_U_BOOT_ARC_H__
+#define __ASM_ARC_U_BOOT_ARC_H__
+
+int arch_early_init_r(void);
+
+#endif	/* __ASM_ARC_U_BOOT_ARC_H__ */
arch/arc/include/asm/u-boot.h new file +15 -0
new file mode 100644
index 0000000..e354edf
@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __ASM_ARC_U_BOOT_H__
+#define __ASM_ARC_U_BOOT_H__
+
+#include <asm-generic/u-boot.h>
+
+/* For image.h:image_check_target_arch() */
+#define IH_ARCH_DEFAULT IH_ARCH_ARC
+
+#endif	/* __ASM_ARC_U_BOOT_H__ */
arch/arc/include/asm/unaligned.h new file +1 -0
new file mode 100644
index 0000000..6cecbbb
@@ -0,0 +1 @@
+#include <asm-generic/unaligned.h>
Signature · 1 line
1.8.5.3
#2 lore raw

PATCH v4 2/9 arc: add cpu files

In reply to Alexey Brodkin
Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
No changes for v4.

 arch/arc/config.mk               |  31 +++++
 arch/arc/cpu/arc700/Makefile     |  13 +++
 arch/arc/cpu/arc700/cache.c      | 138 ++++++++++++++++++++++
 arch/arc/cpu/arc700/config.mk    |   7 ++
 arch/arc/cpu/arc700/cpu.c        |  47 ++++++++
 arch/arc/cpu/arc700/interrupts.c | 142 +++++++++++++++++++++++
 arch/arc/cpu/arc700/reset.c      |  19 +++
 arch/arc/cpu/arc700/start.S      | 241 +++++++++++++++++++++++++++++++++++++++
 arch/arc/cpu/arc700/timer.c      |  24 ++++
 arch/arc/cpu/arc700/u-boot.lds   |  72 ++++++++++++
 10 files changed, 734 insertions(+)
 create mode 100644 arch/arc/config.mk
 create mode 100644 arch/arc/cpu/arc700/Makefile
 create mode 100644 arch/arc/cpu/arc700/cache.c
 create mode 100644 arch/arc/cpu/arc700/config.mk
 create mode 100644 arch/arc/cpu/arc700/cpu.c
 create mode 100644 arch/arc/cpu/arc700/interrupts.c
 create mode 100644 arch/arc/cpu/arc700/reset.c
 create mode 100644 arch/arc/cpu/arc700/start.S
 create mode 100644 arch/arc/cpu/arc700/timer.c
 create mode 100644 arch/arc/cpu/arc700/u-boot.lds
arch/arc/config.mk new file +31 -0
new file mode 100644
index 0000000..76f4f7c
@@ -0,0 +1,31 @@
+#
+# Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+ifndef CONFIG_SYS_BIG_ENDIAN
+CONFIG_SYS_LITTLE_ENDIAN = 1
+endif
+
+ifdef CONFIG_SYS_LITTLE_ENDIAN
+CROSS_COMPILE ?= arc-buildroot-linux-uclibc-
+endif
+
+ifdef CONFIG_SYS_BIG_ENDIAN
+CROSS_COMPILE ?= arceb-buildroot-linux-uclibc-
+PLATFORM_LDFLAGS += -EB
+endif
+
+PLATFORM_CPPFLAGS += -ffixed-r25 -D__ARC__ -DCONFIG_ARC -gdwarf-2
+
+LDSCRIPT := $(SRCTREE)/$(CPUDIR)/u-boot.lds
+
+# Needed for relocation
+LDFLAGS_FINAL += -pie
+
+# Load address for standalone apps
+CONFIG_STANDALONE_LOAD_ADDR ?= 0x82000000
+
+# Support generic board on ARC
+__HAVE_ARCH_GENERIC_BOARD := y
arch/arc/cpu/arc700/Makefile new file +13 -0
new file mode 100644
index 0000000..cdc5002
@@ -0,0 +1,13 @@
+#
+# Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+extra-y	+= start.o
+
+obj-y	+= cache.o
+obj-y	+= cpu.o
+obj-y	+= interrupts.o
+obj-y	+= reset.o
+obj-y	+= timer.o
arch/arc/cpu/arc700/cache.c new file +138 -0

138 lines not on this page · raw message

arch/arc/cpu/arc700/config.mk new file +7 -0
new file mode 100644
index 0000000..3206ff4
@@ -0,0 +1,7 @@
+#
+# Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+PLATFORM_CPPFLAGS += -mA7
arch/arc/cpu/arc700/cpu.c new file +47 -0

47 lines not on this page · raw message

arch/arc/cpu/arc700/interrupts.c new file +142 -0

142 lines not on this page · raw message

arch/arc/cpu/arc700/reset.c new file +19 -0
new file mode 100644
index 0000000..98ebf1d
@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#include <command.h>
+#include <common.h>
+
+int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])
+{
+	printf("Put your restart handler here\n");
+
+#ifdef DEBUG
+	/* Stop debug session here */
+	__asm__("brk");
+#endif
+	return 0;
+}
arch/arc/cpu/arc700/start.S new file +241 -0

241 lines not on this page · raw message

arch/arc/cpu/arc700/timer.c new file +24 -0
new file mode 100644
index 0000000..a0acbbc
@@ -0,0 +1,24 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#include <asm/arcregs.h>
+
+#define NH_MODE	(1 << 1)	/* Disable timer if CPU is halted */
+
+int timer_init(void)
+{
+	write_aux_reg(ARC_AUX_TIMER0_CTRL, NH_MODE);
+	/* Set max value for counter/timer */
+	write_aux_reg(ARC_AUX_TIMER0_LIMIT, 0xffffffff);
+	/* Set initial count value and restart counter/timer */
+	write_aux_reg(ARC_AUX_TIMER0_CNT, 0);
+	return 0;
+}
+
+unsigned long timer_read_counter(void)
+{
+	return read_aux_reg(ARC_AUX_TIMER0_CNT);
+}
arch/arc/cpu/arc700/u-boot.lds new file +72 -0

72 lines not on this page · raw message

Signature · 1 line
1.8.5.3
#3 lore raw

PATCH v4 3/9 arc: add library functions

In reply to Alexey Brodkin

These are library functions used by ARC700 architecture.

Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
No changes for v4.

 arch/arc/lib/Makefile     |  16 ++++++
 arch/arc/lib/bootm.c      | 106 ++++++++++++++++++++++++++++++++++
 arch/arc/lib/memcmp.S     | 121 +++++++++++++++++++++++++++++++++++++++
 arch/arc/lib/memcpy-700.S |  63 +++++++++++++++++++++
 arch/arc/lib/memset.S     |  62 ++++++++++++++++++++
 arch/arc/lib/relocate.c   |  72 +++++++++++++++++++++++
 arch/arc/lib/sections.c   |  21 +++++++
 arch/arc/lib/strchr-700.S | 141 ++++++++++++++++++++++++++++++++++++++++++++++
 arch/arc/lib/strcmp.S     |  97 +++++++++++++++++++++++++++++++
 arch/arc/lib/strcpy-700.S |  67 ++++++++++++++++++++++
 arch/arc/lib/strlen.S     |  80 ++++++++++++++++++++++++++
 11 files changed, 846 insertions(+)
 create mode 100644 arch/arc/lib/Makefile
 create mode 100644 arch/arc/lib/bootm.c
 create mode 100644 arch/arc/lib/memcmp.S
 create mode 100644 arch/arc/lib/memcpy-700.S
 create mode 100644 arch/arc/lib/memset.S
 create mode 100644 arch/arc/lib/relocate.c
 create mode 100644 arch/arc/lib/sections.c
 create mode 100644 arch/arc/lib/strchr-700.S
 create mode 100644 arch/arc/lib/strcmp.S
 create mode 100644 arch/arc/lib/strcpy-700.S
 create mode 100644 arch/arc/lib/strlen.S
arch/arc/lib/Makefile new file +16 -0
new file mode 100644
index 0000000..7675f85
@@ -0,0 +1,16 @@
+#
+# Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+obj-y += sections.o
+obj-y += relocate.o
+obj-y += strchr-700.o
+obj-y += strcmp.o
+obj-y += strcpy-700.o
+obj-y += strlen.o
+obj-y += memcmp.o
+obj-y += memcpy-700.o
+obj-y += memset.o
+obj-$(CONFIG_CMD_BOOTM) += bootm.o
arch/arc/lib/bootm.c new file +106 -0

106 lines not on this page · raw message

arch/arc/lib/memcmp.S new file +121 -0

121 lines not on this page · raw message

arch/arc/lib/memcpy-700.S new file +63 -0

63 lines not on this page · raw message

arch/arc/lib/memset.S new file +62 -0

62 lines not on this page · raw message

arch/arc/lib/relocate.c new file +72 -0

72 lines not on this page · raw message

arch/arc/lib/sections.c new file +21 -0
new file mode 100644
index 0000000..b0b46a4
@@ -0,0 +1,21 @@
+/*
+ * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+/*
+ * For some reason linker sets linker-generated symbols to zero in PIE mode.
+ * A work-around is substitution of linker-generated symbols with
+ * compiler-generated symbols which are properly handled by linker in PAE mode.
+ */
+
+char __bss_start[0] __attribute__((section(".__bss_start")));
+char __bss_end[0] __attribute__((section(".__bss_end")));
+char __image_copy_start[0] __attribute__((section(".__image_copy_start")));
+char __image_copy_end[0] __attribute__((section(".__image_copy_end")));
+char __rel_dyn_start[0] __attribute__((section(".__rel_dyn_start")));
+char __rel_dyn_end[0] __attribute__((section(".__rel_dyn_end")));
+char __text_start[0] __attribute__((section(".__text_start")));
+char __text_end[0] __attribute__((section(".__text_end")));
+char __init_end[0] __attribute__((section(".__init_end")));
arch/arc/lib/strchr-700.S new file +141 -0

141 lines not on this page · raw message

arch/arc/lib/strcmp.S new file +97 -0

97 lines not on this page · raw message

arch/arc/lib/strcpy-700.S new file +67 -0

67 lines not on this page · raw message

arch/arc/lib/strlen.S new file +80 -0

80 lines not on this page · raw message

Signature · 1 line
1.8.5.3
#4 lore raw

PATCH v4 4/9 arc: bdinfo, image and arc-specific init functions declarations support

In reply to Alexey Brodkin
Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
No changes for v4.

 common/cmd_bdinfo.c | 18 ++++++++++++++++++
 common/image.c      |  1 +
 include/common.h    |  3 +++
 include/image.h     |  1 +
 4 files changed, 23 insertions(+)
common/cmd_bdinfo.c +18 -0
index 713de14..15119a7 100644
@@ -517,6 +517,24 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 	return 0;
 }
 
+#elif defined(CONFIG_ARC700)
+
+int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
+{
+	bd_t *bd = gd->bd;
+
+	print_num("mem start",		bd->bi_memstart);
+	print_lnum("mem size",		bd->bi_memsize);
+
+#if defined(CONFIG_CMD_NET)
+	print_eth(0);
+	printf("ip_addr     = %s\n", getenv("ipaddr"));
+#endif
+	printf("baudrate    = %d bps\n", bd->bi_baudrate);
+
+	return 0;
+}
+
 #else
  #error "a case for this architecture does not exist!"
 #endif
common/image.c +1 -0
index ae95c3f..9c6bec5 100644
@@ -82,6 +82,7 @@ static const table_entry_t uimage_arch[] = {
 	{	IH_ARCH_OPENRISC,	"or1k",		"OpenRISC 1000",},
 	{	IH_ARCH_SANDBOX,	"sandbox",	"Sandbox",	},
 	{	IH_ARCH_ARM64,		"arm64",	"AArch64",	},
+	{	IH_ARCH_ARC,		"arc",		"ARC",		},
 	{	-1,			"",		"",		},
 };
 
include/common.h +3 -0
index d5ebb25..221b776 100644
@@ -408,6 +408,9 @@ static inline int setenv_addr(const char *varname, const void *addr)
 #ifdef CONFIG_MIPS
 # include <asm/u-boot-mips.h>
 #endif /* CONFIG_MIPS */
+#ifdef CONFIG_ARC
+# include <asm/u-boot-arc.h>
+#endif /* CONFIG_ARC */
 
 #ifdef CONFIG_AUTO_COMPLETE
 int env_complete(char *var, int maxv, char *cmdv[], int maxsz, char *buf);
include/image.h +1 -0
index 7de2bb2..3ba8c2e 100644
@@ -157,6 +157,7 @@ struct lmb;
 #define IH_ARCH_NDS32	        20	/* ANDES Technology - NDS32  */
 #define IH_ARCH_OPENRISC        21	/* OpenRISC 1000  */
 #define IH_ARCH_ARM64		22	/* ARM64	*/
+#define IH_ARCH_ARC		23	/* Synopsys DesignWare ARC */
 
 /*
  * Image Types
Signature · 1 line
1.8.5.3
#5 lore raw

PATCH v4 5/9 arc: add support for standalone programs

In reply to Alexey Brodkin
Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
Changes for v4:

* Clean-up of EXPORT_FUNC for ARC.

 examples/standalone/stubs.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)
examples/standalone/stubs.c +13 -0
index 32a19ce..c5c025d 100644
@@ -210,6 +210,19 @@ gd_t *global_data;
 "	l.jr	r13\n"		\
 "	l.nop\n"				\
 	: : "i"(offsetof(gd_t, jt)), "i"(XF_ ## x * sizeof(void *)) : "r13");
+#elif defined(CONFIG_ARC)
+/*
+ * r25 holds the pointer to the global_data. r10 is call clobbered.
+  */
+#define EXPORT_FUNC(x) \
+	asm volatile( \
+"	.align 4\n" \
+"	.globl " #x "\n" \
+#x ":\n" \
+"	ld	r10, [r25, %0]\n" \
+"	ld	r10, [r10, %1]\n" \
+"	j	[r10]\n" \
+	: : "i"(offsetof(gd_t, jt)), "i"(XF_ ## x * sizeof(void *)) : "r10");
 #else
 /*"	addi	$sp, $sp, -24\n"	\
 "	br	$r16\n"			\*/
Signature · 1 line
1.8.5.3
#6 lore raw

PATCH v4 6/9 arc: add Arcangel4 board support

In reply to Alexey Brodkin

Arcangel4 is a FPGA-based development board that is used for prototyping and verificationof of both ARC hardware (CPUs) and software running upon CPU.

This board avaialble in 2 flavours:
* Little-endian (arcangel4)
* Big-endian (arcangel4-be)

Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
Changes for v4:
* Removed common CONFIG_SYS_BAUDRATE_TABLE
* Removed MEMTEST-related definitions as suggested by Wolfgang

Note there's a prerequisite - http://patchwork.ozlabs.org/patch/300901/

 board/synopsys/arcangel4/Makefile | 11 +++++
 boards.cfg                        |  2 +
 include/configs/arcangel4-be.h    | 92 +++++++++++++++++++++++++++++++++++++++
 include/configs/arcangel4.h       | 91 ++++++++++++++++++++++++++++++++++++++
 4 files changed, 196 insertions(+)
 create mode 100644 board/synopsys/arcangel4/Makefile
 create mode 100644 include/configs/arcangel4-be.h
 create mode 100644 include/configs/arcangel4.h
board/synopsys/arcangel4/Makefile new file +11 -0
new file mode 100644
index 0000000..575e58f
@@ -0,0 +1,11 @@
+#
+# Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+# This board is mostly used for debugging U-Boot in simulation (ISS).
+# The only peripheral which is used on this board is a serial port which
+# requires no initialization except those in "include/configs/arcangel4.h".
+# And now there's no specific initializations for this board.
+# So this Makefile is only required for satisfaction of U-Boot build system.
boards.cfg +2 -0
index 2dfd2b4..a873aaa 100644
@@ -1229,6 +1229,8 @@ Active  sparc       leon3          -           gaisler         -
 Active  sparc       leon3          -           gaisler         -                   gr_xc3s_1500                         -                                                                                                                                 -
 Active  sparc       leon3          -           gaisler         -                   grsim                                -                                                                                                                                 -
 Active  x86         x86            coreboot    chromebook-x86  coreboot            coreboot-x86                         coreboot:SYS_TEXT_BASE=0x01110000                                                                                                 -
+Active  arc         arc700         -           synopsys        -                   arcangel4                            -                                                                                                                                 Alexey Brodkin <[email protected]>
+Active  arc         arc700         -           synopsys        arcangel4           arcangel4-be                            -                                                                                                                              Alexey Brodkin <[email protected]>
 Orphan  arm         arm1136        mx31        -               imx31_phycore       imx31_phycore_eet                    imx31_phycore:IMX31_PHYCORE_EET                                                                                                   (resigned) Guennadi Liakhovetski <[email protected]>
 Orphan  arm         arm1136        mx31        freescale       -                   mx31ads                              -                                                                                                                                 (resigned) Guennadi Liakhovetski <[email protected]>
 Orphan  arm         pxa            -           -               -                   lubbock                              -                                                                                                                                 (dead address) Kyle Harris <[email protected]>
include/configs/arcangel4-be.h new file +92 -0

92 lines not on this page · raw message

include/configs/arcangel4.h new file +91 -0

91 lines not on this page · raw message

Signature · 1 line
1.8.5.3
#7 lore raw

PATCH v4 7/9 arc: add AXS101 board support

In reply to Alexey Brodkin

AXS101 is a new generation of devlopment boards from Synopsys that houses ASIC with ARC700 and lots of DesignWare peripherals:

* DW APB UART
* DW Mobile Storage (MMC/SD)
* DW I2C
* DW GMAC

Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
Changes for v4:
* Removed common CONFIG_SYS_BAUDRATE_TABLE
* Removed MEMTEST-related definitions as suggested by Wolfgang
* Removed values assigned to logical definitions

 board/synopsys/axs101/Makefile |   8 ++
 board/synopsys/axs101/axs101.c |  44 ++++++++
 board/synopsys/axs101/nand.c   | 226 +++++++++++++++++++++++++++++++++++++++++
 boards.cfg                     |   1 +
 include/configs/axs101.h       | 181 +++++++++++++++++++++++++++++++++
 5 files changed, 460 insertions(+)
 create mode 100644 board/synopsys/axs101/Makefile
 create mode 100644 board/synopsys/axs101/axs101.c
 create mode 100644 board/synopsys/axs101/nand.c
 create mode 100644 include/configs/axs101.h
board/synopsys/axs101/Makefile new file +8 -0
new file mode 100644
index 0000000..f0965f7
@@ -0,0 +1,8 @@
+#
+# Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+obj-y	+= axs101.o
+obj-$(CONFIG_CMD_NAND) += nand.o
board/synopsys/axs101/axs101.c new file +44 -0

44 lines not on this page · raw message

board/synopsys/axs101/nand.c new file +226 -0

226 lines not on this page · raw message

boards.cfg +1 -0
index a873aaa..6fbc6b0 100644
@@ -1229,6 +1229,7 @@ Active  sparc       leon3          -           gaisler         -
 Active  sparc       leon3          -           gaisler         -                   gr_xc3s_1500                         -                                                                                                                                 -
 Active  sparc       leon3          -           gaisler         -                   grsim                                -                                                                                                                                 -
 Active  x86         x86            coreboot    chromebook-x86  coreboot            coreboot-x86                         coreboot:SYS_TEXT_BASE=0x01110000                                                                                                 -
+Active  arc         arc700         -           synopsys        -                   axs101                               -                                                                                                                                 Alexey Brodkin <[email protected]>
 Active  arc         arc700         -           synopsys        -                   arcangel4                            -                                                                                                                                 Alexey Brodkin <[email protected]>
 Active  arc         arc700         -           synopsys        arcangel4           arcangel4-be                            -                                                                                                                              Alexey Brodkin <[email protected]>
 Orphan  arm         arm1136        mx31        -               imx31_phycore       imx31_phycore_eet                    imx31_phycore:IMX31_PHYCORE_EET                                                                                                   (resigned) Guennadi Liakhovetski <[email protected]>
include/configs/axs101.h new file +181 -0

181 lines not on this page · raw message

Signature · 1 line
1.8.5.3
#8 lore raw

PATCH v4 8/9 arc: add architecture to MAKEALL

In reply to Alexey Brodkin
Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
No changes for v4.

 MAKEALL | 6 ++++++
 1 file changed, 6 insertions(+)
MAKEALL +6 -0
index 562071a..54b0d89 100755
@@ -529,6 +529,12 @@ LIST_sparc="$(targets_by_arch sparc)"
 
 LIST_nds32="$(targets_by_arch nds32)"
 
+#########################################################################
+## ARC Systems
+#########################################################################
+
+LIST_arc="$(targets_by_arch arc)"
+
 #-----------------------------------------------------------------------
 
 get_target_location() {
Signature · 1 line
1.8.5.3
#9 lore raw

PATCH v4 9/9 arc: add README for architecture

In reply to Alexey Brodkin
Cc Vineet Gupta <[email protected]>
Cc Francois Bedard <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Heiko Schocher <[email protected]>

---
No changes for v4.

 doc/README.ARC | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)
 create mode 100644 doc/README.ARC
doc/README.ARC new file +27 -0
new file mode 100644
index 0000000..5f414fb
@@ -0,0 +1,27 @@
+Synopsys' DesignWare(r) ARC(r) Processors are a family of 32-bit CPUs
+that SoC designers can optimize for a wide range of uses, from deeply embedded
+to high-performance host applications.
+
+More information on ARC cores avaialble here:
+http://www.synopsys.com/IP/ProcessorIP/ARCProcessors/Pages/default.aspx
+
+Designers can differentiate their products by using patented configuration
+technology to tailor each ARC processor instance to meet specific performance,
+power and area requirements.
+
+The DesignWare ARC processors are also extendable, allowing designers to add
+their own custom instructions that dramatically increase performance.
+
+Synopsys' ARC processors have been used by over 170 customers worldwide who
+collectively ship more than 1 billion ARC-based chips annually.
+
+All DesignWare ARC processors utilize a 16-/32-bit ISA that provides excellent
+performance and code density for embedded and host SoC applications.
+
+The RISC microprocessors are synthesizable and can be implemented in any foundry
+or process, and are supported by a complete suite of development tools.
+
+The ARC GNU toolchain with support for all ARC Processors can be downloaded
+from here (available pre-built toolchains as well):
+
+https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases
Signature · 1 line
1.8.5.3
#10 lore raw

v4 cover Add support for the ARC700 architecture

In reply to Alexey Brodkin
Quoted 1 line · Alexey Brodkin

This patch series adds support for the Synopsys DesignWare ARC700 architecture.

Any chance to get this series (its 4th re-spin)
reviewed/commented/accepted?

Regards,
Alexey

#11 lore raw

v4 cover Add support for the ARC700 architecture

In reply to Alexey Brodkin
Quoted 36 lines · Alexey Brodkin

This patch series adds support for the Synopsys DesignWare ARC700 architecture.

DesignWare ARC700 is family of 32-bit CPUs developed by Synopsys, Inc.

Since version 3.9 ARC architecture is supported in mainline Linux developemnt. And now to get better support in commonly used boot-loader we are introducing port of U-Boot for ARC700 CPUs.

Patches included in this series are also available on GitHub in the 'for-upstream-v4' branch:

git at github.com:foss-for-synopsys-dwc-arc-processors/u-boot.git

Also browsable here:

https://github.com/foss-for-synopsys-dwc-arc-processors/u-boot/tree/for-upstream-v4

NOTE: there's an acked by Tom Rini prerequisite for Arcangel4 board:

http://patchwork.ozlabs.org/patch/300901/

For those who are interested in building this port please download pre-built toolchains for x86_64 hosts.

For RedHat-based distros:
https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases/download/arc-4.8-R2/arc_gnu_4.8-R2_prebuilt_uclibc_le_rhel6_install.tar.gz

For Debian-based distros:
https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases/download/arc-4.8-R2/arc_gnu_4.8-R2_prebuilt_uclibc_le_ubuntu_install.tar.gz

Major changes for v4:

* Clean-up of board configurations.

Each patch that follows has detailed description of its changes.

Quoted 11 lines

Alexey Brodkin (9):
arc: add architecture header files
arc: add cpu files
arc: add library functions
arc: bdinfo, image and arc-specific init functions declarations
support
arc: add support for standalone programs
arc: add Arcangel4 board support
arc: add AXS101 board support
arc: add architecture to MAKEALL
arc: add README for architecture

I've applied the series to u-boot/master. But please note that with the
toolchain links above, MAKEALL doesn't agree that axs101 builds without
error (but doing it with 'make' does) and arcangel4 doesn't build due
to:
arc-linux-ld.bfd: Error: Overflow detected in relocation value;
arc-linux-ld.bfd: Relocation value should be between 16777215 and -16777216 whereas it 2130661664 arc-linux-ld.bfd: Global symbol: "default_serial_console".
arc-linux-ld.bfd:
Relocation type is:R_ARC_S25W_PCREL
FileName:drivers/serial/built-in.o
Section Name:.text
Offset in Section:10
arc-linux-ld.bfd: final link failed: Bad value
make: *** [/home/trini/work/u-boot/u-boot/temp/u-boot] Error 1

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140207/6afed48a/attachment.pgp>
#12 lore raw

v4 cover Add support for the ARC700 architecture

Dear Tom.

Quoted 17 lines · Tom Rini

On Tue, Feb 04, 2014 at 12:56:12PM +0400, Alexey Brodkin wrote:

I've applied the series to u-boot/master. But please note that with the
toolchain links above, MAKEALL doesn't agree that axs101 builds without
error (but doing it with 'make' does) and arcangel4 doesn't build due
to:
arc-linux-ld.bfd: Error: Overflow detected in relocation value;
arc-linux-ld.bfd: Relocation value should be between 16777215 and -16777216 whereas it 2130661664 arc-linux-ld.bfd: Global symbol: "default_serial_console".
arc-linux-ld.bfd:
Relocation type is:R_ARC_S25W_PCREL
FileName:drivers/serial/built-in.o
Section Name:.text
Offset in Section:10
arc-linux-ld.bfd: final link failed: Bad value
make: *** [/home/trini/work/u-boot/u-boot/temp/u-boot] Error 1

You see this error message because expected serial driver was not built. And it was not built because it is still missing in u-boot master tree as of now.

I commented on corresponding driver thread.

Regards,
Alex