From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lukas Auer Date: Sun, 30 Dec 2018 19:27:46 +0100 Subject: [U-Boot] [PATCH 6/6] riscv: qemu: define standalone load address In-Reply-To: <20181230182746.23448-1-lukas.auer@aisec.fraunhofer.de> References: <20181230182746.23448-1-lukas.auer@aisec.fraunhofer.de> Message-ID: <20181230182746.23448-7-lukas.auer@aisec.fraunhofer.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de We need to define the standalone load address to use standalone application on qemu-riscv. Define it and set it equal to CONFIG_SYS_LOAD_ADDR. To not overwrite it, change the assigned of CONFIG_STANDALONE_LOAD_ADDR in arch/riscv/config.mk to a conditional one. Signed-off-by: Lukas Auer --- arch/riscv/config.mk | 2 +- include/configs/qemu-riscv.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/riscv/config.mk b/arch/riscv/config.mk index e484a3f0ef..84654eb3ed 100644 --- a/arch/riscv/config.mk +++ b/arch/riscv/config.mk @@ -23,7 +23,7 @@ PLATFORM_LDFLAGS += -m $(64bit-emul) EFI_LDS := elf_riscv64_efi.lds endif -CONFIG_STANDALONE_LOAD_ADDR = 0x00000000 +CONFIG_STANDALONE_LOAD_ADDR ?= 0x00000000 PLATFORM_CPPFLAGS += -ffixed-gp -fpic PLATFORM_RELFLAGS += -fno-common -gdwarf-2 -ffunction-sections \ diff --git a/include/configs/qemu-riscv.h b/include/configs/qemu-riscv.h index b29d155d09..2588c5a0b2 100644 --- a/include/configs/qemu-riscv.h +++ b/include/configs/qemu-riscv.h @@ -17,6 +17,8 @@ #define CONFIG_SYS_BOOTM_LEN SZ_16M +#define CONFIG_STANDALONE_LOAD_ADDR 0x80200000 + /* Environment options */ #define CONFIG_ENV_SIZE SZ_4K -- 2.20.1