Hi Rebecca,

Thanks for the effort to fix this.


On Tue, 21 Feb 2023 at 02:03, Rebecca Cran <rebe...@quicinc.com> wrote:
>
> The MetronomeDxe driver uses the PCD PcdMetronomeTickPeriod to calculate
> how many ticks to wait in MicroSecondDelay. Given that the timer clock
> on Juno runs at 50 MHz, it ticks every 20 ns; therefore, a setting of
> 1000 is wrong: for example it causes a call to gBS->Stall (1) to take
> 10 us.
>
> The driver in MdeModulePkg/Universal/Metronome assumes the clock ticks
> at least every 100 ns, which is the minimum allowed by the Metronome
> protocol. Since that's the case on Juno, switch from
> EmbeddedPkg/MetronomeDxe to MdeModulePkg/Universal/Metronome.
>
> Signed-off-by: Rebecca Cran <rebe...@quicinc.com>

Makes sense. It wonder why we still have the EmbeddedPkg version in
the first place, given that the MdeModulePkg does the same thing but
better.

> ---
>  Platform/ARM/JunoPkg/ArmJuno.dsc | 3 +--
>  Platform/ARM/JunoPkg/ArmJuno.fdf | 2 +-
>  2 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/Platform/ARM/JunoPkg/ArmJuno.dsc 
> b/Platform/ARM/JunoPkg/ArmJuno.dsc
> index a00b866c5e9a..9cde4c862651 100644
> --- a/Platform/ARM/JunoPkg/ArmJuno.dsc
> +++ b/Platform/ARM/JunoPkg/ArmJuno.dsc
> @@ -189,7 +189,6 @@
>    # ARM Architectural Timer Frequency
>    #
>    gArmTokenSpaceGuid.PcdArmArchTimerFreqInHz|50000000
> -  gEmbeddedTokenSpaceGuid.PcdMetronomeTickPeriod|1000
>
>    gEfiMdeModulePkgTokenSpaceGuid.PcdResetOnMemoryTypeInformationChange|FALSE
>
> @@ -248,10 +247,10 @@
>    MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
>    MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
>    MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
> +  MdeModulePkg/Universal/Metronome/Metronome.inf
>    
> MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
>    MdeModulePkg/Universal/ResetSystemRuntimeDxe/ResetSystemRuntimeDxe.inf
>    EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
> -  EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
>
>    MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
>    MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
> diff --git a/Platform/ARM/JunoPkg/ArmJuno.fdf 
> b/Platform/ARM/JunoPkg/ArmJuno.fdf
> index fca5a78cee6c..836d3cde8781 100644
> --- a/Platform/ARM/JunoPkg/ArmJuno.fdf
> +++ b/Platform/ARM/JunoPkg/ArmJuno.fdf
> @@ -96,10 +96,10 @@ FvNameGuid         = B73FE497-B92E-416e-8326-45AD0D270092
>    INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
>    INF MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
>    INF MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
> +  INF MdeModulePkg/Universal/Metronome/Metronome.inf
>    INF 
> MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
>    INF MdeModulePkg/Universal/ResetSystemRuntimeDxe/ResetSystemRuntimeDxe.inf
>    INF EmbeddedPkg/RealTimeClockRuntimeDxe/RealTimeClockRuntimeDxe.inf
> -  INF EmbeddedPkg/MetronomeDxe/MetronomeDxe.inf
>
>    INF MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
>    INF MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
> --
> 2.30.2
>


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


Reply via email to