delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/09/27/13:59:34

Date: Wed, 27 Sep 2000 23:34:59 +0530
Message-Id: <200009271804.XAA01892@midpec.com>
From: Prashant TR <tr AT midpec DOT com>
To: djgpp AT delorie DOT com
CC: eliz AT is DOT elta DOT co DOT il
In-reply-to: message from Prashant TR on 27 Sep 2000 23:15:27 +0530
Subject: Re: Rebooting the PC
References: <Pine DOT SUN DOT 3 DOT 91 DOT 1000927070443 DOT 26042B AT is>
Reply-To: djgpp AT delorie DOT com

| Date: 27 Sep 2000 23:15:27 +0530
| From: Prashant TR <tr AT midpec DOT com>
| 
|    smsw ax
|    test al, 1
|    jnz try64
|    cli
| hltloop:
|    hlt
|    jmp hltloop
| try64:
|    mov al, 0feh
|    out 64h, al
|    jmp hltloop

This one attempts to halt the system. But for rebooting, try this
code.

   mov al, 0feh
   out 64h, al
   cli
hltloop:
   hlt
   jmp hltloop

Windows generates a GPF for the hlt instruction (with interrupts
cleared).

-- 
Prashant TR <tr AT midpec DOT com>
Web: http://www.midpec.com/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019