Skip to contentSkip to conversation

Power fail handler

DISCUSSION Blue Swirl 2 participants 3 messages May 26, 2005 – May 27, 2005

lore
Share & tools
lore

Blue Swirl

author
#0 lore raw

Hi,

I implemented to Qemu a part of Slavio chip which sends a level 15 interrupt when the power is failing. After that I was surprised to find out that Linux doesn't handle that at all.

It shouldn't be very difficult to add a driver to Linux, but would it be useful? In Qemu, user could send the power fail event to conveniently signal shutdown. Do you know if some real-life power supply generates the signal? Or are drivers for Qemu-only stuff OK?

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/

author
#1 lore raw
Quoted 5 lines

You should print a message when this event occurs, not shut the system down, so the administrator can come down to the machine room and replace the failing power supply. The redundant power is still working when this event is received, so the system should stay up.

Well, printing stuff not very useful in the Qemu case. I thought the driver would send SIGPWR to init process or something like APM/ACPI in x86.

How about Sparc laptops, what happens when operating without AC power and battery gets almost drained?

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/

#2 lore raw
In reply to Blue Swirl

From: "Blue Swirl" <[email protected]>
Date: Fri, 27 May 2005 16:53:31 +0200

Quoted 2 lines

How about Sparc laptops, what happens when operating without AC power and battery gets almost drained?

Those use different devices, in fact some of them probably use the power management facilities of an existing x86 north bridge chipset since the current sparc laptops are all PCI.