Re: Why preallocate pmd in x86 32-bit PAE?

From: Jeremy Fitzhardinge
Date: Fri Nov 16 2007 - 14:15:09 EST


Linus Torvalds wrote:
> So don't do it. Just preallocate for the magic 4-entry PGD. You can make
> the special case just be something like
>

Yes, OK, it makes sense. Conceptually they would be dynamically
allocated and freed, but they'd just happen to start allocated, to avoid
the tlb flush of populating the pgd of an active pagetable. If you
happened to do a 1G munmap, it may end up freeing and reallocating them,
but that's going to be very rare. Either way, the other special cases
are avoided (though pgd_populate would still need to be correct, on the
offchance it gets invoked).

J
-
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/