Re: [edk2-devel] [PATCH v2 0/9] Add ImagePropertiesRecordLib and Fix MAT Bugs

2023-07-19 Thread Ni, Ray
Taylor, Thank you for your effort for removing the duplicated logic in Dxe/Smm Core and fixing the bugs. Two general comments: #1. Can you refactor your patch series in a way that the new lib code is like a "git move" instead of "git add"? For example, you could add an empty lib first and

Re: [edk2-devel] [PATCH 2/2] NetworkPkg/HttpDxe: fix driver binding start issue.

2023-07-19 Thread Michael D Kinney
Merged: https://github.com/tianocore/edk2/pull/4666 Mike > -Original Message- > From: Kinney, Michael D > Sent: Wednesday, July 19, 2023 5:27 PM > To: Kasbekar, Saloni ; Nickle Wang > ; devel@edk2.groups.io; Clark-williams, Zachary > > Cc: Abner Chang ; Igor Kulchytskyy ; > Nick

Re: [edk2-devel] [PATCH] OvmfPkg:Fix Hii form name mismatch with EFI variable

2023-07-19 Thread Wang, Yin
The last 2 change was found when I debug another two fail cases,RouteConfigFunction/RouteConfig_Func,  I will do more investigating on them. let's fallback  to patch v1. I will continue on that thread. Thanks for your time. Yin On 7/19/2023 9:48 PM, Gerd Hoffmann wrote: On Wed, Jul 19, 2023

Re: [edk2-devel] [PATCH 1/1] OvmfPkg:Fix Hii form name mismatch with EFI variable

2023-07-19 Thread Wang, Yin
Hi, Could you help to review on it? Thanks in advance! Yin On 7/17/2023 7:36 PM, Gerd Hoffmann wrote: On Fri, Jul 14, 2023 at 04:59:48PM +0800, Wang, Yin wrote: Onemore need change beside fixs:16acacf24c ("OvmfPkg: fix PlatformConfig") Find by sct case:ExtractConfigConformance fail.

Re: [edk2-devel] [PATCH v3 1/1] UnitTestFrameworkPkg: UnitTestPersistenceLib: Save Unit Test Cache Option

2023-07-19 Thread Michael D Kinney
Reviewed-by: Michael D Kinney > -Original Message- > From: Michael Kubacki > Sent: Friday, June 30, 2023 4:00 PM > To: devel@edk2.groups.io; kuqi...@gmail.com > Cc: Sean Brogan ; Kinney, Michael D > > Subject: Re: [edk2-devel] [PATCH v3 1/1] UnitTestFrameworkPkg: >

Re: [edk2-devel] [PATCH 2/2] NetworkPkg/HttpDxe: fix driver binding start issue.

2023-07-19 Thread Michael D Kinney
Acked-by: Michael D Kinney > -Original Message- > From: Kasbekar, Saloni > Sent: Thursday, July 13, 2023 9:13 AM > To: Nickle Wang ; devel@edk2.groups.io; Clark- > williams, Zachary ; Kinney, Michael D > > Cc: Abner Chang ; Igor Kulchytskyy ; > Nick Ramirez > Subject: RE: [edk2-devel]

[edk2-devel] [PATCH v2 7/9] UefiPayloadPkg: Add ImagePropertiesRecordLib Instance

2023-07-19 Thread Taylor Beebe
Add an instance of ImagePropertiesRecordLib which will be used by the DXE Core. Signed-off-by: Taylor Beebe Cc: Guo Dong Cc: Sean Rhodes Cc: James Lu Cc: Gua Guo --- UefiPayloadPkg/UefiPayloadPkg.dsc | 1 + 1 file changed, 1 insertion(+) diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc

[edk2-devel] [PATCH v2 9/9] MdeModulePkg: Update UEFI and SMM MAT Logic To Use ImagePropertiesRecordLib

2023-07-19 Thread Taylor Beebe
With the new ImagePropertiesRecordLib, UEFI and SMM no longer need to carry duplicate image properties record logic in their respective MAT implementations. Signed-off-by: Taylor Beebe Cc: Jian J Wang Cc: Liming Gao Cc: Dandan Bi --- MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c | 786

[edk2-devel] [PATCH v2 8/9] UefiCpuPkg: Use Attribute From SMM MemoryAttributesTable if Nonzero

2023-07-19 Thread Taylor Beebe
The function EnforceMemoryMapAttribute() in the SMM MAT logic will ensure that the CODE and DATA memory types have the desired attributes. The consumer of the SMM MAT should only override the Attributes field in the MAT if it is nonzero. This also allows the UEFI and SMM MAT logic to use

[edk2-devel] [PATCH v2 6/9] OvmfPkg: Add ImagePropertiesRecordLib Instance

2023-07-19 Thread Taylor Beebe
Add an instance of ImagePropertiesRecordLib which will be used by the DXE Core. Signed-off-by: Taylor Beebe Cc: Ard Biesheuvel Cc: Jiewen Yao Cc: Jordan Justen Cc: Gerd Hoffmann --- OvmfPkg/AmdSev/AmdSevX64.dsc| 1 + OvmfPkg/Bhyve/BhyveX64.dsc | 1 +

[edk2-devel] [PATCH v2 5/9] EmulatorPkg: Add ImagePropertiesRecordLib Instance

2023-07-19 Thread Taylor Beebe
Add an instance of ImagePropertiesRecordLib which will be used by the DXE Core. Signed-off-by: Taylor Beebe Cc: Andrew Fish Cc: Ray Ni --- EmulatorPkg/EmulatorPkg.dsc | 1 + 1 file changed, 1 insertion(+) diff --git a/EmulatorPkg/EmulatorPkg.dsc b/EmulatorPkg/EmulatorPkg.dsc index

[edk2-devel] [PATCH v2 4/9] ArmVirtPkg: Add ImagePropertiesRecordLib Instance

2023-07-19 Thread Taylor Beebe
Add an instance of ImagePropertiesRecordLib which will be used by the DXE Core. Signed-off-by: Taylor Beebe Cc: Ard Biesheuvel Cc: Leif Lindholm Cc: Sami Mujawar Cc: Gerd Hoffmann --- ArmVirtPkg/ArmVirt.dsc.inc | 1 + 1 file changed, 1 insertion(+) diff --git a/ArmVirtPkg/ArmVirt.dsc.inc

[edk2-devel] [PATCH v2 1/9] MdeModulePkg: Add ImagePropertiesRecordLib

2023-07-19 Thread Taylor Beebe
Create a library for manipulating image properties records. Image properties record logic is already present in both the SMM and UEFI MAT logic, and this is a copy of the UEFI MAT logic with added function arguments to remove dependencies on global variables. Signed-off-by: Taylor Beebe Cc: Jian

[edk2-devel] [PATCH v2 2/9] MdeModulePkg: Add ImagePropertiesRecordLib Host-Based Unit Test

2023-07-19 Thread Taylor Beebe
Create a host-based unit test for the ImagePropertiesRecordLib SplitTable() logic. This test has 4 cases which tests different potential image and memory map layouts. 3/4 of these tests fail with the logic in its current state to provide proof of the bugs in the current MAT logic. Signed-off-by:

[edk2-devel] [PATCH v2 3/9] MdeModulePkg: Fix Bugs in MAT Logic

2023-07-19 Thread Taylor Beebe
Fix the bugs in ImagePropertiesRecordLib (which is a copy of the current UEFI MAT logic) before switching the UEFI and SMM MAT logic to use the new library. Signed-off-by: Taylor Beebe Cc: Jian J Wang Cc: Liming Gao Cc: Dandan Bi ---

[edk2-devel] [PATCH v2 0/9] Add ImagePropertiesRecordLib and Fix MAT Bugs

2023-07-19 Thread Taylor Beebe
v2: - A one-line change in patch 3 was moved to patch 9 for correctness. Reference: https://github.com/tianocore/edk2/pull/4590 Bugzilla: https://bugzilla.tianocore.org/show_bug.cgi?id=4492 The UEFI and SMM MAT logic contains duplicate logic for manipulating image properties records which is

Re: 回复: [edk2-devel] [PATCH v1 0/9] Add ImagePropertiesRecordLib and Fix MAT Bugs

2023-07-19 Thread Taylor Beebe
On 7/18/23 10:23 PM, gaoliming via groups.io wrote: Ard: Now, there is no compatible way to introduce new library class for the basic module. One possible solution is to define the default library instance in package dec file together with the library class declaration. Beebe: This

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Ard Biesheuvel
On Wed, 19 Jul 2023 at 19:40, Michael Brown wrote: > > On 19/07/2023 17:52, Ard Biesheuvel wrote: > > On Wed, 19 Jul 2023 at 18:32, Gerd Hoffmann wrote: > >> On Wed, Jul 19, 2023 at 04:04:28PM +, Michael Brown wrote: > >>> It looks as though IoMmuFreeBounceBuffer() should also raise to

Re: [edk2-devel] [PATCH v2 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Ard Biesheuvel
On Wed, 19 Jul 2023 at 18:31, Gerd Hoffmann wrote: > > Searching for an unused bounce buffer in mReservedMemBitmap and > reserving the buffer by flipping the bit is a critical section > which must not be interrupted. Raise the TPL level to ensure > that. > > Without this fix it can happen that

Re: [edk2-devel][PATCH v1] SplitFspBin.py cannot support FSP binary with child FV included

2023-07-19 Thread Chiu, Chasel
Hi Ted, One question below inline. Another minor feedback is the commit/patch subject format should be "Package: title" Thanks, Chasel > -Original Message- > From: Kuo, Ted > Sent: Tuesday, July 18, 2023 7:16 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Michael Brown
On 19/07/2023 17:52, Ard Biesheuvel wrote: On Wed, 19 Jul 2023 at 18:32, Gerd Hoffmann wrote: On Wed, Jul 19, 2023 at 04:04:28PM +, Michael Brown wrote: It looks as though IoMmuFreeBounceBuffer() should also raise to TPL_NOTIFY while modifying mReservedMemBitmap, since the modification

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Ard Biesheuvel
On Wed, 19 Jul 2023 at 18:32, Gerd Hoffmann wrote: > > On Wed, Jul 19, 2023 at 04:04:28PM +, Michael Brown wrote: > > On 19/07/2023 12:33, Gerd Hoffmann wrote: > > > Searching for an unused bounce buffer in mReservedMemBitmap and > > > reserving the buffer by flipping the bit is a critical

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Gerd Hoffmann
On Wed, Jul 19, 2023 at 04:04:28PM +, Michael Brown wrote: > On 19/07/2023 12:33, Gerd Hoffmann wrote: > > Searching for an unused bounce buffer in mReservedMemBitmap and > > reserving the buffer by flipping the bit is a critical section > > which must not be interrupted. Raise the TPL level

[edk2-devel] [PATCH v2 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Gerd Hoffmann
Searching for an unused bounce buffer in mReservedMemBitmap and reserving the buffer by flipping the bit is a critical section which must not be interrupted. Raise the TPL level to ensure that. Without this fix it can happen that IoMmuDxe hands out the same bounce buffer twice, causing trouble

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Michael Brown
On 19/07/2023 12:33, Gerd Hoffmann wrote: Searching for an unused bounce buffer in mReservedMemBitmap and reserving the buffer by flipping the bit is a critical section which must not be interrupted. Raise the TPL level to ensure that. Without this fix it can happen that IoMmuDxe hands out the

Re: [edk2-devel] [PATCH] OvmfPkg:Fix Hii form name mismatch with EFI variable

2023-07-19 Thread Wang, Yin
Hi Grand Thanks for quick reply, Yes, uefi variable mVariableName by shell command dmpstore, could you help to figure out where to initialize mVariableName for arm of x86? Thanks Yin -Original Message- From: Gerd Hoffmann Sent: Wednesday, July 19, 2023 9:48 PM To: Wang, Yin Cc:

Re: [edk2-devel] [PATCH] OvmfPkg:Fix Hii form name mismatch with EFI variable

2023-07-19 Thread Gerd Hoffmann
On Wed, Jul 19, 2023 at 03:45:20PM +0800, Yin Wang wrote: > Onemore need change beside 16acacf24c ("OvmfPkg: fix PlatformConfig") > > Find by sct cases:ExtractConfigConformance > ExtractConfigFunction > ExtractConfig_Func fail on RiscVVirtQemu. > ConfigRequestHdr =

[edk2-devel] [PATCH edk2-platforms v3 1/3] Platform/SbsaQemu: add GIC ITS support

2023-07-19 Thread Marcin Juszkiewicz
From: Shashi Mallela SBSA Reference Platform has GIC ITS support. Let make use of it. Base address is read from TF-A via SMC call. GIC ITS allows us to have complex PCI Express setups. Co-authored-by: Marcin Juszkiewicz Signed-off-by: Shashi Mallela Signed-off-by: Marcin Juszkiewicz ---

[edk2-devel] [PATCH edk2-platforms v3 3/3] Platform/SbsaQemu: handle systems without GIC ITS

2023-07-19 Thread Marcin Juszkiewicz
If firmware is used with QEMU 8.0 or older then there will be no GIC ITS support. In such case we would not add information about it into MCFG and there will be no IORT table. Signed-off-by: Marcin Juszkiewicz --- .../Qemu/SbsaQemu/AcpiTables/AcpiTables.inf | 1 -

[edk2-devel] [PATCH edk2-platforms v3 0/3] Platform/QemuSbsa: add GIC ITS

2023-07-19 Thread Marcin Juszkiewicz
SBSA Reference Platform can have GIC ITS present. And when it has then we can have complex PCI Express setup (and some other things). First patch adds support for GIC ITS. Address is read from TF-A via SMC call. IORT is generated, MADT has ITS information. Linux boots and sees GIC ITS as

[edk2-devel] [PATCH edk2-platforms v3 2/3] Platform/QemuSbsa: add dynamic PcdSmmuBase

2023-07-19 Thread Marcin Juszkiewicz
Store Smmu base address in variable in case it would be needed in more than one place. Signed-off-by: Marcin Juszkiewicz --- Silicon/Qemu/SbsaQemu/SbsaQemu.dec | 1 + Platform/Qemu/SbsaQemu/SbsaQemu.dsc | 1 + 2 files changed, 2 insertions(+) diff --git a/Silicon/Qemu/SbsaQemu/SbsaQemu.dec

[edk2-devel] [PATCH 1/1] OvmfPkg/IoMmuDxe: add locking to IoMmuAllocateBounceBuffer

2023-07-19 Thread Gerd Hoffmann
Searching for an unused bounce buffer in mReservedMemBitmap and reserving the buffer by flipping the bit is a critical section which must not be interrupted. Raise the TPL level to ensure that. Without this fix it can happen that IoMmuDxe hands out the same bounce buffer twice, causing trouble

Re: [edk2-devel] [PATCH] OvmfPkg/CloudHv: update Maintainers.txt entry

2023-07-19 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Jianyong Wu > Sent: Sunday, July 9, 2023 1:44 PM > To: devel@edk2.groups.io; Yao, Jiewen ; > ardb+tianoc...@kernel.org > Cc: Justen, Jordan L ; kra...@redhat.com; Chen, Bo2 > ; anbel...@linux.microsoft.com; jianyong...@arm.com; >

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/RiscVVirt: Check "no-map" and mark EfiReservedMemoryType

2023-07-19 Thread Ranbir Singh
Better to keep the description wrt DT spec. otherwise, looks good to me. Reviewed-by: Ranbir Singh -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#107047): https://edk2.groups.io/g/devel/message/107047 Mute This Topic:

Re: [edk2-devel] [PATCH 2/4] UefiCpuPkg: Add PcdFirstTimeWakeUpAPsBySipi

2023-07-19 Thread Ni, Ray
Reviewed-by: Ray Ni > -Original Message- > From: Xie, Yuanhao > Sent: Wednesday, July 19, 2023 3:45 PM > To: devel@edk2.groups.io > Cc: Dong, Guo ; Ni, Ray ; Rhodes, Sean > ; Lu, James ; Guo, Gua > ; Xie, Yuanhao > Subject: [PATCH 2/4] UefiCpuPkg: Add PcdFirstTimeWakeUpAPsBySipi > >

Re: [edk2-devel] [PATCH 1/4] UefiCpuPkg: Add SendStartupIpiAllExcludingSelf

2023-07-19 Thread Ni, Ray
Reviewed-by: Ray Ni > -Original Message- > From: Xie, Yuanhao > Sent: Wednesday, July 19, 2023 3:45 PM > To: devel@edk2.groups.io > Cc: Xie, Yuanhao ; Dong, Guo ; > Ni, Ray ; Rhodes, Sean ; Lu, James > ; Guo, Gua > Subject: [PATCH 1/4] UefiCpuPkg: Add SendStartupIpiAllExcludingSelf >

Re: [edk2-devel] [PATCH 4/4] UefiCpuPkg:Wake up APs after power-up or RESET through SIPI.

2023-07-19 Thread Ni, Ray
Yuanhao, Can you please mention that the new behavior follows the Intel SDM and include the SDM content in commit message? > -Original Message- > From: devel@edk2.groups.io On Behalf Of Yuanhao Xie > Sent: Wednesday, July 19, 2023 3:45 PM > To: devel@edk2.groups.io > Cc: Dong, Guo ; Ni,

[edk2-devel] [PATCH] OvmfPkg:Fix Hii form name mismatch with EFI variable

2023-07-19 Thread Wang, Yin
Onemore need change beside 16acacf24c ("OvmfPkg: fix PlatformConfig") Find by sct cases:ExtractConfigConformance ExtractConfigFunction ExtractConfig_Func fail on RiscVVirtQemu. Signed-off-by: Yin Wang --- OvmfPkg/PlatformDxe/Platform.c | 2 +-

[edk2-devel] [PATCH 4/4] UefiCpuPkg:Wake up APs after power-up or RESET through SIPI.

2023-07-19 Thread Yuanhao Xie
After a power-up or RESET, since all APs are already in the "wait-for-SIPI state", the BSP can broadcast just a single Startup IPI to the APs to wake them up and initialize them. Cc: Guo Dong Cc: Ray Ni Cc: Sean Rhodes Cc: James Lu Cc: Gua Guo Signed-off-by: Yuanhao Xie ---

[edk2-devel] [PATCH 3/4] OvmfPkg: Disable PcdFirstTimeWakeUpAPsBySipi.

2023-07-19 Thread Yuanhao Xie
Disable PcdFirstTimeWakeUpAPsBySipi for OVMF to let BSP wake up APs by INIT-SIPI-SIPI. Cc: Guo Dong Cc: Ray Ni Cc: Sean Rhodes Cc: James Lu Cc: Gua Guo Signed-off-by: Yuanhao Xie --- OvmfPkg/OvmfPkgIa32.dsc| 4 +++- OvmfPkg/OvmfPkgIa32X64.dsc | 2 ++ OvmfPkg/OvmfPkgX64.dsc | 2 ++

[edk2-devel] [PATCH 2/4] UefiCpuPkg: Add PcdFirstTimeWakeUpAPsBySipi

2023-07-19 Thread Yuanhao Xie
Add PcdFirstTimeWakeUpAPsBySipi to check if it is in the OVMF environment and necessary to wake up APs by INIT-SIPI-SIPI. Cc: Guo Dong Cc: Ray Ni Cc: Sean Rhodes Cc: James Lu Cc: Gua Guo Signed-off-by: Yuanhao Xie --- UefiCpuPkg/Library/MpInitLib/DxeMpInitLib.inf | 1 +

[edk2-devel] [PATCH 1/4] UefiCpuPkg: Add SendStartupIpiAllExcludingSelf

2023-07-19 Thread Yuanhao Xie
From: Yuanhao Xie Add new API SendStartupIpiAllExcludingSelf(), and modify SendInitSipiSipiAllExcludingSelf() by let it call the new API. Cc: Guo Dong Cc: Ray Ni Cc: Sean Rhodes Cc: James Lu Cc: Gua Guo Signed-off-by: Yuanhao Xie --- UefiCpuPkg/Include/Library/LocalApicLib.h | 17

[edk2-devel] [PATCH 0/4] Wake up APs by SIPI

2023-07-19 Thread Yuanhao Xie
After power-up or RESET, Wake up APs through SIPI. Yuanhao Xie (1): UefiCpuPkg: Add SendStartupIpiAllExcludingSelf YuanhaoXie (3): UefiCpuPkg: Add PcdFirstTimeWakeUpAPsBySipi OvmfPkg: Disable PcdFirstTimeWakeUpAPsBySipi. UefiCpuPkg:Wake up APs after power-up or RESET through SIPI.