Re: [RFC 2/4] Have __free_pages_memory() free in larger chunks.
From: Yinghai Lu
Date: Fri Jul 12 2013 - 23:09:03 EST
On Fri, Jul 12, 2013 at 12:45 AM, Robin Holt <holt@xxxxxxx> wrote:
> At the very least, I think we could change to:
> static void __init __free_pages_memory(unsigned long start, unsigned long end)
> {
> int order;
>
> while (start < end) {
> order = ffs(start);
>
> while (start + (1UL << order) > end)
> order--;
>
> __free_pages_bootmem(start, order);
>
> start += (1UL << order);
> }
> }
should work, but need to make sure order < MAX_ORDER.
Yinghai
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/