From: Mingming Cao Date: Tue, 16 Mar 2010 00:25:56 +0000 (-0400) Subject: percpu counter: clean up percpu_counter_sum_and_set() X-Git-Tag: v2.6.27.47~24 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ac6016e3a8c7967cf8e3fe9102a9b87d7092b4bf;p=pandora-kernel.git percpu counter: clean up percpu_counter_sum_and_set() commit 1f7c14c62ce63805f9574664a6c6de3633d4a354 upstream. percpu_counter_sum_and_set() and percpu_counter_sum() is the same except the former updates the global counter after accounting. Since we are taking the fbc->lock to calculate the precise value of the counter in percpu_counter_sum() anyway, it should simply set fbc->count too, as the percpu_counter_sum_and_set() does. This patch merges these two interfaces into one. Signed-off-by: Mingming Cao Acked-by: Peter Zijlstra Cc: Signed-off-by: Andrew Morton Signed-off-by: "Theodore Ts'o" Signed-off-by: Jayson R. King Signed-off-by: Theodore Ts'o --- Reading git-diff-tree failed