Saturday, 15 June 2013

linux - Physical address of the address returned by kmalloc -


I am a little confused about the addresses which are returning to me by Kimallok, the addresses I receive I am in the ffff880000000000 - ffffc7ffffffffff category, so "direct mapping of all physical memory". How does this mapping work? I am pretty sure that the KiloLock does not return a physical address.

You are right, kmelock is not returning a real address, physical One memory map that you've linked to describes the virtual memory map, physical is not a memory map.

A virtual address is usually a physical address by the MUU when you access the data at the address. The translation of the virtual address depends on the memory map specified by the kernel.

You can see how mapping Linux works by mapped storage maps. This is saying, if you have a virtual address between 0xffff880000000000 and 0xffffc7ffffffffff , then it is mapped to physical memory somewhere (we do not know that in fact Nor do we care if we are doing DMA).

No comments:

Post a Comment