<div dir="ltr"><div>Lets consider 32 bit Linux system with 512 physical RAM. Suppose I have standard 3:1 address space split. Now what I understand is</div><div> </div><div>(In general)</div><div>1. In the fourth gigabyte I have kernel space</div>
<div>2. Out of 1GB for kernel address space only 896MB is used as direct mapping and other 128 MB is used for Noncontiguous Memory Area Management, Fixed Mapping and Permanent Mapping.</div><div><br></div><div>PCMIIW</div>
<div><br></div><div>Following are my doubts :   </div>1. Since my system has only 512MB RAM, will there be only direct mappings since 896 is enough to hold 512 RAM?<div>2. When user space program do malloc, we get some virtual address from userspace region (from first 3GB) of process. So will it be like, when I access some memory from that region, there is some physical frame associated with it AND same physical frame will also be mapped in kernel space ?</div>
<div>So what I want  to know, for every physical frame is there a mapping in userspace as well as kernel space ? (given that some address in user space of process map to same physical frame) </div><div>3. If we consider example of Linux system with 4GB, now if I do malloc from user space from which memory region kernel will give memory ? Direct mapped region or fixed map or permanent map ?<br>
<div> <br clear="all"><div>Thanks and regards,<br>Pritam Bankar</div>
</div></div></div>