kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
* user space vs kernel space address space
@ 2013-12-29  9:42 Pritam Bankar
  2013-12-29 13:34 ` Miles MH Chen
  0 siblings, 1 reply; 7+ messages in thread
From: Pritam Bankar @ 2013-12-29  9:42 UTC (permalink / raw)
  To: kernelnewbies

Lets consider 32 bit Linux system with 512 physical RAM. Suppose I have
standard 3:1 address space split. Now what I understand is

(In general)
1. In the fourth gigabyte I have kernel space
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.

PCMIIW

Following are my doubts :
1. Since my system has only 512MB RAM, will there be only direct mappings
since 896 is enough to hold 512 RAM?
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 ?
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)
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 ?

Thanks and regards,
Pritam Bankar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20131229/da827db9/attachment-0001.html 

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-01-07 18:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-29  9:42 user space vs kernel space address space Pritam Bankar
2013-12-29 13:34 ` Miles MH Chen
2013-12-30 14:28   ` Pritam Bankar
2013-12-30 15:31     ` Miles MH Chen
2013-12-31 12:38       ` Pritam Bankar
2013-12-31 12:51         ` Anders Darander
2014-01-07 18:56         ` parmenides

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).