Rebase against bc282905d9491b9f9fe4ae4b69a8ccdf99c5aaa8.

This commit is contained in:
Zebediah Figura
2020-06-23 18:07:36 -05:00
parent 8402c95961
commit 7766c17912
36 changed files with 524 additions and 1918 deletions

View File

@@ -1,4 +1,4 @@
From e25066ea9c9e0442d4c18c13818071c104a9c5d2 Mon Sep 17 00:00:00 2001
From f8c60f99727799ff3d5910e99155db0a356e4d77 Mon Sep 17 00:00:00 2001
From: Martin Storsjo <martin@martin.st>
Date: Wed, 16 Aug 2017 23:48:40 +0300
Subject: [PATCH] ntdll: Always restore TEB to x18 on aarch 64 on return from
@@ -20,24 +20,24 @@ Signed-off-by: Martin Storsjo <martin@martin.st>
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c
index 0568be63ad8..b7612dcc9a7 100644
index 42cdc628021..7b92330e874 100644
--- a/dlls/ntdll/loader.c
+++ b/dlls/ntdll/loader.c
@@ -2036,7 +2036,13 @@ static NTSTATUS build_so_dll_module( const WCHAR *load_path, const UNICODE_STRIN
SERVER_END_REQ;
@@ -1924,7 +1924,13 @@ static NTSTATUS build_module( LPCWSTR load_path, const UNICODE_STRING *nt_name,
/* setup relay debugging entry points */
- if (TRACE_ON(relay)) RELAY_SetupDLL( module );
if (image_info->image_flags & IMAGE_FLAGS_WineBuiltin)
{
- if (TRACE_ON(relay)) RELAY_SetupDLL( *module );
+#ifdef __aarch64__
+ /* Always enable relay entry points on aarch64, to allow restoring
+ * the TEB to x18. */
+ /* Always enable relay entry points on aarch64, to allow restoring
+ * the TEB to x18. */
+#else
+ if (TRACE_ON(relay))
+ if (TRACE_ON(relay))
+#endif
+ RELAY_SetupDLL( module );
*pwm = wm;
return STATUS_SUCCESS;
+ RELAY_SetupDLL( *module );
}
else
{
diff --git a/dlls/ntdll/relay.c b/dlls/ntdll/relay.c
index acccf088811..35dd4161d8b 100644
--- a/dlls/ntdll/relay.c
@@ -56,5 +56,5 @@ index acccf088811..35dd4161d8b 100644
}
--
2.26.0
2.27.0