]> git.baikalelectronics.ru Git - kernel.git/commit
ACPI / LPSS: Use acpi_lpss_* instead of acpi_subsys_* functions for hibernate
authorHans de Goede <hdegoede@redhat.com>
Thu, 18 Apr 2019 11:39:33 +0000 (13:39 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 18 Apr 2019 14:46:45 +0000 (16:46 +0200)
commit4d8a8527f2e113704241de2d6c7ac6221785a8b0
treee55d0a866d79ae99a2a6b7868e84a60d5b89a316
parenta823f410bed73191d790cede57e1b70cd6ab80b6
ACPI / LPSS: Use acpi_lpss_* instead of acpi_subsys_* functions for hibernate

Commit c334d1881618 ("ACPI / LPSS: Resume BYT/CHT I2C controllers from
resume_noirq") makes acpi_lpss_{suspend_late,resume_early}() bail early
on BYT/CHT as resume_from_noirq is set.

This means that on resume from hibernate dw_i2c_plat_resume() doesn't get
called by the restore_early callback, acpi_lpss_resume_early(). Instead it
should be called by the restore_noirq callback matching how things are done
when resume_from_noirq is set and we are doing a regular resume.

Change the restore_noirq callback to acpi_lpss_resume_noirq so that
dw_i2c_plat_resume() gets properly called when resume_from_noirq is set
and we are resuming from hibernate.

Likewise also change the poweroff_noirq callback so that
dw_i2c_plat_suspend gets called properly.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=202139
Fixes: c334d1881618 ("ACPI / LPSS: Resume BYT/CHT I2C controllers from resume_noirq")
Reported-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Cc: 4.20+ <stable@vger.kernel.org> # 4.20+
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/acpi_lpss.c