Skip to content

Commit 4e7a8db

Browse files
ffainelliUwe Kleine-König
authored andcommitted
pwm: bcm2835: Fix NPD in suspend/resume
When 119a508 ("pwm: bcm2835: Add support for suspend/resume") was sent out on October 11th,, there was still a call to platform_set_drvdata() which would ensure that the driver private data structure could be used in bcm2835_pwm_{suspend,resume}. A cleanup now merged as commit commit 2ce7b7f ("pwm: bcm2835: Simplify using devm functions") removed that call which would now cause a NPD in bcm2835_pwm_{suspend,resume} as a consequence. Fixes: 119a508 ("pwm: bcm2835: Add support for suspend/resume") Signed-off-by: Florian Fainelli <[email protected]> Reviewed-by: Uwe Kleine-König <[email protected]> Link: https://lore.kernel.org/linux-pwm/[email protected] Signed-off-by: Uwe Kleine-König <[email protected]>
1 parent b85ea95 commit 4e7a8db

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/pwm/pwm-bcm2835.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,8 @@ static int bcm2835_pwm_probe(struct platform_device *pdev)
155155
pc->chip.ops = &bcm2835_pwm_ops;
156156
pc->chip.npwm = 2;
157157

158+
platform_set_drvdata(pdev, pc);
159+
158160
ret = devm_pwmchip_add(&pdev->dev, &pc->chip);
159161
if (ret < 0)
160162
return dev_err_probe(&pdev->dev, ret,

0 commit comments

Comments
 (0)