percpu_ref: implement percpu_ref_is_dying()
authorTejun Heo <tj@kernel.org>
Tue, 6 Jan 2015 15:26:10 +0000 (10:26 -0500)
committerTejun Heo <tj@kernel.org>
Tue, 6 Jan 2015 15:26:10 +0000 (10:26 -0500)
commit4c907baf36d8339f393bb576d0bab29194d0e6ad
tree86a550f40df9f004913f5b6db4b1e3b69e7d040e
parent6810e4a394f9d781050107529b8d1465c00b7b13
percpu_ref: implement percpu_ref_is_dying()

Implement percpu_ref_is_dying() which tests whether the ref is dying
or dead.  This is useful to determine the current state when a
percpu_ref is used as a cyclic on/off switch via kill and reinit.

Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Kent Overstreet <kmo@daterainc.com>
include/linux/percpu-refcount.h