tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: scheduler support to lock user processes out?

On Sat, Feb 16, 2008 at 12:08:21AM +0100, Matthias Drochner wrote:
> A major problem which causes instability if a system is
> suspended through pmf is that user processes are still
> running while the device tree is traversed and devices
> are prepared for a low-power state. If a process tries
> to access a device which was already prepared for sleep,
> all kinds of nasty things can happen.

I don't think that the place to treat this problem is in the scheduler.
Suspension is not an all-or-nothing affair: it is both possible and
desirable to suspend individual device sub-trees.

A driver is broken if it will touch the hardware it controls while that
hardware is suspended.

I urge developers to use drvctl(8) to test drivers with new PMF
powerhooks.  Before dusting your hands and calling your powerhooks
finished, see if you can suspend it (drvctl -S dev0), run commands
on it that are appropriate for its class (disklabel, ifconfig, *ctl),
and resume (drvctl -R).

Sorry that I haven't committed an update to the drvctl(8) manual page,
yet, I will try to remember to do that, soon.


David Young             OJC Technologies      Urbana, IL * (217) 278-3933 ext 24

Home | Main Index | Thread Index | Old Index