OSDN Git Service

drm/dp, drm/i915: Add support for VESA backlights using PWM for brightness control
authorLyude Paul <lyude@redhat.com>
Fri, 5 Nov 2021 18:33:41 +0000 (14:33 -0400)
committerLyude Paul <lyude@redhat.com>
Wed, 17 Nov 2021 22:36:48 +0000 (17:36 -0500)
commitf58a435311672305d8747f40e35235f7ed64ae69
tree9b20a4b906953f9d4791e892514106acb7be7c8d
parent646596485e1ed2182adf293dfd5aec4a96c46330
drm/dp, drm/i915: Add support for VESA backlights using PWM for brightness control

Now that we've added support to i915 for controlling panel backlights that
need PWM to be enabled/disabled, let's finalize this and add support for
controlling brightness levels via PWM as well. This should hopefully put us
towards the path of supporting _ALL_ backlights via VESA's DPCD interface
which would allow us to finally start trusting the DPCD again.

Note however that we still don't enable using this by default on i915 when
it's not needed, primarily because I haven't yet had a chance to confirm if
it's safe to do this on the one machine in Intel's CI that had an issue
with this: samus-fi-bdw. I have done basic testing of this on other
machines though, by manually patching i915 to force it into PWM-only mode
on some of my laptops.

v2:
* Correct documentation (thanks Doug!)
* Get rid of backlight caps

Signed-off-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Doug Anderson <dianders@chromium.org>
Cc: Rajeev Nandan <rajeevny@codeaurora.org>
Cc: Satadru Pramanik <satadru@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20211105183342.130810-5-lyude@redhat.com
drivers/gpu/drm/drm_dp_helper.c
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
include/drm/drm_dp_helper.h