Page 2 of 2

Re: Triple fault when jumping to p-mode

Posted: Thu Jul 31, 2008 6:38 am
by zhak
so, i changed code base from 1000h:0 to 0:8000h and executed the code under Bochs in debug mode. it works fine. '+' character is displayed on the screen and then jmp $ stuns the system. but in Bochs (not debug mode) the same problem is present - infinite reboot. maybe it's smth with Bochs??? research on the subj is in progress....

Re: Triple fault when jumping to p-mode

Posted: Thu Jul 31, 2008 6:45 am
by zhak
DAMN!!! I GOT IT!!!

Code: Select all

pmode:
    mov ax, 10h
    mov gs, ax
    mov fs, ax
    mov byte [gs:0B8000h], '+'
    sti                ;<<<<<< that is the problem!!!!!
    jmp $
interrupts should not be enabled because IDT is not set up correctly, yet!

such a stupid mistake. sorry that I have bothered all of you :oops: