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

Commit d8047bb8 authored by Vikram Mulukutla's avatar Vikram Mulukutla
Browse files

msm: clock-generic: Add get_rate op for ext clocks



The ext clock type may sometimes need to report the
rate of its parent. Add the get_rate op to allow this.

Change-Id: Id22e6a52aa36422fe4583d9c062a962f3399b6c4
Signed-off-by: default avatarVikram Mulukutla <markivx@codeaurora.org>
parent fe150fb4
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -524,6 +524,11 @@ static int ext_set_rate(struct clk *c, unsigned long rate)
	return clk_set_rate(c->parent, rate);
}

static unsigned long ext_get_rate(struct clk *c)
{
	return clk_get_rate(c->parent);
}

static int ext_set_parent(struct clk *c, struct clk *p)
{
	return clk_set_parent(c->parent, p);
@@ -540,6 +545,7 @@ struct clk_ops clk_ops_ext = {
	.handoff = ext_handoff,
	.round_rate = ext_round_rate,
	.set_rate = ext_set_rate,
	.get_rate = ext_get_rate,
	.set_parent = ext_set_parent,
};