From: Keerthy Date: Thu, 24 Oct 2019 09:30:47 +0000 (+0530) Subject: clk: clk-ti-sci: Notify AVS driver upon setting clock rate X-Git-Url: http://git.dujemihanovic.xyz/login.html?a=commitdiff_plain;h=e0aa873bc7cd38d802cfdbe186fbbbafb9f6691e;p=u-boot.git clk: clk-ti-sci: Notify AVS driver upon setting clock rate Notify AVS driver upon setting clock rate so that voltage is changed accordingly. Signed-off-by: Keerthy --- diff --git a/drivers/clk/clk-ti-sci.c b/drivers/clk/clk-ti-sci.c index c25415d410..478349f22f 100644 --- a/drivers/clk/clk-ti-sci.c +++ b/drivers/clk/clk-ti-sci.c @@ -13,6 +13,7 @@ #include #include #include +#include /** * struct ti_sci_clk_data - clock controller information structure @@ -101,6 +102,10 @@ static ulong ti_sci_clk_set_rate(struct clk *clk, ulong rate) debug("%s(clk=%p, rate=%lu)\n", __func__, clk, rate); +#ifdef CONFIG_K3_AVS0 + k3_avs_notify_freq(clk->id, clk->data, rate); +#endif + /* Ask for exact frequency by using same value for min/target/max */ ret = cops->set_freq(sci, clk->id, clk->data, rate, rate, rate); if (ret)