virtual address,logical address,physical address add linear address

 But coming to kernel they distinguish logical address from virtual
> address. What is the main difference.

kernel logical address has linear (one-to-one) mapping of physical
address to virtual address range. e.g. kernel logical address (linear
address) from 3G to 4G (on x86) can map physical memory of 0-1G, so it
is intutive to get physical address from a logical address by
subtrating 3G from logical address.

while kernel virtual address can be though of as logical address with
no restriction of linear mapping. Then how they map to physical pages?
Well this is achieved through page tables mapping like user space
address, however the virtual address range falls in 3G-4G (on x86)
range only. Basically you can say it is the process mapping of kernel
virtual address range (3G-4G) in its page tables. CPU works through
page-tables hence requires kernel virtual address in code
instructions. So, it is possible thats a kernel page has kernel
virtual address as well as logical address.


> Also, they emphasize on high memory and low memory. Why can not high
> memory can be mapped in to kernel completely.
> Why is that kernel has less visibility of complete space available on RAM.

For a limited address space range of linear mapping, physical memory
has to be limited (one-to-one mapping). So, if your system (x86) has
more than 1G physical RAM, Linux provides some mechanism releasing
some small slot between (3G + 896M) to 4G for dynamically mapping High
phyical memory page frames (>896M physical address), since you can't
always map the complete physical RAM all the time. This dynamic
mapping is done through kmap().


> what is very minimal implementation of MMU for real time systems.

# CONFIG_MMU is not set
means linear mapping of all physical address to virtual address. Not
sure, but seems it requires processor support to work on linear
address bypassing page-tables conversion.

Rajat

 

it from linux kernel maillist

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值