From: Mark Salter Date: Fri, 23 Aug 2013 15:16:42 +0000 (+0100) Subject: arm64: move elf notes into readonly segment X-Git-Tag: firefly_0821_release~3680^2~35^2~1^2~89 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=60d914ababfa53c35bf92b6be1921f265e535ab6;p=firefly-linux-kernel-4.4.55.git arm64: move elf notes into readonly segment The current vmlinux.lds.S places the notes sections between the end of rw data and start of bss. This means that _edata doesn't really point to the end of data. Since notes are read-only, this patch moves them to the read-only segment so that _edata does point to the end of initialized rw data. Signed-off-by: Mark Salter Signed-off-by: Catalin Marinas (cherry picked from commit c80b7ee8520606f77fbc8ced870c96659053269e) Signed-off-by: Mark Brown --- diff --git a/arch/arm64/kernel/vmlinux.lds.S b/arch/arm64/kernel/vmlinux.lds.S index 5e06a1786e26..1e8e6be0241c 100644 --- a/arch/arm64/kernel/vmlinux.lds.S +++ b/arch/arm64/kernel/vmlinux.lds.S @@ -57,6 +57,7 @@ SECTIONS RO_DATA(PAGE_SIZE) EXCEPTION_TABLE(8) + NOTES _etext = .; /* End of text and rodata section */ . = ALIGN(PAGE_SIZE); @@ -108,8 +109,6 @@ SECTIONS } _edata_loc = __data_loc + SIZEOF(.data); - NOTES - BSS_SECTION(0, 0, 0) _end = .;