Dynamic Page Bindings.

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
viral

Dynamic Page Bindings.

Post by viral »

Hi..

When a process is created, we bind whole kernel address space to that process's page directory. So that process can easily do system calls.

Now my memory manager has a heap of 4k at 0xD0000000. So when any new process is created, this address is mapped in its PD.

But kernel heap grows, so when this 4k mem is used I bind another page of 4k at end of old heap in kernel. But then all process starts doing page faults at 0xD0001000. This is obvious as this address is not yet binded in process PD.

Now tell me how do you maintain such dynamic page bindings? Do you bind the page in all process's PD when you bind it in kernels address space?

Hope this is making some sense..
FlashBurn

Re:Dynamic Page Bindings.

Post by FlashBurn »

I alloc enough mem for all 256 page table entries, so that when I map in a new page into kernel space that all processes can access it! This wastes some mem, but it makes lifes easier. There was a thread with the same probelm and I think Brendan is your man, he knows other(s) method(s)!
viral

Re:Dynamic Page Bindings.

Post by viral »

Hello....
There was a thread with the same probelm
I cant find that thread.. can anyone point me that?
Jamethiel

Re:Dynamic Page Bindings.

Post by Jamethiel »

Just have all processes share the kernel page tables. Using the same kernel page tables (the same physical pages) across all processes means that when you update in one process all of the other processes get updated automatically.
Post Reply