Re: [PATCH v1 2/4] clk: qcom: gdsc: Add support for clock voting from GDSC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Taniya Das (2021-11-02 02:56:51)
> In the cases where the clock is required to be enabled before the genpd
> enable add support for the same.

Please describe more. One sentence is not enough here.

> 
> Signed-off-by: Taniya Das <tdas@xxxxxxxxxxxxxx>
> ---
>  drivers/clk/qcom/gdsc.c | 45 +++++++++++++++++++++++++++++++++++++++------
>  drivers/clk/qcom/gdsc.h |  3 +++
>  2 files changed, 42 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/clk/qcom/gdsc.c b/drivers/clk/qcom/gdsc.c
> index 7e1dd8c..1caca32 100644
> --- a/drivers/clk/qcom/gdsc.c
> +++ b/drivers/clk/qcom/gdsc.c
> @@ -478,6 +499,18 @@ int gdsc_register(struct gdsc_desc *desc,
>                         return PTR_ERR(scs[i]->rsupply);
>         }
> 
> +       for (i = 0; i < num; i++) {
> +               if (!scs[i])
> +                       continue;
> +
> +               scs[i]->clk = devm_clk_get(dev, scs[i]->clk_name);
> +               if (IS_ERR(scs[i]->clk))
> +                       return PTR_ERR(scs[i]->clk);
> +               ret = clk_prepare(scs[i]->clk);

Why do we keep it prepared forever? And don't we have support for
writing directly into cxc registers?

> +               if (ret)
> +                       return ret;
> +       }
> +
>         data->num_domains = num;
>         for (i = 0; i < num; i++) {
>                 if (!scs[i])




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux