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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 15 Jan 2018 12:17:43 -0500
From:   Boris Ostrovsky <boris.ostrovsky@...cle.com>
To:     Andi Kleen <andi@...stfloor.org>, x86@...nel.org
Cc:     linux-kernel@...r.kernel.org, Andi Kleen <ak@...ux.intel.com>,
        Thomas Gleixner <tglx@...utronix.de>
Subject: Re: [PATCH 2/6] x86/xen: Mark pv stub assembler symbol visible



On 12/21/2017 07:18 PM, Andi Kleen wrote:
> From: Andi Kleen <ak@...ux.intel.com>
> 
> With LTO any external assembler symbol has to be marked __visible.
> Mark the generated asm PV stubs __visible to prevent a linker error.
> 
> Signed-off-by: Andi Kleen <ak@...ux.intel.com>

Reviewed-by: Boris Ostrovsky <boris.ostrovsky@...cle.com>


> ---
>   arch/x86/include/asm/paravirt.h | 3 ++-
>   drivers/xen/time.c              | 2 +-
>   2 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/x86/include/asm/paravirt.h b/arch/x86/include/asm/paravirt.h
> index 892df375b615..f03445fbbe2f 100644
> --- a/arch/x86/include/asm/paravirt.h
> +++ b/arch/x86/include/asm/paravirt.h
> @@ -745,7 +745,8 @@ static __always_inline bool pv_vcpu_is_preempted(long cpu)
>    */
>   #define PV_THUNK_NAME(func) "__raw_callee_save_" #func
>   #define PV_CALLEE_SAVE_REGS_THUNK(func)					\
> -	extern typeof(func) __raw_callee_save_##func;			\
> +	extern __visible typeof(func) __raw_callee_save_##func;		\
> +	extern __visible typeof(func) func;				\
>   									\
>   	asm(".pushsection .text;"					\
>   	    ".globl " PV_THUNK_NAME(func) ";"				\
> diff --git a/drivers/xen/time.c b/drivers/xen/time.c
> index 3e741cd1409c..708a00c337d7 100644
> --- a/drivers/xen/time.c
> +++ b/drivers/xen/time.c
> @@ -144,7 +144,7 @@ void xen_get_runstate_snapshot(struct vcpu_runstate_info *res)
>   }
>   
>   /* return true when a vcpu could run but has no real cpu to run on */
> -bool xen_vcpu_stolen(int vcpu)
> +__visible bool xen_vcpu_stolen(int vcpu)
>   {
>   	return per_cpu(xen_runstate, vcpu).state == RUNSTATE_runnable;
>   }
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ