diff options
author | Jens Axboe <jaxboe@fusionio.com> | 2011-01-07 02:43:37 -0500 |
---|---|---|
committer | Jens Axboe <jaxboe@fusionio.com> | 2011-01-07 02:43:37 -0500 |
commit | 6c23a9681c0fe7fb7dd331b39dda11926f43746e (patch) | |
tree | bf113a475a17faa866e7e59806378107dcb3aa40 /lib/kref.c | |
parent | 09e099d4bafea3b15be003d548bdf94b4b6e0e17 (diff) |
block: add internal hd part table references
We can't use krefs since it's apparently restricted to very basic
reference counting.
This reverts commit e4a683c8.
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
Diffstat (limited to 'lib/kref.c')
-rw-r--r-- | lib/kref.c | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/lib/kref.c b/lib/kref.c index e7a6e1067122..d3d227a08a4b 100644 --- a/lib/kref.c +++ b/lib/kref.c | |||
@@ -37,18 +37,6 @@ void kref_get(struct kref *kref) | |||
37 | } | 37 | } |
38 | 38 | ||
39 | /** | 39 | /** |
40 | * kref_test_and_get - increment refcount for object only if refcount is not | ||
41 | * zero. | ||
42 | * @kref: object. | ||
43 | * | ||
44 | * Return non-zero if the refcount was incremented, 0 otherwise | ||
45 | */ | ||
46 | int kref_test_and_get(struct kref *kref) | ||
47 | { | ||
48 | return atomic_inc_not_zero(&kref->refcount); | ||
49 | } | ||
50 | |||
51 | /** | ||
52 | * kref_put - decrement refcount for object. | 40 | * kref_put - decrement refcount for object. |
53 | * @kref: object. | 41 | * @kref: object. |
54 | * @release: pointer to the function that will clean up the object when the | 42 | * @release: pointer to the function that will clean up the object when the |