]> git.baikalelectronics.ru Git - kernel.git/commit
mm: Serialize access to min_free_kbytes
authorMel Gorman <mgorman@suse.de>
Mon, 25 Apr 2011 21:36:42 +0000 (21:36 +0000)
committerMarek Szyprowski <m.szyprowski@samsung.com>
Mon, 21 May 2012 13:09:34 +0000 (15:09 +0200)
commita4ea92e6c5b287b67391a400c8e8636cc751908b
tree002aa5a9001a7b600ea8af90b59ccbbe133d48e0
parentf95294fd18621e309a7b72aefbcf5a74f1448fef
mm: Serialize access to min_free_kbytes

There is a race between the min_free_kbytes sysctl, memory hotplug
and transparent hugepage support enablement.  Memory hotplug uses a
zonelists_mutex to avoid a race when building zonelists. Reuse it to
serialise watermark updates.

[a.p.zijlstra@chello.nl: Older patch fixed the race with spinlock]
Signed-off-by: Mel Gorman <mgorman@suse.de>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Tested-by: Barry Song <Baohua.Song@csr.com>
mm/page_alloc.c