| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove unnecessary check in API MmIsBufferOutsideMmValid of
StandaloneMmMemLib.
The API is used to check if a input buffer is outside MMRAM and
inside a valid non-MMRAM range. Previously, the API only checks
if the input buffer is
overlapped with MMRAM range. In the last
commit, we add logic to check if the input buffer is inside valid
non-MMRAM
ranges reported by the resource HOB. Since the resource
HOB only covers valid non-MMRAM ranges, we doesn't need to check
if the input buffer is inside the MMRAM anymore.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
|
| |
Check if the all the resource HOB in the input HOB list of
MmCore entry only covers non-Mmram ranges. The Resource HOB
is to describe the accessible non-Mmram range. All Resource
HOB should not overlap with any Mmram range.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
| |
Separate a function called InitializeMmHobList() to gather
all the operations related to initializing HOB. It doesn't
change any code logic.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Check if the non-MMRAM buffer is inside valid non-mmram
range in API MmIsBufferOutsideMmValid of StandaloneMmMemLib.
Previously, the API only checks if the input buffer is
overlapped with MMRAM range. Currently, in the new standalone
MM infrastructure, we limit the non-MMRAM access to the ranges
reported by the resource HOB. To meet the new design, in this
API, we cache all the memory ranges reported by the resource
HOB and check if the input buffer is inside valid non-MMRAM
ranges reported by the resource HOB.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
| |
Add a internal header file for StandaloneMmMemLib.
Move some common reference and declaration into
StandaloneMmMemLibInternal.h.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove unneeded check MmIsBufferOutsideMmValid() when
StandaloneMmCore checks if the BS data memory described
by a memory allocation HOB needs to be migrated to Mmram.
Currently, the API MmIsBufferOutsideMmValid() return TRUE
when input memory range belongs to non-Mmram memory. Now
the API will be changed in following 5 commits to return
TRUE when a memory range belongs to non-Mmram memroy and
the memory is inside a range described by resource HOB.
This may cause PF when some SMI handler access the memory
from a memory allocation HOB that is not migrated.
To solve this issue, we can directly remove the check
MmIsBufferOutsideMmValid() and always migrate the BS data
memory described by a memory allocation HOB to Mmram.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Clang compile will optimize undefined behavior (UB)
like a pointer with NULL + size, so it is better to
check the pointer before using it.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
4-level paging supports translating 48-bit linear addresses to 52-bit
physical addresses. Since linear addresses are sign-extended,
the linear-address space of 4-level paging is: [0, 2^47-1] and
[0xffff8000_00000000, 0xffffffff_ffffffff]. So only [0, 2^47-1]
linear-address range maps to the identical physical-address range
when 5-Level paging is disabled.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BFV is outside the MMRAM. Currently, StandaloneMmIplPei uses the API
MmUnblockMemoryRequest() to unblock the access for the BFV. However,
the BFV's memory might be gone after ExitBootService event. If any
access to the memory, unexpected error would happen.
To fix the above issue, StandaloneMmCore should shadow standalone BFV
into MMRAM before processing it, then free the shadowed BFV after MM
driver dispatch is done.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In current implementation of MmCommunication, caller (StandaloneMmIplPei
or MmCommunicationDxe) sets the IsCommBufferValid to TRUE and triggers
synchronous MMI, then caller resets IsCommBufferValid to FLASE after MMI
exits.
If asynchronous MMI happens before caller resets the IsCommBufferValid
to FALSE, StandaloneMmCore will mistakenly thought there is still a
synchronous MMI and then update incorrect values into ReturnStatus and
ReturnBufferSize.
To fix the above issue, StandaloneMmCore should reset IsCommBufferValid
to FALSE before MMI exits.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Makes changes to comply with alerts raised by CodeQL.
Most of the issues here fall into the following two categories:
1. Potential use of uninitialized pointer
2. Inconsistent integer width used in loop comparison
Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com>
|
|
|
|
|
|
|
| |
Remove the old stack check lib now that MdeLibs.inc includes
the new one.
Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As per the emailed RFC in
https://edk2.groups.io/g/devel/topic/rfc_move/107675828,
this patch moves CompilerIntrinsicsLib from ArmPkg to
MdePkg as this library provides compiler intrinsics, which
are industry standard.
This aligns with the goal of integrating ArmPkg into existing
packages: https://bugzilla.tianocore.org/show_bug.cgi?id=4121.
The newly placed CompilerIntrinsicsLib is added to MdeLibs.dsc.inc
as every DSC that builds ARM/AARCH64 needs this library added. The
old location is removed from every DSC in edk2 in this commit also
to not break bisectability with minimal hoop jumping.
Continuous-integration-options: PatchCheck.ignore-multi-package
Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When CPU smm profile feature was enabled, unblocked memory should
not set logging attribute when building resource HOB.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Adds an entry to the package's CI configuration file that enable policy
5 for stuart_pr_eval. With this Policy, all INFs used by the package are
extracted from the provided DSC file and compared against the list of
changed *.inf (INF) files in the PR. If there is a match, stuart_pr_eval
will specify that this package is affected by the PR and needs to be
tested.
Signed-off-by: Joey Vagedes <joey.vagedes@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
X64 arch needs to restart the MM dispatcher once MM entry point is
registered, therefore set PcdRestartMmDispatcherOnceMmEntryRegistered
to TRUE by default for X64 only.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a Memory Allocation Hob with EfiBootServicesData memory type is
reported into MM Hob List and it also has a non-zero GUID name, then the
HOB is used by MM driver and needs to migrate the memory into MMRAM.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The MM memory attribute table is ported from SMM Core.
The new file StandaloneMmPkg/Core/MemoryAttributesTable.c, the new code
in StandaloneMmPkg/Core/Page.c and StandaloneMmPkg/Core/Pool.c are
almost identical to MdeModulePkg/Core/PiSmmCore/MemoryAttributesTable.c,
MdeModulePkg/Core/PiSmmCore/Page.c and
MdeModulePkg/Core/PiSmmCore/Pool.c, but changing the word 'SMM' to 'MM'.
Different from SMM Core, Standalone MM Core produces MM MemoryAttributes
table at the end of MmDriverDispatchHandler() when all the drivers are
dispatched, rather than at the MmEndOfDxe event.
Then the MM CPU driver will consumes the table to set memory attribute
in page table.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
When the EndOfPei event is signaled, installs the MM EndOfPei Protocol
so MM Drivers are informed that EndOfPei event is signaled.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add the support using gEfiSmmSmramMemoryGuid to get MMRAM ranges.
If gEfiSmmSmramMemoryGuid HOB is not found, then try to get MMRAM ranges
from gEfiMmPeiMmramMemoryReserveGuid HOB.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Defer the dispatch of the remaining MM drivers once the CPU driver has
been dispatched.
In MmDispatcher, return immediately if the MM Entry Point was registered.
Then the MM IPL will reinvoke the MM Core Dispatcher. This is required
so MM Mode may be enabled as soon as all the dependent MM Drivers for MM
Mode have been dispatched.
Introduce a FeatureFlag PCD to control if MmDispatcher returns or not
when MmEntryPointPoint is registered. Default value is FALSE.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
mMmramRanges and mMmramRangeCount are the global variables that are
used to cache the MMRAM Ranges info, but they are not used in MM Core.
Therefore, remove mMmramRanges and mMmramRangeCount.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
MM_CORE_PRIVATE_DATA is not used as shared structures between MM IPL
and MM Core, therefore clean up definition for MM_CORE_PRIVATE_DATA.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
MM_CORE_PRIVATE_DATA is not used as shared structures between MM IPL
and MM Core, therefore clean up the code related to gMmCorePrivate.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
MM_CORE_PRIVATE_DATA is not used as shared structures between MM IPL
and MM Core, therefore clean up the code related to gMmCorePrivate.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
MM_CORE_PRIVATE_DATA is not used as shared structures between MM IPL
and MM Core, therefore clean up the code related to gMmCorePrivate.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Get the MM Communication context from the MM Communication Buffer,
instead of the pointer inside gMmCorePrivate.
In the MmEntryPoint, check IsCommBufferValid from MM_COMM_BUFFER to
decide whether the MMI is Synchronous MMI or Asynchronous MMI. If it
is a Synchronous MMI, MM Core shadows the communication buffer into
a internal copy, then invokes the MMI handlers, lastly copies data
back to the MM Communication Buffer and set the return status.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Switch to MM HobList as soon as MM HostList is initialized to avoid
StandaloneMmCore still using the HobList which is outside of MMRAM.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Retrieves the MM Core image info from Memory Allocation HOB reported
by MM IPL. Then install Loaded Image Protocol for MM Core with the
image info from HOB.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Install Loaded Image Protocol into MM handle database for each MM
driver.
Change EFI_MM_DRIVER_ENTRY structure definition to hold the Loaded
Image Protocol data directly, instead a pointer to the protocol, to
avoid allocating pool for each MM driver.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
StandaloneMmCore should not support dispatching traditional MM
driver which has dependency on UEFI services. Therefore, remove
the related code that supports traditional MM driver.
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If PcdCpuSmmRestrictedMemoryAccess is TRUE, only unblocked memory
Regions are available, if FALSE, all system memory is available.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Create memory allocation and resource HOB for MM profile data
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Create misc HOBs for CPU, it included MM ACPI S3 Enable HOB,
MM CPU sync configuration HOB, CPU SMM base HOB, SMRAM memory HOB,
MP Information2 HOB and ACPI variable HOB
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Create the HobList which included the HOBs Standalone MM foundation needed,
it included communication buffer HOB, StandaloneMm Core module HOB and
StandaloneMm Core FV HOB
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MmIpl will issue a SWSMI by MM communicate to call gEventMmDispatchGuid
handler to dispatch all StandaloneMm drivers
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Install end of PEI notify PPI for issue gEfiMmEndOfPeiProtocol
Handler in MM
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Install MmCommunicationPpi under PEI stage, PEIM could
use this PPI to communicate with MM handler
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
StandaloneMmIplPei will search the MM Core driver in all FV and relocate
it to MM RAM, and enter MM Core entrypoint to run MM Core.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MM communication buffer HOB data is for StandaloneMm Core and
MM communicate DXE driver.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
StandaloneMmIplPei driver entrypoint for adding StandaloneMm
Ipl feature code under PEI stage.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Create the notifications of some protocols and event that
the Standalone Mm requires in MmCommunicationDxe:
gEfiDxeMmReadyToLockProtocolGuid
gEfiEventExitBootServicesGuid
gEfiEventVirtualAddressChangeGuid
gEfiEndOfDxeEventGroupGuid
gEfiEventReadyToBootGuid
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
| |
Install gEfiMmCommunicationProtocolGuid instance in the
MmCommunicationDxe driver.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
| |
Install gEfiMmCommunication2ProtocolGuid in the
MmCommunicationDxe driver.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
|
|
| |
Add a new MmCommunicationDxe driver. The driver is to:
1.Install gEfiMmCommunication2ProtocolGuid
2.Install gEfiMmCommunicationProtocolGuid
3.Create the notifications of some protocols and event that
the Standalone Mm requires
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
| |
Create null instance MmPlatformHobProducerLibNull.inf for
MmPlatformHobProducerLib.
Signed-off-by: Dun Tan <dun.tan@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
StandaloneMmPkg need to use header file defined under UefiCpuPkg
to support StandaloneMm features.
Signed-off-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Dun Tan <dun.tan@intel.com>
Cc: Yuanhao Xie <yuanhao.xie@intel.com>
Acked-by: Jiaxin Wu <jiaxin.wu@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MmIpl shall use gEventMmDispatchGuid to initialize
EFI_MM_COMMUNICATE_HEADER structure, and then communicate with MmCore
to dispatch all StandaloneMm drivers in SMM environment.
Signed-off-by: Jiaxin Wu <jiaxin.wu@intel.com>
Co-authored-by: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Co-Authored-by: Ray Ni <ray.ni@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Star Zeng <star.zeng@intel.com>
Co-Authored-by: Wei6 Xu <wei6.xu@intel.com>
Cc: Dun Tan <dun.tan@intel.com>
Cc: Yuanhao Xie <yuanhao.xie@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CreateMmPlatformHob() is defined in the MmPlatformHobProducerLib
library class. The function is for StandaloneMm IPL to create all
Platform specific HOBs that required by the Standalone MM env.
Signed-off-by: Dun Tan <dun.tan@intel.com>
Co-authored-by: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Co-authored-by: Ray Ni <ray.ni@intel.com>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Yuanhao Xie <yuanhao.xie@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Sami Mujawar <sami.mujawar@arm.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Hongbin1 Zhang <hongbin1.zhang@intel.com>
Cc: Wei6 Xu <wei6.xu@intel.com>
Cc: Dun Tan <dun.tan@intel.com>
Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
|