seen on aarch64-linux-gnu building the linux-4.3 kernel, with both 2015.12 and 2016.01. details at https://launchpad.net/bugs/1533009 confirmed that the gcc-5 fsf branch builds the kernel fine. The LP issue will be updated with a kernel config to reproduce.
the diff of the generated asm changed with - the .cpu omission: commit be09330da9d0777c4a58568d137e3f8a3dbe0a0b gcc/ Backport from trunk r226558. 2015-08-04 Kyrylo Tkachov <kyrylo.tkachov@arm.com> - the progbits changes: commit da216a29cb73967885035c64308db95e353a167e Author: Yvan Roux <yvan.roux@linaro.org> Date: Fri Oct 30 13:53:11 2015 +0100 gcc/ Backport from trunk r228390. 2015-10-02 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com> * config/aarch64/aarch64.c (aarch64_elf_asm_named_section): Delete. (TLS_SECTION_ASM_FLAG): Delete. gcc/ Backport from trunk r228397. 2015-10-02 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com> * config/aarch64/aarch64-elf.h (TARGET_ASM_NAMED_SECTION): Delete. Change-Id: I6091ea000fd93e0812497a5319d4c632be39ad0c
I'm able to reproduce the difference mentioned in launchpad (.cpu omission), but I'm not sure how it related to the rest of the bug report, which indicates a link with -mcmodel=large. This option is not used in the attachment used to reproduce the .cpu omission, so it may be irrelevant.
I'm following up this on launchpad.
I've also updated https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63304
This message provides background on the kernel a53 erratum workaround: http://www.spinics.net/lists/arm-kernel/msg445346.html And this discusses the main patch we have backported: https://gcc.gnu.org/ml/gcc-patches/2015-07/msg02258.html
I have posted a GCC patch: https://gcc.gnu.org/ml/gcc-patches/2016-01/msg01986.html to change the default of -mpc-relative-literal-loads when -mfix-cortex-a53-843419 is used.
Fixed in trunk at r234108.
Backported and available in our 5.3-2016.03 snapshot.
Hi Team, I do not see 5.3-2016.03 snapshot in release page. Is this fix released ? I would like to use pre-built binary toolchain. Any help is appreciated. I still see this bug when i compiler kernel module and insert with 5.3.1 tool chain. Error log: ---------- root@genericarmv8:~# insmod test_kasan.ko module test_kasan: unsupported RELA relocation: 275 insmod: ERROR: could not insert module test_kasan.ko: Invalid module format root@genericarmv8:~# cat /proc/version Linux version 4.1.21+ (root@kernel) (gcc version 5.3.1 20160113 (Linaro GCC 5.3-2016.02) ) #10 SMP PREEMPT Thu Apr 14 23:34:28 IST 2016 root@genericarmv8:~# Ref: Working on Kernel Ticket for testing KASAN. https://projects.linaro.org/browse/TICKET-309
(In reply to Naresh Kamboju from comment #9) > Hi Team, > > I do not see 5.3-2016.03 snapshot in release page. > Is this fix released ? > I would like to use pre-built binary toolchain. It's a snapshot, not a release. It's available from snapshots.linaro.org (http://snapshots.linaro.org/components/toolchain/gcc-linaro/) but only in source form > Any help is appreciated. > > I still see this bug when i compiler kernel module and insert with 5.3.1 > tool chain. > > Error log: > ---------- > root@genericarmv8:~# insmod test_kasan.ko > module test_kasan: unsupported RELA relocation: 275 > insmod: ERROR: could not insert module test_kasan.ko: Invalid module format > root@genericarmv8:~# cat /proc/version > Linux version 4.1.21+ (root@kernel) (gcc version 5.3.1 20160113 (Linaro GCC > 5.3-2016.02) ) #10 SMP PREEMPT Thu Apr 14 23:34:28 IST 2016 > root@genericarmv8:~# > > Ref: > Working on Kernel Ticket for testing KASAN. > https://projects.linaro.org/browse/TICKET-309 Until our next 5.x release is available, maybe you can try to modify the kernel Makefile as I suggested in comment #24 of: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1533009 This change (or a very similar one) has been integrated in the kernel mainline sources too.