mirror of
https://gitlab.com/qemu-project/edk2.git
synced 2025-10-30 07:56:39 +08:00
PrmPkg: Set DXE_RUNTIME_DRIVER section alignment
Since PRM modules are DXE_RUNTIME_DRIVER images, this change sets the linker flags to the expected section alignment values for runtime code images. This serves as an example for platforms but also results in PRM sample modules in the package having correct section alignment. Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com>
This commit is contained in:
committed by
mergify[bot]
parent
baf0ae3b1d
commit
da44b3b24a
@ -149,3 +149,20 @@
|
||||
[BuildOptions]
|
||||
# Force deprecated interfaces off
|
||||
*_*_*_CC_FLAGS = -D DISABLE_NEW_DEPRECATED_INTERFACES
|
||||
|
||||
#
|
||||
# PRM Modules are DXE_RUNTIME_DRIVER modules. Platforms that build PRM Modules should
|
||||
# ensure sections are page aligned to 4K for X64 and 64K for AARCH64 so paging protections
|
||||
# can be applied to the memory ranges.
|
||||
#
|
||||
[BuildOptions.common.EDKII.DXE_RUNTIME_DRIVER]
|
||||
MSFT:*_*_*_DLINK_FLAGS = /ALIGN:4096
|
||||
CLANGPDB:*_*_*_DLINK_FLAGS = /ALIGN:4096
|
||||
XCODE:*_*_*_DLINK_FLAGS = -seg1addr 0x1000 -segalign 0x1000
|
||||
XCODE:*_*_*_MTOC_FLAGS = -align 0x1000
|
||||
|
||||
[BuildOptions.X64.EDKII.DXE_RUNTIME_DRIVER]
|
||||
GCC:*_*_*_DLINK_FLAGS = -z common-page-size=0x1000
|
||||
|
||||
[BuildOptions.AARCH64.EDKII.DXE_RUNTIME_DRIVER]
|
||||
GCC:*_*_*_DLINK_FLAGS = -z common-page-size=0x10000
|
||||
|
||||
Reference in New Issue
Block a user