summaryrefslogtreecommitdiffstats
path: root/arch/alpha/kernel/process.c
diff options
context:
space:
mode:
authorLinus Torvalds2018-02-02 22:46:21 +0100
committerLinus Torvalds2018-02-02 22:46:21 +0100
commitb89e32ccd1be92a3643df3908d3026b09e271616 (patch)
tree5620ddd276041f34bd8f33464f0e2e6b75e12009 /arch/alpha/kernel/process.c
parentMerge tag 'powerpc-4.16-1' of git://git.kernel.org/pub/scm/linux/kernel/git/p... (diff)
parentalpha: fix crash if pthread_create races with signal delivery (diff)
downloadkernel-qcow2-linux-b89e32ccd1be92a3643df3908d3026b09e271616.tar.gz
kernel-qcow2-linux-b89e32ccd1be92a3643df3908d3026b09e271616.tar.xz
kernel-qcow2-linux-b89e32ccd1be92a3643df3908d3026b09e271616.zip
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mattst88/alpha
Pull alpha updates from Matt Turner: "A few small fixes and clean ups" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mattst88/alpha: alpha: fix crash if pthread_create races with signal delivery alpha: fix formating of stack content alpha: fix reboot on Avanti platform alpha: deprecate pci_get_bus_and_slot() alpha: Fix mixed up args in EXC macro in futex operations alpha: osf_sys.c: use timespec64 where appropriate alpha: osf_sys.c: fix put_tv32 regression alpha: make thread_saved_pc static alpha: make XTABS equivalent to TAB3
Diffstat (limited to 'arch/alpha/kernel/process.c')
-rw-r--r--arch/alpha/kernel/process.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/alpha/kernel/process.c b/arch/alpha/kernel/process.c
index 74bfb1f2d68e..48b81d015d8a 100644
--- a/arch/alpha/kernel/process.c
+++ b/arch/alpha/kernel/process.c
@@ -269,12 +269,13 @@ copy_thread(unsigned long clone_flags, unsigned long usp,
application calling fork. */
if (clone_flags & CLONE_SETTLS)
childti->pcb.unique = regs->r20;
+ else
+ regs->r20 = 0; /* OSF/1 has some strange fork() semantics. */
childti->pcb.usp = usp ?: rdusp();
*childregs = *regs;
childregs->r0 = 0;
childregs->r19 = 0;
childregs->r20 = 1; /* OSF/1 has some strange fork() semantics. */
- regs->r20 = 0;
stack = ((struct switch_stack *) regs) - 1;
*childstack = *stack;
childstack->r26 = (unsigned long) ret_from_fork;
@@ -361,7 +362,7 @@ EXPORT_SYMBOL(dump_elf_task_fp);
* all. -- r~
*/
-unsigned long
+static unsigned long
thread_saved_pc(struct task_struct *t)
{
unsigned long base = (unsigned long)task_stack_page(t);