On 11/25/2014 06:51 PM, Anshuman Khandual wrote: > This patch creates a new OPAL platform event character driver > which will give userspace clients the access to these events > and process them effectively. Following platforms events are > currently supported with this platform driver. > > (1) Environmental and Power Warning (EPOW) > (2) Delayed Power Off (DPO) > > The user interface for this driver is /dev/opal_event character > device file where the user space clients can poll and read for > new opal platform events. The expected sequence of events driven > from user space should be like the following. > > (1) Open the character device file > (2) Poll on the file for POLLIN event > (3) When unblocked, must attempt to read PLAT_EVENT_MAX_SIZE size > (4) Kernel driver will pass at most one opal_plat_event structure > (5) Poll again for more new events > > The driver registers for OPAL messages notifications corresponding to > individual OPAL events. When any of those event messages arrive in the > kernel, the callbacks are called to process them which in turn unblocks > the polling thread on the character device file. The driver also registers > a timer function which will be called after a threshold amount of time to > shutdown the system. The user space client receives the timeout value for > all individual OPAL platform events and hence must prepare the system and > eventually shutdown. In case the user client does not shutdown the system, > the timer function will be called after the threshold and shutdown the > system explicitly. > > Reviewed-by: Neelesh Gupta <neele...@linux.vnet.ibm.com> > Signed-off-by: Anshuman Khandual <khand...@linux.vnet.ibm.com> > --- > Changes in V3: > - Rebased the patch against the mainline > > Changes in V2: > - Changed the function fetch_dpo_timeout > - Export opal_platform_events.h for user space consumption > - Posted here https://patchwork.ozlabs.org/patch/396725/ > > Original V1: > - Original patch > - Posted here http://patchwork.ozlabs.org/patch/394340/
Hey Michael, Do you have any updates on this patch yet ? Thanks ! _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev