Paging Problems...
Posted: Wed Oct 10, 2007 7:32 pm
After re-writing my paging code, every time I enable paging in my OS, I get a triple fault.
-Page directory is aligned(4096)
-IDT and GDT haven't been touched.
-ASM code (write_cr0, etc) is fine.
I see that it is a page fault(14) to address 0x001061c0, but all that is there are my isr/irq macro functions... I attached my code if someone wants to take the time to look at it.
Here is the error message... maybe I'm missing something you can see:
EDIT:
Looking at the objdump, it looks like the faulting address is my printf() function...
Thanks,
Michael
-Page directory is aligned(4096)
-IDT and GDT haven't been touched.
-ASM code (write_cr0, etc) is fine.
I see that it is a page fault(14) to address 0x001061c0, but all that is there are my isr/irq macro functions... I attached my code if someone wants to take the time to look at it.
Here is the error message... maybe I'm missing something you can see:
Code: Select all
03409746575i[KBD ] reset-disable command received
03416715133i[BIOS ] int13_harddisk: function 41, unmapped device for ELDL=80
03416719898i[BIOS ] int13_harddisk: function 08, unmapped device for ELDL=80
03416724540i[BIOS ] *** int 15h function AX=00C0, BX=0000 not yet supported!
03509361341i[CPU0 ] protected mode
03509361341i[CPU0 ] CS.d_b = 32 bit
03509361341i[CPU0 ] SS.d_b = 32 bit
03509361341i[CPU0 ] | EAX=80000011 EBX=0002bd40 ECX=00066e88 EDX=00066e88
03509361341i[CPU0 ] | ESP=00066e68 EBP=00066e68 ESI=0002beb5 EDI=0002beb6
03509361341i[CPU0 ] | IOPL=0 id vip vif ac vm RF nt of df if tf SF zf af PF cf
03509361341i[CPU0 ] | SEG selector base limit G D
03509361341i[CPU0 ] | SEG sltr(index|ti|rpl) base limit G D
03509361341i[CPU0 ] | CS:0008( 0001| 0| 0) 00000000 000fffff 1 1
03509361341i[CPU0 ] | DS:0010( 0002| 0| 0) 00000000 000fffff 1 1
03509361341i[CPU0 ] | SS:0010( 0002| 0| 0) 00000000 000fffff 1 1
03509361341i[CPU0 ] | ES:0010( 0002| 0| 0) 00000000 000fffff 1 1
03509361341i[CPU0 ] | FS:0010( 0002| 0| 0) 00000000 000fffff 1 1
03509361341i[CPU0 ] | GS:0010( 0002| 0| 0) 00000000 000fffff 1 1
03509361341i[CPU0 ] | EIP=00100b33 (00100b33)
03509361341i[CPU0 ] | CR0=0x80000011 CR1=0 CR2=0x001061c0
03509361341i[CPU0 ] | CR3=0x00108000 CR4=0x00000000
03509361341i[CPU0 ] >> add byte ptr ds:[eax], al : 0000
03509361341e[CPU0 ] exception(): 3rd (14) exception with no resolution, shutdown
status is 00h, resetting
Looking at the objdump, it looks like the faulting address is my printf() function...
Thanks,
Michael