diff mbox series

[4/4] pwm: berlin: Don't check the return code of pwmchip_remove()

Message ID 20210504132537.62072-4-u.kleine-koenig@pengutronix.de
State Accepted
Headers show
Series [1/4] pwm: berlin: use consistent naming for variables | expand

Commit Message

Uwe Kleine-König May 4, 2021, 1:25 p.m. UTC
pwmchip_remove() always returns 0. Don't use the value to make it
possible to eventually change the function to return void. This is a
good thing as pwmchip_remove() is usually called from a remove function
(mostly for platform devices) and their return value is ignored by the
device core anyhow.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
 drivers/pwm/pwm-berlin.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/drivers/pwm/pwm-berlin.c b/drivers/pwm/pwm-berlin.c
index 4e838a973c97..605e91d2f6b9 100644
--- a/drivers/pwm/pwm-berlin.c
+++ b/drivers/pwm/pwm-berlin.c
@@ -241,12 +241,12 @@  static int berlin_pwm_probe(struct platform_device *pdev)
 static int berlin_pwm_remove(struct platform_device *pdev)
 {
 	struct berlin_pwm_chip *bpc = platform_get_drvdata(pdev);
-	int ret;
 
-	ret = pwmchip_remove(&bpc->chip);
+	pwmchip_remove(&bpc->chip);
+
 	clk_disable_unprepare(bpc->clk);
 
-	return ret;
+	return 0;
 }
 
 #ifdef CONFIG_PM_SLEEP