s390: compile head.S always with -march=z900
authorHeiko Carstens <heiko.carstens@de.ibm.com>
Thu, 5 Nov 2015 13:03:32 +0000 (14:03 +0100)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Fri, 18 Dec 2015 13:59:26 +0000 (14:59 +0100)
head.S on s390 contains some sanity checks if the kernel will run on a
machine or if the machine is too old, e.g. if the kernel contains
instructions not available on the machine. If so, it will emit an error
message to the console before it stops execution.

Therefore head.S contains only instructions which are availanble with the
earliest machine generation (z900).  In order to make sure we don't
accidently add instructions which are not available on z900, always compile
with -march=z900. This makes sure compilation will fail if wrong
instructions are used.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/kernel/Makefile

index dc167a23b92055b63ecf20f9e9146f672b98ac0e..e9a328d426105664012ad1eea5a66152e3a75e06 100644 (file)
@@ -34,8 +34,10 @@ CFLAGS_sysinfo.o += -w
 #
 CFLAGS_REMOVE_sclp.o = $(CC_FLAGS_FTRACE)
 ifneq ($(CC_FLAGS_MARCH),-march=z900)
-CFLAGS_REMOVE_sclp.o += $(CC_FLAGS_MARCH)
-CFLAGS_sclp.o  += -march=z900
+CFLAGS_REMOVE_sclp.o   += $(CC_FLAGS_MARCH)
+CFLAGS_sclp.o          += -march=z900
+AFLAGS_REMOVE_head.o   += $(CC_FLAGS_MARCH)
+AFLAGS_head.o          += -march=z900
 endif
 GCOV_PROFILE_sclp.o := n
 
This page took 0.024551 seconds and 5 git commands to generate.