Commit Graph

195 Commits

Author SHA1 Message Date
Alexandre Julliard 23ec3ce2a3 ntdll: Start process execution directly at the kernel32 process entry point.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-04 15:03:55 +01:00
Alexandre Julliard 70b69f3e5f ntdll: Don't return from attach_dlls on failure.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-30 19:06:44 +01:00
Alexandre Julliard 6c61ea6a13 ntdll: Suspend a thread with its start context explicitly before attaching dlls.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-30 12:15:51 +01:00
Alexandre Julliard 53e4c36ef8 ntdll: Add a platform-specific helper for starting a thread.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-29 20:15:30 +01:00
Alexandre Julliard f8e0bd1b0d ntdll: Put the initial pthread stack at the end of the Win32 stack.
Create a separate view for it so that the main stack can be freed
independently.

Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-29 10:44:21 +01:00
Alexandre Julliard 93eceba03e ntdll: Move freeing the thread stack to a common helper.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-29 10:43:39 +01:00
Alexandre Julliard 822e142403 ntdll: Support magic \1 prefix in debug format for relay traces.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-25 12:05:40 +01:00
Alexandre Julliard 9e093936e2 ntdll: Use a separate stack when starting new threads.
Based on a patch by Sebastian Lackner.

Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-21 15:05:50 +01:00
Alexandre Julliard 8477ae27a8 ntdll: Fixup imports in the first thread that runs, even if it's not the main one.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-20 20:24:39 +01:00
Alexandre Julliard a003f0aed8 ntdll: Store the kernel32 process entry point in a global variable.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-09-19 11:59:58 +02:00
Alexandre Julliard b31583770f ntdll: Store the PEB lock pointer in the PEB.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-08-31 10:08:01 +02:00
Alexandre Julliard b87c66dd65 ntdll: Move the plaform-independent thread data to the GdiTebBatch TEB field.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-19 19:13:29 +02:00
Alexandre Julliard ce46de5a94 ntdll: Move NtGetContextThread implementation to the platform-specific files.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-18 20:43:32 +02:00
Alexandre Julliard 675e8218f0 ntdll: Move NtSetContextThread implementation to the platform-specific files.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-18 20:43:32 +02:00
Alexandre Julliard 1e48417567 ntdll: Add helper functions for getting and setting thread context through the server.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-18 20:43:32 +02:00
Alexandre Julliard d3bbd03c8f ntdll: Also store dynamic loader information in the PEB on Linux.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-25 20:53:04 +02:00
Michael Müller a345265614 ntdll: Mark LDR data as initialized.
Signed-off-by: Michael Müller <michael@fds-team.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-24 11:08:50 +02:00
Piotr Caban 05ab8b98be ntdll: Add stub implementation of NtQueryInformationThread(ThreadIsIoPending).
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-02-08 10:53:32 +01:00
Andrew Wesie a39d67d8c9 ntdll: Prevent NULL dereference in NtSuspendThread.
Overwatch calls NtSuspendThread directly, and expects to be able to pass in a
NULL pointer for the count argument.

Signed-off-by: Andrew Wesie <awesie@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-02-03 19:05:10 +01:00
Dmitry Timoshkov d039d188f4 ntdll: Add support for fs segment in ThreadDescriptorTableEntry query.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-07-15 11:16:59 +09:00
Sebastian Lackner 12a00ea349 ntdll: Initialize Reserved_0 bit in NtQueryInformationThread.
Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-05-01 11:55:41 +09:00
Sebastian Lackner 56b4d35d52 ntdll: Preinitialize OS version data in thread_init.
Fixes a regression introduced by bd17022c90.

Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-13 21:43:03 +09:00
Alex Henrie 48f3bacb0b ntdll: Avoid double initialization.
Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-01-22 22:25:39 +09:00
Sebastian Lackner 7c468f8eca ntdll: Receive debug registers from server on x86_64.
Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-01-06 15:50:42 +01:00
Jacek Caban 19e16319b8 ntdll: Initialize PEB SessionId to 1.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-10-08 21:32:40 +09:00
Michael Müller 55ae09068b ntdll: Implement ThreadGroupInformation class.
Signed-off-by: Michael Müller <michael@fds-team.de>
Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
2015-10-02 18:11:31 +09:00
Sebastian Lackner 6d9cf49103 ntdll: Ignore higher bits in selector for ThreadDescriptorTableEntry info query.
Fixes a random test failure in kernel32/thread tests caused by the
uninitialized HIWORD.

Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
2015-09-25 21:03:17 +02:00
Sebastian Lackner 845164004b ntdll: Implement ThreadQuerySetWin32StartAddress info class in NtQueryInformationThread. 2015-07-29 21:44:03 +02:00
Sebastian Lackner 6ab494ceb5 ntdll: Implement ThreadQuerySetWin32StartAddress info class in NtSetInformationThread. 2015-07-29 21:44:03 +02:00
Sebastian Lackner 6156cf3134 server: Use a separate wineserver call to fetch thread times. 2015-07-29 21:44:03 +02:00
Charles Davis 97bda9a05f ntdll: Support 64-bit Mac OS. 2015-02-06 22:35:17 +09:00
Hans Leidekker faf70e2fbd ntdll: Fix calculation of process and thread affinity masks on systems with a large number of processors. 2015-01-21 15:31:16 +01:00
Sebastian Lackner 2fcecdb72e ntdll: Avoid leaking activation context in RtlCreateUserThread. (Valgrind). 2014-06-23 10:18:23 +02:00
Sebastian Lackner cfd09b0967 ntdll: Fix leaking activation context when terminating via exit_thread(). (Valgrind). 2014-06-23 10:17:26 +02:00
Alexandre Julliard 598c5816d9 kernel32: Don't allocate FLS index 0. 2014-03-28 17:46:03 +01:00
Jacek Caban 93920c3893 ntdll: Reserve TLS slot 0 for broken apps that compare index to 0 instead of TLS_OUT_OF_INDEXES. 2014-03-28 16:19:55 +01:00
Alexandre Julliard e54503f708 ntdll: Allocate TLS data in all running threads on module load. 2013-12-23 18:39:58 +01:00
Ken Thomases 22cf68e1bc ntdll: On Mac, store the dyld image info address in the PEB. 2013-12-05 12:40:56 +01:00
Nikolay Sivov 93c59714c0 ntdll: Inherit default activation context from creation thread. 2013-09-05 13:23:50 +02:00
Alexandre Julliard fcb3e60332 ntdll: Implement the RunOnce functions. 2013-08-28 22:27:31 +02:00
Alexandre Julliard 5c0b5f4dcb ntdll: Move the select and APC support to server.c. 2013-08-26 20:36:56 +02:00
Dmitry Timoshkov 94336f1aab ntdll: Thread creation control is now taken care by server. 2013-05-17 12:29:43 +02:00
Dmitry Timoshkov 59a23fb42f ntdll: Refuse to create new thread if the target process is being terminated. 2013-04-22 12:37:51 +02:00
André Hentschel 579f4f9da0 ntdll: Exit when we can't map the shared user data. 2012-11-28 20:14:51 +01:00
Daniel Jelinski 6ec731b65c ntdll: Add missing parameters to syscall call. 2012-05-30 11:21:45 +02:00
Detlef Riekenberg 979099a441 ntdll: Read the current processor with the __NR_getcpu syscall. 2012-05-21 11:33:55 +02:00
Detlef Riekenberg 1f80bacc65 ntdll: Use ThreadAffinityMask for NtGetCurrentProcessorNumber. 2012-05-21 10:27:40 +02:00
Detlef Riekenberg 02b74d3fd3 ntdll: Implement NtGetCurrentProcessorNumber. 2012-05-21 10:20:25 +02:00
Bernhard Loos b8629f55f1 ntdll: Initialize the Length field of PEB->LdrData. 2011-08-22 19:49:39 +02:00
Alexandre Julliard e1eb6228f4 ntdll: Ask the server to suspend the thread in the get/set_thread_context requests. 2011-05-06 12:49:42 +02:00