Re: [PATCH v2 5/5] clk: qcom: apcs-msm8916: get parent clock names from DT

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

 



Quoting Jorge Ramirez-Ortiz (2019-09-12 07:15:34)
> @@ -61,6 +62,9 @@ static int qcom_apcs_msm8916_clk_probe(struct platform_device *pdev)
>         if (!a53cc)
>                 return -ENOMEM;
>  
> +       if (of_clk_parent_fill(parent->of_node, parents, 2) == 2)
> +               memcpy(gpll0_a53cc, parents, sizeof(parents));
> +
>         init.name = "a53mux";
>         init.parent_names = gpll0_a53cc;
>         init.num_parents = ARRAY_SIZE(gpll0_a53cc);

Why can't we use new way of specifying parents in this driver too?

> @@ -76,10 +80,11 @@ static int qcom_apcs_msm8916_clk_probe(struct platform_device *pdev)
>         a53cc->src_shift = 8;
>         a53cc->parent_map = gpll0_a53cc_map;
>  
> -       a53cc->pclk = devm_clk_get(parent, NULL);
> +       a53cc->pclk = of_clk_get(parent->of_node, 0);

And then leave this one alone? clk_get() with a NULL id should use a DT
index of 0 from what I can tell.

>         if (IS_ERR(a53cc->pclk)) {
>                 ret = PTR_ERR(a53cc->pclk);
> -               dev_err(dev, "failed to get clk: %d\n", ret);
> +               if (ret != -EPROBE_DEFER)
> +                       dev_err(dev, "failed to get clk: %d\n", ret);
>                 return ret;
>         }
>  




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux