lkml.org 
[lkml]   [2020]   [Jul]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH v5 18/36] arm64/build: Use common DISCARDS in linker script
    Date
    Use the common DISCARDS rule for the linker script in an effort to
    regularize the linker script to prepare for warning on orphaned
    sections. Additionally clean up left-over no-op macros.

    Signed-off-by: Kees Cook <keescook@chromium.org>
    Acked-by: Will Deacon <will@kernel.org>
    ---
    arch/arm64/kernel/vmlinux.lds.S | 5 ++---
    1 file changed, 2 insertions(+), 3 deletions(-)

    diff --git a/arch/arm64/kernel/vmlinux.lds.S b/arch/arm64/kernel/vmlinux.lds.S
    index b29081d16a70..5c1960406b08 100644
    --- a/arch/arm64/kernel/vmlinux.lds.S
    +++ b/arch/arm64/kernel/vmlinux.lds.S
    @@ -6,6 +6,7 @@
    */

    #define RO_EXCEPTION_TABLE_ALIGN 8
    +#define RUNTIME_DISCARD_EXIT

    #include <asm-generic/vmlinux.lds.h>
    #include <asm/cache.h>
    @@ -89,10 +90,8 @@ SECTIONS
    * matching the same input section name. There is no documented
    * order of matching.
    */
    + DISCARDS
    /DISCARD/ : {
    - EXIT_CALL
    - *(.discard)
    - *(.discard.*)
    *(.interp .dynamic)
    *(.dynsym .dynstr .hash .gnu.hash)
    }
    --
    2.25.1
    \
     
     \ /
      Last update: 2020-08-01 01:19    [W:4.233 / U:0.100 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site