]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Consult VBT "LVDS config" bits to determine whether internal LVDS is present
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Fri, 18 May 2018 15:01:38 +0000 (18:01 +0300)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Fri, 25 May 2018 15:00:26 +0000 (18:00 +0300)
commit5eee0b0e2b30628941efb64210c24c1aabe8e99e
treee2a130b9185c4118e2cc0b835faa48707ab8ec55
parentc2a068c33283406a21752b630bebbe59f31a83c6
drm/i915: Consult VBT "LVDS config" bits to determine whether internal LVDS is present

VBT seems to have some bits to tell us whether the internal LVDS port
has something hooked up. In theory one might expect the VBT to not have
a child device for the LVDS port if there's no panel hooked up, but
in practice many VBTs still add the child device. The "LVDS config" bits
seem more reliable though, so let's check those.

So far we've used the "LVDS config" bits to check for eDP support on
ILK+, and disable the internal LVDS when the value is 3. That value
is actually documented as "Both internal LVDS and SDVO LVDS", but in
practice it looks to mean "eDP" on all the ilk+ VBTs I've seen. So let's
keep that interpretation, but for pre-ILK we will consider the value
3 to also indicate the presence of the internal LVDS.

Currently we have 25 DMI matches for the "no internal LVDS" quirk. In an
effort to reduce that let's toss in a WARN when the DMI match and VBT
both tell us that the internal LVDS is not present. The hope is that
people will report a bug, and then we can just nuke the corresponding
entry from the DMI quirk list. Credits to Jani for this idea.

v2: Split the basic int_lvds_support thing to a separate patch (Jani)
v3: Rebase
v4: Limit this to VBT version >= 134

Cc: Jani Nikula <jani.nikula@intel.com>
Cc: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180518150138.18361-1-ville.syrjala@linux.intel.com
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/intel_bios.c
drivers/gpu/drm/i915/intel_lvds.c
drivers/gpu/drm/i915/intel_vbt_defs.h