]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
mm: reduce the amount of work done when updating min_free_kbytes
authorMel Gorman <mgorman@suse.de>
Thu, 8 Dec 2011 04:38:55 +0000 (15:38 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 13 Dec 2011 06:43:09 +0000 (17:43 +1100)
commitce69cece6b51e5475e71e23d8c3359357cb1519c
treeb748da053dd91dd6dd0d2b0584fa1ef4cebd08c5
parent0a05eb0248fc3524dcdb657a6168e3e5c6268740
mm: reduce the amount of work done when updating min_free_kbytes

When min_free_kbytes is updated, some pageblocks are marked
MIGRATE_RESERVE.  Ordinarily, this work is unnoticable as it happens early
in boot but on large machines with 1TB of memory, this has been reported
to delay boot times, probably due to the NUMA distances involved.

The bulk of the work is due to calling calling pageblock_is_reserved() an
unnecessary amount of times and accessing far more struct page metadata
than is necessary.  This patch significantly reduces the amount of work
done by setup_zone_migrate_reserve() improving boot times on 1TB machines.

Signed-off-by: Mel Gorman <mgorman@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/page_alloc.c