<p>Martin Roth has uploaded this change for <strong>review</strong>.</p><p><a href="https://review.coreboot.org/22798">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">soc/amd/common: Collect timestamps before and after AGESA calls<br><br>BUG=b:70432544<br>TEST=Build & boot kahlee. Look at timestamps.<br><br>Change-Id: I8209160f8e23ab77987f8e515c7b00d94f68c8be<br>Signed-off-by: Martin Roth <martinroth@google.com><br>---<br>M src/soc/amd/common/agesawrapper.c<br>1 file changed, 19 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://review.coreboot.org:29418/coreboot refs/changes/98/22798/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/src/soc/amd/common/agesawrapper.c b/src/soc/amd/common/agesawrapper.c<br>index b939183..6d8796c 100644<br>--- a/src/soc/amd/common/agesawrapper.c<br>+++ b/src/soc/amd/common/agesawrapper.c<br>@@ -20,6 +20,7 @@<br> #include <cpu/x86/mtrr.h><br> #include <BiosCallOuts.h><br> #include <string.h><br>+#include <timestamp.h><br> <br> void __attribute__((weak)) SetMemParams(AMD_POST_PARAMS *PostParams) {}<br> void __attribute__((weak)) OemPostParams(AMD_POST_PARAMS *PostParams) {}<br>@@ -62,7 +63,10 @@<br>        AmdResetParams.FchInterface.SataEnable = !((CONFIG_STONEYRIDGE_SATA_MODE == 0) || (CONFIG_STONEYRIDGE_SATA_MODE == 3));<br>       AmdResetParams.FchInterface.IdeEnable = (CONFIG_STONEYRIDGE_SATA_MODE == 0) || (CONFIG_STONEYRIDGE_SATA_MODE == 3);<br> <br>+       timestamp_add_now(TS_AGESA_INIT_RESET_START);<br>         status = AmdInitReset(&AmdResetParams);<br>+  timestamp_add_now(TS_AGESA_INIT_RESET_DONE);<br>+<br>       if (status != AGESA_SUCCESS) agesawrapper_amdreadeventlog(AmdParamStruct.StdHeader.HeapStatus);<br>       AmdReleaseStruct (&AmdParamStruct);<br>       return status;<br>@@ -88,7 +92,10 @@<br>    OemCustomizeInitEarly (AmdEarlyParamsPtr);<br> <br>         AmdEarlyParamsPtr->GnbConfig.PsppPolicy = PsppDisabled;<br>+<br>+        timestamp_add_now(TS_AGESA_INIT_EARLY_START);<br>         status = AmdInitEarly ((AMD_EARLY_PARAMS *)AmdParamStruct.NewStructPtr);<br>+     timestamp_add_now(TS_AGESA_INIT_EARLY_DONE);<br> <br>       if (status != AGESA_SUCCESS) agesawrapper_amdreadeventlog(AmdParamStruct.StdHeader.HeapStatus);<br>       AmdReleaseStruct (&AmdParamStruct);<br>@@ -127,7 +134,9 @@<br>          "unknown"<br>   );<br> <br>+        timestamp_add_now(TS_AGESA_INIT_POST_START);<br>  status = AmdInitPost (PostParams);<br>+   timestamp_add_now(TS_AGESA_INIT_POST_DONE);<br> <br>        /* If UMA is enabled we currently have it below TOP_MEM as well.<br>       * UMA may or may not be cacheable, so Sub4GCacheTop could be<br>@@ -189,7 +198,10 @@<br>   EnvParam->FchInterface.SataIdeMode = (CONFIG_STONEYRIDGE_SATA_MODE == 3);<br>  EnvParam->GnbEnvConfiguration.IommuSupport = FALSE;<br> <br>+    timestamp_add_now(TS_AGESA_INIT_ENV_START);<br>   status = AmdInitEnv (EnvParam);<br>+      timestamp_add_now(TS_AGESA_INIT_ENV_DONE);<br>+<br>         if (status != AGESA_SUCCESS) agesawrapper_amdreadeventlog(EnvParam->StdHeader.HeapStatus);<br>         /* Initialize Subordinate Bus Number and Secondary Bus Number<br>          * In platform BIOS this address is allocated by PCI enumeration code<br>@@ -257,7 +269,10 @@<br>   MidParam->FchInterface.IdeEnable = (CONFIG_STONEYRIDGE_SATA_MODE == 0) || (CONFIG_STONEYRIDGE_SATA_MODE == 3);<br>     MidParam->FchInterface.SataIdeMode = (CONFIG_STONEYRIDGE_SATA_MODE == 3);<br> <br>+      timestamp_add_now(TS_AGESA_INIT_MID_START);<br>   status = AmdInitMid ((AMD_MID_PARAMS *)AmdParamStruct.NewStructPtr);<br>+ timestamp_add_now(TS_AGESA_INIT_MID_DONE);<br>+<br>         if (status != AGESA_SUCCESS) agesawrapper_amdreadeventlog(AmdParamStruct.StdHeader.HeapStatus);<br>       AmdReleaseStruct (&AmdParamStruct);<br> <br>@@ -284,7 +299,11 @@<br>      /* NOTE: if not call amdcreatestruct, the initializer(AmdInitLateInitializer) would not be called */<br>  AmdCreateStruct(&AmdParamStruct);<br>         AmdLateParams = (AMD_LATE_PARAMS *)AmdParamStruct.NewStructPtr;<br>+<br>+   timestamp_add_now(TS_AGESA_INIT_LATE_START);<br>  Status = AmdInitLate(AmdLateParams);<br>+ timestamp_add_now(TS_AGESA_INIT_LATE_DONE);<br>+<br>        if (Status != AGESA_SUCCESS) {<br>                agesawrapper_amdreadeventlog(AmdLateParams->StdHeader.HeapStatus);<br>                 ASSERT(Status == AGESA_SUCCESS);<br></pre><p>To view, visit <a href="https://review.coreboot.org/22798">change 22798</a>. To unsubscribe, visit <a href="https://review.coreboot.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://review.coreboot.org/22798"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: coreboot </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: I8209160f8e23ab77987f8e515c7b00d94f68c8be </div>
<div style="display:none"> Gerrit-Change-Number: 22798 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Martin Roth <martinroth@google.com> </div>