linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] OPAL Poweroff events driver for PowerNV platform
@ 2015-04-10  6:52 Vipin K Parashar
  2015-04-10  6:52 ` [PATCH 1/2] powerpc/powernv: " Vipin K Parashar
  2015-04-10  6:52 ` [PATCH 2/2] powerpc/powernv: Add udev notification and poweroff event attributes Vipin K Parashar
  0 siblings, 2 replies; 3+ messages in thread
From: Vipin K Parashar @ 2015-04-10  6:52 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: Vipin K Parashar

OPAL Poweroff events driver handles poweroff events on PowerNV platform.
Currently this driver supports EPOW (Early Power Off Warning) and
Delayed Power Off (DPO) events on FSP based systems.
	EPOW events are generated by SPCN/FSP due to various critical system
conditions that need system shutdown. Few examples of these conditions are
high ambient temperature or system running on UPS power with UPS battery low.
DPO event is generated in reponse to user initiated system shutdown request.
	OPAL Poweroff events driver handles OPAL notifications for these events,
processes them, starts kernel system poweroff timers and send uevents to notify
udev. Poweroff event attributes are exposed as attributes files for platform
device opal-poweroff-events. Host userspace should add udev scripts to perform
various actions like sending event info to guests for graceful guest shutdown
and host poweroff scripts.

Below attribute files are created for platform device opal-poweroff-events:

admin_shutdown - Poweroff needed due to admin requested shutdown
        Values as below:
        No
        Yes

power_supply - Poweroff needed due to UPS/internal battery
        Values as below:
        Normal
        UPS
        UPS-low

thermal - Poweroff needed due to high, critical ambient or internal temp
        Values as below:
        Normal
        High-ambient-temp
        Critical-ambient-temp
        High-internal-temp
        Critical-internal-temp

timeout: Time allowed for poweroff

Vipin K Parashar (2):
  powerpc/powernv: OPAL poweroff events driver for PowerNV platform
  powerpc/powernv: Add udev notification and poweroff event attributes

 arch/powerpc/include/asm/opal.h                    |  22 +
 arch/powerpc/platforms/powernv/Makefile            |   2 +-
 .../platforms/powernv/opal-poweroff-events.c       | 567 +++++++++++++++++++++
 .../platforms/powernv/opal-poweroff-events.h       |  35 ++
 arch/powerpc/platforms/powernv/opal-wrappers.S     |   3 +-
 arch/powerpc/platforms/powernv/opal.c              |   8 +-
 6 files changed, 634 insertions(+), 3 deletions(-)
 create mode 100644 arch/powerpc/platforms/powernv/opal-poweroff-events.c
 create mode 100644 arch/powerpc/platforms/powernv/opal-poweroff-events.h

--
1.9.3

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

end of thread, other threads:[~2015-04-10  6:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-10  6:52 [PATCH 0/2] OPAL Poweroff events driver for PowerNV platform Vipin K Parashar
2015-04-10  6:52 ` [PATCH 1/2] powerpc/powernv: " Vipin K Parashar
2015-04-10  6:52 ` [PATCH 2/2] powerpc/powernv: Add udev notification and poweroff event attributes Vipin K Parashar

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).