On Mon, 15 Jul 2024 at 05:25, Nhi Pham <n...@os.amperecomputing.com> wrote:
>
> On 7/12/2024 5:01 PM, Ard Biesheuvel via groups.io wrote:
> > On Fri, 12 Jul 2024 at 11:24, Marcin Juszkiewicz
> > <marcin.juszkiew...@linaro.org> wrote:
> >>
> >> SbsaQemu platform have several cpu models available. Since start it
> >> reported "arm-virt" one in SMBIOS instead of real one.
> >>
> >> This change replaces it with the real cpu model like Cortex-A57,
> >> Neoverse-N2 etc.
> >>
> >> Requires change in EDK2 to make PcdProcessorVersion dynamic.
> >>
> >> Signed-off-by: Marcin Juszkiewicz <marcin.juszkiew...@linaro.org>
> >
> > I am going to make the same remark as I did before in a different
> > context: how is it guaranteed that the code that sets the PCD executes
> > before the code that consumes it?
>
> We could implement the setting in a 'PlatformInitDxe', which will be
> added to the 'APPRIORI DXE' list to ensure it is scheduled to run in the
> early DXE phase. This approach will help initialize the neccessary
> compoenents early in the DXE phase, providing a stable foundation for
> subsequent operations.
>

APRIORI DXE should be avoided, so I don't want to see it used in a
reference implementation. (APRIORI DXE breaks the DXE dependency based
dispatch)

> >
> > Making PCDs dynamic is usually not the solution here, unless they are
> > set in the PEI phase and consumed in the DXE phase or after.
> >
> > The EFI SMBIOS protocol has an 'update string' method that you can
> > call from a platform driver. That might be a better fit here, and the
> > PCD can remain fixed, and carry a fallback default value.
> >
>
> In fact that the 'update string' method could eat up the boot time.
> Hence, the SMBIOS string patching is not prefered.
>

Let's implement it correctly first, and then, if boot time appears to
be impacted, think about how to optimize this.

Boot time is not a huge concern for an emulator.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#119933): https://edk2.groups.io/g/devel/message/119933
Mute This Topic: https://groups.io/mt/107179083/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to