iio: adc: exynos: Silence warning about regulators during deferred probe
diff mbox series

Message ID 20200228092121.15918-1-m.szyprowski@samsung.com
State Not Applicable
Headers show
Series
  • iio: adc: exynos: Silence warning about regulators during deferred probe
Related show

Commit Message

Marek Szyprowski Feb. 28, 2020, 9:21 a.m. UTC
Don't confuse user with meaningless warning about the failure in getting
regulators in case of deferred probe.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
 drivers/iio/adc/exynos_adc.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

Comments

Krzysztof Kozlowski Feb. 28, 2020, 11:33 a.m. UTC | #1
On Fri, Feb 28, 2020 at 10:21:21AM +0100, Marek Szyprowski wrote:
> Don't confuse user with meaningless warning about the failure in getting
> regulators in case of deferred probe.
> 
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>  drivers/iio/adc/exynos_adc.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)

Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>

Best regards,
Krzysztof
Jonathan Cameron March 1, 2020, 12:03 p.m. UTC | #2
On Fri, 28 Feb 2020 12:33:14 +0100
Krzysztof Kozlowski <krzk@kernel.org> wrote:

> On Fri, Feb 28, 2020 at 10:21:21AM +0100, Marek Szyprowski wrote:
> > Don't confuse user with meaningless warning about the failure in getting
> > regulators in case of deferred probe.
> > 
> > Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> > ---
> >  drivers/iio/adc/exynos_adc.c | 6 ++++--
> >  1 file changed, 4 insertions(+), 2 deletions(-)  
> 
> Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>

Applied to the togreg branch of iio.git and pushed out
as testing for the autobuilders to play with it.

Thanks,

Jonathan

> 
> Best regards,
> Krzysztof
>

Patch
diff mbox series

diff --git a/drivers/iio/adc/exynos_adc.c b/drivers/iio/adc/exynos_adc.c
index 2df7d057b249..22131a677445 100644
--- a/drivers/iio/adc/exynos_adc.c
+++ b/drivers/iio/adc/exynos_adc.c
@@ -836,8 +836,10 @@  static int exynos_adc_probe(struct platform_device *pdev)
 
 	info->vdd = devm_regulator_get(&pdev->dev, "vdd");
 	if (IS_ERR(info->vdd)) {
-		dev_err(&pdev->dev, "failed getting regulator, err = %ld\n",
-							PTR_ERR(info->vdd));
+		if (PTR_ERR(info->vdd) != -EPROBE_DEFER)
+			dev_err(&pdev->dev,
+				"failed getting regulator, err = %ld\n",
+				PTR_ERR(info->vdd));
 		return PTR_ERR(info->vdd);
 	}