lkml.org 
[lkml]   [2018]   [Apr]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: clk: bulk: silently error out on EPROBE_DEFER
From
Date
Hi Jerome,

On 2018/4/9 22:13, Jerome Brunet wrote:
> In clk_bulk_get(), if we fail to get the clock due to probe deferal, we
> shouldn't print an error message. Just be silent in this case.
>

I saw a confusing clk get failure log occasionally, but didn't pay
much attention to it as the driver finally probed fine. But probably it
came from clk_bulk_get,

Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com>

> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
> ---
> drivers/clk/clk-bulk.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/clk/clk-bulk.c b/drivers/clk/clk-bulk.c
> index 4c10456f8a32..6904ed6da504 100644
> --- a/drivers/clk/clk-bulk.c
> +++ b/drivers/clk/clk-bulk.c
> @@ -42,8 +42,9 @@ int __must_check clk_bulk_get(struct device *dev, int num_clks,
> clks[i].clk = clk_get(dev, clks[i].id);
> if (IS_ERR(clks[i].clk)) {
> ret = PTR_ERR(clks[i].clk);
> - dev_err(dev, "Failed to get clk '%s': %d\n",
> - clks[i].id, ret);
> + if (ret != -EPROBE_DEFER)
> + dev_err(dev, "Failed to get clk '%s': %d\n",
> + clks[i].id, ret);
> clks[i].clk = NULL;
> goto err;
> }
>

\
 
 \ /
  Last update: 2018-04-11 04:55    [W:0.028 / U:2.652 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site