mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Michal Simek <michal.simek@xilinx.com>
To: Mike Looijmans <mike.looijmans@topic.nl>,
	<linux-mmc@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Cc: <michal.simek@xilinx.com>, <chris@printf.net>, <ulf.hansson@linaro.org>
Subject: Re: [PATCH 2/2] mmc/host/sdhci-of-arasan.c: Skip EPROBE_DEFER error messages
Date: Thu, 23 Oct 2014 13:47:45 +0200	[thread overview]
Message-ID: <40072ff932074ee189999faf5dc0a434@BL2FFO11FD037.protection.gbl> (raw)
In-Reply-To: <1414063861-5491-2-git-send-email-mike.looijmans@topic.nl>

Hi Chris,

On 10/23/2014 01:31 PM, Mike Looijmans wrote:
> When the error code is -EPROBE_DEFER, this will already be reported
> so don't emit an error message in that case.
> 
> Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl>
> ---
>  drivers/mmc/host/sdhci-of-arasan.c |    6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/mmc/host/sdhci-of-arasan.c b/drivers/mmc/host/sdhci-of-arasan.c
> index 7ac6718..d5812a0 100644
> --- a/drivers/mmc/host/sdhci-of-arasan.c
> +++ b/drivers/mmc/host/sdhci-of-arasan.c
> @@ -161,7 +161,8 @@ static int sdhci_arasan_probe(struct platform_device *pdev)
>  	host = sdhci_pltfm_init(pdev, &sdhci_arasan_pdata, 0);
>  	if (IS_ERR(host)) {
>  		ret = PTR_ERR(host);
> -		dev_err(&pdev->dev, "platform init failed (%d)\n", ret);
> +		if (ret != -EPROBE_DEFER)
> +			dev_err(&pdev->dev, "platform init failed (%d)\n", ret);
>  		goto clk_disable_all;
>  	}
>  
> @@ -172,7 +173,8 @@ static int sdhci_arasan_probe(struct platform_device *pdev)
>  
>  	ret = sdhci_add_host(host);
>  	if (ret) {
> -		dev_err(&pdev->dev, "platform register failed (%d)\n", ret);
> +		if (ret != -EPROBE_DEFER)
> +			dev_err(&pdev->dev, "platform register failed (%d)\n", ret);
>  		goto err_pltfm_free;
>  	}


I checked other drivers and they are not reporting these bugs. I have briefly looked
at sdhci_add_host and sdhci_platfm_init and they are pretty good error description
+ core itself should report if driver probe failed.
That's why I think that it is just reasonable to remove these both dev_err completely.

What do you think?

Thanks,
Michal

  reply	other threads:[~2014-10-23 12:02 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-23 11:31 [PATCH 1/2] mmc/host/sdhci-of-arasan.c: Use signed formatting in " Mike Looijmans
2014-10-23 11:31 ` [PATCH 2/2] mmc/host/sdhci-of-arasan.c: Skip EPROBE_DEFER " Mike Looijmans
2014-10-23 11:47   ` Michal Simek [this message]
2014-10-27 15:33     ` Ulf Hansson
2014-10-28  7:53       ` Mike Looijmans
2014-10-28  7:53         ` [PATCH] mmc/host/sdhci-of-arasan.c: Omit superfluous " Mike Looijmans
2014-10-28  9:49           ` Ulf Hansson
2014-10-27 15:38 ` [PATCH 1/2] mmc/host/sdhci-of-arasan.c: Use signed formatting in " Ulf Hansson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=40072ff932074ee189999faf5dc0a434@BL2FFO11FD037.protection.gbl \
    --to=michal.simek@xilinx.com \
    --cc=chris@printf.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=mike.looijmans@topic.nl \
    --cc=ulf.hansson@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®