diff options
author | Hans de Goede <hdegoede@redhat.com> | 2022-08-29 16:17:03 +0300 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2022-09-09 22:58:16 +0300 |
commit | 3cb1f40dfdc3b9f5449076c96b4e2523139f5cd0 (patch) | |
tree | 6461cafce22a7d2fb8f6625c0924456836c0160f /drivers/acpi/video_detect.c | |
parent | 18ef1bb093ab1e0a74d146cbf4a9d132d01374d8 (diff) | |
download | linux-3cb1f40dfdc3b9f5449076c96b4e2523139f5cd0.tar.xz |
drivers/platform: toshiba_acpi: Call HCI_PANEL_POWER_ON on resume on some models
Some Toshibas have a broken acpi-video interface for brightness control, so
far these have been using a special workaround in drivers/acpi/acpi_video.c
which gets activated by the disable_backlight_sysfs_if module-param/quirks.
The recent x86/acpi backlight refactoring has broken this workaround:
1. This workaround relies on acpi_video_get_backlight_type() returning
acpi_video so that the acpi_video code actually runs; and
2. this relies on the actual native GPU driver to offer the sysfs
backlight interface to userspace.
After the refactor this breaks since the native driver will no
longer register its backlight-device if acpi_video_get_backlight_type()
does not return native and making it return native breaks 1.
Keeping the acpi_video backlight handling on resume active, while not
using it to set the brightness, is necessary because it does a _BCM
call on resume which is necessary to turn the panel back on on resume.
Looking at the DSDT shows that this _BCM call results in a Toshiba
HCI_SET HCI_LCD_BRIGHTNESS call, which turns the panel back on.
This commit makes toshiba_acpi do a HCI_SET HCI_PANEL_POWER_ON call
on resume on the affected models, so that the (now broken)
acpi_video disable_backlight_sysfs_if workaround will no longer
be necessary.
Note this uses HCI_PANEL_POWER_ON instead of HCI_LCD_BRIGHTNESS
to avoid changing the configured brightness level.
Tested-by: Arvid Norlander <lkml@vorpal.se>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to 'drivers/acpi/video_detect.c')
0 files changed, 0 insertions, 0 deletions