summaryrefslogtreecommitdiff
path: root/drivers/mailbox/mailbox-xgene-slimpro.c
diff options
context:
space:
mode:
authorBorislav Petkov <bp@suse.de>2016-11-14 21:41:31 +0300
committerMichal Marek <mmarek@suse.com>2016-11-15 19:08:14 +0300
commitc6a385539175ebc603da53aafb7753d39089f32e (patch)
tree7719bd0abb47d7f3bf6fe9ecbdaa50c58b01e005 /drivers/mailbox/mailbox-xgene-slimpro.c
parentcc6acc11cad1eb1ae39707a3a6e4a97fafbeeabd (diff)
downloadlinux-c6a385539175ebc603da53aafb7753d39089f32e.tar.xz
kbuild: Steal gcc's pie from the very beginning
So Sebastian turned off the PIE for kernel builds but that was too late - Kbuild.include already uses KBUILD_CFLAGS and trying to disable gcc options with, say cc-disable-warning, fails: gcc -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs ... -Wno-sign-compare -fno-asynchronous-unwind-tables -Wframe-address -c -x c /dev/null -o .31392.tmp /dev/null:1:0: error: code model kernel does not support PIC mode because that returns an error and we can't disable the warning. For example in this case: KBUILD_CFLAGS += $(call cc-disable-warning,frame-address,) which leads to gcc issuing all those warnings again. So let's turn off PIE/PIC at the earliest possible moment, when we declare KBUILD_CFLAGS so that cc-disable-warning picks it up too. Also, we need the $(call cc-option ...) because -fno-PIE is supported since gcc v3.4 and our lowest supported gcc version is 3.2 right now. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: stable@vger.kernel.org Cc: Ben Hutchings <ben@decadent.org.uk> Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Michal Marek <mmarek@suse.com>
Diffstat (limited to 'drivers/mailbox/mailbox-xgene-slimpro.c')
0 files changed, 0 insertions, 0 deletions