[08/34] nptl: Move pthreadP.h into sysdeps directory
Checks
Context |
Check |
Description |
dj/TryBot-apply_patch |
success
|
Patch applied to master at the time it was sent
|
Commit Message
This mirrors the situation on Hurd. These directories are on
the include search part, so #include <pthreadP.h> works after this
change on both Hurd and nptl.
---
nptl_db/thread_dbP.h | 2 +-
sysdeps/nptl/aio_misc.h | 2 +-
sysdeps/nptl/dl-tls_init_tp.c | 2 +-
sysdeps/nptl/fork.c | 2 +-
sysdeps/nptl/gai_misc.h | 2 +-
sysdeps/nptl/jmp-unwind.c | 2 +-
sysdeps/nptl/libc-lockP.h | 2 +-
sysdeps/nptl/libc_start_call_main.h | 2 +-
{nptl => sysdeps/nptl}/pthreadP.h | 2 +-
sysdeps/nptl/pthread_early_init.h | 2 +-
sysdeps/nptl/setxid.h | 2 +-
sysdeps/posix/spawni.c | 2 +-
sysdeps/unix/sysv/linux/dl-execstack.c | 2 +-
sysdeps/unix/sysv/linux/mq_notify.c | 2 +-
sysdeps/unix/sysv/linux/s390/jmp-unwind.c | 2 +-
sysdeps/unix/sysv/linux/sigprocmask.c | 2 +-
sysdeps/unix/sysv/linux/spawni.c | 2 +-
sysdeps/unix/sysv/linux/timer_create.c | 2 +-
sysdeps/unix/sysv/linux/timer_routines.c | 2 +-
sysdeps/unix/sysv/linux/tls-internal.h | 2 +-
sysdeps/unix/sysv/linux/x86/longjmp.c | 2 +-
21 files changed, 21 insertions(+), 21 deletions(-)
rename {nptl => sysdeps/nptl}/pthreadP.h (99%)
Comments
On 17/06/2021 15:57, Florian Weimer via Libc-alpha wrote:
> This mirrors the situation on Hurd. These directories are on
> the include search part, so #include <pthreadP.h> works after this
> change on both Hurd and npt
Nice change, is is really awkward to keep using nptl/pthreadP or keep
adding some extra hacks to include it outside nptl.
LGTM, thanks.
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
> ---
> nptl_db/thread_dbP.h | 2 +-
> sysdeps/nptl/aio_misc.h | 2 +-
> sysdeps/nptl/dl-tls_init_tp.c | 2 +-
> sysdeps/nptl/fork.c | 2 +-
> sysdeps/nptl/gai_misc.h | 2 +-
> sysdeps/nptl/jmp-unwind.c | 2 +-
> sysdeps/nptl/libc-lockP.h | 2 +-
> sysdeps/nptl/libc_start_call_main.h | 2 +-
> {nptl => sysdeps/nptl}/pthreadP.h | 2 +-
> sysdeps/nptl/pthread_early_init.h | 2 +-
> sysdeps/nptl/setxid.h | 2 +-
> sysdeps/posix/spawni.c | 2 +-
> sysdeps/unix/sysv/linux/dl-execstack.c | 2 +-
> sysdeps/unix/sysv/linux/mq_notify.c | 2 +-
> sysdeps/unix/sysv/linux/s390/jmp-unwind.c | 2 +-
> sysdeps/unix/sysv/linux/sigprocmask.c | 2 +-
> sysdeps/unix/sysv/linux/spawni.c | 2 +-
> sysdeps/unix/sysv/linux/timer_create.c | 2 +-
> sysdeps/unix/sysv/linux/timer_routines.c | 2 +-
> sysdeps/unix/sysv/linux/tls-internal.h | 2 +-
> sysdeps/unix/sysv/linux/x86/longjmp.c | 2 +-
> 21 files changed, 21 insertions(+), 21 deletions(-)
> rename {nptl => sysdeps/nptl}/pthreadP.h (99%)
>
> diff --git a/nptl_db/thread_dbP.h b/nptl_db/thread_dbP.h
> index 712fa3aeb6..7e7d1d5535 100644
> --- a/nptl_db/thread_dbP.h
> +++ b/nptl_db/thread_dbP.h
> @@ -27,7 +27,7 @@
> #include <assert.h>
> #include "proc_service.h"
> #include "thread_db.h"
> -#include "../nptl/pthreadP.h" /* This is for *_BITMASK only. */
> +#include <pthreadP.h> /* This is for *_BITMASK only. */
> #include <list.h>
> #include <gnu/lib-names.h>
> #include <libc-diag.h>
Ok.
> diff --git a/sysdeps/nptl/aio_misc.h b/sysdeps/nptl/aio_misc.h
> index 3e9b8929b2..a5c439fab5 100644
> --- a/sysdeps/nptl/aio_misc.h
> +++ b/sysdeps/nptl/aio_misc.h
> @@ -21,7 +21,7 @@
> correct aio_suspend and lio_listio implementations. */
>
> #include <assert.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <futex-internal.h>
>
> #define DONT_NEED_AIO_MISC_COND 1
Ok.
> diff --git a/sysdeps/nptl/dl-tls_init_tp.c b/sysdeps/nptl/dl-tls_init_tp.c
> index b7b3bb1cdb..c3349dd14c 100644
> --- a/sysdeps/nptl/dl-tls_init_tp.c
> +++ b/sysdeps/nptl/dl-tls_init_tp.c
> @@ -19,7 +19,7 @@
> #include <kernel-features.h>
> #include <ldsodefs.h>
> #include <list.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <tls.h>
>
> #ifndef __ASSUME_SET_ROBUST_LIST
Ok.
> diff --git a/sysdeps/nptl/fork.c b/sysdeps/nptl/fork.c
> index 062b01265a..39ab797612 100644
> --- a/sysdeps/nptl/fork.c
> +++ b/sysdeps/nptl/fork.c
> @@ -27,7 +27,7 @@
> #include <ldsodefs.h>
> #include <stdio-lock.h>
> #include <atomic.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <register-atfork.h>
> #include <arch-fork.h>
> #include <futex-internal.h>
Ok.
> diff --git a/sysdeps/nptl/gai_misc.h b/sysdeps/nptl/gai_misc.h
> index 82948fdf96..36bf27523d 100644
> --- a/sysdeps/nptl/gai_misc.h
> +++ b/sysdeps/nptl/gai_misc.h
> @@ -22,7 +22,7 @@
>
> #include <assert.h>
> #include <signal.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <futex-internal.h>
>
> #define DONT_NEED_GAI_MISC_COND 1
Ok.
> diff --git a/sysdeps/nptl/jmp-unwind.c b/sysdeps/nptl/jmp-unwind.c
> index 96c4862c74..5254c16b81 100644
> --- a/sysdeps/nptl/jmp-unwind.c
> +++ b/sysdeps/nptl/jmp-unwind.c
> @@ -19,7 +19,7 @@
> #include <setjmp.h>
> #include <stddef.h>
> #include <libc-lock.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
>
> void
> _longjmp_unwind (jmp_buf env, int val)
Ok.
> diff --git a/sysdeps/nptl/libc-lockP.h b/sysdeps/nptl/libc-lockP.h
> index ec7b02bbdd..ef88a3e533 100644
> --- a/sysdeps/nptl/libc-lockP.h
> +++ b/sysdeps/nptl/libc-lockP.h
> @@ -36,7 +36,7 @@
> #if IS_IN (libpthread)
> /* This gets us the declarations of the __pthread_* internal names,
> and hidden_proto for them. */
> -# include <nptl/pthreadP.h>
> +# include <pthreadP.h>
> #endif
>
> /* Mutex type. */
Ok.
> diff --git a/sysdeps/nptl/libc_start_call_main.h b/sysdeps/nptl/libc_start_call_main.h
> index b56bf34325..06d72c1e38 100644
> --- a/sysdeps/nptl/libc_start_call_main.h
> +++ b/sysdeps/nptl/libc_start_call_main.h
> @@ -17,7 +17,7 @@
> <https://www.gnu.org/licenses/>. */
>
> #include <atomic.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
>
> _Noreturn static void
> __libc_start_call_main (int (*main) (int, char **, char ** MAIN_AUXVEC_DECL),
Ok.
> diff --git a/nptl/pthreadP.h b/sysdeps/nptl/pthreadP.h
> similarity index 99%
> rename from nptl/pthreadP.h
> rename to sysdeps/nptl/pthreadP.h
> index 675d1de753..ca96ff073b 100644
> --- a/nptl/pthreadP.h
> +++ b/sysdeps/nptl/pthreadP.h
> @@ -25,7 +25,7 @@
> #include <setjmp.h>
> #include <stdbool.h>
> #include <sys/syscall.h>
> -#include "descr.h"
> +#include <nptl/descr.h>
> #include <tls.h>
> #include <lowlevellock.h>
> #include <stackinfo.h>
Ok.
> diff --git a/sysdeps/nptl/pthread_early_init.h b/sysdeps/nptl/pthread_early_init.h
> index 5b49ce39c2..89774c1477 100644
> --- a/sysdeps/nptl/pthread_early_init.h
> +++ b/sysdeps/nptl/pthread_early_init.h
> @@ -20,7 +20,7 @@
> #define _PTHREAD_EARLY_INIT_H 1
>
> #include <nptl/nptl-stack.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <pthread_mutex_conf.h>
> #include <sys/resource.h>
>
Ok.
> diff --git a/sysdeps/nptl/setxid.h b/sysdeps/nptl/setxid.h
> index 8b49d11550..e90367bf02 100644
> --- a/sysdeps/nptl/setxid.h
> +++ b/sysdeps/nptl/setxid.h
> @@ -15,7 +15,7 @@
> License along with the GNU C Library; if not, see
> <https://www.gnu.org/licenses/>. */
>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <sys/single_threaded.h>
> #include <sysdep.h>
>
Ok.
> diff --git a/sysdeps/posix/spawni.c b/sysdeps/posix/spawni.c
> index a649788668..fe3b5bb7f6 100644
> --- a/sysdeps/posix/spawni.c
> +++ b/sysdeps/posix/spawni.c
> @@ -28,7 +28,7 @@
> #include <not-cancel.h>
> #include <local-setxid.h>
> #include <shlib-compat.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <dl-sysdep.h>
> #include <libc-pointer-arith.h>
> #include <ldsodefs.h>
Ok.
> diff --git a/sysdeps/unix/sysv/linux/dl-execstack.c b/sysdeps/unix/sysv/linux/dl-execstack.c
> index e2449d1890..6598c90357 100644
> --- a/sysdeps/unix/sysv/linux/dl-execstack.c
> +++ b/sysdeps/unix/sysv/linux/dl-execstack.c
> @@ -20,7 +20,7 @@
> #include <ldsodefs.h>
> #include <libintl.h>
> #include <list.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <stackinfo.h>
> #include <stdbool.h>
> #include <sys/mman.h>
Ok.
> diff --git a/sysdeps/unix/sysv/linux/mq_notify.c b/sysdeps/unix/sysv/linux/mq_notify.c
> index 6f46d29d1d..e22850a910 100644
> --- a/sysdeps/unix/sysv/linux/mq_notify.c
> +++ b/sysdeps/unix/sysv/linux/mq_notify.c
> @@ -28,7 +28,7 @@
> #include <unistd.h>
> #include <sys/socket.h>
> #include <not-cancel.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
>
>
> /* Defined in the kernel headers: */
Ok.
> diff --git a/sysdeps/unix/sysv/linux/s390/jmp-unwind.c b/sysdeps/unix/sysv/linux/s390/jmp-unwind.c
> index 8e0399a3e9..5fbca71f5b 100644
> --- a/sysdeps/unix/sysv/linux/s390/jmp-unwind.c
> +++ b/sysdeps/unix/sysv/linux/s390/jmp-unwind.c
> @@ -19,7 +19,7 @@
> #include <setjmp.h>
> #include <stddef.h>
> #include <libc-lock.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
>
> void
> _longjmp_unwind (jmp_buf env, int val)
Ok.
> diff --git a/sysdeps/unix/sysv/linux/sigprocmask.c b/sysdeps/unix/sysv/linux/sigprocmask.c
> index 9dfd8076d1..eeec05d037 100644
> --- a/sysdeps/unix/sysv/linux/sigprocmask.c
> +++ b/sysdeps/unix/sysv/linux/sigprocmask.c
> @@ -16,7 +16,7 @@
> <https://www.gnu.org/licenses/>. */
>
> #include <signal.h>
> -#include <nptl/pthreadP.h> /* SIGCANCEL, SIGSETXID */
> +#include <pthreadP.h> /* SIGCANCEL, SIGSETXID */
>
> /* Get and/or change the set of blocked signals. */
> int
Ok.
> diff --git a/sysdeps/unix/sysv/linux/spawni.c b/sysdeps/unix/sysv/linux/spawni.c
> index 501f8fbccd..3b435e6c86 100644
> --- a/sysdeps/unix/sysv/linux/spawni.c
> +++ b/sysdeps/unix/sysv/linux/spawni.c
> @@ -27,7 +27,7 @@
> #include <not-cancel.h>
> #include <local-setxid.h>
> #include <shlib-compat.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <dl-sysdep.h>
> #include <libc-pointer-arith.h>
> #include <ldsodefs.h>
Ok.
> diff --git a/sysdeps/unix/sysv/linux/timer_create.c b/sysdeps/unix/sysv/linux/timer_create.c
> index 37de98fde4..1ea0086487 100644
> --- a/sysdeps/unix/sysv/linux/timer_create.c
> +++ b/sysdeps/unix/sysv/linux/timer_create.c
> @@ -24,7 +24,7 @@
> #include <time.h>
> #include <sysdep.h>
> #include <internaltypes.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include "kernel-posix-timers.h"
> #include "kernel-posix-cpu-timers.h"
>
Ok.
> diff --git a/sysdeps/unix/sysv/linux/timer_routines.c b/sysdeps/unix/sysv/linux/timer_routines.c
> index 60e60e0098..4098da8a5f 100644
> --- a/sysdeps/unix/sysv/linux/timer_routines.c
> +++ b/sysdeps/unix/sysv/linux/timer_routines.c
> @@ -21,7 +21,7 @@
> #include <signal.h>
> #include <stdbool.h>
> #include <sysdep-cancel.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include "kernel-posix-timers.h"
>
>
Ok.
> diff --git a/sysdeps/unix/sysv/linux/tls-internal.h b/sysdeps/unix/sysv/linux/tls-internal.h
> index 40798a5dcc..17128136dd 100644
> --- a/sysdeps/unix/sysv/linux/tls-internal.h
> +++ b/sysdeps/unix/sysv/linux/tls-internal.h
> @@ -20,7 +20,7 @@
> #define _TLS_INTERNAL_H 1
>
> #include <stdlib.h>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
>
> static inline struct tls_internal_t *
> __glibc_tls_internal (void)
Ok.
> diff --git a/sysdeps/unix/sysv/linux/x86/longjmp.c b/sysdeps/unix/sysv/linux/x86/longjmp.c
> index 1cc8b8dfad..25e2af7685 100644
> --- a/sysdeps/unix/sysv/linux/x86/longjmp.c
> +++ b/sysdeps/unix/sysv/linux/x86/longjmp.c
> @@ -18,7 +18,7 @@
>
> #include <sysdeps/x86/longjmp.c>
>
> -#include <nptl/pthreadP.h>
> +#include <pthreadP.h>
> #include <jmp_buf-ssp.h>
>
> #ifdef __x86_64__
>
Ok.
@@ -27,7 +27,7 @@
#include <assert.h>
#include "proc_service.h"
#include "thread_db.h"
-#include "../nptl/pthreadP.h" /* This is for *_BITMASK only. */
+#include <pthreadP.h> /* This is for *_BITMASK only. */
#include <list.h>
#include <gnu/lib-names.h>
#include <libc-diag.h>
@@ -21,7 +21,7 @@
correct aio_suspend and lio_listio implementations. */
#include <assert.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <futex-internal.h>
#define DONT_NEED_AIO_MISC_COND 1
@@ -19,7 +19,7 @@
#include <kernel-features.h>
#include <ldsodefs.h>
#include <list.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <tls.h>
#ifndef __ASSUME_SET_ROBUST_LIST
@@ -27,7 +27,7 @@
#include <ldsodefs.h>
#include <stdio-lock.h>
#include <atomic.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <register-atfork.h>
#include <arch-fork.h>
#include <futex-internal.h>
@@ -22,7 +22,7 @@
#include <assert.h>
#include <signal.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <futex-internal.h>
#define DONT_NEED_GAI_MISC_COND 1
@@ -19,7 +19,7 @@
#include <setjmp.h>
#include <stddef.h>
#include <libc-lock.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
void
_longjmp_unwind (jmp_buf env, int val)
@@ -36,7 +36,7 @@
#if IS_IN (libpthread)
/* This gets us the declarations of the __pthread_* internal names,
and hidden_proto for them. */
-# include <nptl/pthreadP.h>
+# include <pthreadP.h>
#endif
/* Mutex type. */
@@ -17,7 +17,7 @@
<https://www.gnu.org/licenses/>. */
#include <atomic.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
_Noreturn static void
__libc_start_call_main (int (*main) (int, char **, char ** MAIN_AUXVEC_DECL),
similarity index 99%
rename from nptl/pthreadP.h
rename to sysdeps/nptl/pthreadP.h
@@ -25,7 +25,7 @@
#include <setjmp.h>
#include <stdbool.h>
#include <sys/syscall.h>
-#include "descr.h"
+#include <nptl/descr.h>
#include <tls.h>
#include <lowlevellock.h>
#include <stackinfo.h>
@@ -20,7 +20,7 @@
#define _PTHREAD_EARLY_INIT_H 1
#include <nptl/nptl-stack.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <pthread_mutex_conf.h>
#include <sys/resource.h>
@@ -15,7 +15,7 @@
License along with the GNU C Library; if not, see
<https://www.gnu.org/licenses/>. */
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <sys/single_threaded.h>
#include <sysdep.h>
@@ -28,7 +28,7 @@
#include <not-cancel.h>
#include <local-setxid.h>
#include <shlib-compat.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <dl-sysdep.h>
#include <libc-pointer-arith.h>
#include <ldsodefs.h>
@@ -20,7 +20,7 @@
#include <ldsodefs.h>
#include <libintl.h>
#include <list.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <stackinfo.h>
#include <stdbool.h>
#include <sys/mman.h>
@@ -28,7 +28,7 @@
#include <unistd.h>
#include <sys/socket.h>
#include <not-cancel.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
/* Defined in the kernel headers: */
@@ -19,7 +19,7 @@
#include <setjmp.h>
#include <stddef.h>
#include <libc-lock.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
void
_longjmp_unwind (jmp_buf env, int val)
@@ -16,7 +16,7 @@
<https://www.gnu.org/licenses/>. */
#include <signal.h>
-#include <nptl/pthreadP.h> /* SIGCANCEL, SIGSETXID */
+#include <pthreadP.h> /* SIGCANCEL, SIGSETXID */
/* Get and/or change the set of blocked signals. */
int
@@ -27,7 +27,7 @@
#include <not-cancel.h>
#include <local-setxid.h>
#include <shlib-compat.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <dl-sysdep.h>
#include <libc-pointer-arith.h>
#include <ldsodefs.h>
@@ -24,7 +24,7 @@
#include <time.h>
#include <sysdep.h>
#include <internaltypes.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include "kernel-posix-timers.h"
#include "kernel-posix-cpu-timers.h"
@@ -21,7 +21,7 @@
#include <signal.h>
#include <stdbool.h>
#include <sysdep-cancel.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include "kernel-posix-timers.h"
@@ -20,7 +20,7 @@
#define _TLS_INTERNAL_H 1
#include <stdlib.h>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
static inline struct tls_internal_t *
__glibc_tls_internal (void)
@@ -18,7 +18,7 @@
#include <sysdeps/x86/longjmp.c>
-#include <nptl/pthreadP.h>
+#include <pthreadP.h>
#include <jmp_buf-ssp.h>
#ifdef __x86_64__