-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Mikhail Krichanov
committed
Jan 19, 2024
1 parent
cff574f
commit 549c489
Showing
10 changed files
with
134 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
MdePkg/Library/Ring3UefiBootServicesTableLib/X64/SysCall.nasm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
;------------------------------------------------------------------------------ | ||
; Copyright (c) 2024, Mikhail Krichanov. All rights reserved. | ||
; SPDX-License-Identifier: BSD-3-Clause | ||
;------------------------------------------------------------------------------ | ||
|
||
DEFAULT REL | ||
SECTION .text | ||
|
||
; extern ASM_PFX(mCoreBS) | ||
|
||
;------------------------------------------------------------------------------ | ||
; UINTN | ||
; EFIAPI | ||
; SysCall ( | ||
; IN UINTN Address | ||
; ); | ||
;------------------------------------------------------------------------------ | ||
global ASM_PFX(SysCall) | ||
ASM_PFX(SysCall): | ||
mov rdx, rcx | ||
|
||
; SYSCALL saves RFLAGS into R11 and the RIP of the next instruction into RCX. | ||
syscall | ||
|
||
; SYSRET copies the value in RCX into RIP and loads RFLAGS from R11. | ||
ret |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters