Tool/software: Linux
so i want to understand how gpio-poweroff works within the SDK environment
i think i understand it to be a signal that handles the voltage shutdown in the PMIC to allow for the proper shutdown procedure. it gives a timeout in the drivers to allow the userspace/kernel time to wrap up anything before it starts ramping down power rails. is that correct?
second: in userspace how do i know that this has occurred? i looked around in /dev and i can't see anything obvious that would be a signal i could latch on to. if the system is about to shut down and i my program is running a large portion of the system then my program needs to know we are shutting down.
if i am wrong about this then what would you suggest i use as a means to know when the power has been pulled from the system and we should start to handle shutting down the world?