Skip to content

Commit 4e3cea8

Browse files
Subbaraman Narayanamurthygregkh
authored andcommitted
interconnect: qcom: bcm-voter: add a missing of_node_put()
[ Upstream commit a005937 ] Add a missing of_node_put() in of_bcm_voter_get() to avoid the reference leak. Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org> Reviewed-by: Matthias Kaehlcke <mka@chromium.org> Link: https://lore.kernel.org/r/1619116570-13308-1-git-send-email-subbaram@codeaurora.org Fixes: 976daac ("interconnect: qcom: Consolidate interconnect RPMh support") Signed-off-by: Georgi Djakov <djakov@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent d7932e6 commit 4e3cea8

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎drivers/interconnect/qcom/bcm-voter.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// SPDX-License-Identifier: GPL-2.0
22
/*
3-
* Copyright (c) 2020, The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2020-2021, The Linux Foundation. All rights reserved.
44
*/
55

66
#include <asm/div64.h>
@@ -212,6 +212,7 @@ struct bcm_voter *of_bcm_voter_get(struct device *dev, const char *name)
212212
}
213213
mutex_unlock(&bcm_voter_lock);
214214

215+
of_node_put(node);
215216
return voter;
216217
}
217218
EXPORT_SYMBOL_GPL(of_bcm_voter_get);

0 commit comments

Comments
 (0)