https://bugzilla.kernel.org/show_bug.cgi?id=44161

--- Comment #142 from Kieran Clancy <codebeard+ker...@gmail.com> ---
Created attachment 127121
  --> https://bugzilla.kernel.org/attachment.cgi?id=127121&action=edit
acpi_ec_clear function, only run on affected hardware

There is already a function which runs on resume, namely
acpi_ec_unblock_transactions(). This patch uses that function rather than
setting up a new hook to be run on wake.

To avoid potential side-effects on non-Samsung hardware, I have also added DMI
info which is checked along with other quirks when the ACPI bus is initialised.
If the system vendor is Samsung, the flag EC_FLAGS_CLEAR_ON_RESUME is set to 1.

When the system resumes and acpi_ec_unblock_transactions() is run, this flag is
checked and acpi_ec_clear() is run if necessary.

Finally, acpi_ec_clear() is also run if needed when the EC is finalised in
acpi_ec_add(), in case the EC was jammed when the system boots. Otherwise the
EC wouldn't be cleared until a manual suspend+resume (which may not happen
often, or at all, depending on the user).

I'd also like to reiterate that we should ideally find out how to stop the EC
filling during suspend, since this:
a) would prevent problems if resume never happens and another operating system
is booted which doesn't clear the EC (e.g. Windows, or a Linux kernel prior to
this patch)
b) may reduce power consumption while in sleep - perhaps the EC or other
hardware is supposed to be put in a lower power state as part of this process

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

------------------------------------------------------------------------------
Managing the Performance of Cloud-Based Applications
Take advantage of what the Cloud has to offer - Avoid Common Pitfalls.
Read the Whitepaper.
http://pubads.g.doubleclick.net/gampad/clk?id=121054471&iu=/4140/ostg.clktrk
_______________________________________________
acpi-bugzilla mailing list
acpi-bugzilla@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/acpi-bugzilla

Reply via email to