thanks to all u geniuses, its working now !!!
james, thanks for ur time. I really really appriciate the attention that you gave to my problem. Also AJ and everyone else, thanks for ur support.
Ok, now let me do some biopsy of the problem...
james returned me the code with some modification,
he added the lines
Code: Select all
1)memset(kernel_directory,0,sizeof(page_directory_t));
2)kernel_directory->physicalAddr = (u32int)kernel_directory->tablesPhysical;
3)memset(dir->tables[table_idx],0,0x1000);
&
added this to the main for testing page fault
1)*ptr = 99999;
what he did was initialized the directories and tables to 0...
and also initialized the member physicalAddr, which was not done earlier.
well, what made the code run was the last addition,
i only added this line to my previous code, (without the 1st three changes), and it shows a page fault.
Whats so special about this *ptr = 99999; ???
when earlier, we tried to invoke the page fault by
it wasn't getting invoked, but with *ptr = 99999; it is ????
why ?