Features/RamAPI: Difference between revisions
(Created page with '== Summary == Introduce a new API for registration RAM regions of memory. == Owner == '''Name:''' Anthony Liguori '''Email:''' anthony@codemonkey.ws =…') |
(→Owner) |
||
Line 5: | Line 5: | ||
== Owner == | == Owner == | ||
'''Name:''' [[User:AnthonyLiguori|Anthony Liguori]] | * '''Name:''' [[User:AnthonyLiguori|Anthony Liguori]] | ||
'''Email:''' anthony@codemonkey.ws | * '''Email:''' anthony@codemonkey.ws | ||
== Summary == | == Summary == |
Revision as of 18:07, 2 March 2010
Summary
Introduce a new API for registration RAM regions of memory.
Owner
- Name: Anthony Liguori
- Email: anthony@codemonkey.ws
Summary
We register all types of memory through a single API today (cpu_register_physical_memory). RAM memory is registered as IO_MEM_RAM but not all IO_MEM_RAM is RAM. In certain cases, PCI IO regions are mapped as IO_MEM_RAM as an optimization. While device memory tends to be transient, RAM mappings are almost always consistent throughout the life time of the VM.
All of our mapping APIs assume that all memory mappings are transient. This assumption is too conservative for a lot of applications (like virtio) and leads to a measurable performance overhead in constantly looking up the same mappings in the fast path.
This new API should provide an interface for registration RAM regions along with a new API to map RAM regions. This would allow devices to attempt to map what they think are RAM, and provided it succeeds, use the persistent mapping. For devices like virtio, if a ring is located in a non-RAM region, we can error out.