[U-Boot] [PATCH 09/12] risck: tools: Prelink u-boot

Tom Rini trini at konsulko.com
Fri Dec 22 15:31:28 UTC 2017


On Fri, Dec 22, 2017 at 03:44:26PM +0800, Andes wrote:

> From: Rick Chen <rick at andestech.com>
> 
> Add prelink-riscv to arrange .rela.dyn and .rela.got
> in compile time.
> 
> Signed-off-by: Rick Chen <rick at andestech.com>
> Signed-off-by: Rick Chen <rickchen36 at gmail.com>
> Signed-off-by: Greentime Hu <green.hu at gmail.com>
> ---
>  Makefile                |    4 ++
>  tools/Makefile          |    1 +
>  tools/prelink-riscv.c   |   91 ++++++++++++++++++++++++++++++++++++++++++
>  tools/prelink-riscv.inc |  101 +++++++++++++++++++++++++++++++++++++++++++++++
>  4 files changed, 197 insertions(+), 0 deletions(-)
>  create mode 100644 tools/prelink-riscv.c
>  create mode 100644 tools/prelink-riscv.inc
> 
> diff --git a/Makefile b/Makefile
> index c573ddb..bb6416f 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1264,6 +1264,10 @@ ifeq ($(CONFIG_KALLSYMS),y)
>  	$(call cmd,u-boot__) common/system_map.o
>  endif
>  
> +ifeq ($(CONFIG_RISCV),y)
> +	@tools/prelink-riscv $@ 0
> +endif
> +
>  quiet_cmd_sym ?= SYM     $@
>        cmd_sym ?= $(OBJDUMP) -t $< > $@
>  u-boot.sym: u-boot FORCE
> diff --git a/tools/Makefile b/tools/Makefile
> index 4d32fe5..571f571 100644
> --- a/tools/Makefile
> +++ b/tools/Makefile
> @@ -185,6 +185,7 @@ hostprogs-$(CONFIG_KIRKWOOD) += kwboot
>  hostprogs-$(CONFIG_ARCH_MVEBU) += kwboot
>  hostprogs-y += proftool
>  hostprogs-$(CONFIG_STATIC_RELA) += relocate-rela
> +hostprogs-$(CONFIG_RISCV) += prelink-riscv
>  
>  hostprogs-y += fdtgrep
>  fdtgrep-objs += $(LIBFDT_OBJS) fdtgrep.o
> diff --git a/tools/prelink-riscv.c b/tools/prelink-riscv.c
> new file mode 100644
> index 0000000..dd099a9
> --- /dev/null
> +++ b/tools/prelink-riscv.c
> @@ -0,0 +1,91 @@
> +#if __BYTE_ORDER__ != __ORDER_LITTLE_ENDIAN__
> +#error "Only little-endian host is supported"
> +#endif
[snip]
> diff --git a/tools/prelink-riscv.inc b/tools/prelink-riscv.inc
> new file mode 100644
> index 0000000..f7f9596
> --- /dev/null
> +++ b/tools/prelink-riscv.inc

Needs license information, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20171222/fe9f6777/attachment.sig>


More information about the U-Boot mailing list