Revert "ACPI / EC: Remove old CLEAR_ON_RESUME quirk"
authorZhang Rui <rui.zhang@intel.com>
Fri, 1 Feb 2019 06:13:41 +0000 (14:13 +0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 1 Feb 2019 11:56:49 +0000 (12:56 +0100)
commitb6a3e1475b0220378ad32bdf4d8692f058b1fc03
tree42326013e8801c3bae214f7c4a4257c498d9687d
parent116f2b348b7454ff377b779076b3ead7d47ccb7b
Revert "ACPI / EC: Remove old CLEAR_ON_RESUME quirk"

On some Samsung hardware, it is necessary to clear events accumulated by
the EC during sleep. These ECs stop reporting GPEs until they are manually
polled, if too many events are accumulated.
Thus the CLEAR_ON_RESUME quirk is introduced to send EC query commands
unconditionally after resume to clear all the EC query events on those
platforms.

Later, commit 4c237371f290 ("ACPI / EC: Remove old CLEAR_ON_RESUME quirk")
removes the CLEAR_ON_RESUME quirk because we thought the new EC IRQ
polling logic should handle this case.

Now it has been proved that the EC IRQ Polling logic does not fix the
issue actually because we got regression report on these Samsung
platforms after removing the quirk.

Thus revert commit 4c237371f290 ("ACPI / EC: Remove old CLEAR_ON_RESUME
quirk") to introduce back the Samsung quirk in this patch.

Link: https://bugzilla.kernel.org/show_bug.cgi?id=44161
Tested-by: Ortwin Glück <odi@odi.ch>
Tested-by: Francisco Cribari <cribari@gmail.com>
Tested-by: Balazs Varga <balazs4web@gmail.com>
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/ec.c