Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
5b01bf79
Commit
5b01bf79
authored
Nov 25, 2023
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Store the syscall table in the TEB on ARM64.
parent
f2fa8ca2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
signal_arm64.c
dlls/ntdll/unix/signal_arm64.c
+6
-1
No files found.
dlls/ntdll/unix/signal_arm64.c
View file @
5b01bf79
...
...
@@ -149,10 +149,12 @@ C_ASSERT( sizeof( struct syscall_frame ) == 0x330 );
struct
arm64_thread_data
{
struct
syscall_frame
*
syscall_frame
;
/* 02f0 frame pointer on syscall entry */
SYSTEM_SERVICE_TABLE
*
syscall_table
;
/* 02f8 syscall table */
};
C_ASSERT
(
sizeof
(
struct
arm64_thread_data
)
<=
sizeof
(((
struct
ntdll_thread_data
*
)
0
)
->
cpu_data
)
);
C_ASSERT
(
offsetof
(
TEB
,
GdiTebBatch
)
+
offsetof
(
struct
arm64_thread_data
,
syscall_frame
)
==
0x2f0
);
C_ASSERT
(
offsetof
(
TEB
,
GdiTebBatch
)
+
offsetof
(
struct
arm64_thread_data
,
syscall_table
)
==
0x2f8
);
static
inline
struct
arm64_thread_data
*
arm64_thread_data
(
void
)
{
...
...
@@ -1669,10 +1671,13 @@ void syscall_dispatcher_return_slowpath(void)
void
call_init_thunk
(
LPTHREAD_START_ROUTINE
entry
,
void
*
arg
,
BOOL
suspend
,
TEB
*
teb
,
struct
syscall_frame
*
frame
,
void
*
syscall_cfa
)
{
struct
arm64_thread_data
*
thread_data
=
(
struct
arm64_thread_data
*
)
&
teb
->
GdiTebBatch
;
CONTEXT
*
ctx
,
context
=
{
CONTEXT_ALL
};
I386_CONTEXT
*
i386_context
;
ARM_CONTEXT
*
arm_context
;
thread_data
->
syscall_table
=
KeServiceDescriptorTable
;
context
.
X0
=
(
DWORD64
)
entry
;
context
.
X1
=
(
DWORD64
)
arg
;
context
.
X18
=
(
DWORD64
)
teb
;
...
...
@@ -1819,7 +1824,7 @@ __ASM_GLOBAL_FUNC( __wine_syscall_dispatcher,
__ASM_CFI
(
".cfi_offset 28, -0x68
\n\t
"
)
"and x20, x8, #0xfff
\n\t
"
/* syscall number */
"ubfx x21, x8, #12, #2
\n\t
"
/* syscall table number */
"
adr x16, "
__ASM_NAME
(
"KeServiceDescriptorTable"
)
"
\n\t
"
"
ldr x16, [x18, #0x2f8]
\n\t
"
/* arm64_thread_data()->syscall_table */
"add x21, x16, x21, lsl #5
\n\t
"
"ldr x16, [x21, #16]
\n\t
"
/* table->ServiceLimit */
"cmp x20, x16
\n\t
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment