lkml.org 
[lkml]   [2021]   [Jun]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [patch V3 61/66] x86/fpu/signal: Sanitize the xstate check on sigframe
From
Date
On 18/06/2021 15:19, Thomas Gleixner wrote:
> Utilize the check for the extended state magic in the FX software reserved
> bytes and set the parameters for restoring fx_only in the relevant members
> of fw_sw_user.
>
> This allows further cleanups on top because the data is consistent.
>
> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> ---
> arch/x86/kernel/fpu/signal.c | 69 +++++++++++++++++++------------------------
> 1 file changed, 32 insertions(+), 37 deletions(-)
>
> --- a/arch/x86/kernel/fpu/signal.c
> +++ b/arch/x86/kernel/fpu/signal.c
> @@ -15,29 +15,29 @@
> #include <asm/sigframe.h>
> #include <asm/trace/fpu.h>
>
> -static struct _fpx_sw_bytes fx_sw_reserved, fx_sw_reserved_ia32;
> +static struct _fpx_sw_bytes fx_sw_reserved, fx_sw_reserved_ia32 __ro_after_init;

You probably want a second __ro_after_init here.

~Andrew

\
 
 \ /
  Last update: 2021-06-18 23:11    [W:0.509 / U:1.584 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site