summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2024-09-03MdePkg: Fix a buffer overread.John Baldwin1-1/+2
DevPathToTextUsbWWID allocates a separate copy of the SerialNumber string to append a null terminator if the original string is not null terminated. However, by using AllocateCopyPool, it tries to copy 'Length + 1' words from the existing string containing 'Length' characters into the target string. Split the copy out to only copy 'Length' characters instead. This was reported by GCC's -Wstringop-overread when compiling a copy of this routine included in a library on FreeBSD. Signed-off-by: John Baldwin <jhb@FreeBSD.org>
2024-09-03pip-requirements.txt: Bump versions of several packages and fix URLRebecca Cran1-6/+6
edk2-basetools was depending on old versions of several packages. That was fixed in version 0.1.53. Update pip-requirements.txt to use that version, and bump the versions and dependency expressions of other packages to use or allow use of newer versions. Also, update the URL to the requirements file format since it's moved. Signed-off-by: Rebecca Cran <rebecca@bsdio.com>
2024-09-03FatPkg/EnhancedFatDxe: Downgrade debug level for no media foundNhi Pham1-1/+1
It is normal for a disk to not have FAT file system (known as No Media), therefore, it should not produce a "failed" entry in the boot console. This aims to lower the debug level to verbose. Signed-off-by: Nhi Pham <nhi@os.amperecomputing.com>
2024-09-03UefiPayloadPkg/UefiPayloadPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03UefiCpuPkg/UefiCpuPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03StandaloneMmPkg/StandaloneMmPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03SourceLevelDebugPkg/SourceLevelDebugPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03SignedCapsulePkg/SignedCapsulePkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03ShellPkg/ShellPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03SecurityPkg/SecurityPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03PcAtChipsetPkg/PcAtChipsetPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03NetworkPkg/NetworkPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03EmulatorPkg/EmulatorPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03ArmPlatformPkg/ArmPlatformPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03ArmPkg/ArmPkg.ci.yaml: Add PrEval CI configJoey Vagedes1-0/+3
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>
2024-09-03NetworkPkg/SnpDxe: return error for unsupported parameterNickle Wang1-3/+6
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4729 From SCT testing report, Reset() does not support the case when ExtendedVerification is set to FALSE. So, we should return EFI_INVALID_PARAMETER in this case. For details, please refer to Bug 4729. Signed-off-by: Nickle Wang <nicklew@nvidia.com>
2024-09-03NetworkPkg: DxeHttpLib: Use HTTP error 429Ken Lautner2-0/+8
Include a mapping for HTTP error 429 to return the correct status code. Additionally include a link to the official HTTP status codes in the HttpMappingToStatusCode function header. Signed-off-by: Kenneth Lautner <kenlautner3@gmail.com>
2024-09-03MdePkg: Add HTTP error 429Ken Lautner1-1/+2
Add support for HTTP error 429 in the protocol .h file. Signed-off-by: Kenneth Lautner <kenlautner3@gmail.com>
2024-09-02MdeModulePkg: Enable VarCheckHiiLibStandaloneMm.xieyuanh1-0/+2
Enable VarCheckHiiLibStandaloneMm. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Add VarCheckHiiLibStandaloneMm.xieyuanh3-0/+214
This library is designed for handling variable HII checks within the Standalone MMm environment. It includes the functions dedicated to registering handlers that process information received from VarCheckHiiLibMmDependency. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Move DUMP_VAR_CHECK_HII in common filexieyuanh2-251/+251
No functional changes. Move DUMP_VAR_CHECK_HII in common file Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Relocate VarCheckHiiInternalDumpHex, VarCheckHiiQuestionxieyuanh2-250/+245
Move VarCheckHiiInternalDumpHex and VarCheckHiiQuestion to the common file. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Wrap SetVariableCheckHandlerHii as a common APIxieyuanh4-78/+158
Rename SetVariableCheckHandlerHii and wrap it as a common API to facilitate the usage in the following patches. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Rename VarCheckHiiLibNullClass as VarCheckHiiLib.xieyuanh2-4/+4
No functional changes. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Modified BuildVarCheckHiiBin parameter to IN OUT.xieyuanh1-1/+1
Change the Size parameter of BuildVarCheckHiiBin from OUT to an input-output parameter. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Enable VarCheckHiiLibMmDependencyxieyuanh1-1/+3
Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Jiaxin Wu <jiaxin.wu@intel.com> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Add VarCheckHiiLibMmDependency library.xieyuanh4-0/+199
VarCheckHiiLibMmDependency retrieve data (mVarCheckHiiBin) at the end of the DXE phase, and pass the acquired data to the VarCheckHiiLibStandaloneMm through a communication protocol. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02MdeModulePkg: Relocation of mVarCheckHiiBin declarationxieyuanh4-11/+9
Relocate the declaration of mVarCheckHiiBin to support for standalone MM modules utilizing the same mVarCheckHiiBin. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.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> Cc: Dandan Bi <dandan.bi@intel.com> Signed-off-by: Yuanhao Xie <yuanhao.xie@intel.com>
2024-09-02DynamicTablesPkg: Adds generic ACPI Creator IDAbdul Lateef Attar14-14/+19
Adds generic creator id as DYNT. Updates the common ACPI tables with generic CreatorId. Cc: Sami Mujawar <Sami.Mujawar@arm.com> Cc: Pierre Gondois <pierre.gondois@arm.com> Signed-off-by: Abdul Lateef Attar <AbdulLateef.Attar@amd.com>
2024-09-02DynamicTablesPkg: Adds WSMT generator for X64Abdul Lateef Attar7-2/+353
Adds ACPI WSMT table generator library. Updates acpi standard table enum with wsmt. Updates X64 namespace object. Updates the object parser. Updates the Readme. Cc: Sami Mujawar <Sami.Mujawar@arm.com> Cc: Pierre Gondois <pierre.gondois@arm.com> Signed-off-by: Abdul Lateef Attar <AbdulLateef.Attar@amd.com>
2024-09-02SecurityPkg: Fix break missing at TPM_ALG_KEYEDHASH casezodf00559801-0/+1
According issue #5509, case TPM_ALG_KEYEDHASH is missing the break statement. Signed-off-by: zodf0055980 <zodf0055980@gmail.com>
2024-09-02BaseTools: GenMake: FIx missing logs from GenMake.pyKen Lautner1-0/+1
EdkLogger logs were not showing up as part of the build log output. Adding the EdkLogger import to GenMake.py fixes the missing log prints. Signed-off-by: Kenneth Lautner <kenlautner3@gmail.com>
2024-09-02MdeModulePkg/VariableStandaloneMm: Notify variable write ready in MMWei6 Xu2-0/+14
In Standalone MM, there is no notification to MM drivers that variable write is ready. Install gSmmVariableWriteGuid into MM handle database for the notification. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Wei6 Xu <wei6.xu@intel.com>
2024-09-01ArmPkg: Fix timer wrap-aroundCarsten Haitzler1-4/+10
The timer counter register can wrap around and when this happens, we'll get misbehavior for any MicroSecondDelay() calls. This adds handling for that. Signed-off-by: Carsten Haitzler <carsten.haitzler@foss.arm.com>
2024-08-31MdePkg: Add Reset Reason definitionsSaloni Kasbekar1-0/+48
Add Reset Reason definitions defined in ACPI 6.5 Signed-off-by: Saloni Kasbekar <saloni.kasbekar@intel.com>
2024-08-31SecurityPkg: Fix exponent unmarshaled as 16 bitszodf00559801-1/+1
According issue #5536, exponent is 32 bits but is unmarshaled as 16 bits. Signed-off-by: zodf0055980 <zodf0055980@gmail.com>
2024-08-31SecurityPkg: Measure Invoke EBS even in failure caseMatthew Carlson1-0/+11
This patch measures the ExitBootServices invocation to the TPM even in the case of ExitBootServices failing, per TCG PC Client Platform Firmware Profile Version 1.06 Revision 52 Family 2.0 section 8.2.4(i). Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com>
2024-08-31MdePkg: Remove duplicate source from BaseMemoryLib INF filesAshraf Ali5-116/+13
Signed-off-by: Ashraf Ali <ashraf.ali.s@intel.com>
2024-08-31BaseTools: Trim: Add header/footer for ASL includeJoey Vagedes1-5/+28
When including one ASL file in another, add a header / footer to the included file to easily tell where the included file starts and ends. Signed-off-by: Joey Vagedes <joey.vagedes@gmail.com>
2024-08-31CryptoPkg/BaseCryptLibMbedTls: Fix uninitialized variable errorsArd Biesheuvel2-8/+8
Clang complains about a couple of variables potentially being uninitialized, and those complaints seem to be valid. Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
2024-08-31CryptoPkg/OpensslLib CLANGDWARF: Use gnu99 C dialect for asm() supportArd Biesheuvel2-2/+2
'asm' is not a keyword in C99, but GCC supports it nonetheless as a GNU extension. So when using Clang, we must specify the gnu99 dialect explicitly, or inline asm blocks using asm() rather than __asm__() will be rejected by the compiler. Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
2024-08-31OvmfPkg: Move kernel hashes section to endDionna Glaze1-5/+6
When launching a SEV-SNP VM, the ROM is not all that must be measured. The OvmfSevMetadata sections describe ranges of memory that must be measured with different types than PAGE_TYPE_NORMAL, except one. The SevSnpKernelHashes page is also PAGE_TYPE_NORMAL, but is populated by the VMM from configuration data that is separate from the OVMF build itself. To more compactly provide reference values for the measurement of the firmware separately from the kernel hashes, it's advantageous to measure as much known information as possible first. Whereas VMMs are permitted to measure these sections in any order they prefer, the normative order of how they appear in the .fd is easiest to follow. This change is semantics-preserving. Measurement calculation tools that do not follow the normative ordering would need updating to accommodate, but I don't know of any. The accounting for EC2 moving the CPUID page to the end of measurement would be unchanged. This change is to improve performance of a proposed launch update event log to separate responsibility for initially measured data before VM launch, application/vnd.amd.sevsnp.launch-updates+cbor: https://github.com/deeglaze/draft-deeglaze-amd-sev-snp-corim-profile Signed-off-by: Dionna Glaze <dionnaglaze@google.com>
2024-08-31Sync AARCH64 GCD Capabilities with Page TableOliver Smith-Denny1-6/+49
On AARCH64 systems, the GCD is not fully synced with the page table. On x86 systems, the GCD is synced by adding `EFI_MEMORY_RO`, `EFI_MEMORY_RP`, and `EFI_MEMORY_XP` to the current capabilities of the GCD, then the page table attributes are set on the GCD attributes. However, on AARCH64, the GCD capabilities do not get updated, instead only the attributes from the page table are masked by the existing GCD capabilities, which means that any new page table attribute which are already set are dropped and the GCD does not reflect the state of the system. This has been seen to cause issues where memory in the page table that was marked `EFI_MEMORY_XP` had an additional attribute set using the GCD capabilities, which did not include `EFI_MEMORY_XP`, this caused the page table to be updated to lose `EFI_MEMORY_XP`, which is a potential security issue. The existing behavior on AARCH64 systems is an implementation error, it assumes one of two things: - The page table attributes must be a subset of the GCD capabilities - The GCD does not need to have its capabilities synced to what the page table attributes are The first is incorrect as important attributes such as `EFI_MEMORY_XP` do not get applied to the GCD capabilities by default and therefore must be synced back. This comment from ArmPkg's CpuDxe driver helps explain: ```c // The GCD implementation maintains its own copy of the state of memory // space attributes. GCD needs to know what the initial memory space // attributes are. The CPU Arch. Protocol does not provide a // GetMemoryAttributes function for GCD to get this so we must resort to // calling GCD (as if we were a client) to update its copy of the // attributes. This is bad architecture and should be replaced with a // way for GCD to query the CPU Arch. driver of the existing memory // space attributes instead. ``` However, this comment misses that updating the capabilities is critical to updating the attributes. The second is incorrect because significant pieces of core code reference the GCD attributes instead of the page table attributes. For example, NonDiscoverablePciDeviceDxe uses the GCD capabilities and attributes when interacting with a non-discoverable PCI device. When the GCD is not synced to the page table, we get the errors and security concerns listed above. Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com>
2024-08-31OvmfPkg/PlatformInitLib: allow switching to 4-level pagingGerd Hoffmann3-0/+185
There are a number of mostly older guests such as RHEL-7 which do not support 5-level paging. This patch adds support for switching from 5-level paging mode back to 4-level paging mode. This is done in PEI, after inspecting the address space needed (installed memory and reservations configured via fw_cfg). By default small guests (which need less than 1 TB) will use 4-level paging mode. There is a fw_cfg override though, so it is possible to force the one or the other this way: qemu-system-x86_64 -fw_cfg name=opt/org.tianocode/PagingLevel,string=5 Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2024-08-30MdePkg: Remove the old name of LoongArch CSR 0x20Chao Li1-1/+0
Since all places where the old name was used for the LoongArch CSR 0x20 regiser have been changed to the new name, the old name is removed. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Zhiguang Liu <zhiguang.liu@intel.com> Signed-off-by: Chao Li <lichao@loongson.cn>
2024-08-30OvmfPkg: Using the new name of LoongArch CSR 0x20 registerChao Li1-1/+1
Since the LoongArch SPEC has adjusted the CSR 0x20 register name and the MdePkg also added the new name, so enable it in OvmfPkg. Cc: Ard Biesheuvel <ardb+tianocore@kernel.org> Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Chao Li <lichao@loongson.cn>
2024-08-30UefiCpuPkg: Using the new name of LoongArch CSR 0x20 registerChao Li2-2/+2
Since the LoongArch SPEC has adjusted the CSR 0x20 register name and the MdePkg also added the new name, so enable it in UefiCpuPkg. Cc: Ray Ni <ray.ni@intel.com> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Jiaxin Wu <jiaxin.wu@intel.com> Signed-off-by: Chao Li <lichao@loongson.cn>
2024-08-30MdePkg: Rename the LoongArch CSR 0x20 registerChao Li2-12/+13
Added a new name for CSR 0x20 because LoongArch SPEC has adjustd the CSR 0x20 register name. Ref: LoongArch Reference Manual Vol 1, Seciton 7.1. https://loongson.github.io/LoongArch-Documentation/LoongArch-Vol1-EN.html#control-and-status-registers Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Zhiguang Liu <zhiguang.liu@intel.com> Signed-off-by: Chao Li <lichao@loongson.cn>
2024-08-30StandaloneMmPkg: Restart dispatcher once MM entry is registered for X64Wei6 Xu1-0/+7
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>
2024-08-30OvmfPkg/OvmfXen: Introduce Xen's ResetSystemLib, to use xen hypercallAnthony PERARD5-5/+234
When booting OvmfXen, the ACPI interface for shutdown/reset might not be available, instead use the hypercall interface. While it's probably possible to use the hypercall in all cases, we keep using the same interface while it still possible. That is ACPI on HVM guest, and fallback to hypercall on PVH guest. Signed-off-by: Anthony PERARD <anthony.perard@citrix.com> Signed-off-by: Jason Andryuk <jason.andryuk@amd.com>