linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] ACPI: Tiny power button driver
@ 2020-02-11 23:36 Josh Triplett
  2020-02-11 23:37 ` [PATCH 1/2] ACPI: button: move HIDs to acpi/button.h Josh Triplett
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Josh Triplett @ 2020-02-11 23:36 UTC (permalink / raw)
  To: Rafael J. Wysocki, linux-acpi; +Cc: Arjan van de Ven, linux-kernel

Virtual machines often use an ACPI power button event to tell the
machine to shut down gracefully.

Provide an extremely lightweight "tiny power button" driver to handle
this event by signaling init directly, rather than running a separate
daemon (such as acpid or systemd-logind) that adds to startup time and
VM image complexity.

I originally proposed a change to the ACPI power button driver to
introduce an optional path to signal init, but Rafael expressed a
preference to have this as a separate, mutually exclusive driver
instead. The result did come out much simpler, conceptually, with the
added benefit of being able to disable CONFIG_INPUT entirely for a
kernel that exclusively targets cloud/VM systems.

The first patch in the series just moves HID definitions to
acpi/button.h in preparation for sharing them with the tiny-power-button
driver. The second patch provides the driver itself.

Josh Triplett (2):
  acpi: button: move HIDs to acpi/button.h
  acpi: Add new tiny-power-button driver to directly signal init

 drivers/acpi/Kconfig             | 24 +++++++++++++++++
 drivers/acpi/Makefile            |  1 +
 drivers/acpi/button.c            |  3 ---
 drivers/acpi/tiny-power-button.c | 46 ++++++++++++++++++++++++++++++++
 include/acpi/button.h            |  4 +++
 5 files changed, 75 insertions(+), 3 deletions(-)
 create mode 100644 drivers/acpi/tiny-power-button.c

-- 
2.25.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-02-13 22:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-11 23:36 [PATCH 0/2] ACPI: Tiny power button driver Josh Triplett
2020-02-11 23:37 ` [PATCH 1/2] ACPI: button: move HIDs to acpi/button.h Josh Triplett
2020-02-11 23:38 ` [PATCH 2/2] ACPI: Add new tiny-power-button driver to directly signal init Josh Triplett
2020-02-13 22:43 ` [PATCH 0/2] ACPI: Tiny power button driver Rafael J. Wysocki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).