powerpc/ptrace: Preserve previous TM fprs/vsrs on short regset write
authorDave Martin <Dave.Martin@arm.com>
Thu, 5 Jan 2017 16:50:57 +0000 (16:50 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Fri, 20 Jan 2017 03:55:19 +0000 (14:55 +1100)
commitb34ca60148c53971d373643195cc5c4d5d20be78
tree434266b9f31e68d97566b46a3c777ae2dab3f579
parent99dfe80a2a246c600440a815741fd2e74a8b4977
powerpc/ptrace: Preserve previous TM fprs/vsrs on short regset write

Ensure that if userspace supplies insufficient data to PTRACE_SETREGSET
to fill all the check pointed registers, the thread's old check pointed
registers are preserved.

Fixes: 9d3918f7c0e5 ("powerpc/ptrace: Enable support for NT_PPC_CVSX")
Fixes: 19cbcbf75a0c ("powerpc/ptrace: Enable support for NT_PPC_CFPR")
Cc: stable@vger.kernel.org # v4.8+
Signed-off-by: Dave Martin <Dave.Martin@arm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/ptrace.c