[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: pgd clarification
Santosh Eraniose wrote:
>
> Hello,
> In the mm_struct structure I notice only an entry for pgd_t* pgd.
> Cannot a process memory space occupy more that 4MB of virtual addr space.
> In that case how is one pgd sufficient?
> 1pgd can address 1024*4*1024 =4MB. or a 4k page
No. mm_struct->pgd is a pointer to a page directory, which maps the
entire 4G virtual address space. On x86, each of the 1024 elements
of the page directory addresses 4MB of virtual space, either
directly or via an additional layer of page tables.
HTH,
-- Joe
> I expected a list of pgd so that on a pagefault, the process would navigate
> thro the pgd, find the virtual address mapping to the physical page and
> then return the pte?
> Thanks in advance.
> regards
>
> --
> Santosh Eraniose
>
> -
> Kernelnewbies: Help each other learn about the Linux kernel.
> Archive: http://mail.nl.linux.org/
> IRC Channel: irc.openprojects.net / #kernelnewbies
> Web Page: http://www.kernelnewbies.org/
--
"If I ever get reincarnated... let me make certain I don't come back
as a paperclip." -- protagonist, H Murakami's "Hard-boiled Wonderland"
// Linux MM Documentation in progress:
// http://home.earthlink.net/~jknapka/linux-mm/vmoutline.html
* Evolution is an "unproven theory" in the same sense that gravity is. *
-
Kernelnewbies: Help each other learn about the Linux kernel.
Archive: http://mail.nl.linux.org/
IRC Channel: irc.openprojects.net / #kernelnewbies
Web Page: http://www.kernelnewbies.org/