Skip to content

Commit

Permalink
Revert "clk: tegra: super: Switch to determine_rate"
Browse files Browse the repository at this point in the history
This reverts commit 493ffb0.
  • Loading branch information
digetx committed Jun 18, 2023
1 parent b31564e commit f0c1ad4
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions drivers/clk/tegra/clk-super.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,22 +142,15 @@ static const struct clk_ops tegra_clk_super_mux_ops = {
.restore_context = clk_super_mux_restore_context,
};

static int clk_super_determine_rate(struct clk_hw *hw,
struct clk_rate_request *req)
static long clk_super_round_rate(struct clk_hw *hw, unsigned long rate,
unsigned long *parent_rate)
{
struct tegra_clk_super_mux *super = to_clk_super_mux(hw);
struct clk_hw *div_hw = &super->frac_div.hw;
unsigned long rate;

__clk_hw_set_clk(div_hw, hw);

rate = super->div_ops->round_rate(div_hw, req->rate,
&req->best_parent_rate);
if (rate < 0)
return rate;

req->rate = rate;
return 0;
return super->div_ops->round_rate(div_hw, rate, parent_rate);
}

static unsigned long clk_super_recalc_rate(struct clk_hw *hw,
Expand Down Expand Up @@ -200,7 +193,7 @@ const struct clk_ops tegra_clk_super_ops = {
.get_parent = clk_super_get_parent,
.set_parent = clk_super_set_parent,
.set_rate = clk_super_set_rate,
.determine_rate = clk_super_determine_rate,
.round_rate = clk_super_round_rate,
.recalc_rate = clk_super_recalc_rate,
.restore_context = clk_super_restore_context,
};
Expand Down

0 comments on commit f0c1ad4

Please sign in to comment.