Commit bae49e7
s390/ptrace: Preserve previous registers for short regset write
commit 9dce990d2cf57b5ed4e71a9cdbd7eae4335111ff upstream.
Ensure that if userspace supplies insufficient data to
PTRACE_SETREGSET to fill all the registers, the thread's old
registers are preserved.
convert_vx_to_fp() is adapted to handle only a specified number of
registers rather than unconditionally handling all of them: other
callers of this function are adapted appropriately.
Based on an initial patch by Dave Martin.
Reported-by: Dave Martin <Dave.Martin@arm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent 8637de3 commit bae49e7
1 file changed
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
963 | 963 | | |
964 | 964 | | |
965 | 965 | | |
| 966 | + | |
| 967 | + | |
| 968 | + | |
| 969 | + | |
| 970 | + | |
966 | 971 | | |
967 | 972 | | |
968 | 973 | | |
| |||
1067 | 1072 | | |
1068 | 1073 | | |
1069 | 1074 | | |
| 1075 | + | |
| 1076 | + | |
| 1077 | + | |
1070 | 1078 | | |
1071 | 1079 | | |
1072 | 1080 | | |
| |||
0 commit comments