[PATCH 5.10 068/158] nios2: restarts apply only to the first sigframe we build...

From: Greg Kroah-Hartman
Date: Tue Aug 23 2022 - 08:19:26 EST


From: Al Viro <viro@xxxxxxxxxxxxxxxxxx>

commit 411a76b7219555c55867466c82d70ce928d6c9e1 upstream.

Fixes: b53e906d255d ("nios2: Signal handling support")
Signed-off-by: Al Viro <viro@xxxxxxxxxxxxxxxxxx>
Signed-off-by: Dinh Nguyen <dinguyen@xxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
arch/nios2/kernel/signal.c | 1 +
1 file changed, 1 insertion(+)

--- a/arch/nios2/kernel/signal.c
+++ b/arch/nios2/kernel/signal.c
@@ -264,6 +264,7 @@ static int do_signal(struct pt_regs *reg
regs->ea = restart_addr;
break;
}
+ regs->orig_r2 = -1;
}

if (get_signal(&ksig)) {