powerpc: fix swapcontext backwards compatibility due to VSX ucontext changes

Paul Mackerras paulus at samba.org
Fri Jul 4 21:08:01 EST 2008


Michael Neuling writes:

> +	    /*
> +	     * If userspace doesn't provide enough room for VSX data,
> +	     * but current thread has used VSX, we don't have anywhere
> +	     * to store the full context back into.
> +	     */
> +		((ctx_size < sizeof(struct ucontext)) &&
> +		 (regs->msr & MSR_VSX) && old_ctx) ||

I think we need to check current->thread.used_vsr rather than
regs->msr here (in both instances of this code).

Paul.



More information about the Linuxppc-dev mailing list