Page 1 of 1

Paging

Posted: Tue Sep 17, 2002 6:41 am
by PlayOS
I am trying to implement paging, but for some reason if I have my System Timer and Keyboard IRQ's unmasked the system crashes.

If I have these masked then the system runs ok, but if I try to reference any non present pages, it crashes, without sending any Page Fault exceptions.

Does a memory address have to be mapped before it can be used, like do I have to have a page pointing to that address, before it will send me a page fault, when the page is marked not present.

Re:Paging

Posted: Tue Sep 17, 2002 2:04 pm
by drizzt
Are you sure that your IDT is correctly set up?

Re:Paging

Posted: Wed Sep 18, 2002 3:27 am
by PlayOS
Hi,

If I create four tables and map all of the memory, I dont get the problem!

I know that this isn't right. Any ideas?

Re:Paging

Posted: Wed Sep 18, 2002 3:54 am
by PlayOS
OK, I worked the first problem, I was starting my stack at 16MB and I was only mapping 8MB. Now, I get the error from bochs saying 'iret: cs selector null' does anyone know what this means, the only place I use IRET is in my interrupts, so does this mean there is a problem with the interrupts?

Re:Paging

Posted: Wed Sep 18, 2002 4:07 am
by PlayOS
OK, The problem above still applies except also if I disable IRQ's everything goes well, until I try to access memory that is not mapped, then I get an error about a TSS, do I need the TSS once paging is enabled?

Remember, the problem above is still happening when IRQ's are enabled.