]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
powerpc: fix swapcontext backwards compat. with VSX ucontext changes
authorMichael Neuling <mikey@neuling.org>
Tue, 8 Jul 2008 08:43:41 +0000 (18:43 +1000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 9 Jul 2008 06:30:47 +0000 (16:30 +1000)
commitc1cb299ead405f0ac065c4430729549b187e5b32
treef61b78d06c8bc49e5b671bd065464613758dcefb
parent1b17adf19b4d66858f366acd82b4e81cba5edc93
powerpc: fix swapcontext backwards compat. with VSX ucontext changes

When the ucontext changed to add the VSX context, this broke backwards
compatibly on swapcontext.  swapcontext only compares the ucontext size
passed in from the user to the new kernel ucontext size.

This adds a check against the old ucontext size (with VMX but without
VSX).  It also adds some sanity check for ucontexts without VSX, but
where VSX is used according the MSR.  Fixes for both 32 and 64bit
processes on 64bit kernels

Kudos to Paulus for noticing.

Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/kernel/signal_32.c
arch/powerpc/kernel/signal_64.c