usb: chipidea: msm: Be silent on probe defer errors
authorStephen Boyd <stephen.boyd@linaro.org>
Wed, 28 Dec 2016 22:57:07 +0000 (14:57 -0800)
committerPeter Chen <peter.chen@nxp.com>
Fri, 20 Jan 2017 07:27:38 +0000 (15:27 +0800)
If something fails in ci_hdrc_add_device() due to probe defer, we
shouldn't print an error message. Be silent in this case as we'll
try probe again later.

Acked-by: Peter Chen <peter.chen@nxp.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org>
Signed-off-by: Peter Chen <peter.chen@nxp.com>
drivers/usb/chipidea/ci_hdrc_msm.c

index 316044dba0ac16f951c7d7bf0bb5af7745147e3f..f1ede7909f54397ea624036165787d58408b2b8c 100644 (file)
@@ -262,8 +262,9 @@ static int ci_hdrc_msm_probe(struct platform_device *pdev)
        plat_ci = ci_hdrc_add_device(&pdev->dev, pdev->resource,
                                     pdev->num_resources, &ci->pdata);
        if (IS_ERR(plat_ci)) {
-               dev_err(&pdev->dev, "ci_hdrc_add_device failed!\n");
                ret = PTR_ERR(plat_ci);
+               if (ret != -EPROBE_DEFER)
+                       dev_err(&pdev->dev, "ci_hdrc_add_device failed!\n");
                goto err_mux;
        }