Hans Leidekker
4e71e86747
ntdll: Read the chassis type from sysfs.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-27 20:23:43 +02:00
Alexandre Julliard
87d9fef2ae
ntdll: Take stack guarantee into account when handling stack overflows.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-26 12:04:25 +02:00
Alex Henrie
56f96c17f2
ntdll/tests: Add more tests for RtlIpv4StringToAddress.
...
Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-23 19:38:00 +02:00
Alexandre Julliard
59f1c98e2c
ntdll: Run signal handlers on the signal stack on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-22 14:45:03 +02:00
Alexandre Julliard
b96d15e1b0
ntdll: Add .seh annotations for x86_64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-21 11:56:13 +02:00
Richard Yao
8d55542473
advapi32: Add EventWriteString stub.
...
"Are You Ready for Valve Index?" needs this to work.
Signed-off-by: Richard Yao <ryao@gentoo.org>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-19 16:13:26 +02:00
Alexandre Julliard
14e34bedbf
ntdll: Share dynamic exception table functions across platforms.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-19 13:21:47 +02:00
Alexandre Julliard
44a6043388
ntdll: Move some exception definitions to winnt.h.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-19 13:17:37 +02:00
Zebediah Figura
08fc532033
ntdll: Handle UWOP_EPILOG directives in x86_64 unwind info.
...
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-19 11:29:28 +02:00
Zebediah Figura
7ea3a14792
ntdll: Handle version 2 unwind info on x86_64.
...
It seems this is identical to version 1, but with an additional UWOP_EPILOG
opcode.
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-19 11:29:28 +02:00
Naveen Narayanan
de5392bfe7
ntdll: Set pthread stack guard size to 0 for NetBSD.
...
pthread_attr_setstack(3) in NetBSD 8.0 and newer sets the guard size
to 65536 and extends the stack beyond the specified range.
Signed-off-by: Naveen Narayanan <zerous@nocebo.space>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 20:27:06 +02:00
Alexandre Julliard
fc97373f62
ntdll: Fix support for breakpoint exceptions on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 15:41:55 +02:00
Alexandre Julliard
3027c266fc
ntdll: Don't run exception handlers on the signal stack on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 15:41:25 +02:00
Alexandre Julliard
94a98cf5a2
ntdll: Implement setting the thread context on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 14:53:07 +02:00
Alexandre Julliard
1c9fdaab0f
ntdll: Save the context from the caller stack frame in RtlCaptureContext() on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 14:52:23 +02:00
Alexandre Julliard
84783ed74f
ntdll: Preserve the stack red zone on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 14:51:47 +02:00
Alexandre Julliard
85c01202ac
ntdll: Use the exception fault code to detect write access on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 14:47:17 +02:00
Alexandre Julliard
07f37f2137
ntdll: Add support for saving/restoring FPU state on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 14:44:41 +02:00
Rémi Bernon
8a765533d6
ntdll: Implement zero_bits parameter in virtual alloc functions.
...
Use alloc_area.limit field to limit the search in reserved areas to the
desired memory range, or call find_free_area to get a pointer to a free
memory region which matches the zero_bits constraint, then mmap it with
MAP_FIXED flag.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:29:45 +02:00
Rémi Bernon
6672fc9d85
ntdll: Use custom internal zero_bits_64 parameter format.
...
The zero_bits parameter can be a pointer mask on Win64 and WoW64 and it
was incorrectly truncated to 16bits in APCs. Testing shows that only the
leading zeroes are used in the mask, so we can safely use the 64 based
number of leading zeroes everywhere instead.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:29:45 +02:00
Rémi Bernon
f172dd03ff
ntdll/tests: Update zero_bits > 31 test case to validate bitmask behavior.
...
Only the leading zeroes are taken into account, so 0x1aaaaaaa zero_bits
behaves as 0x1fffffff
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:11:46 +02:00
Rémi Bernon
54ba6b0ce5
ntdll/tests: Use MEM_TOP_DOWN parameter to consistently fail zero_bits tests.
...
The todo_wine_if made the tests not really test anything, and one test
was succeeding when it shouldn't. Now we can actually remove the todo
when 1 zero_bits handling is implemented.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:11:33 +02:00
Rémi Bernon
3cdb5072e8
ntdll/tests: Factor WoW64 checks and add is_win64 constant.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:11:27 +02:00
Rémi Bernon
d1a7b681ea
ntdll: Change zero_bits parameter type to ULONG_PTR for NtMapViewOfSection and NtAllocateVirtualMemory.
...
It can be a pointer mask, eventually 64bit, and ULONG_PTR is what can be
found in several documentation of these functions.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:11:15 +02:00
Rémi Bernon
5328b9e083
ntdll: Directly call internal functions from APC handler.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:11:08 +02:00
Rémi Bernon
1aa963efd7
ntdll: Add alloc_type parameter to virtual_map_section and top_down to map_image.
...
NtMapViewOfSection also accepts the MEM_TOP_DOWN parameter that can
be used in combination with zero_bits to map memory on the highest
possible address.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-13 12:11:02 +02:00
Michael Stefaniuc
724c216d18
ntdll: Remove useless cast to self.
...
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-12 09:32:02 +02:00
Nikolay Sivov
2a15f77b49
ntdll: Ignore -1 time value same as 0 when setting file times.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-09 10:03:19 +02:00
Nikolay Sivov
3172b854ae
ntdll/tests: Add some tests for setting file times.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-09 10:03:17 +02:00
Francois Gouget
cc9ce65d96
ntdll: Add a trailing '\n' to a TRACE().
...
Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-08 17:53:36 +02:00
Francois Gouget
4392ee399e
ntdll/tests: A spelling fix in a comment.
...
Signed-off-by: Francois Gouget <fgouget@free.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-08 17:53:36 +02:00
Zebediah Figura
a28736df1f
include: Add NTSTATUS severity macros.
...
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-08 09:15:43 +02:00
Alexandre Julliard
9b6d2d3310
ntdll: Silence FIXME for LdrResolveDelayLoadedAPI().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-07 00:12:25 +02:00
Alexandre Julliard
e91e6cc9bd
ntdll: Reimplement thread initialization in assembler on ARM64.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-07 00:12:25 +02:00
Chip Davis
ca2b701249
ntdll: Stub power request APIs.
...
Signed-off-by: Chip Davis <cdavis@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-01 19:12:03 +02:00
Chip Davis
6420ebdf93
ntdll: Move SetThreadExecutionState() implementation to ntdll.
...
Signed-off-by: Chip Davis <cdavis@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-01 19:12:03 +02:00
Chip Davis
4e4aa46775
ntdll: Implement RtlCaptureStackBackTrace() for x86_64.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=40868
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47101
Signed-off-by: Chip Davis <cdavis@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-08-01 19:12:03 +02:00
Gabriel Ivăncescu
ec4752cef2
ntdll: Define AT_NO_AUTOMOUNT if needed.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47445
Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-31 09:27:58 +02:00
Jacek Caban
5e0b0d3521
server: Rename cpu_type_t to client_cpu_t.
...
To avoid conflicts with mac headers.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-05 17:43:53 +02:00
Jacek Caban
7f9faf10c7
ntdll: Implement DbgUiIssueRemoteBreakin.
...
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-05 17:42:04 +02:00
Jacek Caban
4c2afc8ad9
ntdll: Implement _snprintf_s and _vsnprintf_s.
...
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-03 23:44:24 +02:00
Jacek Caban
b350095b76
ntdll: Move null terminating result to pf_vsnprintf callers.
...
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-03 23:44:24 +02:00
Hans Leidekker
5252d76003
ntdll: Use the machine ID for the system UUID on Linux.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-02 20:03:20 +02:00
Hans Leidekker
16e5c78bfe
ntdll: Use a common structure for the SMBIOS table entry header.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-02 20:02:32 +02:00
Hans Leidekker
bd8ce4c1b1
ntdll: Fix sysfs path for the product name.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-02 20:02:27 +02:00
Alexandre Julliard
21d91ef04b
ntdll: Initialize filesystem redirects before kernel32 is loaded.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-02 12:36:05 +02:00
Zebediah Figura
bf891f34af
ntdll: Correctly fill DataTransferLength in SCSI_PASS_THROUGH and SCSI_PASS_THROUGH_DIRECT.
...
DataTransferLength specifies the number of bytes transferred, but
sg_io_hdr_t.resid gives the number of bytes *not* transferred:
https://www.tldp.org/HOWTO/SCSI-Generic-HOWTO/x356.html
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47424
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-02 08:00:13 +02:00
Hans Leidekker
a8745d1211
ntdll: Support NtQuerySystemInformation(SystemFirmwareTableInformation) on macOS.
...
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-01 14:41:47 +02:00
Dmitry Timoshkov
84a46a27e7
ntdll: Add '-norelay' flag for _vsnprintf().
...
Otherwise for instance +relay,+ver log has ver: traces completely messed up.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-07-01 14:41:25 +02:00
Alexandre Julliard
32fdffac42
include: Implement some inline functions in C instead of assembly.
...
This way the same code can be used on all platforms.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2019-06-26 23:08:53 +02:00