diff options
author | Luc Van Oostenryck <luc.vanoostenryck@gmail.com> | 2017-10-31 18:22:05 +0100 |
---|---|---|
committer | Stafford Horne <shorne@gmail.com> | 2017-11-03 06:01:17 +0100 |
commit | afa83808817357e10b0a4e6d5b89f7b899dabd49 (patch) | |
tree | 6e08cd26d6a0565a863c1a7075b2597b1912082b | |
parent | openrisc: add tick timer multi-core sync logic (diff) | |
download | linux-afa83808817357e10b0a4e6d5b89f7b899dabd49.tar.xz linux-afa83808817357e10b0a4e6d5b89f7b899dabd49.zip |
openrisc: pass endianness info to sparse
openrisc is big-endian only but sparse assumes the same endianness
as the building machine.
This is problematic for code which expect __BYTE_ORDER__ being
correctly predefined by the compiler which sparse can then
pre-process differently from what gcc would, depending on the
building machine endianness.
Fix this by letting sparse know about the architecture endianness.
To: Jonas Bonn <jonas@southpole.se>
To: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
To: Stafford Horne <shorne@gmail.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Signed-off-by: Stafford Horne <shorne@gmail.com>
-rw-r--r-- | arch/openrisc/Makefile | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/openrisc/Makefile b/arch/openrisc/Makefile index 89076a66eee2..cf8802962864 100644 --- a/arch/openrisc/Makefile +++ b/arch/openrisc/Makefile @@ -25,6 +25,7 @@ LDFLAGS_vmlinux := LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name) KBUILD_CFLAGS += -pipe -ffixed-r10 -D__linux__ +CHECKFLAGS += -mbig-endian ifeq ($(CONFIG_OPENRISC_HAVE_INST_MUL),y) KBUILD_CFLAGS += $(call cc-option,-mhard-mul) |