aboutsummaryrefslogtreecommitdiff
path: root/sysdeps
diff options
context:
space:
mode:
authorSzabolcs Nagy <szabolcs.nagy@arm.com>2022-07-13 11:06:49 +0100
committerSzabolcs Nagy <szabolcs.nagy@arm.com>2022-10-27 14:46:52 +0100
commit280d809f68aaa725bc3d2e1724c42d83e951248f (patch)
treed0ed98cd19201a96d412352f79aac5e1c6ed070e /sysdeps
parent96ac67a64b4eb14473ea1e06aa665a903052b643 (diff)
downloadglibc-280d809f68aaa725bc3d2e1724c42d83e951248f.zip
glibc-280d809f68aaa725bc3d2e1724c42d83e951248f.tar.gz
glibc-280d809f68aaa725bc3d2e1724c42d83e951248f.tar.bz2
cheri: nptl: fix thread ID types for capabilities
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/nptl/bits/pthreadtypes.h4
-rw-r--r--sysdeps/nptl/bits/thread-shared-types.h4
2 files changed, 8 insertions, 0 deletions
diff --git a/sysdeps/nptl/bits/pthreadtypes.h b/sysdeps/nptl/bits/pthreadtypes.h
index 6f8907f..706c2bb 100644
--- a/sysdeps/nptl/bits/pthreadtypes.h
+++ b/sysdeps/nptl/bits/pthreadtypes.h
@@ -24,7 +24,11 @@
/* Thread identifiers. The structure of the attribute type is not
exposed on purpose. */
+#ifdef __CHERI_PURE_CAPABILITY__
+typedef __uintcap_t pthread_t;
+#else
typedef unsigned long int pthread_t;
+#endif
/* Data structures for mutex handling. The structure of the attribute
diff --git a/sysdeps/nptl/bits/thread-shared-types.h b/sysdeps/nptl/bits/thread-shared-types.h
index 5653507..1efdf4b 100644
--- a/sysdeps/nptl/bits/thread-shared-types.h
+++ b/sysdeps/nptl/bits/thread-shared-types.h
@@ -103,7 +103,11 @@ struct __pthread_cond_s
};
typedef unsigned int __tss_t;
+#ifdef __CHERI_PURE_CAPABILITY__
+typedef __uintcap_t __thrd_t;
+#else
typedef unsigned long int __thrd_t;
+#endif
typedef struct
{