diff options
author | Miguel Vadillo <vadillo@ti.com> | 2012-01-26 19:39:59 -0600 |
---|---|---|
committer | Todd Poynor <toddpoynor@google.com> | 2012-03-23 13:48:55 -0700 |
commit | b5368bdd16b7e4fc9e042d15fdc945c90e6e298a (patch) | |
tree | d68c53dd4dd1ea884549b36da1eb5c76df92a3a5 | |
parent | aecbc9a50dbf6638f20c286498b673d83f1cc503 (diff) | |
download | kernel_samsung_tuna-b5368bdd16b7e4fc9e042d15fdc945c90e6e298a.zip kernel_samsung_tuna-b5368bdd16b7e4fc9e042d15fdc945c90e6e298a.tar.gz kernel_samsung_tuna-b5368bdd16b7e4fc9e042d15fdc945c90e6e298a.tar.bz2 |
rpmsg: resmgr: disable aux_clk_src in case of error
If set_rate of aux_clk failed aux_clk_src was being left
enabled affecting the core OFF, fix the same.
Also avoid changing the return value of clk_set_rate.
Change-Id: I897d0669b43bf75ae49e9119ebfadf531bd585d5
Reported-by: Huzefa Kankroliwala <huzefank@ti.com>
Reported-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Miguel Vadillo <vadillo@ti.com>
-rw-r--r-- | drivers/rpmsg/rpmsg_resmgr.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/rpmsg/rpmsg_resmgr.c b/drivers/rpmsg/rpmsg_resmgr.c index a13094d..c98a1b9 100644 --- a/drivers/rpmsg/rpmsg_resmgr.c +++ b/drivers/rpmsg/rpmsg_resmgr.c @@ -214,7 +214,6 @@ static int rprm_auxclk_request(struct rprm_elem *e, struct rprm_auxclk *obj) if (ret) { pr_err("%s: rate not supported by %s\n", __func__, clk_src_name[obj->parent_src_clk]); - ret = -EINVAL; goto error_aux_src_parent; } @@ -236,7 +235,7 @@ static int rprm_auxclk_request(struct rprm_elem *e, struct rprm_auxclk *obj) ret = clk_set_rate(acd->aux_clk, (obj->clk_rate * MHZ)); if (ret) { pr_err("%s: rate not supported by %s\n", __func__, clk_name); - goto error_aux_src_parent; + goto error_aux_enable; } ret = clk_enable(acd->aux_clk); |