On Mon, Dec 11, 2000 at 04:14:55PM -0700, Ronald G Minnich wrote:
> On Mon, 11 Dec 2000, Eric Seppanen wrote:
>
> > And wouldn't access to reboot from /proc mean that the system would
> > shutdown prematurely? Since init will call the reboot syscall when
> > it's time to reboot, why would you want to add an alternate mechanism?
>
> actually, it's useful. It's pretty much a nicer version of the "Magic
> SysReq key". If you're running ext3 then an instantaneous reboot is kind
> of handy, and you're not going to be hurt by doing it.
OK, knock yourself out :)
But I'm assuming you're going to want _normal_ reboots to work as well,
and shouldn't that mean that machine_restart() should be fixed up?
Otherwise, you have to hack init, which seems like a waste of time.
If that's true, then why not fix machine_restart(), and then make your
/proc entry just a front-end to the sys_reboot syscall? Then normal
(init-driven) reboots will work, and you can have a software "big red
button" if you want to test your fancy new journalling filesystem :)
(I know machine_restart() works on your boxes, Ron, but if fixes have to
be made to get some machines working I think it'd be silly to ignore the
machine_restart path)