1. 26 Jan, 2021 6 commits
  2. 25 Jan, 2021 18 commits
  3. 22 Jan, 2021 6 commits
  4. 21 Jan, 2021 7 commits
  5. 19 Jan, 2021 3 commits
    • Lyude Paul's avatar
      drm/dp: Revert "drm/dp: Introduce EDID-based quirks" · 7c553f8b
      Lyude Paul authored
      This reverts commit 0883ce81. Originally
      these quirks were added because of the issues with using the eDP
      backlight interfaces on certain laptop panels, which made it impossible
      to properly probe for DPCD backlight support without having a whitelist
      for panels that we know have working VESA backlight control interfaces
      over DPCD. As well, it should be noted it was impossible to use the
      normal sink OUI for recognizing these panels as none of them actually
      filled out their OUIs, hence needing to resort to checking EDIDs.
      
      At the time we weren't really sure why certain panels had issues with
      DPCD backlight controls, but we eventually figured out that there was a
      second interface that these problematic laptop panels actually did work
      with and advertise properly: Intel's proprietary backlight interface for
      HDR panels. So far the testing we've done hasn't brought any panels to
      light that advertise this interface and don't support it properly, which
      means we finally have a real solution to this problem.
      
      As a result, we now have no need for the force DPCD backlight quirk, and
      furthermore this also removes the need for any kind of EDID quirk
      checking in DRM. So, let's just revert it for now since we were the only
      driver using this.
      
      v3:
      * Rebase
      v2:
      * Fix indenting error picked up by checkpatch in
        intel_edp_init_connector()
      Signed-off-by: default avatarLyude Paul <lyude@redhat.com>
      Acked-by: default avatarJani Nikula <jani.nikula@intel.com>
      Cc: thaytan@noraisin.net
      Cc: Vasily Khoruzhick <anarsoul@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210114221709.2261452-6-lyude@redhat.com
      7c553f8b
    • Lyude Paul's avatar
      drm/i915/dp: Allow forcing specific interfaces through enable_dpcd_backlight · 2227816e
      Lyude Paul authored
      Since we now support controlling panel backlights through DPCD using
      both the standard VESA interface, and Intel's proprietary HDR backlight
      interface, we should allow the user to be able to explicitly choose
      between one or the other in the event that we're wrong about panels
      reliably reporting support for the Intel HDR interface.
      
      So, this commit adds support for this by introducing two new
      enable_dpcd_backlight options: 2 which forces i915 to only probe for the
      VESA interface, and 3 which forces i915 to only probe for the Intel
      backlight interface (might be useful if we find panels in the wild that
      report the VESA interface in their VBT, but actually only support the
      Intel backlight interface).
      
      v3:
      * Rebase
      Signed-off-by: default avatarLyude Paul <lyude@redhat.com>
      Reviewed-by: default avatarJani Nikula <jani.nikula@intel.com>
      Cc: thaytan@noraisin.net
      Cc: Vasily Khoruzhick <anarsoul@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210114221709.2261452-5-lyude@redhat.com
      2227816e
    • Lyude Paul's avatar
      drm/i915/dp: Enable Intel's HDR backlight interface (only SDR for now) · 4a8d7990
      Lyude Paul authored
      So-recently a bunch of laptops on the market have started using DPCD
      backlight controls instead of the traditional DDI backlight controls.
      Originally we thought we had this handled by adding VESA backlight
      control support to i915, but the story ended up being a lot more
      complicated then that.
      
      Simply put-there's two main backlight interfaces Intel can see in the
      wild. Intel's proprietary HDR backlight interface, and the standard VESA
      backlight interface. Note that many panels have been observed to report
      support for both backlight interfaces, but testing has shown far more
      panels work with the Intel HDR backlight interface at the moment.
      Additionally, the VBT appears to be capable of reporting support for the
      VESA backlight interface but not the Intel HDR interface which needs to
      be probed by setting the right magic OUI.
      
      On top of that however, there's also actually two different variants of
      the Intel HDR backlight interface. The first uses the AUX channel for
      controlling the brightness of the screen in both SDR and HDR mode, and
      the second only uses the AUX channel for setting the brightness level in
      HDR mode - relying on PWM for setting the brightness level in SDR mode.
      
      For the time being we've been using EDIDs to maintain a list of quirks
      for panels that safely do support the VESA backlight interface. Adding
      support for Intel's HDR backlight interface in addition however, should
      finally allow us to auto-detect eDP backlight controls properly so long
      as we probe like so:
      
      * If the panel's VBT reports VESA backlight support, assume it really
        does support it
      * If the panel's VBT reports DDI backlight controls:
        * First probe for Intel's HDR backlight interface
        * If that fails, probe for VESA's backlight interface
        * If that fails, assume no DPCD backlight control
      * If the panel's VBT reports any other backlight type: just assume it
        doesn't have DPCD backlight controls
      
      Changes since v4:
      * Fix checkpatch issues
      Changes since v3:
      * Stop using drm_device and use drm_i915_private instead
      * Don't forget to return from intel_dp_aux_hdr_get_backlight() if we fail
        to read the current backlight mode from the DPCD
      * s/uint8_t/u8/
      * Remove unneeded parenthesis in intel_dp_aux_hdr_enable_backlight()
      * Use drm_dbg_kms() in intel_dp_aux_init_backlight_funcs()
      Signed-off-by: default avatarLyude Paul <lyude@redhat.com>
      Reviewed-by: default avatarJani Nikula <jani.nikula@intel.com>
      Cc: thaytan@noraisin.net
      Cc: Vasily Khoruzhick <anarsoul@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210114221709.2261452-4-lyude@redhat.com
      4a8d7990