summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorFlavio Cruz <flaviocruz@gmail.com>2024-02-12 01:26:34 -0500
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2024-02-12 18:52:21 +0100
commit10b25803ce879ee6ac832b884bfdabc79769486a (patch)
tree75aa37ab8f0f8ed3ae2e7009027329cf6937df29 /include
parentdf9270ef134498d4fffb921286375137d3639ae5 (diff)
Add thread_set_name RPC.
Like task_set_name, we use the same size as the task name and will inherit the task name, whenever it exists. This will be used to implement pthread_setname_np. Message-ID: <20240212062634.1082207-2-flaviocruz@gmail.com>
Diffstat (limited to 'include')
-rw-r--r--include/mach/gnumach.defs8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/mach/gnumach.defs b/include/mach/gnumach.defs
index 6252de96..7ecf74d3 100644
--- a/include/mach/gnumach.defs
+++ b/include/mach/gnumach.defs
@@ -207,3 +207,11 @@ routine vm_pages_phys(
vaddr : vm_address_t;
size : vm_size_t;
out pages : rpc_phys_addr_array_t);
+
+/*
+ * Set the name of thread THREAD to NAME. This is a debugging aid.
+ * NAME will be used in error messages printed by the kernel.
+ */
+simpleroutine thread_set_name(
+ thread : thread_t;
+ name : kernel_debug_name_t);