/* restore the FPU state from a signal context  */
int fpu_restore_sigcontext(struct fpucontext *fpucontext)
/* restore the FPU state from a signal context  */
int fpu_restore_sigcontext(struct fpucontext *fpucontext)
{
	struct task_struct *tsk = current;
	int ret;
	ret = copy_from_user(&tsk->thread.fpu_state,
			     fpucontext,
			     min(sizeof(struct fpu_state_struct),
				 sizeof(struct fpucontext)));
	if (!ret)
		set_using_fpu(tsk);
	return ret;
}