summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/hwtracing/coresight/of_coresight.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/hwtracing/coresight/of_coresight.c b/drivers/hwtracing/coresight/of_coresight.c
index 70205f3eae8e..28d3aef1660b 100644
--- a/drivers/hwtracing/coresight/of_coresight.c
+++ b/drivers/hwtracing/coresight/of_coresight.c
@@ -168,6 +168,11 @@ static int of_coresight_parse_endpoint(struct device *dev,
ret = 1;
} while (0);
+ if (rparent)
+ of_node_put(rparent);
+ if (rport)
+ of_node_put(rport);
+
return ret;
}