<p>Arthur Heymans has uploaded this change for <strong>review</strong>.</p><p><a href="https://review.coreboot.org/27801">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">[TEST]cpu/x86/lapic: Build the lapic monotonic timer in romstage<br><br>Also link in postcar stage.<br><br>Change-Id: I08fd1795508f76abdab1618585366bf9d06482ff<br>Signed-off-by: Arthur Heymans <arthur@aheymans.xyz><br>---<br>M src/cpu/x86/lapic/Makefile.inc<br>M src/cpu/x86/lapic/apic_timer.c<br>2 files changed, 3 insertions(+), 2 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://review.coreboot.org:29418/coreboot refs/changes/01/27801/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/cpu/x86/lapic/Makefile.inc b/src/cpu/x86/lapic/Makefile.inc</span><br><span>index e02dcdd..9454f8f 100644</span><br><span>--- a/src/cpu/x86/lapic/Makefile.inc</span><br><span>+++ b/src/cpu/x86/lapic/Makefile.inc</span><br><span>@@ -3,6 +3,7 @@</span><br><span> ramstage-$(CONFIG_SMP) += secondary.S</span><br><span> romstage-$(CONFIG_UDELAY_LAPIC) += apic_timer.c</span><br><span> ramstage-$(CONFIG_UDELAY_LAPIC) += apic_timer.c</span><br><span style="color: hsl(120, 100%, 40%);">+postcar-$(CONFIG_UDELAY_LAPIC) += apic_timer.c</span><br><span> bootblock-y += boot_cpu.c</span><br><span> verstage-y += boot_cpu.c</span><br><span> romstage-y += boot_cpu.c</span><br><span>diff --git a/src/cpu/x86/lapic/apic_timer.c b/src/cpu/x86/lapic/apic_timer.c</span><br><span>index ec2e71c..7369c05 100644</span><br><span>--- a/src/cpu/x86/lapic/apic_timer.c</span><br><span>+++ b/src/cpu/x86/lapic/apic_timer.c</span><br><span>@@ -138,14 +138,14 @@</span><br><span>         } while ((start - value) < ticks);</span><br><span> }</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-#if IS_ENABLED(CONFIG_LAPIC_MONOTONIC_TIMER) && !defined(__PRE_RAM__)</span><br><span style="color: hsl(120, 100%, 40%);">+#if IS_ENABLED(CONFIG_LAPIC_MONOTONIC_TIMER)</span><br><span> #include <timer.h></span><br><span> </span><br><span> static struct monotonic_counter {</span><br><span>       int initialized;</span><br><span>     struct mono_time time;</span><br><span>       uint32_t last_value;</span><br><span style="color: hsl(0, 100%, 40%);">-} mono_counter;</span><br><span style="color: hsl(120, 100%, 40%);">+} mono_counter CAR_GLOBAL;</span><br><span> </span><br><span> void timer_monotonic_get(struct mono_time *mt)</span><br><span> {</span><br><span></span><br></pre><p>To view, visit <a href="https://review.coreboot.org/27801">change 27801</a>. To unsubscribe, or for help writing mail filters, 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/27801"/><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: I08fd1795508f76abdab1618585366bf9d06482ff </div>
<div style="display:none"> Gerrit-Change-Number: 27801 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Arthur Heymans <arthur@aheymans.xyz> </div>