Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Mar 1998 01:25:41 +0300 (MSK)
From:      Andrew Maltsev <am@amsoft.ru>
To:        walter@fortean.com (Bruce M. Walter)
Cc:        freebsd-hackers@FreeBSD.ORG
Subject:   Re: APM power off (patch)
Message-ID:  <199803092225.BAA05980@amsoft.ru>
In-Reply-To: <Pine.BSF.3.96.980309162230.17781A-100000@aries.fortean.com> from "Bruce M. Walter" at "Mar 9, 98 04:30:01 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
> > What can be more standart, than ioctl(/dev/apm) for userland and
> > apm_power_off for kernel stuff?
> > 
> > Or should we call it machine_power_off() and place a hook in
> > i386/machdep.c?
> 
> The idea is to have a kernel callout hook using the at_shutdown interface.

Ok.

Please forgive me my stupidness - I still cannot understand what can be
broken by calling something_power_off as a very last step of system
shutdown procedure? Yes, all that at_shutdown, at_very_shutdown and so
on may exist, but what difference does it make?

> My personal feeling is that I don't want any APM code at all in my
> kernels, especially my server boxes.  I do want UPS shutdown code.  With
> the callout mechanism, I only get the shutdown code which is in the
> drivers I use *AND* the kernel doesn't have to know diddly squat about
> what ugly and convoluted things I need to do to turn off a UPS or
> Motherbord from Vendor XYZ with APM version 99.34 :)

APM provides (trough very unpleasant polling interface, yes) the more or
less universal mechanism to do the job. How are you planning to power
off without APM? Direct i/o programming - it would be a lot of work for
nothing.. Or do you mean to switch to real mode after system has been
shut down and only then initialize APM and call 0x5307 (by one function
in which name there is no `apm' :))?

Seems a bit reasonable for busy server (because of 1 Hz polling in APM),
but only a bit.. Supposing even 100 cycles to check that no event
happened - it's only about 0.00004 percent perfomance degrade.

If I understood all wrong - I beg your pardon. It's only some hours ago I
first time read that APM spec and started thinking around :)


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199803092225.BAA05980>