Re: [edk2-devel] [PATCH] SecurityPkg/SecureBoot: Support RSA 512 and RSA 384

2023-07-06 Thread Yao, Jiewen
CPL_KEY_INFO is not standard, but implementation choice. I notice KeyType field is not used today. I assume it is 0 today. Can we use 0 to indicate RSASSA? Thank you Yao, Jiewen > -Original Message- > From: Sheng, W > Sent: Thursday, July 6, 2023 2:48 PM > To: Yao, Jiewen ; devel@edk

Re: [edk2-devel] [PATCH v3] SecurityPkg/SecureBoot: Support RSA 512 and RSA 384

2023-07-06 Thread Gary Lin via groups.io
On Thu, Jul 06, 2023 at 02:36:54PM +0800, Sheng Wei via groups.io wrote: > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3413 > The title, "Support RSA 512 and RSA 384", looks very strange. I assume it should be "Support SHA 512 and SHA 384"? Gary Lin > Cc: Jiewen Yao > Cc: Jian J Wang >

Re: [edk2-devel] [PATCH] SecurityPkg/SecureBoot: Support RSA 512 and RSA 384

2023-07-06 Thread Sheng Wei
Hi Jiewen, As your suggestion. I will check if CPL_KEY_INFO. KeyType == 0 first. If true, I will use below table to select RSA algorithm. KeyLengthInBitsRSA algorithm 2048RSA 2K 3072RSA 3K 4096RSA 4K Do you have any comment

[edk2-devel] [PATCH v4] SecurityPkg/SecureBoot: Support RSA 512 and RSA 384

2023-07-06 Thread Sheng Wei
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3413 Cc: Jiewen Yao Cc: Jian J Wang Cc: Min Xu Cc: Zeyi Chen Cc: Fiona Wang Signed-off-by: Sheng Wei --- CryptoPkg/Library/BaseCryptLib/Pk/CryptTs.c | 3 +- MdePkg/Include/Guid/ImageAuthentication.h | 26 +++ MdePkg/MdePkg.dec

Re: [edk2-devel] [PATCH v2 1/3] RedfishPkg/RedfishRestExDxe: fix CPU exception in RedfishRestExDxe

2023-07-06 Thread Nickle Wang via groups.io
I am ok to remove it since we don't use it. @Abner Chang, comment as driver author? Thanks, Nickle > -Original Message- > From: Mike Maslenkin > Sent: Wednesday, July 5, 2023 4:43 PM > To: devel@edk2.groups.io; Nickle Wang > Cc: Abner Chang ; Igor Kulchytskyy ; > Nick Ramirez > Subjec

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

2023-07-06 Thread PierreGondois
From: Pierre Gondois v3: - As the unsafe algorithm GUID will not be added to the UEFI specification, rename: - gEfiRngAlgorithmUnSafe to gEdkiiRngAlgorithmUnSafe - EFI_RNG_ALGORITHM_UNSAFE to EDKII_RNG_ALGORITHM_UNSAFE v2: [1/8] MdePkg/ArmTrngLib: Remove ASSERTs in Null implementation - Dr

[edk2-devel] [PATCH v3 1/6] SecurityPkg/SecurityPkg.dec: Move PcdCpuRngSupportedAlgorithm to MdePkg

2023-07-06 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. Signed-

[edk2-devel] [PATCH v3 2/6] MdePkg/DxeRngLib: Request raw algorithm instead of default

2023-07-06 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 be

[edk2-devel] [PATCH v3 3/6] MdePkg/Rng: Add GUIDs to describe Rng algorithms

2023-07-06 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() fun

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

2023-07-06 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 Revi

[edk2-devel] [PATCH v3 5/6] SecurityPkg/RngDxe: Use GetRngGuid() when probing RngLib

2023-07-06 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() fun

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

2023-07-06 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 --- .../RandomNumberGenerat

Re: [edk2-devel] [Patch V4 0/5] Eliminate the second INIT-SIPI-SIPI sequence

2023-07-06 Thread Gerd Hoffmann
On Wed, Jul 05, 2023 at 07:22:06AM +, Ni, Ray wrote: > Gard, any comments? Tested-by: Gerd Hoffmann Acked-by: Gerd Hoffmann take care, Gerd -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#106692): https://edk2.groups.io/g/devel/

Re: [edk2-devel] [PATCH v1 3/3] OvmfPkg/BhyvePkg: enable bus enumeration

2023-07-06 Thread Peter Grehan
On 7/3/23 9:34 PM, Corvin Köhne wrote: On Mon, 2023-06-12 at 11:20 +0200, Corvin Köhne wrote: bhyve supports adding a ROM to PCI devices. It was added to support GPU passthrough of dedicated AMD GPUs. At the moment, this ROM file is mostly useless as it's not shadowed and executed by firmware. C

Re: [edk2-devel] [PATCH] RedfishPkg/RedfishDebugLib: add new interfaces

2023-07-06 Thread Chang, Abner via groups.io
[AMD Official Use Only - General] Reviewed-by: Abner Chang > -Original Message- > From: Nickle Wang > Sent: Wednesday, July 5, 2023 10:50 AM > To: devel@edk2.groups.io > Cc: Chang, Abner ; Igor Kulchytskyy > > Subject: [PATCH] RedfishPkg/RedfishDebugLib: add new interfaces > > Caution:

Re: [edk2-devel] [PATCH v2 2/3] RedfishPkg/RedfishPlatformConfigDxe: hide debug message

2023-07-06 Thread Chang, Abner via groups.io
[AMD Official Use Only - General] Reviewed-by: Abner Chang > -Original Message- > From: Nickle Wang > Sent: Wednesday, July 5, 2023 2:57 PM > To: devel@edk2.groups.io > Cc: Chang, Abner ; Igor Kulchytskyy > ; Nick Ramirez > Subject: [PATCH v2 2/3] RedfishPkg/RedfishPlatformConfigDxe: h

Re: [edk2-devel] [PATCH v2 1/3] RedfishPkg/RedfishRestExDxe: fix CPU exception in RedfishRestExDxe

2023-07-06 Thread Chang, Abner via groups.io
[AMD Official Use Only - General] I am also ok to remove this. However please have another patch for this, thus the purpose of change is clear. Thanks Abner > -Original Message- > From: Nickle Wang > Sent: Thursday, July 6, 2023 4:08 PM > To: Mike Maslenkin ; devel@edk2.groups.io; > Ch

Re: [edk2-devel] [PATCH v2 1/3] RedfishPkg/RedfishRestExDxe: fix CPU exception in RedfishRestExDxe

2023-07-06 Thread Nickle Wang via groups.io
Thanks Abner. Will create a separated patch to remove "RestExSb->RestExChildrenNum". Regards, Nickle > -Original Message- > From: Chang, Abner > Sent: Thursday, July 6, 2023 7:01 PM > To: Nickle Wang ; Mike Maslenkin > ; devel@edk2.groups.io > Cc: Igor Kulchytskyy ; Nick Ramirez > Subj

[edk2-devel] [PATCH v3 1/1] ArmVirtPkg: use PcdTerminalTypeGuidBuffer for VirtioSerial console

2023-07-06 Thread Gerd Hoffmann
Be consistent with pl011-based serial console setup. Suggested-by: Laszlo Ersek Signed-off-by: Gerd Hoffmann --- ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ArmVirtPkg/Library/PlatformBootManagerLib/Platform

Re: [edk2-devel] [PATCH] MdeModulePkg/XhciDxe: Use Performance Timer for XHCI Timeouts

2023-07-06 Thread Michael Brown
On 05/07/2023 21:15, Henz, Patrick wrote: REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2948 XhciDxe uses the timer functionality provided by the boot services table to detect timeout conditions. This breaks the driver's ExitBootServices call back, as CoreExitBootServices halts the timer be

[edk2-devel] Event: TianoCore edk2-test Bug Triage Meeting - Thursday, July 6, 2023 #cal-reminder

2023-07-06 Thread Group Notification
*Reminder: TianoCore edk2-test Bug Triage Meeting* *When:* Thursday, July 6, 2023 10:00pm to 11:00pm (UTC+08:00) Asia/Shanghai *Where:* https://armltd.zoom.us/j/91247522013?pwd=ei9nUndTbG9oWEROS2M1aVREZkpiQT09&from=addon *Organizer:* Edhaya Chandran edhaya.chand...@arm.com ( edhaya.chand...@arm

[edk2-devel] Now: TianoCore edk2-test Bug Triage Meeting - Thursday, July 6, 2023 #cal-notice

2023-07-06 Thread Group Notification
*TianoCore edk2-test Bug Triage Meeting* *When:* Thursday, July 6, 2023 10:00pm to 11:00pm (UTC+08:00) Asia/Shanghai *Where:* https://armltd.zoom.us/j/91247522013?pwd=ei9nUndTbG9oWEROS2M1aVREZkpiQT09&from=addon *Organizer:* Edhaya Chandran edhaya.chand...@arm.com ( edhaya.chand...@arm.com?subje

Re: [edk2-devel] [PATCH] MdeModulePkg/XhciDxe: Use Performance Timer for XHCI Timeouts

2023-07-06 Thread Henz, Patrick
Hi Michael, I agree that XhcGetElapsedTime() would be better off in TimerLib, but I wasn't sure how the community would feel about adding to the interface. As for your question, I was wondering the same thing, I'm not sure if there are any platforms that do not have a free-running timer that wo

Re: [edk2-devel] [PATCH v3 1/1] ArmVirtPkg: use PcdTerminalTypeGuidBuffer for VirtioSerial console

2023-07-06 Thread Laszlo Ersek
On 7/6/23 14:30, Gerd Hoffmann wrote: > Be consistent with pl011-based serial console setup. > > Suggested-by: Laszlo Ersek > Signed-off-by: Gerd Hoffmann > --- > ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c | 9 +++-- > 1 file changed, 7 insertions(+), 2 deletions(-) > > diff --

Re: [edk2-devel] [PATCH v1 2/2] BaseTools: GenFw: auto-set nxcompat flag

2023-07-06 Thread Joey Vagedes via groups.io
Hi all, Do you have any concerns over the changes I've made to GenFw.c as seen above? Please let me know if you have any questions, concerns, or improvements; I would be happy to help! Thanks, Joey On Fri, Jun 23, 2023 at 8:44 AM Joey Vagedes wrote: > Automatically set the nxcompat flag in the

Re: [edk2-devel] [PATCH v1 1/1] BaseTools: scan Edk2ToolsBuild.py make output

2023-07-06 Thread Joey Vagedes via groups.io
Hi All, Any concerns over this patch? It merely adds the ability to detect some compiler errors when building BaseTools with Edk2ToolsBuild.py and report them as logging level ERROR to get a quick glimpse at the error without needing to review the entire log. Thanks, Joey On Wed, Jun 21, 2023 at

[edk2-devel] [PATCH 1/1] OvmfPkg/PlatformBootManagerLib: setup virtio-mmio devices.

2023-07-06 Thread Gerd Hoffmann
Add DetectAndPreparePlatformVirtioDevicePath() helper function to setup virtio-mmio devices. Start with virtio-serial support. This makes virtio console usable with microvm. Signed-off-by: Gerd Hoffmann --- .../PlatformBootManagerLib.inf| 1 + .../PlatformBootManagerLib/BdsPla

Re: [edk2-devel] [PATCH v1 08/24] DynamicTablesPkg: CI: Add PrEval entry

2023-07-06 Thread Sami Mujawar
Hi Joey, Thank you for this patch. Reviewed-by: Sami Mujawar Regards, Sami Mujawar On 26/06/2023, 22:35, "Joey Vagedes" mailto:joey.vage...@gmail.com>> wrote: Adds a PrEval entry to the package's ci.yaml file which is used to verify if the package uses a particular library instance when th

Re: [edk2-devel] [PATCH] MdeModulePkg/XhciDxe: Use Performance Timer for XHCI Timeouts

2023-07-06 Thread Michael Brown
On 06/07/2023 15:19, Henz, Patrick wrote: I agree that XhcGetElapsedTime() would be better off in TimerLib, but I wasn't sure how the community would feel about adding to the interface. My understanding is that the TimerLib API is not prescribed by any standards document, and that this change

Re: [edk2-devel] [PATCH] MdeModulePkg/XhciDxe: Use Performance Timer for XHCI Timeouts

2023-07-06 Thread Michael D Kinney
There is a similar lib API for SMI handlers: https://github.com/tianocore/edk2/blob/master/MdePkg/Include/Library/SmmPeriodicSmiLib.h /** This function returns the time in 100ns units since the periodic SMI handler function was called. If the periodic SMI handler was resumed through Period

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

2023-07-06 Thread Kun Qin
Hi Pierre, Thanks for sending the update. I tested on QEMU with this change (no TRNG from TFA), it works for me. Tested-by: Kun Qin Please note that the change below is still needed to avoid data abortion exception. It will be helpful if one of the maintainers can help merging it. [PATCH v2

Re: [edk2-devel] [edk2-platforms][PATCH v1 1/1] MinPlatformPkg: Fix build errors in SmmVariableWriteLib

2023-07-06 Thread Isaac Oram
Pushed as f4fbaf6022603957fefa77c9ceb77f4b2851b0dc -Original Message- From: devel@edk2.groups.io On Behalf Of Isaac Oram Sent: Wednesday, July 5, 2023 7:55 PM To: devel@edk2.groups.io; mikub...@linux.microsoft.com Cc: Chiu, Chasel ; Desimone, Nathaniel L ; Gao, Liming ; Dong, Eric Subj

Re: [edk2-devel] [edk2-platforms][PATCH v1 1/1] MinPlatformPkg: Add Mem Type Info variable validity checks

2023-07-06 Thread Isaac Oram
Pushed as 87c40ac89b97eccac690762536db5376af15bb65 -Original Message- From: devel@edk2.groups.io On Behalf Of Isaac Oram Sent: Wednesday, July 5, 2023 7:57 PM To: devel@edk2.groups.io; mikub...@linux.microsoft.com Cc: Chiu, Chasel ; Desimone, Nathaniel L ; Gao, Liming ; Dong, Eric ; Lau

[edk2-devel] [PATCH 0/4] Sync BSP's APIC mode to APs in MP init flow

2023-07-06 Thread Ni, Ray
Ray Ni (4): UefiCpuPkg/MpInitLib: Separate X2APIC enabling to subfunction UefiCpuPkg/MpInitLib: Sync BSP's APIC mode to APs in InitConfig path UefiCpuPkg/MpInitLib: Skip X2APIC enabling when BSP in X2APIC already UefiCpuPkg/CpuFeatures: Deprecate CPU_FEATURE_X2APIC .../Include/Library/Reg

[edk2-devel] [PATCH 1/4] UefiCpuPkg/MpInitLib: Separate X2APIC enabling to subfunction

2023-07-06 Thread Ni, Ray
It's very confusing that auto X2 APIC enabling and APIC ID sorting are all performed inside CollectProcessorCount(). The change is to separate the X2 APIC enabling to AutoEnableX2Apic() and call that from MpInitLibInitialize(). SortApicId() is called from MpInitLibInitialize() as well. Signed-off

[edk2-devel] [PATCH 2/4] UefiCpuPkg/MpInitLib: Sync BSP's APIC mode to APs in InitConfig path

2023-07-06 Thread Ni, Ray
The change saves the BSP's initial APIC mode and syncs to all APs in first time wakeup. It allows certain platforms to switch to X2 APIC as early as possible and also independent on CpuFeaturePei/Dxe. The platform should switch BSP to X2 APIC mode first before the CpuMpPeim runs. Signed-off-by: Ra

[edk2-devel] [PATCH 3/4] UefiCpuPkg/MpInitLib: Skip X2APIC enabling when BSP in X2APIC already

2023-07-06 Thread Ni, Ray
The BSP's APIC mode is synced to all APs in CollectProcessorCount(). So, it's safe to skip the X2 APIC enabling in AutoEnableX2Apic() which runs later when BSP's APIC mode is X2 APIC already. Signed-off-by: Ray Ni Cc: Eric Dong Cc: Rahul Kumar Cc: Gerd Hoffmann --- UefiCpuPkg/Library/MpInitLi

[edk2-devel] [PATCH 4/4] UefiCpuPkg/CpuFeatures: Deprecate CPU_FEATURE_X2APIC

2023-07-06 Thread Ni, Ray
Since MpLib supports to sync BSP's initial APIC mode to APs, platform can set BSP to X2 APIC mode before MpLib runs and expect MpLib syncs the X2 APIC mode to all APs. With such capability in MpLib, CpuCommonFeaturesLib's X2 APIC enable logic is dropped for simplificity. Such code removal also rem