gma: Do not check for hot-plug events on analog port
The corresponding bits in PCH_ADPA reflect the current state of the
connection and not a change in the state. This was interpreted wrong
since some PRMs state that these bits can be cleared. It seems they
can't be, though. Linux' i915 also doesn't try to clear them and only
interprets their state as presence of a display.
Change-Id: I8e8bfd30937f393e5c411b7d48668a4f5f7b0129
Signed-off-by: Nico Huber <nico.huber@secunet.com>
Reviewed-on: https://review.coreboot.org/18167
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: Nico Huber <nico.h@gmx.de>
diff --git a/common/haswell_shared/hw-gfx-gma-port_detect.adb b/common/haswell_shared/hw-gfx-gma-port_detect.adb
index 01bd0fe..bf9fba5 100644
--- a/common/haswell_shared/hw-gfx-gma-port_detect.adb
+++ b/common/haswell_shared/hw-gfx-gma-port_detect.adb
@@ -19,9 +19,6 @@
package body HW.GFX.GMA.Port_Detect
is
- PCH_ADPA_CRT_HPD_CHANNEL_MASK : constant := 3 * 2 ** 24;
- PCH_ADPA_CRT_HPD_ENABLE : constant := 1 * 2 ** 23;
-
SFUSE_STRAP_CRT_DAC_CAP_DISABLE : constant := 1 * 2 ** 6;
HOTPLUG_CTL_DDI_A_HPD_INPUT_ENABLE : constant := 1 * 2 ** 4;
@@ -83,12 +80,6 @@
(Register => Registers.SFUSE_STRAP,
Mask => SFUSE_STRAP_CRT_DAC_CAP_DISABLE,
Result => DAC_Disabled);
- if not DAC_Disabled then
- Registers.Set_Mask
- (Register => Registers.PCH_ADPA,
- Mask => PCH_ADPA_CRT_HPD_CHANNEL_MASK or -- clear status
- PCH_ADPA_CRT_HPD_ENABLE);
- end if;
Config.Valid_Port (Analog) := not DAC_Disabled;
end if;
@@ -156,16 +147,7 @@
GPU_Port : constant GMA.GPU_Port :=
Config_Helpers.To_GPU_Port (Primary, Port);
begin
- if Port = Analog then
- Registers.Read (Registers.PCH_ADPA, Ctl32, Verbose => False);
- Ctl32 := Ctl32 and PCH_ADPA_CRT_HPD_CHANNEL_MASK;
- Detected := Ctl32 = PCH_ADPA_CRT_HPD_CHANNEL_MASK;
- if Ctl32 /= 0 then
- Registers.Set_Mask
- (Register => Registers.PCH_ADPA,
- Mask => PCH_ADPA_CRT_HPD_CHANNEL_MASK);
- end if;
- elsif Config.Has_HOTPLUG_CTL and then GPU_Port = DIGI_A then
+ if Config.Has_HOTPLUG_CTL and then GPU_Port = DIGI_A then
Registers.Read (Registers.HOTPLUG_CTL, Ctl32, Verbose => False);
Detected := (Ctl32 and HOTPLUG_CTL_DDI_A_HPD_LONG_DETECT) /= 0;