Commit d2eb03e9 authored by Hans de Goede's avatar Hans de Goede Committed by Kleber Sacilotto de Souza

ACPI / LPSS: Add missing prv_offset setting for byt/cht PWM devices

BugLink: https://bugs.launchpad.net/bugs/1792174

commit fdcb613d upstream.

The LPSS PWM device on on Bay Trail and Cherry Trail devices has a set
of private registers at offset 0x800, the current lpss_device_desc for
them already sets the LPSS_SAVE_CTX flag to have these saved/restored
over device-suspend, but the current lpss_device_desc was not setting
the prv_offset field, leading to the regular device registers getting
saved/restored instead.

This is causing the PWM controller to no longer work, resulting in a black
screen,  after a suspend/resume on systems where the firmware clears the
APB clock and reset bits at offset 0x804.

This commit fixes this by properly setting prv_offset to 0x800 for
the PWM devices.

Cc: stable@vger.kernel.org
Fixes: e1c74817 ("ACPI / LPSS: Add Intel BayTrail ACPI mode PWM")
Fixes: 1bfbd8eb ("ACPI / LPSS: Add ACPI IDs for Intel Braswell")
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Acked-by: default avatarRafael J . Wysocki <rjw@rjwysocki.net>
Signed-off-by: default avatarThierry Reding <thierry.reding@gmail.com>
Signed-off-by: default avatarSudip Mukherjee <sudipm.mukherjee@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarStefan Bader <stefan.bader@canonical.com>
Signed-off-by: default avatarKleber Sacilotto de Souza <kleber.souza@canonical.com>
parent 995bb4d1
...@@ -176,10 +176,12 @@ static const struct lpss_device_desc lpt_sdio_dev_desc = { ...@@ -176,10 +176,12 @@ static const struct lpss_device_desc lpt_sdio_dev_desc = {
static const struct lpss_device_desc byt_pwm_dev_desc = { static const struct lpss_device_desc byt_pwm_dev_desc = {
.flags = LPSS_SAVE_CTX, .flags = LPSS_SAVE_CTX,
.prv_offset = 0x800,
}; };
static const struct lpss_device_desc bsw_pwm_dev_desc = { static const struct lpss_device_desc bsw_pwm_dev_desc = {
.flags = LPSS_SAVE_CTX | LPSS_NO_D3_DELAY, .flags = LPSS_SAVE_CTX | LPSS_NO_D3_DELAY,
.prv_offset = 0x800,
}; };
static const struct lpss_device_desc byt_uart_dev_desc = { static const struct lpss_device_desc byt_uart_dev_desc = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment