On 05/03/2010 11:18 AM, Avi Kivity wrote:
On 05/03/2010 12:03 PM, Jiri Slaby wrote:When you get a slub in the middle of page, how?
Modify vmalloc_to_{page,pfn} accordingly.But it won't work well for vmalloc_to_{page,pfn} and similar.Because vmalloc is used to allocate virtually contiguous memory. v inA kmalloc()ed page is virtually contiguous, satisfying your requirement.
vmalloc means virtually.
Nope, from what I understand, vmalloc aligns (uses page allocator). EvenSome codeBoth would be a bug IMO. vmalloc() follows kmalloc() and malloc() which
may expect vmalloc result to be in the vmalloc area and page-aligned
(both in position and size).
only guarantee natural alignment.
for purposes of vmalloc_to_*.