Use of contiguous physical memory in cxgbe driver
Garrett Wollman
wollman at bimajority.org
Thu Feb 13 21:05:16 UTC 2014
<<On Thu, 13 Feb 2014 15:16:54 -0500, John Baldwin <jhb at freebsd.org> said:
> It seeks to use the smallest size possible however. It is true that
> we don't attempt to move a busy page elsewhere to free up memory
> (e.g. if you had a 2MB free chunk with one busy 4k page in the
> middle), but we can't really do that safely. Given the existence of
> the direct map, we can't relocate a page and be sure that we have
> also relocated all possible pointers to it.
I doubt that this can be usefully auto-configured. As an
administrator, I would be perfectly happy with a situation where I can
tell the system to set aside some amount of memory at initialization
(say, 16 superpages per (virtual) CPU) and get better performance.
It's not a real imposition on a 128-GB server to set aside 1 GB of
memory for big contiguous allocations if the applications will benefit
from it. But in the absence of a guaranteed allocation, network
drivers need to avoid requiring contiguous physical memory when they
don't need it.
-GAWollman
More information about the freebsd-net
mailing list