Re: [edk2-devel] When TPM is enabled, Ubuntu doesn't boot

2024-01-16 Thread Laszlo Ersek
On 1/15/24 13:34, Hamit Can Karaca wrote: > Hi Yao, Jiewen, > I actually tried to get help from the ubuntu people but they really > don't understand what is going in the UEFI side. I am trying to fix > this problem for 3 weeks now and I am about the give up. I hope > somebody can help me :( The lo

Re: [edk2-devel] [PATCH v2 2/6] OvmfPkg/VirtNorFlashDxe: clarify block write logic & fix shadowbuffer reads

2024-01-16 Thread Laszlo Ersek
mp; BOUNDARY_OF_32_WORDS) + NumBytes; //| | i.e., the relative offset inside (or just past) //| | the *double-word* such that it is the //| | *exclusive* end of the (logical) update. With that comment update: Reviewed-by: Laszlo Ersek Thanks!

Re: [edk2-devel] [PATCH v2 3/6] OvmfPkg/VirtNorFlashDxe: add a loop for NorFlashWriteBuffer calls.

2024-01-16 Thread Laszlo Ersek
er + P30_MAX_BUFFER_SIZE_IN_BYTES > + Instance->ShadowBuffer + Index * > P30_MAX_BUFFER_SIZE_IN_BYTES > ); > + if (EFI_ERROR (Status)) { > +goto Exit; > + } > } > > Exit: Reviewed-by: Laszlo Ersek -=-=-=-=-=-=

Re: [edk2-devel] [PATCH v2 4/6] OvmfPkg/VirtNorFlashDxe: allow larger writes without block erase

2024-01-16 Thread Laszlo Ersek
TES)) { > + if ((End - Start) <= (4 * P30_MAX_BUFFER_SIZE_IN_BYTES)) { > // Check to see if we need to erase before programming the data into NOR. > // If the destination bits are only changing from 1s to 0s we can just > write. > // After a block is erased all bits

Re: [edk2-devel] [PATCH v2 5/6] OvmfPkg/VirtNorFlashDxe: ValidateFvHeader: unwritten state is EOL too

2024-01-16 Thread Laszlo Ersek
302,11 @@ ValidateFvHeader ( >break; > } > > +if (VarHeader->State == 0xff) { > + DEBUG ((DEBUG_INFO, "%a: end of var list (unwritten state)\n", > __func__)); > + break; > +} > + > VarName = NULL;

Re: [edk2-devel] [PATCH v2 6/6] OvmfPkg/VirtNorFlashDxe: move DoErase code block into new function

2024-01-16 Thread Laszlo Ersek
On 1/15/24 16:59, Gerd Hoffmann wrote: > Move the DoErase code block into a separate function, call the function > instead of jumping around with goto. > > Signed-off-by: Gerd Hoffmann > --- > OvmfPkg/VirtNorFlashDxe/VirtNorFlash.c | 76 +- > 1 file changed, 51 insertions(

Re: [edk2-devel] [PATCH 1/6] UefiCpuPkg/LocalApicTimerDxe: Duplicate OvmfPkg/LocalApicTimerDxe driver

2024-01-16 Thread Laszlo Ersek
On 1/16/24 10:48, Michael Brown wrote: > On 16/01/2024 08:47, Gerd Hoffmann wrote: >> I think the reason is that the next timer interrupt arriving while the >> handler is running still is *much* more likely in virtual machines >> because the vCPU does not get 100% of the of the physical CPU time >>

Re: [edk2-devel] [PATCH v7 25/37] ArmVirtPkg: Move PlatformBootManagerLib to OvmfPkg

2024-01-16 Thread Laszlo Ersek
On 1/16/24 12:54, Chao Li wrote: > On 2024/1/15 16:46, Laszlo Ersek wrote: >> On 1/12/24 09:25, Chao Li wrote: >>> @@ -29,7 +29,6 @@ >>>QemuKernel.c >>> >>> [Packages] >>> - ArmVirtPkg/ArmVirtPkg.dec >>>MdeModulePkg/MdeMo

Re: [edk2-devel] [PATCH v2 6/6] OvmfPkg/VirtNorFlashDxe: move DoErase code block into new function

2024-01-16 Thread Laszlo Ersek
On 1/16/24 14:44, Laszlo Ersek wrote: > On 1/15/24 16:59, Gerd Hoffmann wrote: >> Move the DoErase code block into a separate function, call the function >> instead of jumping around with goto. >> >> Signed-off-by: Gerd Hoffmann >> --- >> Ovmf

Re: [edk2-devel] [PATCH 1/6] UefiCpuPkg/LocalApicTimerDxe: Duplicate OvmfPkg/LocalApicTimerDxe driver

2024-01-16 Thread Laszlo Ersek
On 1/16/24 16:16, Michael Brown wrote: > On 16/01/2024 14:34, Laszlo Ersek wrote: >> On 1/16/24 10:48, Michael Brown wrote: >> IOW, my impression is that NestedInterruptTplLib can certainly handle >> all scenarios thrown at it, but where it really matters is in the face >

Re: [edk2-devel] [PATCH 1/2] OvmfPkg: remove TPM1_ENABLE build option

2024-01-17 Thread Laszlo Ersek
> | X64 | X64| OvmfPkgIa64.dsc | None > | > | IA32 X64| PEI-IA32 DXE-X64 | OvmfPkgIa32X64.dsc | None > | > -| IA32 X64 Full | PEI-IA32 DXE-X64 | OvmfPkgIa32X64.dsc | > SECURE_BOO

Re: [edk2-devel] [PATCH 2/2] OvmfPkg/Tcg2Config: remove unused TPM 1.2 support

2024-01-17 Thread Laszlo Ersek
h interface version 1.2. > - > - @retval EFI_SUCCESS TPM-1.2 available. The Tpm12RequestUseTpm() and > - Tpm12SubmitCommand(TPM_ORD_GetTicks) operations > - (from the Tpm12DeviceLib class) have succeeded. > - > - @return

Re: [edk2-devel] [PATCH v3 6/6] OvmfPkg/VirtNorFlashDxe: move DoErase code block into new function

2024-01-17 Thread Laszlo Ersek
device back into Read Array mode > + SEND_NOR_COMMAND (Instance->DeviceBaseAddress, 0, P30_CMD_READ_ARRAY); > > - // Put the data at the appropriate location inside the buffer area > - CopyMem ((VOID *)((UINTN)Instance->ShadowBuffer + Offset), Buffer, > *NumBytes); > - &

Re: [edk2-devel] [PATCH v2 1/2] UefiCpuPkg/CpuPageTableLib: Enhance function header for PageTableMap()

2024-01-17 Thread Laszlo Ersek
On 1/17/24 07:21, Zhiguang Liu wrote: > PageTableMap() only modifies the PageTable root pointer when creating from > zero. > Explicitly explain it in function header. > > Cc: Ray Ni > Cc: Laszlo Ersek > Cc: Rahul Kumar > Cc: Gerd Hoffmann > Signed-off-by: Zhigua

Re: [edk2-devel] [PATCH v2 2/2] UefiCpuPkg/CpuMpPei: Don't write CR3 in ConvertMemoryPageToNotPresent

2024-01-17 Thread Laszlo Ersek
ction. Also, because ConvertMemoryPageToNotPresent in called in a > loop, to improve performance, there is no need to flush TLB > inside ConvertMemoryPageToNotPresent. Just flushing TLB after the loop > is enough. > > Cc: Ray Ni > Cc: Laszlo Ersek > Cc: Rahul Kumar > Cc:

Re: [edk2-devel] [PATCH v2] UefiCpuPkg: Fix issue that IsModified is wrongly set in PageTableMap

2024-01-17 Thread Laszlo Ersek
leLibMapInLevel, the function assume page > table is not changed, and add ASSERT to check. But hardware may change > the page table, which cause the ASSERT happens. > Fix the issue by considering the hardware may also change page table, > and document the detail in function header. > >

Re: [edk2-devel] [PATCH v1 1/1] MdePkg/BaseCacheMaintenanceLib: RV64 replace asserts with logs

2024-01-18 Thread Laszlo Ersek
platform/drivers need to have > better guard for such functionality. > > Signed-off-by: Dhaval Sharma > Cc: Liming Gao > Cc: Michael D Kinney > Cc: Zhiguang Liu > Cc: Sunil V L > Cc: Andrei Warkentin > Cc: Laszlo Ersek > Cc: Pedro Falcato > Cc: Yang Cheng >

Re: [edk2-devel] Memory Attribute for depex section

2024-01-18 Thread Laszlo Ersek
On 1/18/24 07:00, Nhi Pham wrote: > Hi Laszlo, > > On 1/16/2024 2:00 AM, Laszlo Ersek wrote: >> On 1/15/24 15:04, Ard Biesheuvel wrote: >>> On Mon, 15 Jan 2024 at 14:07, Nhi Pham >>> wrote: >>>> >>>> On 1/12/2024 4:45 PM, Laszlo Ersek wro

Re: [edk2-devel] [PATCH 2/2] OvmfPkg/Tcg2Config: remove unused TPM 1.2 support

2024-01-18 Thread Laszlo Ersek
On 1/17/24 15:12, Gerd Hoffmann wrote: >> This patch is good: >> >> Reviewed-by: Laszlo Ersek >> >> but the series shouldn't stop here. In "OvmfPkg/Tcg/Tcg2Config", we're >> left with an INF file (Tcg2ConfigPei.inf) that still refe

Re: [edk2-devel] [PATCH v3 0/6] OvmfPkg/VirtNorFlashDxe: fix corruption + misc small improvements

2024-01-18 Thread Laszlo Ersek
On 1/16/24 18:10, Gerd Hoffmann wrote: > This is a little series containing the flash corruption fix sent > yesterday with an slightly improved commit message and some small > improvements on top of this. > > v3: > - fix diagram > - fix DoErase control flow > - pick up reviewed-by tags > v2: >

Re: [edk2-devel] [PATCH 0/3] DxeTpm and DxeTpm2MeasureBootLib symbol rename

2024-01-18 Thread Laszlo Ersek
On 1/17/24 23:47, Doug Flick via groups.io wrote: > OVMF is failing because it includes both DxeTpm2MeasureBootLib and > DxeTpm2MeasureBootLib which makes the symbols collide. This patch > renames the function names to be unique to avoid symbol collision. > > Cc: Jiewen Yao > Cc: Rahul Kumar >

Re: [edk2-devel] RFC: Folder layout change in UefiCpuPkg

2024-01-19 Thread Laszlo Ersek
for review. > >   > > Mike, Laszlo, Gerd, Abner, any comments? I'm also OK with plan A. Thanks Laszlo > >   > >   > > Thanks, > > Ray > > *From:* Chao Li > *Sent:* Thursday, January 18, 2024 4:27 PM > *To:* Ni, Ray ; Sunil V L > *Cc:* de

Re: [edk2-devel] [PATCH 1/1] StandaloneMmPkg/Core: Remove optimization for depex evaluation

2024-01-19 Thread Laszlo Ersek
On 1/19/24 05:56, Nhi Pham wrote: > From: Laszlo Ersek > > The current dependency evaluator violates the memory access permission > when patching depex grammar directly in the read-only depex memory area. > > Laszlo pointed out the optimization issue in the thread (1) "

Re: [edk2-devel] Memory Attribute for depex section

2024-01-19 Thread Laszlo Ersek
On 1/19/24 05:43, Nhi Pham wrote: > On 1/18/2024 9:49 PM, Laszlo Ersek wrote: >>>>> but I'd prefer to just remove this >>>>> optimization from standalone MM, given that not only a) it shouldn't >>>>> have to deal with a large number of pro

Re: [edk2-devel] [PATCH v2 1/2] MdeModulePkg: Move NestedInterruptTplLib to MdeModulePkg

2024-01-22 Thread Laszlo Ersek
med by drivers outside of OvmfPkg. > > Cc: Ray Ni > Cc: Laszlo Ersek > Cc: Gerd Hoffmann > Cc: Michael D Kinney > Signed-off-by: Michael Brown > --- > MdeModulePkg/MdeModulePkg.dec | 4 > OvmfPkg/OvmfPkg.dec

Re: [edk2-devel] [PATCH v2 2/2] MdeModulePkg: Add missing Iret.h to NestedInterruptTplLib sources list

2024-01-22 Thread Laszlo Ersek
st don't like it when a commit message only consists of a subject line.) Thanks for considering! Reviewed-by: Laszlo Ersek -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#114141): https://edk2.groups.io/g/devel/message/114141

Re: [edk2-devel] [PATCH v3] UefiCpuPkg: Fix issue that IsModified is wrongly set in PageTableMap

2024-01-23 Thread Laszlo Ersek
the page table. > Also, add more comment to explain this behavior. > > Cc: Ray Ni > Cc: Laszlo Ersek > Cc: Rahul Kumar > Cc: Gerd Hoffmann > Cc: Crystal Lee > Cc: Pedro Falcato > Signed-off-by: Zhiguang Liu > --- > .../Library/CpuPageTableLib/CpuPageTableMap.

Re: [edk2-devel] [PATCH v1] MdePkg/BaseCpuLibNull: Add stub function of StandardSignatureIsAuthenticAMD() in CpuLibNull instance

2024-01-23 Thread Laszlo Ersek
On 1/23/24 12:36, Huang, Qing wrote: > CpuLib.h exposes StandardSignatureIsAuthenticAMD() API and we require stub > function in its BaseCpuLibNull library > instance to avoid potential link issue. > > Signed-off-by: Qing Huang > --- > MdePkg/Library/BaseCpuLibNull/BaseCpuLibNull.c | 17

Re: [edk2-devel] [PATCH V1 1/1] UefiCpuPkg/ResetVector: Cache Disable should not be set by default in CR0

2024-01-23 Thread Laszlo Ersek
On 1/23/24 11:52, Gerd Hoffmann wrote: > On Mon, Jan 22, 2024 at 01:11:52PM -0600, Brian J. Johnson wrote: >> On 1/18/24 09:46, Gerd Hoffmann wrote: >>> On Wed, Jan 10, 2024 at 04:43:47PM +, West, Catharine wrote: Disabling cache by default results in violation of BTG protections (if BTG

Re: [edk2-devel] [edk2-discuss] Multi-ISA Driver Compatibility Survey

2024-01-23 Thread Laszlo Ersek
On 1/22/24 20:04, Rebecca Cran wrote: > Originally posted at > https://twitter.com/UEFIForum/status/1745518769232077208 > > The Multi-ISA Driver Compatibility Survey is at > https://docs.google.com/forms/d/e/1FAIpQLScXjwaSBgLeqB1coEDxCPxho5JWF3AMqshOTJ2wd6Tf0He4LA/viewform > > From that page: >

Re: [edk2-devel] [PATCH v3 3/5] MdeModulePkg: Do nothing on NestedInterruptRestoreTPL(TPL_HIGH_LEVEL)

2024-01-23 Thread Laszlo Ersek
logic might as well be "panic" here (except edk2 does not have a central panic API that's suitable for all platforms). I probably missed the previous discussion that led to this patch. Either way, it seems reasonable. Acked-by: Laszlo Ersek -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links:

Re: [edk2-devel] [PATCH v3 4/5] MdeModulePkg: Add self-tests for NestedInterruptTplLib

2024-01-23 Thread Laszlo Ersek
t; +ASSERT (FALSE); > + } > + > + // > + // If no timer interrupt occurred then this indicates that the timer > + // interrupt handler failed to rearm the timer before calling > + // NestedInterruptRestoreTPL(). This would prevent nested > + // interrupts from occu

Re: [edk2-devel] [PATCH v3 5/5] MdeModulePkg: Extend NestedInterruptTplLib to support Arm CPUs

2024-01-23 Thread Laszlo Ersek
ld include the declarations of variables and functions for exactly those libraries that we link against. There are two exceptions (that I can think of at once): when we only want macros from a lib class header, or when we include a lib class header because we are implementing an instance for that lib class

Re: [edk2-devel] [PATCH V1 1/1] UefiCpuPkg/ResetVector: Cache Disable should not be set by default in CR0

2024-01-24 Thread Laszlo Ersek
On 1/23/24 17:11, Gerd Hoffmann wrote: > Hi, > > Well, it's OVMF in a virtual machine. No boot guard involved. > So we could probably go for a OVMF-specific patch here. > > But I'd prefer to figure what exactly is happening here before going > down that route. An extreme sl

Re: [edk2-devel] [PATCH v3 3/5] MdeModulePkg: Do nothing on NestedInterruptRestoreTPL(TPL_HIGH_LEVEL)

2024-01-24 Thread Laszlo Ersek
On 1/23/24 17:59, Michael Brown wrote: > On 23/01/2024 16:32, Laszlo Ersek wrote: >> On 1/23/24 16:31, Michael Brown wrote: >>> At TPL_HIGH_LEVEL, CPU interrupts are disabled (as per the UEFI >>> specification) and so we should never encounter a situation in which

Re: [edk2-devel] [PATCH v3 4/5] MdeModulePkg: Add self-tests for NestedInterruptTplLib

2024-01-24 Thread Laszlo Ersek
On 1/23/24 18:41, Michael Brown wrote: > On 23/01/2024 16:55, Laszlo Ersek wrote: >>> +  /// >>> +  /// Number of self-tests performed. >>> +  /// >>> +  UINTN  SelfTestCount; >>>   } NESTED_INTERRUPT_STATE; >>>     /** >> >&g

Re: [edk2-devel] [Patch 1/1] MdePkg/Library/BaseCpuLibNull: Add missing X86 specific services

2024-01-24 Thread Laszlo Ersek
b library class include to all C files. > > Cc: Liming Gao > Cc: Zhiguang Liu > Cc: Laszlo Ersek > Cc: Qing Huang > Signed-off-by: Michael D Kinney > --- > .../Library/BaseCpuLibNull/BaseCpuLibNull.c | 17 + > .../Library/BaseCpuLibNull/BaseCpuLibNull.inf | 3 +

Re: [edk2-devel] [PATCH] MdeModulePkg/SMM: Support to unregister SMI handler inside SMI handler

2024-01-24 Thread Laszlo Ersek
is the spec silent on it (in which case I guess we can call this a quality-of-implementation improvement)? > > Reviewed-by: Ray Ni Reviewed-by: Laszlo Ersek Thanks Laszlo > > Thanks, > Ray >> -Original Message- >> From: Liu, Zhiguang >> Sent: Wednesday,

Re: [edk2-devel] Resources for Creating Packages

2024-01-24 Thread Laszlo Ersek
meta (CC Mike): On 1/22/24 19:25, ryderkeys via groups.io wrote: > (Originally sent to edk2 discuss but it looks like my message has > been stuck in moderation for a week, so I thought I would try here > instead.) I'm now checking the moderation queue for edk2-discuss; I seem to have found your o

Re: [edk2-devel] [Patch v2 1/1] MdeModulePkg/Core/Dxe: Set MemoryTypeInfo bin range from HOB

2024-01-24 Thread Laszlo Ersek
On 1/23/24 21:24, Michael D Kinney wrote: > Provide an optional method for PEI to declare a specific address > range to use for the Memory Type Information bins. The current > algorithm uses heuristics that tends to place the Memory Type > Information bins in the same location, but memory configura

Re: [edk2-devel] [Patch v2 1/1] MdeModulePkg/Core/Dxe: Set MemoryTypeInfo bin range from HOB

2024-01-24 Thread Laszlo Ersek
On 1/23/24 21:24, Michael D Kinney wrote: > Provide an optional method for PEI to declare a specific address > range to use for the Memory Type Information bins. The current > algorithm uses heuristics that tends to place the Memory Type > Information bins in the same location, but memory configura

Re: [edk2-devel] pixiefail

2024-01-24 Thread Laszlo Ersek
On 1/23/24 19:49, Doug Flick via groups.io wrote: > Gerd, > > As a new EDK2 developer, I'm working through getting the patches up > to EDK2 but I have to follow the EDK2 patch process which is not the > fastest thing to follow and also not my day job. If you want to see > where I am you can look a

Re: [edk2-devel] [PATCH V1 1/1] UefiCpuPkg/ResetVector: Cache Disable should not be set by default in CR0

2024-01-24 Thread Laszlo Ersek
On 1/24/24 14:26, Gerd Hoffmann wrote: > Hi, > >> So, yesterday I read your status on virt-staff, and I found an entry in >> it that resembled this upstream thread pretty closely. However, your >> status was the *only* mention of "mdev" specifically, and so I wasn't >> sure if *mdev* meant the s

Re: [edk2-devel] pixiefail

2024-01-24 Thread Laszlo Ersek
On 1/24/24 15:35, Laszlo Ersek wrote: > I figure the most flexible approach for those that dislike email-based > review for embargoed patches would be if github.com supported locked > down *PRs* (i.e., not private organizatons). In other words, if those > PRs would be submitted agai

Re: [edk2-devel] pixiefail

2024-01-24 Thread Laszlo Ersek
the GHSA process looks great! I didn't know! Thanks! Laszlo > > On Wed, Jan 24, 2024 at 6:57 AM Laszlo Ersek <mailto:ler...@redhat.com>> wrote: > > On 1/24/24 15:35, Laszlo Ersek wrote: > > > I figure the most flexible approach for those that di

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/Sec: Setup MTRR early in the boot process.

2024-01-24 Thread Laszlo Ersek
On 1/24/24 16:15, Gerd Hoffmann wrote: > Specifically before running lzma uncompress of the main firmware volume. > This is needed to make sure caching is enabled, otherwise the uncompress > can be extremely slow. > > Adapt the ASSERTs in PlatformInitLib to the changes. > > Background: In some v

Re: [edk2-devel] 回复: [Patch v2 1/1] MdeModulePkg/Core/Dxe: Set MemoryTypeInfo bin range from HOB

2024-01-24 Thread Laszlo Ersek
On 1/24/24 15:59, gaoliming via groups.io wrote: > Mike: > Current algorithm tries to reserve the top available memory for memory type > bin range. > If the platform uses new way to describe the memory range, should we > suggest the rule to still > use the top memory resource hob for the memor

Re: [edk2-devel] [PATCH 1/1] MdeModulePkg/VirtualMemory: drop 5-level paging assert

2024-01-24 Thread Laszlo Ersek
On 1/24/24 16:49, Gerd Hoffmann wrote: > The ResetVector decides at runtime (depending in CPU capabilities) (1) s/depending in/dependent on/ > whenever it uses 5-level paging or not. Firmware builds with 5-level > paging enabled (PcdUse5LevelPageTable=TRUE) may run run in 4-level (2) typo: "run

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/ResetVector: send post codes to qemu debug console

2024-01-24 Thread Laszlo Ersek
On 1/24/24 16:31, Gerd Hoffmann wrote: > Neat when doing ResetVector coding. > > Signed-off-by: Gerd Hoffmann > --- > OvmfPkg/ResetVector/DebugCon.asm | 43 +++ > OvmfPkg/ResetVector/ResetVector.nasmb | 2 +- > 2 files changed, 44 insertions(+), 1 deletion(-) > cre

Re: [edk2-devel] [PATCH] MdeModulePkg/SMM: Support to unregister SMI handler inside SMI handler

2024-01-24 Thread Laszlo Ersek
> *From:*Ni, Ray > *Sent:* Wednesday, January 24, 2024 11:17 AM > *To:* Laszlo Ersek ; devel@edk2.groups.io; Liu, > Zhiguang > *Cc:* Liming Gao ; Wu, Jiaxin > ; Felix Polyudov > *Subject:* [EXTERNAL] Re: [edk2-devel] [PATCH] MdeModulePkg/SMM: Support > to unregister SMI

Re: [edk2-devel] [PATCH] MdeModulePkg/SMM: Support to unregister SMI handler inside SMI handler

2024-01-25 Thread Laszlo Ersek
On 1/24/24 05:03, Zhiguang Liu wrote: > To support unregister SMI handler inside SMI handler itself, > get next node before SMI handler is executed, since LIST_ENTRY that > Link points to may be freed if unregister SMI handler in SMI handler > itself. > > Cc: Liming Gao > Cc: Jiaxin Wu > Cc: Ray

Re: [edk2-devel] [PATCH 01/11] OvmfPkg: add ShellComponents.dsc.inc

2024-01-25 Thread Laszlo Ersek
vmfPkg/OvmfPkgX64.dsc | 43 +- > 2 files changed, 50 insertions(+), 42 deletions(-) > create mode 100644 OvmfPkg/Include/Dsc/ShellComponents.dsc.inc "git show --color --color-moved=zebra" works wonders on this patch. Reviewed-by: Laszlo Ersek -=-=-=-=-=-=-=-

Re: [edk2-devel] [PATCH 02/11] OvmfPkg: add ShellLibs.dsc.inc

2024-01-25 Thread Laszlo Ersek
I have several comments on this one: On 1/24/24 17:37, Gerd Hoffmann wrote: > Move EFI Shell libraries from OvmfPkgX64.dsc to > the new ShellComponents.dsc.inc include file. > > Signed-off-by: Gerd Hoffmann > --- > OvmfPkg/Include/Dsc/ShellLibs.dsc.inc | 11 +++ > OvmfPkg/OvmfPkgX64.dsc

Re: [edk2-devel] [PATCH 03/11] OvmfPkg: add ShellDxe.fdf.inc

2024-01-25 Thread Laszlo Ersek
inf > +INF ShellPkg/DynamicCommand/HttpDynamicCommand/HttpDynamicCommand.inf > +INF > OvmfPkg/LinuxInitrdDynamicShellCommand/LinuxInitrdDynamicShellCommand.inf > +!endif > + > +INF ShellPkg/Application/Shell/Shell.inf > +!endif ... and this indeed shows, in comparison to patch#

Re: [edk2-devel] [PATCH 04/11] OvmfPkg: Shell*.inc: allow building without network support

2024-01-25 Thread Laszlo Ersek
On 1/24/24 17:37, Gerd Hoffmann wrote: > Add NETWORK_ENABLE conditionals for the components > which need network support. > > Signed-off-by: Gerd Hoffmann > --- > OvmfPkg/Include/Dsc/ShellComponents.dsc.inc | 4 > OvmfPkg/Include/Fdf/ShellDxe.fdf.inc| 2 ++ > 2 files changed, 6 inse

Re: [edk2-devel] [PATCH 05/11] OvmfPkg: ShellDxe.fdf.inc: add VariablePolicyDynamicCommand to FV

2024-01-25 Thread Laszlo Ersek
riablePolicyDynamicCommand.inf > INF > OvmfPkg/LinuxInitrdDynamicShellCommand/LinuxInitrdDynamicShellCommand.inf > !endif > Reviewed-by: Laszlo Ersek -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#114431): https://edk2.groups.io/g/deve

Re: [edk2-devel] [PATCH 06/11] OvmfPkg: switch OvmfPkgIa32 to new shell include files

2024-01-25 Thread Laszlo Ersek
xe.inf > !endif Note that this patch is inconsistent with patch#2 (OvmfPkg: add ShellLibs.dsc.inc); in that patch, "OvmfPkgX64.dsc" gets a module-scope ShellCEntryLib class resolution for "EnrollDefaultKeys.inf", but here, "OvmfPkgIa32.dsc". *However*, that incons

Re: [edk2-devel] [PATCH 07/11] OvmfPkg: switch OvmfPkgIa32X64 to new shell include files

2024-01-25 Thread Laszlo Ersek
!if $(SECURE_BOOT_ENABLE) == TRUE > > SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf > - OvmfPkg/EnrollDefaultKeys/EnrollDefaultKeys.inf > + OvmfPkg/EnrollDefaultKeys/EnrollDefaultKeys.inf { > + > +ShellCEntryLib|ShellPkg/Library/UefiS

Re: [edk2-devel] [PATCH 08/11] OvmfPkg: switch AmdSevX64 to new shell include files

2024-01-25 Thread Laszlo Ersek
clude/Dsc/ShellComponents.dsc.inc > >OvmfPkg/PlatformDxe/Platform.inf >OvmfPkg/AmdSevDxe/AmdSevDxe.inf { (1) This is not an identical change. That's alright (we could say this is an intended benefit from factoring out the shell stuff -- it is now bringing forward this platfor

Re: [edk2-devel] [PATCH 09/11] OvmfPkg: switch IntelTdxX64 to new shell include files

2024-01-25 Thread Laszlo Ersek
cShellCommand.inf > -!endif > -!if $(BUILD_SHELL) == TRUE > -INF ShellPkg/Application/Shell/Shell.inf > -!endif > - > INF MdeModulePkg/Logo/LogoDxe.inf > > # > @@ -332,6 +325,8 @@ [FV.NCCFV] > INF OvmfPkg/VirtioGpuDxe/VirtioGpu.inf &g

Re: [edk2-devel] [PATCH 10/11] OvmfPkg: switch MicrovmX64 to new shell include files

2024-01-25 Thread Laszlo Ersek
igDxe.inf > - OvmfPkg/EnrollDefaultKeys/EnrollDefaultKeys.inf > + OvmfPkg/EnrollDefaultKeys/EnrollDefaultKeys.inf { > + > +ShellCEntryLib|ShellPkg/Library/UefiShellCEntryLib/UefiShellCEntryLib.inf > + } > !endif > >OvmfPkg/PlatformDxe/Platform.inf &quo

Re: [edk2-devel] [PATCH 11/11] OvmfPkg/CI: copy shell to virtual drive

2024-01-25 Thread Laszlo Ersek
On 1/24/24 17:38, Gerd Hoffmann wrote: > Place the EFI shell as EFI/BOOT/BOOT{ARCH}.EFI on the virtual drive. > This allows the "run to shell" CI test case to work even in case the > shell is not included in the firmware image. In the commit message, can you list the platforms explicitly that bene

Re: [edk2-devel] [PATCH] MdeModulePkg/SMM: Support to unregister SMI handler inside SMI handler

2024-01-25 Thread Laszlo Ersek
On 1/25/24 13:05, Ni, Ray wrote: > Laszlo, > SMI handler is called from SmmCore. > So SmmCore knows which handle is passed to the SMI handler. > How about let Unregister() rejects the request coming from a SMI handler > which unregisters other handles? > > A "gCurrentSmiHandle" can be assigned be

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/Sec: Setup MTRR early in the boot process.

2024-01-25 Thread Laszlo Ersek
On 1/25/24 07:52, Gerd Hoffmann wrote: > On Wed, Jan 24, 2024 at 05:14:10PM +0100, Laszlo Ersek wrote: >> On 1/24/24 16:15, Gerd Hoffmann wrote: >>> Specifically before running lzma uncompress of the main firmware volume. >>> This is needed to make sure caching is enable

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/ResetVector: send post codes to qemu debug console

2024-01-25 Thread Laszlo Ersek
On 1/25/24 08:50, Gerd Hoffmann wrote: > On Wed, Jan 24, 2024 at 05:43:29PM -0800, Erdem Aktas wrote: >> Same for TDX, I did not run it but it should cause failure >> as debugShowPostCode is called OvmfPkg/ResetVector/Ia32/IntelTdx.asm before >> actually the #VE handlers are installed. >> >>> Had a

Re: [edk2-devel] [Patch v2 1/1] MdeModulePkg/Core/Dxe: Set MemoryTypeInfo bin range from HOB

2024-01-25 Thread Laszlo Ersek
On 1/24/24 18:46, Kinney, Michael D wrote: > Hi Laszlo, > > Yes. I can add more details in the commit message. > > The impact is for ACPI S4. There are many reasons why the set of > HOBs passed into the DXE Core may change from boot to boot or that > allocations in the early DXE init phase shou

Re: [edk2-devel] [PATCH v2 0/2] MdeModulePkg: 5-level paging fixes

2024-01-25 Thread Laszlo Ersek
rtions(+), 6 deletions(-) > series Reviewed-by: Laszlo Ersek Feel free to keep the R-b if Ray suggests a different approach for the PCD renaming (e.g., keeping the existing name, or replacing "PcdGetBool (PcdUse5LevelPageTable)" with constant TRUE altogether) Laszlo -=-=-=-

Re: [edk2-devel] [PATCH v2 1/4] OvmfPkg/Sec: Setup MTRR early in the boot process.

2024-01-25 Thread Laszlo Ersek
On 1/25/24 11:52, Pedro Falcato wrote: > On Thu, Jan 25, 2024 at 8:23 AM Gerd Hoffmann wrote: >> >> Specifically before running lzma uncompress of the main firmware volume. >> This is needed to make sure caching is enabled, otherwise the uncompress >> can be extremely slow. >> >> Adapt the ASSERTs

[edk2-devel] [edk2-platforms PATCH 1/1] AmpereAltraPkg/Ac01PcieLib: drop useless link status register read

2023-10-17 Thread Laszlo Ersek
: Nhi Pham Cc: Rebecca Cran Suggested-by: Nhi Pham Signed-off-by: Laszlo Ersek --- Silicon/Ampere/AmpereAltraPkg/Library/Ac01PcieLib/PcieCore.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/Silicon/Ampere/AmpereAltraPkg/Library/Ac01PcieLib/PcieCore.c b/Silicon/Ampere/AmpereAltraP

Re: [edk2-devel] [PATCH v2 1/1] UefiCpuPkg/BaseXApicX2ApicLib: fix CPUID_V2_EXTENDED_TOPOLOGY detection

2023-10-17 Thread Laszlo Ersek
0; > + } else { > +AsmCpuidEx (CPUID_V2_EXTENDED_TOPOLOGY, 0, NULL, > &ExtendedTopologyEbx.Uint32, NULL, NULL); > + } > + > + if (ExtendedTopologyEbx.Bits.LogicalProcessors == 0) { > if (Die != NULL) { >*Die = 0; > } Reviewed-by: Laszlo Erse

Re: [edk2-devel] [edk2-platforms PATCH 1/1] AmpereAltraPkg/Ac01PcieLib: drop useless link status register read

2023-10-17 Thread Laszlo Ersek
On 10/17/23 13:38, Nhi Pham via groups.io wrote: > Thanks, Laszlo for this patch. > > Reviewed-by: Nhi Pham > > Regards, > Nhi Thank you both for reviewing; commit 7f3e7fc0b4ed. Laszlo > > On 10/17/2023 5:05 PM, Laszlo Ersek via groups.io wrote:

Re: [edk2-devel] [PATCH v5 1/2] MdePkg:Implement RISCV CMO

2023-10-17 Thread Laszlo Ersek
On 10/17/23 14:17, Dhaval Sharma wrote: > Implementing code to support Cache Management Operations > (CMO) defined by RV spec https://github.com/riscv/riscv-CMOs > > Notes: > 1. CMO only supports block based Operations. Meaning complete >cache flush/invd/clean Operations are not available. In t

Re: [edk2-devel] [PATCH v5 2/2] OvmfPkg/RiscVVirt: Override for RV CPU Features

2023-10-17 Thread Laszlo Ersek
On 10/17/23 14:17, Dhaval Sharma wrote: > This PCD provides a way for platform to override any > HW features that are default enabled by previous stages > of FW (like OpenSBI). For the case where previous/prev > stage has disabled the feature, this override is not > useful and its usage should be a

Re: [edk2-devel] [PATCH v5 1/2] MdePkg:Implement RISCV CMO

2023-10-17 Thread Laszlo Ersek
On 10/17/23 16:22, Laszlo Ersek wrote: > On 10/17/23 14:17, Dhaval Sharma wrote: >> Implementing code to support Cache Management Operations >> (CMO) defined by RV spec https://github.com/riscv/riscv-CMOs (28) Please do not abbreviate RISC-V as "RV". It's incredibly

Re: [edk2-devel] [PATCH v5 2/2] OvmfPkg/RiscVVirt: Override for RV CPU Features

2023-10-17 Thread Laszlo Ersek
On 10/17/23 14:17, Dhaval Sharma wrote: > This PCD provides a way for platform to override any > HW features that are default enabled by previous stages > of FW (like OpenSBI). For the case where previous/prev > stage has disabled the feature, this override is not > useful and its usage should be a

Re: [edk2-devel] [PATCH edk2-platforms v5 7/7] Sophgo/SG2042Pkg: Add platform readme and document.

2023-10-18 Thread Laszlo Ersek
On 10/13/23 05:03, caiyuqing...@163.com wrote: > diff --git a/Platform/Sophgo/Maintainers.md b/Platform/Sophgo/Maintainers.md > new file mode 100644 > index ..4cb32c359a31 > --- /dev/null > +++ b/Platform/Sophgo/Maintainers.md > @@ -0,0 +1,105 @@ > +##Project Name: EDK2 Sophgo SG2042 >

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/VirtioFsDxe: fix SimpleFileOpen

2023-10-18 Thread Laszlo Ersek
; FileName=\"%s\": " It's nice to see this topic pop up on edk2-devel; apparently you started testing shim on top of virtio-fs. :) I have had the following patch in my local repo, on a separate branch, since April this year: > commit cb4a6d1664ea6cabd14d2af0e5d9abb114973

Re: [edk2-devel] [PATCH edk2-platforms v5 7/7] Sophgo/SG2042Pkg: Add platform readme and document.

2023-10-18 Thread Laszlo Ersek
tility creates a git-format-patch alias called "fp" that includes these options. BTW I could help Ard out by pushing this patch set (well, v4, with the Maintainers.txt fix), I'm just not clear when a patch set counts as "sufficiently reviewed" for edk2-platforms. Laszlo

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/VirtioFsDxe: fix SimpleFileOpen

2023-10-18 Thread Laszlo Ersek
On 10/18/23 13:33, Pedro Falcato wrote: > On Wed, Oct 18, 2023 at 12:20 PM Laszlo Ersek wrote: >> >> On 10/18/23 12:33, Gerd Hoffmann wrote: >>> VirtiofsDxe throws an error in case the caller tries to open a file or >>> directory using an handle with is not a

Re: [edk2-devel] [PATCH] Remove memory cache setting for memory under 1MB

2023-10-18 Thread Laszlo Ersek
On 10/18/23 13:55, Yuanhao Xie wrote: > With the fact that CSM is not supported, > the request is to remove the cache setting for memory under 1MB. > This can be treated as the missing part of legacy CSM deprecation. > > This patch only set the 0 to 9 and C to F as Write Back. > A0

Re: [edk2-devel] [PATCH edk2-platforms v4 4/4] SbsaQemu: disable XHCI in DSDT if not present

2023-10-18 Thread Laszlo Ersek
On 10/18/23 13:28, Marcin Juszkiewicz wrote: > W dniu 18.10.2023 o 13:23, Pedro Falcato pisze: >> On Wed, Oct 18, 2023 at 12:16 PM Marcin Juszkiewicz >> wrote: >>> >>> W dniu 18.10.2023 o 12:32, Nhi Pham pisze: Acked-by: Nhi Pham Nit: I think you want to run uncrustify for Patch 3

Re: [edk2-devel] [PATCH 1/5] PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe: rename LibRtcVirtualNotifyEvent

2023-10-18 Thread Laszlo Ersek
t;devel@edk2.groups.io <mailto:devel@edk2.groups.io> on > behalf of Laszlo Ersek via groups.io" <mailto:devel@edk2.groups.io> on behalf of lersek=redhat@groups.io > <mailto:redhat@groups.io>> wrote: > > > PcatRealTimeClockRuntimeDxe seems to have c

Re: [edk2-devel] [PATCH 0/5] EmbeddedPkg/RealTimeClockLib: drop LibRtcVirtualNotifyEvent from lib class

2023-10-18 Thread Laszlo Ersek
On 10/12/23 11:10, Laszlo Ersek wrote: > https://bugzilla.tianocore.org/show_bug.cgi?id=4564 > > The RealTimeClockLib class header in edk2's EmbeddedPkg mistakenly > declares a function called LibRtcVirtualNotifyEvent(). No component ever > calls this function across mo

Re: [edk2-devel] [PATCH edk2-platforms v5 7/7] Sophgo/SG2042Pkg: Add platform readme and document.

2023-10-18 Thread Laszlo Ersek
On 10/18/23 14:21, Sunil V L wrote: > On Wed, Oct 18, 2023 at 02:11:17PM +0200, Laszlo Ersek wrote: >> On 10/18/23 13:21, 蔡雨晴 wrote: >>> Hi Laszlo, >>> >>> Thank you for your comments. I will commit a new patch to add the >>> maintainers to the "

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/VirtioFsDxe: fix SimpleFileOpen

2023-10-18 Thread Laszlo Ersek
On 10/18/23 15:08, Pedro Falcato wrote: > On Wed, Oct 18, 2023 at 1:20 PM Laszlo Ersek wrote: >> >> On 10/18/23 13:33, Pedro Falcato wrote: >>> On Wed, Oct 18, 2023 at 12:20 PM Laszlo Ersek wrote: >>>> >>>> On 10/18/23 12:33, Gerd Hoffmann wrot

Re: [edk2-devel] [PATCH 1/1] OvmfPkg/VirtioFsDxe: fix SimpleFileOpen

2023-10-18 Thread Laszlo Ersek
On 10/18/23 15:13, Gerd Hoffmann wrote: > Hi, > >>> - if (!VirtioFsFile->IsDirectory) { >>> + if (!VirtioFsFile->IsDirectory && FileName[0] != '\\') { > >> It's nice to see this topic pop up on edk2-devel; apparently you started >> testing shim on top of virtio-fs. :) > > Indeed. For starte

Re: [edk2-devel] [PATCH 1/5] PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe: rename LibRtcVirtualNotifyEvent

2023-10-18 Thread Laszlo Ersek
On 10/18/23 17:15, Sami Mujawar wrote: > Hi Laszlo, > > Please see my response inline marked [SAMI]. > > Regards, > > Sami Mujawar > > On 18/10/2023, 14:42, "Laszlo Ersek" <mailto:ler...@redhat.com>> wrote: > > > Hi Sami, >

Re: [edk2-devel] [PATCH 0/5] EmbeddedPkg/RealTimeClockLib: drop LibRtcVirtualNotifyEvent from lib class

2023-10-18 Thread Laszlo Ersek
On 10/18/23 15:44, Ard Biesheuvel wrote: > On Wed, 18 Oct 2023 at 15:43, Laszlo Ersek wrote: >> >> On 10/12/23 11:10, Laszlo Ersek wrote: >>> https://bugzilla.tianocore.org/show_bug.cgi?id=4564 >>> >>> The RealTimeClockLib class header in edk2's

[edk2-devel] [PATCH] OvmfPkg/VirtioFsDxe: tolerate opening an abs. pathname rel. to a reg. file

2023-10-18 Thread Laszlo Ersek
euvel Cc: Gerd Hoffmann Cc: Jiewen Yao Cc: Jordan Justen Signed-off-by: Laszlo Ersek --- Notes: context:-U4 OvmfPkg/VirtioFsDxe/SimpleFsOpen.c | 17 ++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/OvmfPkg/VirtioFsDxe/SimpleFsOpen.c b/OvmfPkg/VirtioFsDxe

Re: [edk2-devel] [PATCH v5 2/2] OvmfPkg/RiscVVirt: Override for RV CPU Features

2023-10-19 Thread Laszlo Ersek
ne* > (25-26) The *API* renames belong to v6 patch#2. & The new APIs, plus the > *file* rename, belong to v6 patch#3. *Done* > (27) Please use the assembler macros from point (11). Please see (11) > (28-29-30-31) Please do not abbreviate RISC-V as "RV". It's incredi

Re: [edk2-devel] Question about OvmfPackage cxl emulation support

2023-10-19 Thread Laszlo Ersek
On 10/19/23 03:51, Yoshinoya wrote: > Hi, > I findd qemu supports cxl emulation, but it uses seabios as virtual > machine firmware. > > Does UEFI OvmfPackage have a plan to support CXL device enumeration and > declaration? I expect MdeModulePkg would have to add some generic CXL device driver, wh

Re: [edk2-devel] [PATCH v5 2/2] OvmfPkg/RiscVVirt: Override for RV CPU Features

2023-10-19 Thread Laszlo Ersek
On 10/19/23 11:22, Laszlo Ersek wrote: > On 10/19/23 08:48, Dhaval Sharma wrote: >> (11) I agree that we should use symbolic names rather than >> magic constants, but raw encodings of machine instructions don't belong >> into a >>      C header file. [Dhaval] This

Re: [edk2-devel] [PATCH] OvmfPkg/VirtioFsDxe: tolerate opening an abs. pathname rel. to a reg. file

2023-10-19 Thread Laszlo Ersek
On 10/19/23 08:28, Gerd Hoffmann wrote: > On Wed, Oct 18, 2023 at 07:24:34PM +0200, Laszlo Ersek wrote: >> Referring to a file relative to a regular file makes no sense (or at least >> it cannot be implemented consistently with how a file is referred to >> re

Re: [edk2-devel] [PATCH v1 1/1] Maintainers.txt: Add maintainers for Sophgo platform

2023-10-19 Thread Laszlo Ersek
;Maintainers.txt" file. > > Cc: dahogn > Cc: meng-cz > Cc: USER0FISH > Cc: Sunil V L > Cc: Leif Lindholm > Cc: Michael D Kinney > Cc: Laszlo Ersek > Signed-off-by: caiyuqing379 > --- > Maintainers.txt| 9 ++ > Platform/Sophgo/Mainta

Re: [edk2-devel] [PATCH] OvmfPkg/VirtioFsDxe: tolerate opening an abs. pathname rel. to a reg. file

2023-10-19 Thread Laszlo Ersek
On 10/19/23 15:50, Pedro Falcato wrote: > On Wed, Oct 18, 2023 at 6:24 PM Laszlo Ersek wrote: >> >> Referring to a file relative to a regular file makes no sense (or at least >> it cannot be implemented consistently with how a file is referred to >&

Re: [edk2-devel] [PATCH v5 2/2] OvmfPkg/RiscVVirt: Override for RV CPU Features

2023-10-19 Thread Laszlo Ersek
for this. (And even if CI has gcc-12, I'd still ask for the macros, because RHEL9 / EPEL9 don't seem to have a new enough binutils.) Thanks Laszlo > > On Thu, Oct 19, 2023 at 5:47 PM Laszlo Ersek <mailto:ler...@redhat.com>> wrote: > > On 10/19/23 11:2

Re: [edk2-devel] [PATCH v1] EmbeddedPkg/NorFlashInfoLib: Update norflash device list

2023-10-20 Thread Laszlo Ersek
On 10/18/23 10:57, Ard Biesheuvel wrote: > On Wed, 18 Oct 2023 at 10:49, YuinYee Chew > wrote: >> >> Dear Maintainers, >> >> Just a friendly reminder to ask if you could take a look at my patch. I'd >> really appreciate your feedback and help. >> > > Thanks for the reminder. I don't have time to

[edk2-devel] [PATCH] ArmPlatformPkg/PL031RealTimeClockLib: remove superfluous instance init steps

2023-10-20 Thread Laszlo Ersek
undant for step (3); it does not try to set "gRT" fields). (Note that the lib instance INF file already does not list gEfiRealTimeClockArchProtocolGuid.) Tested with ArmVirtQemu. Cc: Ard Biesheuvel Cc: Leif Lindholm Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=4565 Signed-

[edk2-devel] [edk2-platforms PATCH 1/7] Hisilicon/DS3231RealTimeClockLib: remove superfluous instance init steps

2023-10-20 Thread Laszlo Ersek
ready does not list UefiBootServicesTableLib, UefiRuntimeServicesTableLib, and gEfiRealTimeClockArchProtocolGuid.) Build-tested only (with the D03 and D05 platforms). Cc: Ard Biesheuvel Cc: Leif Lindholm Cc: Wenyi Xie Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=4565 Signed-off-by: L

[edk2-devel] [edk2-platforms PATCH 0/7] drop needless init steps in RealTimeClockLib instances

2023-10-20 Thread Laszlo Ersek
: Leif Lindholm Cc: Ling Jia Cc: Marcin Wojtas Cc: Peng Xie Cc: Wenyi Xie Cc: Xianglai li Cc: Yiqi Shu Thanks Laszlo Laszlo Ersek (7): Hisilicon/DS3231RealTimeClockLib: remove superfluous instance init steps LoongArchQemuPkg/LsRealTimeClockLib: remove superfluous instance init

<    1   2   3   4   5   6   7   8   9   10   >