Skip to content

Commit b2edb16

Browse files
ukleinekclaudiubeznea
authored andcommitted
pwm: ab8500: Explicitly allocate pwm chip base dynamically
The ab8500 driver is the last one which doesn't (explicitly) use dynamic allocation of the pwm id. Looking through the kernel sources I didn't find a place that relies on this id. And with the device probed from device tree pdev->id is -1 anyhow; making this explicit looks beneficial, too. Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org> Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
1 parent eb16fc3 commit b2edb16

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/pwm/pwm-ab8500.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ static int ab8500_pwm_probe(struct platform_device *pdev)
101101

102102
ab8500->chip.dev = &pdev->dev;
103103
ab8500->chip.ops = &ab8500_pwm_ops;
104-
ab8500->chip.base = pdev->id;
104+
ab8500->chip.base = -1;
105105
ab8500->chip.npwm = 1;
106106

107107
err = pwmchip_add(&ab8500->chip);

0 commit comments

Comments
 (0)