Info : Using a PowerMac G5 as a server
benh at kernel.crashing.org
Mon Feb 21 08:36:43 EST 2011
On Mon, 2011-02-21 at 07:05 +1100, Benjamin Herrenschmidt wrote:
> Yes, there is. We reverse engineered that a while back and somebody even
> wrote a little tool to control it, though I don't remember where that
> can be found... If necessary, we can try to dig again, the RE wasn't
> that hard.
a quick look seems to indicate that a bunch of the necessary command
definitions are present in smu.h already. Search for SMU_POWER_EVENTS
You probably need to send a SMU_CMD_POWER_EVENTS_COMMAND with
SET_POWERUP_EVENTS and SMU_PWR_WAKEUP_AC_INSERT as arguments.
You can find examples of how to send SMU commands there:
Fell free to submit your resulting new utility to powerpc-utils :-)
More information about the Linuxppc-dev