]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm: memcg: clean up fault accounting
authorJohannes Weiner <jweiner@redhat.com>
Thu, 8 Dec 2011 04:42:46 +0000 (15:42 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 13 Dec 2011 06:43:32 +0000 (17:43 +1100)
commitd51c442dca3f4529810271d94320316578e44289
tree2b32e671deb976a9516ef4fa2a2bda18fac2f5c0
parentabc2621b2297d8ffd397553302d3c1036e32ff47
mm: memcg: clean up fault accounting

The fault accounting functions have a single, memcg-internal user, so they
don't need to be global.  In fact, their one-line bodies can be directly
folded into the caller.  And since faults happen one at a time, use
this_cpu_inc() directly instead of this_cpu_add(foo, 1).

Signed-off-by: Johannes Weiner <jweiner@redhat.com>
Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Acked-by: Michal Hocko <mhocko@suse.cz>
Acked-by: Balbir Singh <bsingharora@gmail.com>
Cc: David Rientjes <rientjes@google.com>
Cc: Hugh Dickins <hughd@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/memcontrol.c