Bootloaders
Bootloaders
Hi ya'll
I'm on my bootloader and have run in to some trouble. I've done tons of research on the net not to mention reading half of "Operating systems: Design and Implamentation" yet I still getting stuck:). I have made and loaded my GDT turned of Interupts and other stuff.
My problem is the wonderful triple fault
In the code:
mov eax, cr0
or al, 1
mov cr0, eax
if I comment out the last line my bootloader just hangs but does not triple fault other wise it does.
I'm just realy stuck and lookin for some hints of what I might try.
Thank you
Frank
I'm on my bootloader and have run in to some trouble. I've done tons of research on the net not to mention reading half of "Operating systems: Design and Implamentation" yet I still getting stuck:). I have made and loaded my GDT turned of Interupts and other stuff.
My problem is the wonderful triple fault
In the code:
mov eax, cr0
or al, 1
mov cr0, eax
if I comment out the last line my bootloader just hangs but does not triple fault other wise it does.
I'm just realy stuck and lookin for some hints of what I might try.
Thank you
Frank
Re:Bootloaders
I thank you for your help thus far. What were you able to determine about my code? And thank you for a look at your code I nothing else I'll try to modify mine using yours as a guide if thats all right with you.
Thank you again
Frank
Thank you again
Frank
Re:Bootloaders(yours)
Now I really must begin to wonder? I booted your up and it to reset the computer. Could that be because I had no kernel for it to load or would that be more a physical system problem?
Re:Bootloaders
Here is your problem:
Change it to:
Hope this helps!
Code: Select all
codeSeg
dw 0FFFFh
dw 0000h
db 00h
db 98h ; Right Here
db 0CFh
db 00h
Code: Select all
codeSeg
dw 0FFFFh
dw 0000h
db 00h
db 9Ah ; This line has been changed
db 0CFh
db 00h
Re:Bootloaders(Tom)
Thank you again your code works now I just have to play with it a bit and make sure that I understand it operation an I'll be all set. But I look forward to the challange. Thank you again for your help.
Frank
Frank
Re:Bootloaders(Tom)
With respect to your boot loader. how do you init, the segments to there respective selectors after the
jmp $
I seams that If I change that to
jmp $ + 1 I triple fault the CPU
So where do you go from this?
Thanks for any ideas:)
Frank
jmp $
I seams that If I change that to
jmp $ + 1 I triple fault the CPU
So where do you go from this?
Thanks for any ideas:)
Frank
Re:Bootloaders
You are jumping to a unknown place...that's why...
Also...after there...you load your C kernel if you want to program your OS in C.
Also...after there...you load your C kernel if you want to program your OS in C.