summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuenter Roeck <linux@roeck-us.net>2017-02-12 02:04:56 +0300
committerStephen Boyd <sboyd@codeaurora.org>2017-02-16 04:17:55 +0300
commit6ff8ec98e12f984b9d62e43f83b0a3c44e2bdc12 (patch)
tree3b3ac2cca699eb8684c72ffcfa8b4f61da252d76
parent1006ccccd03c0e420bf0398a5ab944759268f387 (diff)
downloadlinux-6ff8ec98e12f984b9d62e43f83b0a3c44e2bdc12.tar.xz
clk: qcom: Do not drop device node twice
of_find_node_by_name() drops the reference to a passed device node. It is not necessary to drop it again, and doing so may result in the device node being released prematurely. Cc: Rob Herring <robh@kernel.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Fixes: ee15faffef11 ("clk: qcom: common: Add API to register board clocks backwards compatibly") Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
-rw-r--r--drivers/clk/qcom/common.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/clk/qcom/common.c b/drivers/clk/qcom/common.c
index cfab7b400381..03f9d316f969 100644
--- a/drivers/clk/qcom/common.c
+++ b/drivers/clk/qcom/common.c
@@ -145,7 +145,6 @@ static int _qcom_cc_register_board_clk(struct device *dev, const char *path,
clocks_node = of_find_node_by_path("/clocks");
if (clocks_node)
node = of_find_node_by_name(clocks_node, path);
- of_node_put(clocks_node);
if (!node) {
fixed = devm_kzalloc(dev, sizeof(*fixed), GFP_KERNEL);