Re: [edk2-devel] [PATCH v2 1/1] MdePkg/BaseLib: Add SpeculationBarrier implementation for RiscV64

2023-06-02 Thread Li, Yong
Hi Michael This is the change to MdePkg/Library/BaseLib/RiscV64. Since it is for RiscV specific, I somehow got the review from Sunil. Not sure need additional reviewer and or anything else from my side ? It is my first patch to edk2, please help proceed and look for the feedback. Thanks On 20

Re: [edk2-devel] failed pr

2023-06-02 Thread Michael D Kinney
Merged Mike > -Original Message- > From: Ard Biesheuvel > Sent: Friday, June 2, 2023 4:39 PM > To: devel@edk2.groups.io; Kinney, Michael D > Cc: Michael Kubacki ; Sean Brogan > > Subject: Re: [edk2-devel] failed pr > > Another one > > https://github.com/tianocore/edk2/pull/4473 > >

Re: [edk2-devel] [PATCH v2] OvmfPkg: Create additional PML1 entries for large SEV-SNP VMs

2023-06-02 Thread Lendacky, Thomas via groups.io
On 6/2/23 17:49, Ard Biesheuvel wrote: On Fri, 2 Jun 2023 at 23:20, Lendacky, Thomas via groups.io wrote: On 1/26/23 14:26, Mikolaj Lisik wrote: Edk2 was failing, rather than creating more PML4 entries, when they weren't present in the initial memory acceptance flow. Because of that VMs with

Re: [edk2-devel] failed pr

2023-06-02 Thread Ard Biesheuvel
Another one https://github.com/tianocore/edk2/pull/4473 On Sat, 3 Jun 2023 at 00:32, Ard Biesheuvel wrote: > > Thanks! > > On Fri, 2 Jun 2023 at 18:38, Michael D Kinney > wrote: > > > > Done. > > > > Mike > > > > > -Original Message- > > > From: Kinney, Michael D > > > Sent: Friday, Ju

Re: [edk2-devel] [PATCH v2] OvmfPkg: Create additional PML1 entries for large SEV-SNP VMs

2023-06-02 Thread Ard Biesheuvel
On Sat, 3 Jun 2023 at 00:49, Ard Biesheuvel wrote: > > On Fri, 2 Jun 2023 at 23:20, Lendacky, Thomas via groups.io > wrote: > > > > On 1/26/23 14:26, Mikolaj Lisik wrote: > > > Edk2 was failing, rather than creating more PML4 entries, when they > > > weren't present in the initial memory acceptan

Re: [edk2-devel] [PATCH v2] OvmfPkg: Create additional PML1 entries for large SEV-SNP VMs

2023-06-02 Thread Ard Biesheuvel
On Fri, 2 Jun 2023 at 23:20, Lendacky, Thomas via groups.io wrote: > > On 1/26/23 14:26, Mikolaj Lisik wrote: > > Edk2 was failing, rather than creating more PML4 entries, when they > > weren't present in the initial memory acceptance flow. Because of that > > VMs with more than 512G memory were c

Re: [edk2-devel] failed pr

2023-06-02 Thread Ard Biesheuvel
Thanks! On Fri, 2 Jun 2023 at 18:38, Michael D Kinney wrote: > > Done. > > Mike > > > -Original Message- > > From: Kinney, Michael D > > Sent: Friday, June 2, 2023 9:37 AM > > To: devel@edk2.groups.io; a...@kernel.org; Michael Kubacki > > ; Sean Brogan > > Cc: Kinney, Michael D > > Sub

Re: [edk2-devel] [PATCH v2] OvmfPkg: Create additional PML1 entries for large SEV-SNP VMs

2023-06-02 Thread Lendacky, Thomas via groups.io
On 1/26/23 14:26, Mikolaj Lisik wrote: Edk2 was failing, rather than creating more PML4 entries, when they weren't present in the initial memory acceptance flow. Because of that VMs with more than 512G memory were crashing. This code fixes that. This change affects only SEV-SNP VMs. The code wa

Re: [edk2-devel][PATCH v1 1/1] CharEncodingCheckPlugin: Remove Noisy Print

2023-06-02 Thread Michael D Kinney
Reviewed-by: Michael D Kinney > -Original Message- > From: Oliver Smith-Denny > Sent: Friday, June 2, 2023 1:45 PM > To: devel@edk2.groups.io > Cc: Sean Brogan ; Michael Kubacki > ; Kinney, Michael D > ; Gao, Liming > Subject: [edk2-devel][PATCH v1 1/1] CharEncodingCheckPlugin: Remove

Re: [edk2-devel] [PATCH] MdeModulePkg: Fix port multiplier port in AhciPei PEIM

2023-06-02 Thread Hsueh, Hong-Chih (Neo) via groups.io
[AMD Official Use Only - General] Hi Abner, Thank you for your feedback. I updated the commit and re-create the PR as below: https://github.com/tianocore/edk2/pull/4471 Regards, Neo From: Chang, Abner Sent: Friday, June 2, 2023 11:31 AM To: Hsueh, Hong-Chih (Ne

[edk2-devel] [PATCH 1/1] MdeModulePkg/Bus/Ata/AtaBusDxe: Fix SIGN_EXTENSION Coverity issue

2023-06-02 Thread Ranbir Singh
From: Ranbir Singh Line number 365 does contain a typecast with UINT32, but it is after all the operations (16-bit left shift followed by OR'ing) are over. To avoid any SIGN_EXTENSION, typecast the intermediate result after 16-bit left shift operation immediately with UINT32. Cc: Hao A Wu Cc: R

Re: [edk2-devel] [PATCH] MdeModulePkg: Fix port multiplier port in AhciPei PEIM

2023-06-02 Thread Hsueh, Hong-Chih (Neo) via groups.io
[AMD Official Use Only - General] Hi Hao, Thank you for your review. I already created a pull request for this commit, may I know how to proceed to merge it into master? https://github.com/tianocore/edk2/pull/4424 Regards, Neo From: Wu, Hao A Sent: Thursday,

[edk2-devel] [PATCH 2/2] MdeModulePkg/Bus/Ata/AtaAtapiPassThru: Fix UNUSED_VALUE Coverity issue

2023-06-02 Thread Ranbir Singh
From: Ranbir Singh The return value stored in Status after call to SetDriveParameters is not made of any use thereafter and hence it remains as UNUSED. Assuming, this non-usage is deliberate, the storage in Status can be done away with. Cc: Hao A Wu Cc: Ray Ni REF: https://bugzilla.tianocore.o

[edk2-devel] [PATCH 1/2] MdeModulePkg/Bus/Ata/AtaAtapiPassThru: Fix SIGN_EXTENSION Coverity issue

2023-06-02 Thread Ranbir Singh
From: Ranbir Singh Line number 1348 does contain a typecast with UINT32, but it is after all the operations (16-bit left shift followed by OR'ing) are over. To avoid any SIGN_EXTENSION, typecast the intermediate result after 16-bit left shift operation immediately with UINT32. Cc: Hao A Wu Cc:

Re: [edk2-devel] [PATCH v2] MdePkg ACPI65: Update MADT Revision pre ACPI Spec 6.5

2023-06-02 Thread Michael D Kinney
Reviewed-by: Michael D Kinney > -Original Message- > From: Chen, Aryeh > Sent: Thursday, June 1, 2023 4:56 AM > To: devel@edk2.groups.io > Cc: Chen, Aryeh ; Kinney, Michael D > ; Gao, Liming ; Liu, > Zhiguang ; Yao, Jiewen > Subject: [PATCH v2] MdePkg ACPI65: Update MADT Revision pre

Re: [edk2-devel] [PATCH v2 1/1] MdePkg/BaseLib: Add SpeculationBarrier implementation for RiscV64

2023-06-02 Thread Sunil V L
On Thu, Jun 01, 2023 at 06:56:05PM +0800, Yong Li wrote: > Implement the SpeculationBarrier with implementations consisting of > fence instruction which provides finer-grain memory orderings. > Perform Data Barrier in RiscV: fence rw,rw > Perform Instruction Barrier in RiscV: fence.i; fence r,r > M

[edk2-devel] [PATCH 1/1] BaseTools/tools_def: Add "-fno-unwind-tables" to GCC5_RISCV64_CC_FLAGS

2023-06-02 Thread Sunil V L
gcc-13 for RISC-V enables unwind tables by default similar to ARM64. This generates .eh_frame_hdr section which is not handled well by GenFw causing failures. Disable the unwind tables by adding -fno-unwind-tables flag similar to [1]. [1] - https://github.com/tianocore/edk2/commit/cbf00651eda6 S

Re: [edk2-devel] [RFC PATCH] ArmPkg: Enable AuditMode for Uncrustify CI checks

2023-06-02 Thread Michael Kubacki
On 6/2/2023 11:50 AM, Ard Biesheuvel wrote: On Fri, 2 Jun 2023 at 17:26, Michael Kubacki wrote: Are there particular areas that could be improved to make it more usable for you? I'm trying to find actionable improvements that can be made, if any. I know it's not perfect but developers can run

Re: [edk2-devel] failed pr

2023-06-02 Thread Michael D Kinney
Done. Mike > -Original Message- > From: Kinney, Michael D > Sent: Friday, June 2, 2023 9:37 AM > To: devel@edk2.groups.io; a...@kernel.org; Michael Kubacki > ; Sean Brogan > Cc: Kinney, Michael D > Subject: RE: [edk2-devel] failed pr > > I am working on it. > > Mike > > > -Origi

Re: [edk2-devel] failed pr

2023-06-02 Thread Michael D Kinney
I am working on it. Mike > -Original Message- > From: devel@edk2.groups.io On Behalf Of Ard > Biesheuvel > Sent: Friday, June 2, 2023 9:19 AM > To: Kinney, Michael D ; Michael Kubacki > ; Sean Brogan ; > edk2-devel-groups-io > Subject: [edk2-devel] failed pr > > Could someone push the

Re: [edk2-devel] [PATCH] MdeModulePkg: Fix port multiplier port in AhciPei PEIM

2023-06-02 Thread Chang, Abner via groups.io
[AMD Official Use Only - General] Hi Leo, Please add Hao's RB in the commit message below your signed-off-by, thus we know this patch has been reviewed. I also suggest to update your commit subject to "MdeModulePkg/Bus: Fix port multiplier port in AhciPei PEIM". Please resend the PR with above

[edk2-devel] failed pr

2023-06-02 Thread Ard Biesheuvel
Could someone push the merge button on this pr please? https://github.com/tianocore/edk2/pull/4470 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#105661): https://edk2.groups.io/g/devel/message/105661 Mute This Topic: https://groups.io/m

Re: [edk2-devel] [RFC PATCH] ArmPkg: Enable AuditMode for Uncrustify CI checks

2023-06-02 Thread Ard Biesheuvel
On Fri, 2 Jun 2023 at 17:26, Michael Kubacki wrote: > > Are there particular areas that could be improved to make it more usable > for you? I'm trying to find actionable improvements that can be made, if > any. > > I know it's not perfect but developers can run it with a single keyboard > shortcut

[edk2-devel] [PATCH v2 7/7] ArmPkg/CpuDxe: Simplify memory attributes protocol implementation

2023-06-02 Thread Ard Biesheuvel
Now that ArmSetMemoryAttributes() permits a mask to be provided, we can simplify the implementation the UEFI memory attribute protocol substantially, and just pass on the requested mask to be set or cleared directly. Signed-off-by: Ard Biesheuvel --- ArmPkg/Drivers/CpuDxe/MemoryAttribute.c | 50

[edk2-devel] [PATCH v2 6/7] MdeModulePkg/DxeIpl ARM AARCH64: Switch to generic handoff code

2023-06-02 Thread Ard Biesheuvel
Now that we have a generic method to manage memory permissions using a PPI, we can switch to the generic version of the DXE handoff code in DxeIpl, and drop the ARM specific version. Signed-off-by: Ard Biesheuvel --- MdeModulePkg/Core/DxeIplPeim/Arm/DxeLoadFunc.c | 71 MdeMo

[edk2-devel] [PATCH v2 5/7] ArmPkg/CpuPei: Implement the memory attributes PPI

2023-06-02 Thread Ard Biesheuvel
Implement the newly defined PPI that permits the PEI core and DXE IPL to manage memory permissions on ranges of DRAM, for doing things like mapping the stack non-executable, or granting executable permissions to shadowed PEIMs. Signed-off-by: Ard Biesheuvel --- ArmPkg/Drivers/CpuPei/CpuPei.c |

[edk2-devel] [PATCH v2 4/7] ArmPkg/ArmMmuLib: Extend API to manage memory permissions better

2023-06-02 Thread Ard Biesheuvel
Currently, ArmSetMemoryAttributes () takes a combination of EFI_MEMORY_xx constants describing the memory type and permission attributes that should be set on a region of memory. In cases where the memory type is omitted, we assume that the memory permissions being set are final, and that existing

[edk2-devel] [PATCH v2 3/7] MdeModulePkg/DxeIpl: Use memory attribute PPI to remap the stack NX

2023-06-02 Thread Ard Biesheuvel
If the associated PCD is set to TRUE, use the memory attribute PPI to remap the stack non-executable. This provides a generic method for doing so, which will be used by ARM and AArch64 as well once they move to the generic DxeIpl handoff implementation. Signed-off-by: Ard Biesheuvel --- MdeModul

[edk2-devel] [PATCH v2 2/7] MdeModulePkg/DxeIpl: Merge EBC, RISCV64 and LOONGARCH code

2023-06-02 Thread Ard Biesheuvel
The Risc-V and LoongArch specific versions of the DXE core handoff code in DxeIpl are essentially copies of the EBC version (modulo the copyright in the header and some debug prints in the code). In preparation for introducing a generic PPI based method to implement the non-executable stack, let's

[edk2-devel] [PATCH v2 1/7] MdeModulePkg: Define memory attribute PPI

2023-06-02 Thread Ard Biesheuvel
Define a PPI interface that may be used by the PEI core or other PEIMs to manage permissions on memory ranges. This is primarily intended for restricting permissions to what is actually needed for correct execution by the code in question, and for limiting the use of memory mappings that are both w

[edk2-devel] [PATCH v2 0/7] Add PPI to manage PEI phase memory attributes

2023-06-02 Thread Ard Biesheuvel
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4468 This is a followup to the RFC that I sent to the edk2-devel list on the 25th of May. In an attempt to make some incremental progress, this v2 only covers the NX remapping of the DXE stack in DxeIpl, using the newly introduced memory attribu

Re: [edk2-devel] [PATCH 01/22] CryptoPkg/openssl: update submodule to openssl-3.0.8

2023-06-02 Thread Yao, Jiewen
Thanks Ard. That is good news. We may try the patch to see if that will break X86. Current blocking issue seems IA32 intrinsic and OVMF size. I am not sure if Gerd has any idea on that. Thank you Yao, Jiewen > -Original Message- > From: Ard Biesheuvel > Sent: Friday, June 2, 2023 5:15

Re: [edk2-devel] [edk2-platforms][PATCH 0/4] Add support new SMBIOS Tables and refactor to adapt with ArmPkg/SMBIOS

2023-06-02 Thread Ard Biesheuvel
On Wed, 24 May 2023 at 02:41, Minh Nguyen wrote: > > These patches helps to add new SMBIOS Tables (Type 16, 17, 19) and refactor > SmbiosPlatformDxe. > > Minh Nguyen (4): > JadePkg: Correct PCD names for SMBIOS Type 0 > JadePkg: Leverage ArmPkg/Smbios (Type 0, 1, 2, 3, 13, 32) > JadePkg: Re

Re: [edk2-devel] [edk2-platforms][PATCH 0/6] Support NVMe Hot Plug feature for Ampere Altra and Ampere Altra Max

2023-06-02 Thread Ard Biesheuvel
On Thu, 11 May 2023 at 10:10, Minh Nguyen wrote: > > These patches support NVMe Hot Plug feature for Ampere Altra and Ampere Altra > Max. > > Minh Nguyen (2): > AmpereAltraPkg: Add Hot Plug Slot Capable during PCIe port > initialization > AmpereAltraPkg: Change PCIe Amba Link Timeout valu

Re: [edk2-devel] [edk2-platforms][PATCH 0/3] Add necessary changes for PCIe core and remove unnecessary checks for PCIe Devmap mode

2023-06-02 Thread Ard Biesheuvel
On Wed, 24 May 2023 at 02:45, Minh Nguyen wrote: > > Hi Leif and Ard > > Could you please help merge this series? > Pushed as 4303f7782c08..a869bae89a6d Thanks, > > On 5/11/2023 2:51 PM, Minh Nguyen wrote: > > These patches help to improve PCIe core for Link training sequence and > > add logi

Re: [edk2-devel] [PATCH v2 1/1] ArmPkg: add SMC defines for SiP service calls

2023-06-02 Thread Leif Lindholm
On Thu, Jun 01, 2023 at 19:14:25 +0200, Marcin Juszkiewicz wrote: > They are useful for those platforms where SMC SiP calls exist. > > Signed-off-by: Marcin Juszkiewicz Thanks, merged as 4354c22f3877. > --- > ArmPkg/Include/IndustryStandard/ArmStdSmc.h | 9 + > 1 file changed, 9 insert

Re: [edk2-devel] [RFC PATCH] ArmPkg: Enable AuditMode for Uncrustify CI checks

2023-06-02 Thread Leif Lindholm
On Fri, Jun 02, 2023 at 10:51:36 +0200, Ard Biesheuvel wrote: > Uncrustify checks are too rigid, making them counter-productive: > > - it leads to code that is arguably harder to parse visually (e.g., > the changes to ArmPkg/Include/Chipset/AArch64Mmu.h in commit > 429309e0c6b74792) > - it for

Re: [edk2-devel] [PATCH v1 1/1] ArmPkg: CpuDxe: Sync GCD Capabilities With Page Table Attributes

2023-06-02 Thread Ard Biesheuvel
On Fri, 2 Jun 2023 at 05:10, Michael Kubacki wrote: > > Sounds good, thanks for the quick response. Can you please send a > calendar invite when you get a chance? > > On 6/1/2023 10:42 PM, Ni, Ray wrote: > > It's a good idea to have a focus area ("project") for everyone working > > together on th

Re: [edk2-devel] [PATCH 01/22] CryptoPkg/openssl: update submodule to openssl-3.0.8

2023-06-02 Thread Ard Biesheuvel
On Fri, 2 Jun 2023 at 04:53, Yao, Jiewen wrote: > > Hi Ard > Would you please take a look at > https://github.com/tianocore/edk2-staging/tree/OpenSSL30, which is our > current working version? If you have any idea, please propose patch. > > Also, could you please try that on ARM/AARCH64 platform

[edk2-devel] [RFC PATCH] ArmPkg: Enable AuditMode for Uncrustify CI checks

2023-06-02 Thread Ard Biesheuvel
Uncrustify checks are too rigid, making them counter-productive: - it leads to code that is arguably harder to parse visually (e.g., the changes to ArmPkg/Include/Chipset/AArch64Mmu.h in commit 429309e0c6b74792) - it forces indentation-only changes to code in the vicinity of actual changes,

Re: [edk2-devel] [Patch V4 10/15] UefiCpuPkg: Add GenSmmPageTable() to create smm page table

2023-06-02 Thread duntan
In original code logic, SmmS3 page table set GuardPage in smm normal stack as not-present instead of Smm S3 Stack. A bugzila has been submitted to track this issue: https://bugzilla.tianocore.org/show_bug.cgi?id=4476 . Will fix the issue in future patches. So now remain the code status that the