Unavoidable triple Fault
Posted: Sun Jul 26, 2009 2:17 am
Of course I know it's avoidable... The bugger just seems to be persistent. Here's what I do:
1.) Bootloader enters pmode, loads kernel, and jumps to it.
2.) Kernel disables interrupts, sets up stack, cs, ds, etc. (all segment regs)
3.) Kernel sets up IDT (with a single ISR (# 0) ) and loads it into idt register
4.) Kernel outputs offset of ISR, outputs offset and contents of IDT, outputs offset and contents of ISR descriptor
5.) Kernel disables interrupts
6.) **Seemingly** unavoidable triple fault is thrown (exception 13)
Everything seems to be correct judging by the kernels output of the ISR, IDT table, and IDTdescriptor. Yet, the triple fault is thrown IMMEDIATELY after I issue an "sti" statement. Heres the output of the kernel, comment for your readability in my own special way:
Keep in mind that those bytes are stored in little endian. If you fix them visually, you can see that everything points to where it should.
Here is botchs log from the time I enter p-mode, to the time I triple fault: http://pastebin.ca/1507662
Thanks to bochs I now know what's that I have been triple faulting and that's the problem; with vbox I had absolutely no clue. However, I remain clueless to the cause of the triple fault... All help appreciated,
Brodeur235
1.) Bootloader enters pmode, loads kernel, and jumps to it.
2.) Kernel disables interrupts, sets up stack, cs, ds, etc. (all segment regs)
3.) Kernel sets up IDT (with a single ISR (# 0) ) and loads it into idt register
4.) Kernel outputs offset of ISR, outputs offset and contents of IDT, outputs offset and contents of ISR descriptor
5.) Kernel disables interrupts
6.) **Seemingly** unavoidable triple fault is thrown (exception 13)
Everything seems to be correct judging by the kernels output of the ISR, IDT table, and IDTdescriptor. Yet, the triple fault is thrown IMMEDIATELY after I issue an "sti" statement. Heres the output of the kernel, comment for your readability in my own special way:
Keep in mind that those bytes are stored in little endian. If you fix them visually, you can see that everything points to where it should.
Here is botchs log from the time I enter p-mode, to the time I triple fault: http://pastebin.ca/1507662
Thanks to bochs I now know what's that I have been triple faulting and that's the problem; with vbox I had absolutely no clue. However, I remain clueless to the cause of the triple fault... All help appreciated,
Brodeur235