From d83f0734e1522a5e5ea2494565f4dcd25a86d6a0 Mon Sep 17 00:00:00 2001 From: Carlos O'Donell Date: Sun, 7 Sep 2014 16:18:06 -0400 Subject: [PATCH] HPPA: Transition to new non-addon NPTL. Merge roland/nptl-hppa to master, update and test for hppa-linux-gnu. This commit squashes and commits the work done by Roland McGrath on roland/nptl-hppa to migrate hppa to the new non-addon NPTL. Some additional tweaks were required for tcb-offsets.sym to work correctly along with clone.S (unique to hppa). --- ChangeLog | 38 +++++++++++++++++++ .../linux => }/hppa/nptl/bits/pthreadtypes.h | 0 .../linux => }/hppa/nptl/bits/semaphore.h | 0 sysdeps/hppa/nptl/tcb-offsets.sym | 2 +- .../linux/hppa/{nptl/fork.c => arch-fork.h} | 5 +-- sysdeps/unix/sysv/linux/hppa/clone.S | 3 +- .../sysv/linux/hppa/{nptl => }/lowlevellock.h | 0 sysdeps/unix/sysv/linux/hppa/nptl/clone.S | 3 -- .../sysv/linux/hppa/nptl/libc-lowlevellock.c | 20 ---------- .../sysv/linux/hppa/{nptl => }/pt-vfork.S | 0 .../unix/sysv/linux/hppa/{nptl => }/pthread.h | 0 .../sysv/linux/hppa/{nptl => }/pthreadP.h | 0 .../hppa/{nptl => }/pthread_cond_broadcast.c | 0 .../hppa/{nptl => }/pthread_cond_destroy.c | 0 .../linux/hppa/{nptl => }/pthread_cond_init.c | 0 .../hppa/{nptl => }/pthread_cond_signal.c | 0 .../hppa/{nptl => }/pthread_cond_timedwait.c | 0 .../linux/hppa/{nptl => }/pthread_cond_wait.c | 0 .../linux/hppa/{nptl => }/sysdep-cancel.h | 0 19 files changed, 42 insertions(+), 29 deletions(-) rename sysdeps/{unix/sysv/linux => }/hppa/nptl/bits/pthreadtypes.h (100%) rename sysdeps/{unix/sysv/linux => }/hppa/nptl/bits/semaphore.h (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl/fork.c => arch-fork.h} (89%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/lowlevellock.h (100%) delete mode 100644 sysdeps/unix/sysv/linux/hppa/nptl/clone.S delete mode 100644 sysdeps/unix/sysv/linux/hppa/nptl/libc-lowlevellock.c rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pt-vfork.S (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthread.h (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthreadP.h (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthread_cond_broadcast.c (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthread_cond_destroy.c (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthread_cond_init.c (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthread_cond_signal.c (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthread_cond_timedwait.c (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/pthread_cond_wait.c (100%) rename sysdeps/unix/sysv/linux/hppa/{nptl => }/sysdep-cancel.h (100%) diff --git a/ChangeLog b/ChangeLog index 8dcc334930..565280cc91 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,41 @@ +2014-09-07 Roland McGrath + Carlos O'Donell + + * sysdeps/unix/sysv/linux/hppa/nptl/libc-lowlevellock.c: File removed. + * sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h: Moved ... + * sysdeps/unix/sysv/linux/hppa/lowlevellock.h: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pt-vfork.S: Moved ... + * sysdeps/unix/sysv/linux/hppa/pt-vfork.S: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthread.h: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthread.h: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthreadP.h: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthreadP.h: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_broadcast.c: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthread_cond_broadcast.c: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_destroy.c: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthread_cond_destroy.c: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_init.c: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthread_cond_init.c: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_signal.c: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthread_cond_signal.c: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_timedwait.c: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthread_cond_timedwait.c: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_wait.c: Moved ... + * sysdeps/unix/sysv/linux/hppa/pthread_cond_wait.c: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h: Moved ... + * sysdeps/unix/sysv/linux/hppa/sysdep-cancel.h: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/bits/pthreadtypes.h: Moved ... + * sysdeps/hppa/nptl/bits/pthreadtypes.h: ... here. + * sysdeps/unix/sysv/linux/hppa/nptl/bits/semaphore.h: Moved ... + * sysdeps/hppa/nptl/bits/semaphore.h: ... here. + * sysdeps/unix/sysv/linux/hppa/clone.S: Include . + Deconditionalize the code that was previously under [RESET_PID]. + * sysdeps/unix/sysv/linux/hppa/nptl/clone.S: File removed. + * sysdeps/unix/sysv/linux/hppa/arch-fork.h: New file. + * sysdeps/unix/sysv/linux/hppa/nptl/fork.c: File removed. + * sysdeps/hppa/nptl/tcb-offsets.sym: Include pthread.h and don't + include sysdep.h. + 2014-09-08 Allan McRae * version.h (RELEASE): Set to "development". diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/bits/pthreadtypes.h b/sysdeps/hppa/nptl/bits/pthreadtypes.h similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/bits/pthreadtypes.h rename to sysdeps/hppa/nptl/bits/pthreadtypes.h diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/bits/semaphore.h b/sysdeps/hppa/nptl/bits/semaphore.h similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/bits/semaphore.h rename to sysdeps/hppa/nptl/bits/semaphore.h diff --git a/sysdeps/hppa/nptl/tcb-offsets.sym b/sysdeps/hppa/nptl/tcb-offsets.sym index f3cc82621a..c2f326ee3d 100644 --- a/sysdeps/hppa/nptl/tcb-offsets.sym +++ b/sysdeps/hppa/nptl/tcb-offsets.sym @@ -1,4 +1,4 @@ -#include +#include #include RESULT offsetof (struct pthread, result) diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/fork.c b/sysdeps/unix/sysv/linux/hppa/arch-fork.h similarity index 89% rename from sysdeps/unix/sysv/linux/hppa/nptl/fork.c rename to sysdeps/unix/sysv/linux/hppa/arch-fork.h index 3c21f5aef9..f4241fa49d 100644 --- a/sysdeps/unix/sysv/linux/hppa/nptl/fork.c +++ b/sysdeps/unix/sysv/linux/hppa/arch-fork.h @@ -1,4 +1,5 @@ -/* Copyright (C) 2005-2014 Free Software Foundation, Inc. +/* ARCH_FORK definition for Linux fork implementation. HPPA version. + Copyright (C) 2005-2014 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -29,5 +30,3 @@ INLINE_SYSCALL (clone, 5, \ CLONE_CHILD_SETTID | CLONE_CHILD_CLEARTID | SIGCHLD, \ NULL, NULL, NULL, &THREAD_SELF->tid) - -#include diff --git a/sysdeps/unix/sysv/linux/hppa/clone.S b/sysdeps/unix/sysv/linux/hppa/clone.S index 1a3c6c800d..ac8c468d65 100644 --- a/sysdeps/unix/sysv/linux/hppa/clone.S +++ b/sysdeps/unix/sysv/linux/hppa/clone.S @@ -24,6 +24,7 @@ #include #define _ERRNO_H 1 #include +#include /* Non-thread code calls __clone with the following parameters: int clone(int (*fn)(void *arg), @@ -131,7 +132,6 @@ ENTRY(__clone) ldwm -64(%sp), %r4 .LthreadStart: -#ifdef RESET_PID # define CLONE_VM_BIT 23 /* 0x00000100 */ # define CLONE_THREAD_BIT 15 /* 0x00010000 */ /* Load original clone flags. @@ -150,7 +150,6 @@ ENTRY(__clone) stw %ret0, PID_THREAD_OFFSET(%r26) stw %ret0, TID_THREAD_OFFSET(%r26) 1: -#endif /* Load up the arguments. */ ldw -60(%sp), %arg0 ldw -64(%sp), %r22 diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h b/sysdeps/unix/sysv/linux/hppa/lowlevellock.h similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h rename to sysdeps/unix/sysv/linux/hppa/lowlevellock.h diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/clone.S b/sysdeps/unix/sysv/linux/hppa/nptl/clone.S deleted file mode 100644 index 23750b3f88..0000000000 --- a/sysdeps/unix/sysv/linux/hppa/nptl/clone.S +++ /dev/null @@ -1,3 +0,0 @@ -#define RESET_PID -#include -#include "../clone.S" diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/libc-lowlevellock.c b/sysdeps/unix/sysv/linux/hppa/nptl/libc-lowlevellock.c deleted file mode 100644 index 8f50fed615..0000000000 --- a/sysdeps/unix/sysv/linux/hppa/nptl/libc-lowlevellock.c +++ /dev/null @@ -1,20 +0,0 @@ -/* low level locking for pthread library. Generic futex-using version. - Copyright (C) 2003-2014 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Paul Mackerras , 2003. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include "lowlevellock.c" diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pt-vfork.S b/sysdeps/unix/sysv/linux/hppa/pt-vfork.S similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pt-vfork.S rename to sysdeps/unix/sysv/linux/hppa/pt-vfork.S diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthread.h b/sysdeps/unix/sysv/linux/hppa/pthread.h similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthread.h rename to sysdeps/unix/sysv/linux/hppa/pthread.h diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthreadP.h b/sysdeps/unix/sysv/linux/hppa/pthreadP.h similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthreadP.h rename to sysdeps/unix/sysv/linux/hppa/pthreadP.h diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_broadcast.c b/sysdeps/unix/sysv/linux/hppa/pthread_cond_broadcast.c similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_broadcast.c rename to sysdeps/unix/sysv/linux/hppa/pthread_cond_broadcast.c diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_destroy.c b/sysdeps/unix/sysv/linux/hppa/pthread_cond_destroy.c similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_destroy.c rename to sysdeps/unix/sysv/linux/hppa/pthread_cond_destroy.c diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_init.c b/sysdeps/unix/sysv/linux/hppa/pthread_cond_init.c similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_init.c rename to sysdeps/unix/sysv/linux/hppa/pthread_cond_init.c diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_signal.c b/sysdeps/unix/sysv/linux/hppa/pthread_cond_signal.c similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_signal.c rename to sysdeps/unix/sysv/linux/hppa/pthread_cond_signal.c diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_timedwait.c b/sysdeps/unix/sysv/linux/hppa/pthread_cond_timedwait.c similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_timedwait.c rename to sysdeps/unix/sysv/linux/hppa/pthread_cond_timedwait.c diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_wait.c b/sysdeps/unix/sysv/linux/hppa/pthread_cond_wait.c similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/pthread_cond_wait.c rename to sysdeps/unix/sysv/linux/hppa/pthread_cond_wait.c diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h b/sysdeps/unix/sysv/linux/hppa/sysdep-cancel.h similarity index 100% rename from sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h rename to sysdeps/unix/sysv/linux/hppa/sysdep-cancel.h -- 2.43.5