[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120414235933.GA11321@redhat.com>
Date: Sun, 15 Apr 2012 01:59:33 +0200
From: Oleg Nesterov <oleg@...hat.com>
To: "H. Peter Anvin" <hpa@...or.com>,
Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Chuck Ebbert <chuckebbert.lk@...il.com>,
Jan Kratochvil <jan.kratochvil@...hat.com>,
linux-kernel@...r.kernel.org
Subject: Re: ptrace && fpu_lazy_restore
forgot to mention just in case...
On 04/15, Oleg Nesterov wrote:
>
> --- x/arch/x86/kernel/i387.c~ 2012-04-09 20:12:12.000000000 +0200
> +++ x/arch/x86/kernel/i387.c 2012-04-15 01:34:09.000000000 +0200
> @@ -301,6 +301,8 @@ int xfpregs_set(struct task_struct *targ
>
> sanitize_i387_state(target);
>
> + target->thread.fpu.last_cpu = ~0;
> +
> ret = user_regset_copyin(&pos, &count, &kbuf, &ubuf,
> &target->thread.fpu.state->fxsave, 0, -1);
>
> @@ -563,6 +565,8 @@ int fpregs_set(struct task_struct *targe
>
> sanitize_i387_state(target);
>
> + target->thread.fpu.last_cpu = ~0;
> +
> if (!HAVE_HWFP)
> return fpregs_soft_set(target, regset, pos, count, kbuf, ubuf);
>
with this hack the test-case works fine.
Oleg.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists