<p>Martin Roth has uploaded this change for <strong>review</strong>.</p><p><a href="https://review.coreboot.org/25345">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">soc/amd/stoneyridge: Generate SPCR table<br><br>Add the Serial Port Console Redirection Table to Stoney's ACPI tables.<br>Stoney customizes the OEM and OEM_TABLE IDs to notify the linux kernel<br>of of the custom input clock.<br><br>BUG=b:74392237<br>TEST=Build Grunt, verify SPCR table<br><br>Change-Id: Icc98bcf4f8c070b8002bcc795254b19f928c741b<br>Signed-off-by: Martin Roth <martinroth@google.com><br>---<br>M src/soc/amd/stoneyridge/acpi.c<br>1 file changed, 15 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/45/25345/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/soc/amd/stoneyridge/acpi.c b/src/soc/amd/stoneyridge/acpi.c</span><br><span>index 02ee6fa..4fa06e9 100644</span><br><span>--- a/src/soc/amd/stoneyridge/acpi.c</span><br><span>+++ b/src/soc/amd/stoneyridge/acpi.c</span><br><span>@@ -262,6 +262,21 @@</span><br><span>              unsigned long current,</span><br><span>               struct acpi_rsdp *rsdp)</span><br><span> {</span><br><span style="color: hsl(120, 100%, 40%);">+  acpi_spcr_t * spcr = (void *)current;</span><br><span style="color: hsl(120, 100%, 40%);">+ current = acpi_create_spcr(current);</span><br><span style="color: hsl(120, 100%, 40%);">+  if (current != (unsigned long)spcr) {</span><br><span style="color: hsl(120, 100%, 40%);">+         /*</span><br><span style="color: hsl(120, 100%, 40%);">+             * Update SPCR IDs for Stoney so Linux can configure the input</span><br><span style="color: hsl(120, 100%, 40%);">+                 * clock in order to compute the baud rate divisor registers.</span><br><span style="color: hsl(120, 100%, 40%);">+          */</span><br><span style="color: hsl(120, 100%, 40%);">+           memcpy(spcr->header.oem_id, "AMDCZ ", 6);</span><br><span style="color: hsl(120, 100%, 40%);">+                memcpy(spcr->header.oem_table_id, "AMDCZ   ", 8);</span><br><span style="color: hsl(120, 100%, 40%);">+                spcr->header.checksum = 0; /* clear before re-chesksumming */</span><br><span style="color: hsl(120, 100%, 40%);">+              spcr->header.checksum = acpi_checksum((void *)spcr,</span><br><span style="color: hsl(120, 100%, 40%);">+                                spcr->header.length);</span><br><span style="color: hsl(120, 100%, 40%);">+              acpi_add_table(rsdp, (void *)spcr);</span><br><span style="color: hsl(120, 100%, 40%);">+   }</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span>  return acpi_write_hpet(device, current, rsdp);</span><br><span> }</span><br><span> </span><br><span></span><br></pre><p>To view, visit <a href="https://review.coreboot.org/25345">change 25345</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/25345"/><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: Icc98bcf4f8c070b8002bcc795254b19f928c741b </div>
<div style="display:none"> Gerrit-Change-Number: 25345 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Martin Roth <martinroth@google.com> </div>