]> Git Repo - linux.git/commitdiff
pwm: omap-dmtimer: Return -EPROBE_DEFER if no dmtimer platform data
authorDavid Rivshin <[email protected]>
Wed, 1 Aug 2018 14:17:29 +0000 (10:17 -0400)
committerThierry Reding <[email protected]>
Mon, 20 Aug 2018 09:32:19 +0000 (11:32 +0200)
If a pwm-omap-dmtimer is probed before the dmtimer it uses, the platform
data won't be set yet.

Fixes: ac30751df953 ("ARM: OMAP: pdata-quirks: Remove unused timer pdata")
Cc: <[email protected]> # 4.17+
Signed-off-by: David Rivshin <[email protected]>
Acked-by: Pavel Machek <[email protected]>
Tested-by: Pavel Machek <[email protected]>
Acked-by: Ladislav Michl <[email protected]>
Tested-by: Andreas Kemnade <[email protected]>
Signed-off-by: Thierry Reding <[email protected]>
drivers/pwm/pwm-omap-dmtimer.c

index 665da3c8fbcebab087db37cbedc21897b0cb04e8..f45798679e3c046add4f646ecd5c86e02a7b9b9c 100644 (file)
@@ -264,8 +264,9 @@ static int pwm_omap_dmtimer_probe(struct platform_device *pdev)
 
        timer_pdata = dev_get_platdata(&timer_pdev->dev);
        if (!timer_pdata) {
-               dev_err(&pdev->dev, "dmtimer pdata structure NULL\n");
-               ret = -EINVAL;
+               dev_dbg(&pdev->dev,
+                        "dmtimer pdata structure NULL, deferring probe\n");
+               ret = -EPROBE_DEFER;
                goto put;
        }
 
This page took 0.054448 seconds and 4 git commands to generate.