Path: utzoo!attcan!uunet!cs.utexas.edu!usc!zaphod.mps.ohio-state.edu!mips!bridge2!mbt
From: mbt@bridge2.ESD.3Com.COM (Brad Turner)
Newsgroups: comp.sys.ibm.pc.programmer
Subject: Re: How to do a warm-boot from a C program
Message-ID: <1353@bridge2.ESD.3Com.COM>
Date: 20 Feb 90 15:55:50 GMT
References: <2028@milton.acs.washington.edu>
Organization: 3Com Corp., Mt. View, CA
Lines: 53
JXS118@psuvm.psu.edu (Jeff Siegel, Op from Atherton Hall) writes:
>In article
>>
>>jimmy writes:
>>>Does anyone know how to do a boot from a C program?
>>
>>Yes, just do an Interrupt 25 (which is 19h). That will do it nicely.
>Sorry, but my first reaction is NO ! NO ! NO !
>This is a seems to be a common misconception. Int 19h is too buggy on
>most machines that I've seen. It won't reset any hardware registers
>that may have been mucked with. It alsowill fail (mostly) if you have
>multiple-page-tracking-type EMM drivers installed. Your best bet for a reboot
>is to far jump to addresss FFFF:0000. This will cause the almost-equivalent
>of pressing the resest button (provided you have one.) However, this invokes
>the memory test (usually lengthy). To exactly mimick a CTRL-ALT-DEL, you must
>write hex word 1234 into some special address in the bios data areas (it is
>listed in Norton, i don't remeber what the address is.) and then do the far
>jump.
feed the following lines to debug:
-------------------cut here-----------------------
a
mov dx,0
mov ds,dx
mov ax,1234
mov [472],ax
jmp ffff:0000
r cx
10
w
q
------------------cut here-------------------------
Note the blank line is required (that tells the mini-assembler to quit
assembling)
Make sure to invoke debug with a filename (eg C:\>debug reboot.com)
otherwise the write command will bomb.
Ideally you should save whats between the above ---cut here--- lines
and feed it to debug (i.e. C:\>debug reboot.com < infile )
By moving 0x1234 into ax you will avoid the memory test. If you want to
do the memory test move 0 into ax rather than 0x1234
-brad-
--
v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v^v
Brad Turner |2081 Shoreline Blvd.|(415) 969-2099 ext 217 | I speak for myself
3Com Corp. |Mtn. View, CA 94043 |mbt@bridge2.ESD.3Com.Com| NOT for my employer