Commit 667e3c41 authored by Christophe Leroy's avatar Christophe Leroy Committed by Michael Ellerman

powerpc/signal_32: Remove !FULL_REGS() special handling in PPC64 save_general_regs()

Since commit ("1bd79336 powerpc: Fix various
syscall/signal/swapcontext bugs"), getting save_general_regs() called
without FULL_REGS() is very unlikely and generates a warning.

The 32-bit version of save_general_regs() doesn't take care of it
at all and copies all registers anyway since that commit.

Moreover, commit 965dd3ad ("powerpc/64/syscall: Remove
non-volatile GPR save optimisation") is another reason why it would
never happen.

So the same with 64-bit, don't worry about FULL_REGS() and copy
all registers all the time.
Signed-off-by: default avatarChristophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/173de3b659fa3a5f126a0eb170522cccd909950f.1594125164.git.christophe.leroy@csgroup.eu
parent 41ea93cf
...@@ -109,8 +109,6 @@ static inline int save_general_regs(struct pt_regs *regs, ...@@ -109,8 +109,6 @@ static inline int save_general_regs(struct pt_regs *regs,
WARN_ON(!FULL_REGS(regs)); WARN_ON(!FULL_REGS(regs));
for (i = 0; i <= PT_RESULT; i ++) { for (i = 0; i <= PT_RESULT; i ++) {
if (i == 14 && !FULL_REGS(regs))
i = 32;
if ( i == PT_SOFTE) { if ( i == PT_SOFTE) {
if(__put_user((unsigned int)softe, &frame->mc_gregs[i])) if(__put_user((unsigned int)softe, &frame->mc_gregs[i]))
return -EFAULT; return -EFAULT;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment