Message ID | 20220215084412.8090-3-marex@denx.de (mailing list archive) |
---|---|
State | Superseded, archived |
Headers | show |
Series | [1/3] dt-bindings: clk: Introduce 'critical-clocks' property | expand |
diff --git a/drivers/clk/clk-bd718x7.c b/drivers/clk/clk-bd718x7.c index ac40b669d60b7..8b41f122bbb0d 100644 --- a/drivers/clk/clk-bd718x7.c +++ b/drivers/clk/clk-bd718x7.c @@ -70,10 +70,16 @@ static int bd71837_clk_is_enabled(struct clk_hw *hw) return enabled & c->mask; } +static int bd71837_match_clkspec(struct clk_hw *hw, struct of_phandle_args *clkspec) +{ + return 0; +} + static const struct clk_ops bd71837_clk_ops = { .prepare = &bd71837_clk_enable, .unprepare = &bd71837_clk_disable, .is_prepared = &bd71837_clk_is_enabled, + .match_clkspec = &bd71837_match_clkspec, }; static int bd71837_clk_probe(struct platform_device *pdev)
The new match_clkspec() callback is used to determine whether struct clk_hw that is currently being registered matches the clock specifier currently in DT "critical-clock" property, and if so, then the CLK_IS_CRITICAL is added to these newly registered clock. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Rob Herring <robh+dt@kernel.org> Cc: Stephen Boyd <sboyd@kernel.org> Cc: devicetree@vger.kernel.org Cc: linux-power@fi.rohmeurope.com To: linux-clk@vger.kernel.org --- drivers/clk/clk-bd718x7.c | 6 ++++++ 1 file changed, 6 insertions(+)