Messages in this thread | | | Date | Mon, 14 Jan 2008 08:22:06 +0000 | From | "Jan Beulich" <> | Subject | Re: [PATCH] adjust/fix LDT handling for Xen |
| |
>>> Jeremy Fitzhardinge <Jeremy.Fitzhardinge@citrix.com> 11.01.08 18:28 >>> >Jan Beulich wrote: >> Don't rely on kmalloc(PAGE_SIZE) returning PAGE_SIZE aligned memory >> (Xen requires GDT *and* LDT to be page-aligned). > >Can kmalloc return non-page-aligned PAGE_SIZE allocations?
Documentation says it's to return pointer-size aligned memory - any excess alignment is therefore an implementation detail. (Nevertheless, afaics all current allocators generate page-aligned chunks.)
>> Using the page >> allocator interface also removes the (albeit small) slab allocator >> overhead. > >Runtime or space overhead? Given that they're once-off allocations, the >time part isn't a big factor. And apparently LDT is completely unused.
Both, but as I also said the saving is small.
Jan
| |