[edk2-devel] [PATCH] IntelSiliconPkg/Vtd: Resolve parameter transfer errors

2023-07-12 Thread Sheng Wei
Fix the capsule update assert caused by function call errors. Cc: Ray Ni Cc: Rangasai V Chaganty Cc: Jenny Huang Cc: Robert Kowalewski Signed-off-by: Sheng Wei --- .../Intel/IntelSiliconPkg/Feature/VTd/IntelVTdCoreDxe/VtdReg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[edk2-devel] Event: TianoCore Community Meeting - APAC/NAMO - Thursday, July 13, 2023 #cal-reminder

2023-07-12 Thread Group Notification
*Reminder: TianoCore Community Meeting - APAC/NAMO* *When:* Thursday, July 13, 2023 7:30pm to 8:30pm (UTC-07:00) America/Los Angeles *Where:*

Re: [edk2-devel] [PATCH 00/14] Implement Dynamic Memory Protections

2023-07-12 Thread Taylor Beebe
On 7/12/2023 3:05 AM, Gerd Hoffmann wrote: On Tue, Jul 11, 2023 at 04:52:37PM -0700, Taylor Beebe wrote: In the past, memory protection settings were configured via FixedAtBuild PCDs, which resulted in a build-time configuration of memory mitigations. This approach limited the flexibility of

Re: [edk2-devel] [edk2-platforms][PATCH V1 19/20] ArmPkg/MmCommunicationDxe: Use the FF-A transport for MM requests

2023-07-12 Thread Girish Mahadevan via groups.io
Couple of comments/questions inline (prefixed by [GM]) Thanks Girish On 7/11/2023 8:36 AM, Nishant Sharma via groups.io wrote: External email: Use caution opening links or attachments From: Achin Gupta This patch packages requests for accessing a Standalone MM driver through the MM

Re: [edk2-devel] [edk2-platforms][PATCH V1 18/20] ArmPkg/MmCommunicationDxe: Discover the StMM SP

2023-07-12 Thread Girish Mahadevan via groups.io
A few comments in line. (Prefixed with [GM]) Best Regards Girish On 7/11/2023 8:36 AM, Nishant Sharma via groups.io wrote: External email: Use caution opening links or attachments From: Achin Gupta This patch adds support for discovering the presence of the SP using the

Re: [edk2-devel] heap/page guard broken on aarch64

2023-07-12 Thread Oliver Smith-Denny
On 7/12/2023 6:26 AM, Gerd Hoffmann wrote: On Wed, Jul 12, 2023 at 02:03:37PM +0200, Ard Biesheuvel wrote: On Wed, 12 Jul 2023 at 10:41, Gerd Hoffmann wrote: PcdHeapGuardPageType=0x7e PcdHeapGuardPoolType=0x7e This looks like the debug 'poison' value is applied to the

Re: [edk2-devel] [edk2-platforms][PATCH V1 00/20] Add the support for ARM Firmware First Framework

2023-07-12 Thread Oliver Smith-Denny
Thanks for sending out the patchset! I may be missing it, where is the StMM FF-A partition manifest as part of this? I see where it gets parsed, but not the actual information. My understanding, which may be flawed, is that there should be a separate file defining the StMM manifest. Is that

Re: [edk2-devel] [edk2-platforms][PATCH V1 18/20] ArmPkg/MmCommunicationDxe: Discover the StMM SP

2023-07-12 Thread Oliver Smith-Denny
On 7/11/2023 7:36 AM, Nishant Sharma wrote: From: Achin Gupta This patch adds support for discovering the presence of the SP using the EFI_MM_COMMUNICATION_PROTOCOL GUID that implements Standalone MM drivers. This is done by querying the framework through FFA_PARTITION_INFO_GET whether any

Re: [edk2-devel] [edk2-platforms][PATCH V1 17/20] ArmPkg/MmCommunicationDxe: Unmap FF-A RX/TX buffers during ExitBootServices

2023-07-12 Thread Oliver Smith-Denny
On 7/11/2023 7:36 AM, Nishant Sharma wrote: From: Achin Gupta An FF-A partition can map only a single RX/TX buffer pair with the framework. The DXE MM communication driver maps its pair before ExitBootServices is called. The OS cannot re-use this pair once it boots subsequently and loads its

Re: [edk2-devel] [edk2-platforms][PATCH V1 10/20] StandaloneMmPkg: Populate Hoblist for SP init from StMM boot information

2023-07-12 Thread Oliver Smith-Denny
On 7/11/2023 7:36 AM, Nishant Sharma wrote: From: Achin Gupta This patch adds support for creating a hoblist from the reduced boot information retrieved from the SP manifest. Signed-off-by: Achin Gupta Signed-off-by: Nishant Sharma ---

Re: [edk2-devel] [edk2-platforms][PATCH V1 08/20] StandaloneMmPkg: Add backwards compatible support to detect FF-A v1.1

2023-07-12 Thread Oliver Smith-Denny
On 7/11/2023 7:36 AM, Nishant Sharma wrote: From: Achin Gupta For better or worse, an StMM SP can communicate with the SPM through one of these interfaces. 1. SPM_MM interface 2. FF-A v1.0 interface 3. FF-A v1.1 interface 2) implements only minimal FF-A support. It reuses the initialisation

Re: [edk2-devel] [edk2-platforms][PATCH V1 02/20] StandaloneMmPkg: Allocate and initialise SP stack from internal memory

2023-07-12 Thread Chris Fernald
Would it be possible to make the stack size configurable in a way that doesn't require an silicon/platform vendor to customize the assembly code? Perhaps through a fixed PCD if its not problematic to do so with the .space directive. Thanks, Chris On 7/11/2023 7:36 AM, Nishant Sharma wrote:

Re: [edk2-devel] [edk2-platforms][PATCH V1 06/20] ArmPkg: Add support for FFA_MEM_PERM_GET/SET ABIs

2023-07-12 Thread Oliver Smith-Denny
On 7/11/2023 7:36 AM, Nishant Sharma wrote: From: Achin Gupta This patch uses the FFA_MEM_PERM_GET/SET ABIs to tweak the permissions of a set of pages if FF-A v1.1 and above is supported by the SPMC. For FF-A v1.0 the previous method through FFA_MSG_SEND_DIRECT_REQ/RESP is used.

Re: [edk2-devel] [edk2-platforms][PATCH V1 04/20] ArmPkg: Add data structures to receive FF-A boot information

2023-07-12 Thread Oliver Smith-Denny
On 7/11/2023 7:36 AM, Nishant Sharma wrote: From: Achin Gupta The SPMC will pass the manifest to the StMM SP which contains the boot information required for SP initialisation. This patch defines the data structures defined in Section 5.4 of the FF-A v1.1 BETA0 spec to enable this support. The

Re: [edk2-devel] [edk2-platforms][PATCH V1 01/20] ArmPkg: Change PcdFfaEnable flag datatype

2023-07-12 Thread Chris Fernald
On top of Oliver's question, in the changes to|||StandaloneMmPkg/Library/StandaloneMmCoreEntryPoint/StandaloneMmCoreEntryPoint.inf, we should probably leave the .ARM and .AARCH64 specifiers since that is not an ARM specific INF. | -Chris On 7/12/2023 10:21 AM, Oliver Smith-Denny wrote: On

Re: [edk2-devel] [edk2-platforms][PATCH V1 01/20] ArmPkg: Change PcdFfaEnable flag datatype

2023-07-12 Thread Oliver Smith-Denny
On 7/11/2023 7:36 AM, Nishant Sharma wrote: FeatureFlag type PCD flags are declared by typecasting an integer value to BOOLEAN. These flags cannot be use in assembly code as assembler does not recognise C primitive types. Change the flag data type from BOOLEAN to UINT32. Signed-off-by: Nishant

Re: [edk2-devel] [edk2-platforms][PATCH V1 19/20] ArmPkg/MmCommunicationDxe: Use the FF-A transport for MM requests

2023-07-12 Thread Kun Qin
Hi Achin, The main MM communicate usage in PEI we have today is the variable service, because non secure UEFI cannot access flash directly. We had a few use cases where we need to check the variable from the previous boot in PEI, update some configuration data and consume it for the rest of

[edk2-devel] [PATCH v1 1/1] ShellPkg: Acpivew/GTDT: Print timer flags information.

2023-07-12 Thread levi.yun
Currently, GTDT only prints the value of timer flags in hex. This change prints the detail informaiton about Timer flags in GTDT. before: Shell> acpiview -s GTDT ... Non-Secure EL1 timer FLAGS : 0x2 Virtual timer GSIV : 0x1B Virtual timer FLAGS

Re: [edk2-devel] [edk2-platforms][PATCH V1 19/20] ArmPkg/MmCommunicationDxe: Use the FF-A transport for MM requests

2023-07-12 Thread Achin Gupta
Hi Kun, IIUC, not much happens during the PEI phase on Arm platforms. Hence the patches focus on DXE in the Normal world. It would be difficult to provide an effort estimate as we do not see a use case and consequently this is not on the to-do list. Would you be able to provide more detail

[edk2-devel] [PATCH] UefiPayloadPkg: Add FIT support

2023-07-12 Thread brucex . wang
From: BruceX Wang Cc: Guo Dong Cc: Sean Rhodes Cc: James Lu Cc: Gua Guo Signed-off-by: BruceX Wang --- .../UniversalPayload/UniversalPayload.h | 6 +- MdeModulePkg/MdeModulePkg.dec | 3 + MdePkg/Include/Library/FdtLib.h | 17 +

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

2023-07-12 Thread Ranbir Singh
Agreed! Will update accordingly. On Wed, Jul 12, 2023 at 12:36 PM Wu, Hao A wrote: > It works for me, better to override by: > > Status = EFI_SUCCESS; > > > > Best Regards, > > Hao Wu > > > > *From:* Ranbir Singh > *Sent:* Wednesday, July 12, 2023 3:01 PM > *To:* Wu, Hao A > *Cc:*

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

2023-07-12 Thread Ranbir Singh
Thanks Hao for digging deeper into this. The if block itself might get knocked off in Release mode when there is only a DEBUG statement inside it and hence Coverity might still complain. So, we can override the Status value in this scenario inside the if block and then proceed normally - let me

[edk2-devel] Event: TianoCore Community Meeting EMEA/NAMO - Thursday, July 13, 2023 #cal-reminder

2023-07-12 Thread Group Notification
*Reminder: TianoCore Community Meeting EMEA/NAMO* *When:* Thursday, July 13, 2023 8:00am to 9:00am (UTC-07:00) America/Los Angeles *Where:* Microsoft Teams meeting Join on your computer or mobile app Click here to join the meeting Meeting ID: 226 323 011 029 Passcode: hMRCj6 Download Teams |

Re: [edk2-devel] [PATCH v3 0/6] SecurityPkg/MdePkg: Update RngLib GUID identification

2023-07-12 Thread PierreGondois
Hello Kun, As I made some small changes to the patch-set, I didn't include your tested-by tag, but the changes should be quite small, The v4 is available at: - https://edk2.groups.io/g/devel/message/106856 Regards, Pierre On 7/6/23 21:01, Kun Qin wrote: Hi Pierre, Thanks for sending the

Re: [edk2-devel] [PATCH v4 0/8] SecurityPkg/MdePkg: Update RngLib GUID identification

2023-07-12 Thread PierreGondois
The patch reflecting the move of BaseRngLibTimerLib to MdeModulePkg is available at: https://edk2.groups.io/g/devel/message/106865 On 7/12/23 15:29, pierre.gond...@arm.com wrote: From: Pierre Gondois v4: - New patches: - [1/8] MdePkg: Move BaseRngLibTimerLib to MdeModulePkg - [5/8]

[edk2-devel] [PATCH v1 1/1] Platform/Silicon: Reflect BaseRngLibTimerLib moving to MdeModulePkg

2023-07-12 Thread PierreGondois
From: Pierre Gondois Reflect a recent change moving the BaseRngLibTimerLib to the MdeModulePkg. Signed-off-by: Pierre Gondois --- Platform/ARM/SgiPkg/SgiPlatformMm.dsc.inc| 2 +- Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc | 2 +-

[edk2-devel] [PATCH v1 0/1] Platform: Reflect BaseRngLibTimerLib moving to MdeModulePkg

2023-07-12 Thread PierreGondois
From: Pierre Gondois Following the patch-set at: - https://edk2.groups.io/g/devel/message/106856 and the discussion at: - https://edk2.groups.io/g/devel/message/106791 Reflect the move of BaseRngLibTimerLib to MdeModulePkg in edk2-platforms. Pierre Gondois (1): Platform/Silicon: Reflect

[edk2-devel] [PATCH v4 8/8] SecurityPkg/RngDxe: Simplify Rng algorithm selection for Arm

2023-07-12 Thread PierreGondois
From: Pierre Gondois The first element of mAvailableAlgoArray is defined as the default Rng algorithm to use. Don't go through the array at each RngGetRNG() call and just return the first element of the array. Signed-off-by: Pierre Gondois Reviewed-by: Sami Mujawar ---

[edk2-devel] [PATCH v4 7/8] SecurityPkg/RngDxe: Use GetRngGuid() when probing RngLib

2023-07-12 Thread PierreGondois
From: Pierre Gondois BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4151 The EFI_RNG_PROTOCOL can rely on the RngLib. The RngLib has multiple implementations, some of them are unsafe (e.g. BaseRngLibTimerLib). To allow the RngDxe to detect when such implementation is used, a GetRngGuid()

[edk2-devel] [PATCH v4 6/8] MdePkg/Rng: Add GetRngGuid() to RngLib

2023-07-12 Thread PierreGondois
From: Pierre Gondois The EFI_RNG_PROTOCOL can use the RngLib. The RngLib has multiple implementations, some of them are unsafe (e.g. BaseRngLibTimerLib). To allow the RngDxe to detect when such implementation is used, add a GetRngGuid() function to the RngLib. Signed-off-by: Pierre Gondois

[edk2-devel] [PATCH v4 5/8] MdeModulePkg/Rng: Add GUID to describe unsafe Rng algorithms

2023-07-12 Thread PierreGondois
From: Pierre Gondois BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4441 The EFI_RNG_PROTOCOL can rely on the RngLib. The RngLib has multiple implementations, some of them are unsafe (e.g. BaseRngLibTimerLib). To allow the RngDxe to detect when such implementation is used, a GetRngGuid()

[edk2-devel] [PATCH v4 4/8] MdePkg/Rng: Add GUID to describe Arm Rndr Rng algorithms

2023-07-12 Thread PierreGondois
From: Pierre Gondois BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4441 The EFI_RNG_PROTOCOL can rely on the RngLib. The RngLib has multiple implementations, some of them are unsafe (e.g. BaseRngLibTimerLib). To allow the RngDxe to detect when such implementation is used, a GetRngGuid()

[edk2-devel] [PATCH v4 3/8] MdePkg/DxeRngLib: Request raw algorithm instead of default

2023-07-12 Thread PierreGondois
From: Pierre Gondois The DxeRngLib tries to generate a random number using the 3 NIST SP 800-90 compliant DRBG algorithms, i.e. 256-bits CTR, HASH and HMAC. If none of the call is successful, the fallback option is the default RNG algorithm of the EFI_RNG_PROTOCOL. This default algorithm might

[edk2-devel] [PATCH v4 2/8] SecurityPkg/SecurityPkg.dec: Move PcdCpuRngSupportedAlgorithm to MdePkg

2023-07-12 Thread PierreGondois
From: Pierre Gondois In order to use PcdCpuRngSupportedAlgorithm in the MdePkg in a following patch and to avoid making the MdePkg dependent on another package, move PcdCpuRngSupportedAlgorithm to the MdePkg. As the Pcd is only used for AARCH64, place it in an AARCH64 specific sections.

[edk2-devel] [PATCH v4 0/8] SecurityPkg/MdePkg: Update RngLib GUID identification

2023-07-12 Thread PierreGondois
From: Pierre Gondois v4: - New patches: - [1/8] MdePkg: Move BaseRngLibTimerLib to MdeModulePkg - [5/8] MdeModulePkg/Rng: Add GUID to describe unsafe Rng algorithms - This patch-set now requires to be accepted along an edk-platforms patch moving the BaseRngLibTimerLib to MdeModulePkg v3:

[edk2-devel] [PATCH v4 1/8] MdePkg: Move BaseRngLibTimerLib to MdeModulePkg

2023-07-12 Thread PierreGondois
From: Pierre Gondois The BaseRngLibTimerLib allows to generate number based on a timer. This mechanism allows to have a basic non-secure implementation for non-production platforms. To bind and identify Random Number Generators implementations with a GUID, an unsafe GUID should be added. This

Re: [edk2-devel] heap/page guard broken on aarch64

2023-07-12 Thread Gerd Hoffmann
On Wed, Jul 12, 2023 at 02:03:37PM +0200, Ard Biesheuvel wrote: > On Wed, 12 Jul 2023 at 10:41, Gerd Hoffmann wrote: > > > > PcdHeapGuardPageType=0x7e > > PcdHeapGuardPoolType=0x7e > This looks like the debug 'poison' value is applied to the freed guard > page before the

Re: [edk2-devel] heap/page guard broken on aarch64

2023-07-12 Thread Ard Biesheuvel
On Wed, 12 Jul 2023 at 10:41, Gerd Hoffmann wrote: > > Hi, > > Tried to debug a bug which looks like memory corruption, turned on page > and heap guard: > > PcdHeapGuardPageType=0x7e > PcdHeapGuardPoolType=0x7e > PcdHeapGuardPropertyMask=0x03 > > With that the firmware

Re: [edk2-devel] [PATCH 00/14] Implement Dynamic Memory Protections

2023-07-12 Thread Gerd Hoffmann
On Tue, Jul 11, 2023 at 04:52:37PM -0700, Taylor Beebe wrote: > In the past, memory protection settings were configured via FixedAtBuild PCDs, > which resulted in a build-time configuration of memory mitigations. This > approach limited the flexibility of applying mitigations to the > system and

[edk2-devel] heap/page guard broken on aarch64

2023-07-12 Thread Gerd Hoffmann
Hi, Tried to debug a bug which looks like memory corruption, turned on page and heap guard: PcdHeapGuardPageType=0x7e PcdHeapGuardPoolType=0x7e PcdHeapGuardPropertyMask=0x03 With that the firmware crashes due to a page fault. Stack trace (with PCs manually mapped to

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

2023-07-12 Thread Ard Biesheuvel
On Wed, 12 Jul 2023 at 09:06, Wu, Hao A wrote: > > It works for me, better to override by: > > Status = EFI_SUCCESS; > > So now we're adding unnecessary assignments just to please coverity? I don't think this is a good idea. If Coverity does not understand that the source references Status

Re: [edk2-devel] [PATCH v1 1/1] UefiCpuPkg: Uses gMmst in MmSaveStateLib

2023-07-12 Thread Chang, Abner via groups.io
[AMD Official Use Only - General] Acked-by: Abner Chang > -Original Message- > From: Abdul Lateef Attar > Sent: Wednesday, July 12, 2023 2:24 PM > To: devel@edk2.groups.io > Cc: Attar, AbdulLateef (Abdul Lateef) ; Eric > Dong ; Ray Ni ; Rahul Kumar > ; Gerd Hoffmann ; Chang, > Abner >

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

2023-07-12 Thread Wu, Hao A
It works for me, better to override by: Status = EFI_SUCCESS; Best Regards, Hao Wu From: Ranbir Singh Sent: Wednesday, July 12, 2023 3:01 PM To: Wu, Hao A Cc: devel@edk2.groups.io; Ni, Ray Subject: Re: [PATCH v2 2/2] MdeModulePkg/Bus/Ata/AtaAtapiPassThru: Fix UNUSED_VALUE Coverity issue

[edk2-devel] [PATCH v1 1/1] UefiCpuPkg: Uses gMmst in MmSaveStateLib

2023-07-12 Thread Abdul Lateef Attar via groups.io
From: Abdul Lateef Attar BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4182 Use gMmst instead of gSmst. Replace SmmServicesTableLib with MmServicesTableLib. Cc: Eric Dong Cc: Ray Ni Cc: Rahul Kumar Cc: Gerd Hoffmann Cc: Abner Chang Signed-off-by: Abdul Lateef Attar ---

[edk2-devel] [PATCH v1 0/1] UefiCpuPkg: Uses gMmst in MmSaveStateLib

2023-07-12 Thread Abdul Lateef Attar via groups.io
PR: https://github.com/tianocore/edk2/pull/4625 BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4182 Use gMmst instead of gSmst. Replace SmmServicesTableLib with MmServicesTableLib. Cc: Eric Dong Cc: Ray Ni Cc: Rahul Kumar Cc: Gerd Hoffmann Cc: Abner Chang Cc: Abdul Lateef Attar Abdul