<p>Nico Huber has uploaded this change for <strong>review</strong>.</p><p><a href="https://review.coreboot.org/20822">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">gma hsw+: Treat DDI E and PCH DAC disabling separately<br><br>We only use DDI E for analog VGA outputs through the PCH DAC. DDI E<br>might be configured differently, though, by a previously running dri-<br>ver, so we have to treat the two entities seperately on the All_Off()<br>path.<br><br>Change-Id: I603ecd29c48af43bc21acaadbedaeae451acbcf3<br>Signed-off-by: Nico Huber <nico.h@gmx.de><br>---<br>M common/haswell_shared/hw-gfx-gma-connectors-ddi.adb<br>M common/haswell_shared/hw-gfx-gma-connectors.adb<br>M common/haswell_shared/hw-gfx-gma-port_detect.adb<br>M common/hw-gfx-gma-config.ads.template<br>4 files changed, 10 insertions(+), 12 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://review.coreboot.org:29418/libgfxinit refs/changes/22/20822/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/common/haswell_shared/hw-gfx-gma-connectors-ddi.adb b/common/haswell_shared/hw-gfx-gma-connectors-ddi.adb<br>index 4440376..a93f3ec 100644<br>--- a/common/haswell_shared/hw-gfx-gma-connectors-ddi.adb<br>+++ b/common/haswell_shared/hw-gfx-gma-connectors-ddi.adb<br>@@ -559,7 +559,7 @@<br> begin<br> pragma Debug (Debug.Put_Line (GNAT.Source_Info.Enclosing_Entity));<br> <br>- if Port = DIGI_E then<br>+ if Config.Has_PCH_DAC and then Port = DIGI_E then<br> PCH.VGA.Off;<br> PCH.Transcoder.Off (PCH.FDI_A);<br> -- PCH.VGA.Clock_Off; -- Can't tell what Linux does, if anything.<br>@@ -570,7 +570,9 @@<br> <br> if Port = DIGI_E then<br> SPLL.Off;<br>- PCH.FDI.Off (PCH.FDI_A, PCH.FDI.Clock_Off);<br>+ if Config.Has_PCH_DAC then<br>+ PCH.FDI.Off (PCH.FDI_A, PCH.FDI.Clock_Off);<br>+ end if;<br> end if;<br> end Off;<br> <br>diff --git a/common/haswell_shared/hw-gfx-gma-connectors.adb b/common/haswell_shared/hw-gfx-gma-connectors.adb<br>index 734b11a..6a8227c 100644<br>--- a/common/haswell_shared/hw-gfx-gma-connectors.adb<br>+++ b/common/haswell_shared/hw-gfx-gma-connectors.adb<br>@@ -86,9 +86,6 @@<br> for Port in Digital_Port range DIGI_A .. Config.Last_Digital_Port loop<br> DDI.Off (Port);<br> end loop;<br>- if Config.Is_FDI_Port (Analog) then<br>- DDI.Off (DIGI_E);<br>- end if;<br> end Post_All_Off;<br> <br> end HW.GFX.GMA.Connectors;<br>diff --git a/common/haswell_shared/hw-gfx-gma-port_detect.adb b/common/haswell_shared/hw-gfx-gma-port_detect.adb<br>index 1302cf0..be83bd5 100644<br>--- a/common/haswell_shared/hw-gfx-gma-port_detect.adb<br>+++ b/common/haswell_shared/hw-gfx-gma-port_detect.adb<br>@@ -124,7 +124,9 @@<br> Config.Valid_Port (Internal) := Internal_Detected;<br> <br> -- DDI_[BCD]<br>- for Port in Ext_Digital_Port range DIGI_B .. Config.Last_Digital_Port loop<br>+ for Port in Ext_Digital_Port range<br>+ DIGI_B .. Ext_Digital_Port'Min (DIGI_D, Config.Last_Digital_Port)<br>+ loop<br> if Config.Has_Presence_Straps then<br> Registers.Is_Set_Mask<br> (Register => Registers.SFUSE_STRAP,<br>diff --git a/common/hw-gfx-gma-config.ads.template b/common/hw-gfx-gma-config.ads.template<br>index 55696c7..5b51941 100644<br>--- a/common/hw-gfx-gma-config.ads.template<br>+++ b/common/hw-gfx-gma-config.ads.template<br>@@ -172,7 +172,7 @@<br> Valid_Port : Valid_Per_Port renames Valid_Port_GPU (CPU);<br> <br> Last_Digital_Port : constant Digital_Port :=<br>- (if Has_DDI_D then DIGI_D else DIGI_C);<br>+ (if Has_DDI_E then DIGI_E else DIGI_C);<br> <br> ----------------------------------------------------------------------------<br> <br>@@ -182,11 +182,8 @@<br> when Ironlake .. Ivybridge => FDI_Per_Port'<br> (Internal => Internal_Display = LVDS,<br> others => True),<br>- when Haswell => FDI_Per_Port'<br>- (Analog => True,<br>- others => False),<br>- when Broadwell => FDI_Per_Port'<br>- (Analog => CPU_Var = Normal,<br>+ when Haswell .. Broadwell => FDI_Per_Port'<br>+ (Analog => Has_PCH_DAC,<br> others => False),<br> when others => FDI_Per_Port'<br> (others => False));<br></pre><p>To view, visit <a href="https://review.coreboot.org/20822">change 20822</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/20822"/><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: I603ecd29c48af43bc21acaadbedaeae451acbcf3 </div>
<div style="display:none"> Gerrit-Change-Number: 20822 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Nico Huber <nico.h@gmx.de> </div>