diff mbox series

[RFC,1/9] Build skiboot little-endian by default

Message ID 20200502113649.176329-2-npiggin@gmail.com
State New
Headers show
Series OPAL V4 | expand

Checks

Context Check Description
snowpatch_ozlabs/apply_patch success Successfully applied on branch master (0f1937ef40fca0c3212a9dff1010b832a24fb063)
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot success Test snowpatch/job/snowpatch-skiboot on branch master
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot-dco success Signed-off-by present

Commit Message

Nicholas Piggin May 2, 2020, 11:36 a.m. UTC
LE is the way to go. Significantly smaller, less stack, faster, can
avoid endian flips when called from an LE OS, subsequent patches are
adding some LE specific features. They aren't exclusvely LE, but I
haven't implemented for BE yet.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---
 Makefile | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/Makefile b/Makefile
index d236df9ec..6e5b91d84 100644
--- a/Makefile
+++ b/Makefile
@@ -48,12 +48,18 @@  KERNEL ?=
 #
 STACK_CHECK ?= $(DEBUG)
 
+BIG_ENDIAN ?= 0
+ifeq ($(BIG_ENDIAN),1)
+LITTLE_ENDIAN = 0
+else
+LITTLE_ENDIAN ?= 1
+endif
+
 #
 # Experimental (unsupported) build options
 #
-# Little-endian does not yet build. Include it here to set ELF ABI.
-LITTLE_ENDIAN ?= 0
-# ELF v2 ABI is more efficient and compact
+# ELF v2 ABI is more efficient and compact.
+# This can be set for big-endian builds. Clearing it for LE probably won't work.
 ELF_ABI_v2 ?= $(LITTLE_ENDIAN)
 # Discard unreferenced code and data at link-time
 DEAD_CODE_ELIMINATION ?= 0