]> Git Repo - linux.git/commit
pwm: bcm2835: Simplify using devm functions
authorUwe Kleine-König <[email protected]>
Fri, 29 Sep 2023 16:19:09 +0000 (18:19 +0200)
committerThierry Reding <[email protected]>
Fri, 13 Oct 2023 08:07:18 +0000 (10:07 +0200)
commit2ce7b7f6704c9a8040fb12eb2b682986d9129e68
treeabc1292be4fa3d78d312d977030abf87970f6762
parentb498c14efd4241d79999b9bb943e963eb982450c
pwm: bcm2835: Simplify using devm functions

With devm_clk_get_enabled() the call to clk_disable_unprepare() can be
dropped from the error path and the remove callback. With
devm_pwmchip_add() pwmchip_remove() can be dropped. Then the remove
callback is empty and can go away, too. With bcm2835_pwm_remove() the only
user of platform_get_drvdata() is gone and so platform_set_drvdata() can
be dropped from .probe(), too.

Also use dev_err_probe() for simplified (and improved) error reporting.

Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Uwe Kleine-König <[email protected]>
Signed-off-by: Thierry Reding <[email protected]>
drivers/pwm/pwm-bcm2835.c
This page took 0.054406 seconds and 4 git commands to generate.