|
@@ -1,82 +0,0 @@
|
|
|
-From afdb9343e167ff0ef2f573e6866f5b0c7c717c76 Mon Sep 17 00:00:00 2001
|
|
|
-From: Alistair Francis <alistair.francis@wdc.com>
|
|
|
-Date: Fri, 22 Feb 2019 15:02:55 -0800
|
|
|
-Subject: [PATCH 2/2] Makefile: Set the platform variables before parsing the
|
|
|
- platforms
|
|
|
-
|
|
|
-Ensure the platform variable PLATFORM_RISCV_XLEN is set before we parse
|
|
|
-the platform files.
|
|
|
-
|
|
|
-This fixes the 32-bit openSBI FW_JUMP_ADDR.
|
|
|
-
|
|
|
-Upstream-Status: Submitted [https://github.com/riscv/opensbi/pull/73]
|
|
|
-Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
|
|
|
----
|
|
|
- Makefile | 44 ++++++++++++++++++++++----------------------
|
|
|
- 1 file changed, 22 insertions(+), 22 deletions(-)
|
|
|
-
|
|
|
-diff --git a/Makefile b/Makefile
|
|
|
-index 10851fc..e60e762 100644
|
|
|
---- a/Makefile
|
|
|
-+++ b/Makefile
|
|
|
-@@ -74,6 +74,28 @@ DTC = dtc
|
|
|
- # Guess the compillers xlen
|
|
|
- OPENSBI_CC_XLEN := $(shell TMP=`$(CC) -dumpmachine | sed 's/riscv\([0-9][0-9]\).*/\1/'`; echo $${TMP})
|
|
|
-
|
|
|
-+# Setup platform XLEN, ABI, ISA and Code Model
|
|
|
-+ifndef PLATFORM_RISCV_XLEN
|
|
|
-+ ifeq ($(OPENSBI_CC_XLEN), 32)
|
|
|
-+ PLATFORM_RISCV_XLEN = 32
|
|
|
-+ else
|
|
|
-+ PLATFORM_RISCV_XLEN = 64
|
|
|
-+ endif
|
|
|
-+endif
|
|
|
-+ifndef PLATFORM_RISCV_ABI
|
|
|
-+ ifeq ($(PLATFORM_RISCV_XLEN), 32)
|
|
|
-+ PLATFORM_RISCV_ABI = ilp$(PLATFORM_RISCV_XLEN)
|
|
|
-+ else
|
|
|
-+ PLATFORM_RISCV_ABI = lp$(PLATFORM_RISCV_XLEN)
|
|
|
-+ endif
|
|
|
-+endif
|
|
|
-+ifndef PLATFORM_RISCV_ISA
|
|
|
-+ PLATFORM_RISCV_ISA = rv$(PLATFORM_RISCV_XLEN)imafdc
|
|
|
-+endif
|
|
|
-+ifndef PLATFORM_RISCV_CODE_MODEL
|
|
|
-+ PLATFORM_RISCV_CODE_MODEL = medany
|
|
|
-+endif
|
|
|
-+
|
|
|
- # Setup list of objects.mk files
|
|
|
- ifdef PLATFORM
|
|
|
- platform-object-mks=$(shell if [ -d $(platform_dir) ]; then find $(platform_dir) -iname "objects.mk" | sort -r; fi)
|
|
|
-@@ -112,28 +134,6 @@ deps-y+=$(platform-common-objs-path-y:.o=.dep)
|
|
|
- deps-y+=$(lib-objs-path-y:.o=.dep)
|
|
|
- deps-y+=$(firmware-objs-path-y:.o=.dep)
|
|
|
-
|
|
|
--# Setup platform XLEN, ABI, ISA and Code Model
|
|
|
--ifndef PLATFORM_RISCV_XLEN
|
|
|
-- ifeq ($(OPENSBI_CC_XLEN), 32)
|
|
|
-- PLATFORM_RISCV_XLEN = 32
|
|
|
-- else
|
|
|
-- PLATFORM_RISCV_XLEN = 64
|
|
|
-- endif
|
|
|
--endif
|
|
|
--ifndef PLATFORM_RISCV_ABI
|
|
|
-- ifeq ($(PLATFORM_RISCV_XLEN), 32)
|
|
|
-- PLATFORM_RISCV_ABI = ilp$(PLATFORM_RISCV_XLEN)
|
|
|
-- else
|
|
|
-- PLATFORM_RISCV_ABI = lp$(PLATFORM_RISCV_XLEN)
|
|
|
-- endif
|
|
|
--endif
|
|
|
--ifndef PLATFORM_RISCV_ISA
|
|
|
-- PLATFORM_RISCV_ISA = rv$(PLATFORM_RISCV_XLEN)imafdc
|
|
|
--endif
|
|
|
--ifndef PLATFORM_RISCV_CODE_MODEL
|
|
|
-- PLATFORM_RISCV_CODE_MODEL = medany
|
|
|
--endif
|
|
|
--
|
|
|
- # Setup compilation commands flags
|
|
|
- GENFLAGS = -I$(platform_dir)/include
|
|
|
- GENFLAGS += -I$(platform_common_dir)/include
|
|
|
---
|
|
|
-2.20.1
|
|
|
-
|