1
0
Fork 0
alistair23-linux/drivers/gpu
Maarten Lankhorst 5b1ec9ac7a drm/i915/backlight: Fix backlight takeover on LPT, v3.
On lynxpoint the bios sometimes sets up the backlight using the CPU
display, but the driver expects using the PWM PCH override register.

Read the value from the CPU register, then convert it to the other
units by converting from the old duty cycle, to freq, to the new units.

This value is then programmed in the override register, after which
we set the override and disable the CPU display control. This allows
us to switch the source without flickering, and make the backlight
controls work in the driver.

Changes since v1:
- Read BLC_PWM_CPU_CTL2 to cpu_ctl2.
- Clean up cpu_mode if slightly.
- Always disable BLM_PWM_ENABLE in cpu_ctl2.
Changes since v2:
- Simplify cpu_mode handling (Jani)

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108225
Cc: Basil Eric Rabi <ericbasil.rabi@gmail.com>
Cc: Hans de Goede <jwrdegoede@fedoraproject.org>
Cc: Tolga Cakir <cevelnet@gmail.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Tested-by: Tolga Cakir <cevelnet@gmail.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190108160842.13396-2-maarten.lankhorst@linux.intel.com
2019-01-24 13:02:48 +01:00
..
drm drm/i915/backlight: Fix backlight takeover on LPT, v3. 2019-01-24 13:02:48 +01:00
host1x gpu: host1x: Add Tegra194 support 2018-11-29 17:11:49 +01:00
ipu-v3 gpu: ipu-v3: image-convert: allow three rows or columns 2018-11-05 14:40:08 +01:00
vga drm-misc-next for v4.21, part 1: 2018-11-19 10:40:33 +10:00
Makefile