<p>Arthur Heymans has uploaded this change for <strong>review</strong>.</p><p><a href="https://review.coreboot.org/21514">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">hw-gfx-gma.adb: Fix decoding Stolen Memory on Gen4<br><br>Stolen memory needs to be decoded in MB.<br><br>Change-Id: I1ceb9ffd85d6ebb54a0e099e200a5068c34a6251<br>Signed-off-by: Arthur Heymans <arthur@aheymans.xyz><br>---<br>M common/hw-gfx-gma.adb<br>1 file changed, 3 insertions(+), 3 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://review.coreboot.org:29418/libgfxinit refs/changes/14/21514/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/common/hw-gfx-gma.adb b/common/hw-gfx-gma.adb<br>index b188f31..9dba073 100644<br>--- a/common/hw-gfx-gma.adb<br>+++ b/common/hw-gfx-gma.adb<br>@@ -507,7 +507,7 @@<br>      (1, 4, 8, 16, 32, 48, 64, 128, 256, 96, 160, 224, 352);<br>    function Stolen_Size_Gen4 (GGC : Word16) return Stolen_Size_Range is<br>      (if GMS_Gen4 (GGC) in Valid_Stolen_Size_Gen4'Range then<br>-         Valid_Stolen_Size_Gen4 (GMS_Gen4 (GGC)) else 0);<br>+         Valid_Stolen_Size_Gen4 (GMS_Gen4 (GGC)) * 2 ** 20 else 0);<br> <br>    function GTT_Size_Gen6 (GGC : Word16) return Natural is<br>      (Natural (Shift_Right (GGC, 8) and 16#03#) * 2 ** 20);<br>@@ -537,7 +537,7 @@<br>    is<br>       GGC_Reg : constant :=<br>         (case Config.CPU is<br>-            when G45 | Ironlake                 => 16#52#,<br>+            when G45 | Ironlake           => 16#52#,<br>             when Sandybridge .. Skylake   => 16#50#);<br>       GGC : Word16;<br>    begin<br>@@ -575,7 +575,7 @@<br>          Valid :=<br>             FB_Last_Page (FB) < GTT_Size / Config.GTT_PTE_Size and<br>             FB_Last_Page (FB) < Natural (Stolen_Size / GTT_Page_Size) and<br>-            FB_Last_Page (FB) < Aperture_Size / GTT_Page_Size;<br>+              FB_Last_Page (FB) < Aperture_Size / GTT_Page_Size;<br>          pragma Debug (not Valid, Debug.Put<br>            ("Stolen memory too small to hold framebuffer."));<br>       end if;<br></pre><p>To view, visit <a href="https://review.coreboot.org/21514">change 21514</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/21514"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: libgfxinit </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: I1ceb9ffd85d6ebb54a0e099e200a5068c34a6251 </div>
<div style="display:none"> Gerrit-Change-Number: 21514 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Arthur Heymans <arthur@aheymans.xyz> </div>