lkml.org 
[lkml]   [2019]   [Mar]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 21/24] x86/fpu: Let __fpu__restore_sig() restore the !32bit+fxsr frame from kernel memory
On 2019-03-21 21:26:29 [+0100], To linux-kernel@vger.kernel.org wrote:
> diff --git a/arch/x86/kernel/fpu/signal.c b/arch/x86/kernel/fpu/signal.c
> index 5a467a381245c..052a16c96218f 100644
> --- a/arch/x86/kernel/fpu/signal.c
> +++ b/arch/x86/kernel/fpu/signal.c
> @@ -297,28 +298,63 @@ static int __fpu__restore_sig(void __user *buf, void __user *buf_fx, int size)

> + } else {
> + ret = __copy_from_user(&state->fsave, buf_fx, state_size);
> + if (ret)
> + goto err_out;
> + ret = copy_users_to_fregs(buf_fx);

This needs to become
ret = copy_users_to_fregs(&fpu->state.fsave);

here and in the follow up patch (fixing locally)

> + }

Sebastian

\
 
 \ /
  Last update: 2019-03-22 15:57    [W:0.126 / U:0.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site