aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Rutland <mark.rutland@arm.com>2021-12-17 15:39:17 +0000
committerMark Rutland <mark.rutland@arm.com>2021-12-17 15:40:00 +0000
commitae5010b75aaeb2f0110399b12099d59044d3b22d (patch)
treefe300b9b708072d49b4dabd02c75778a73012594
parent488dd36233a4a0d80f516054ee894688fc8f447f (diff)
downloadlinux-ae5010b75aaeb2f0110399b12099d59044d3b22d.tar.gz
WIP: kref: use refcount_init()
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
-rw-r--r--include/linux/kref.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/kref.h b/include/linux/kref.h
index d32e21a2538c2..ab409aaea57c4 100644
--- a/include/linux/kref.h
+++ b/include/linux/kref.h
@@ -28,7 +28,7 @@ struct kref {
*/
static inline void kref_init(struct kref *kref)
{
- refcount_set(&kref->refcount, 1);
+ refcount_init(&kref->refcount, 1);
}
static inline unsigned int kref_read(const struct kref *kref)