Doubt regarindg Virtual Memory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Friends,

Please help me to figure out some basic concepts in MM.

>From the books, i learned that VMA to PA translation consists of traversing the full page directory, which consists of   Global Directory, Middle Directory and Page Table.

I have also read that, VMA to PA translation is done using a macro virt_to_page  defined as given below.

#define virt_to_page(kaddr) (mem_map + (__pa(kaddr) >> PAGE_SHIFT))


If
there is a macro, why we need code for traversing all the page
directories ?.  This macro is a simple math, which points to an index
in global mem_map array, which contains all the pages in the system.


So my doubts are, 
Is the macro only for ZONE_NORMAL (upto 896M, which is directly mapped by kernel)  memory pages ?.
Is mem_map array contains pages upto ZONE_NORMAL ?
Is page traversing happens only for HIGH_MEM ?.

Regards,
Shameem



      

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux