Skip to content

Commit

Permalink
ntdll/unix/signal_x86_64: update for set GS base syscall change
Browse files Browse the repository at this point in the history
  • Loading branch information
X547 committed Mar 9, 2022
1 parent c8283ac commit 66313e3
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion dlls/ntdll/unix/signal_x86_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,17 @@
#endif
#ifdef __HAIKU__
# include <SupportDefs.h>
#if 0
# include <private/system/syscalls.h>
# include <private/system/arch/x86/arch_thread_defs.h>
#else
#define THREAD_SYSCALLS "thread"
#define THREAD_SET_GS_BASE 1

extern status_t _kern_generic_syscall(const char *subsystem, uint32 function,
void *buffer, size_t bufferSize);
#endif
#endif

#define NONAMELESSUNION
#define NONAMELESSSTRUCT
Expand Down Expand Up @@ -3046,7 +3054,7 @@ void signal_init_thread( TEB *teb )
TEB so alloc_tls_slot() can find it. */
teb->Reserved5[0] = amd64_thread_data()->pthread_teb;
#elif defined (__HAIKU__)
_kern_generic_syscall("thread", /*THREAD_SET_GS_BASE*/ 1, teb, 0);
_kern_generic_syscall(THREAD_SYSCALLS, THREAD_SET_GS_BASE, &teb, sizeof(teb));
#else
# error Please define setting %gs for your architecture
#endif
Expand Down

0 comments on commit 66313e3

Please sign in to comment.