lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 3 Apr 2017 16:30:24 -0700
From:   Kees Cook <keescook@...omium.org>
To:     Jessica <jeyu@...hat.com>
Cc:     Andrew Morton <akpm@...ux-foundation.org>,
        Arnd Bergmann <arnd@...db.de>, Eddie Kovsky <ewk@...ovsky.org>,
        linux-arch <linux-arch@...r.kernel.org>,
        LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] vmlinux.lds: add missing VMLINUX_SYMBOL macros

On Mon, Apr 3, 2017 at 3:43 PM, Jessica <jeyu@...hat.com> wrote:
> From: Jessica Yu <jeyu@...hat.com>
>
> When __{start,end}_ro_after_init is referenced from C code, we run into the
> following build errors on blackfin:
>
>   kernel/extable.c:169: undefined reference to `__start_ro_after_init'
>   kernel/extable.c:169: undefined reference to `__end_ro_after_init'
>
> The build error is due to the fact that blackfin is one of the few arches
> that prepends an underscore '_' to all symbols defined in C. Fix this by
> wrapping __{start,end}_ro_after_init in vmlinux.lds.h with VMLINUX_SYMBOL(),
> which adds the necessary prefix for arches that have HAVE_UNDERSCORE_SYMBOL_PREFIX.
>
> Signed-off-by: Jessica Yu <jeyu@...hat.com>

Thanks!

Acked-by: Kees Cook <keescook@...omium.org>

-Kees

> ---
> This patch is based on next-20170403.
>
>  include/asm-generic/vmlinux.lds.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.lds.h
> index 979b573..54918ae 100644
> --- a/include/asm-generic/vmlinux.lds.h
> +++ b/include/asm-generic/vmlinux.lds.h
> @@ -261,9 +261,9 @@
>   */
>  #ifndef RO_AFTER_INIT_DATA
>  #define RO_AFTER_INIT_DATA                                             \
> -       __start_ro_after_init = .;                                      \
> +       VMLINUX_SYMBOL(__start_ro_after_init) = .;                      \
>         *(.data..ro_after_init)                                         \
> -       __end_ro_after_init = .;
> +       VMLINUX_SYMBOL(__end_ro_after_init) = .;
>  #endif
>
>  /*
> --
> 2.5.5
>



-- 
Kees Cook
Pixel Security

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ