percpu: Generic support for this_cpu_add, sub, dec, inc_return
authorChristoph Lameter <cl@linux.com>
Mon, 6 Dec 2010 17:39:59 +0000 (11:39 -0600)
committerTejun Heo <tj@kernel.org>
Fri, 17 Dec 2010 14:15:28 +0000 (15:15 +0100)
commita663ffff1d2e94a7c549a37d08ed9169ce83bdd6
treeb33e87a2b1051b8ae57eb39cd147122c59da9189
parenta3383e8372c0c11238f9bb9777929bfc3a2d320a
percpu: Generic support for this_cpu_add, sub, dec, inc_return

Introduce generic support for this_cpu_add_return etc.

The fallback is to realize these operations with simpler __this_cpu_ops.

tj: - Reformatted __cpu_size_call_return2() to make it more consistent
      with its neighbors.
    - Dropped unnecessary temp variable ret__ from
      __this_cpu_generic_add_return().

Reviewed-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Acked-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Christoph Lameter <cl@linux.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
include/linux/percpu.h