Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3c69280b authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "coresight: Set clk rate for all coresight devices"

parents eff5930f 2a787e6d
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -13,6 +13,7 @@
#include <linux/slab.h>
#include <linux/mutex.h>
#include <linux/clk.h>
#include <dt-bindings/clock/qcom,aop-qmp.h>
#include <linux/coresight.h>
#include <linux/of_platform.h>
#include <linux/delay.h>
@@ -1046,6 +1047,14 @@ struct coresight_device *coresight_register(struct coresight_desc *desc)
	atomic_t *refcnts = NULL;
	struct coresight_device *csdev;
	struct coresight_connection *conns = NULL;
	struct clk *pclk;

	pclk = clk_get(desc->dev, "apb_pclk");
	if (!IS_ERR(pclk)) {
		ret = clk_set_rate(pclk, QDSS_CLK_LEVEL_DYNAMIC);
		if (ret)
			dev_err(desc->dev, "clk set rate failed\n");
	}

	csdev = kzalloc(sizeof(*csdev), GFP_KERNEL);
	if (!csdev) {