vt8500_pwm_remove() is only called after vt8500_pwm_probe() returned
successfully. In this case driver data was set to a non-NULL value
and so chip can never be NULL.
While touching this code also put declaration and assignment in a single
line.
Signed-off-by: Uwe Kleine-König <redacted>
---
drivers/pwm/pwm-vt8500.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
Until pwmchip_remove() returns the PWM is supposed to work, so
pwmchip_remove() must be called before the clock is stopped.
The return value of pwmchip_remove doesn't need to be checked because
it returns zero anyhow and I plan to make it return void soon.
Signed-off-by: Uwe Kleine-König <redacted>
---
drivers/pwm/pwm-vt8500.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
Hello,
for the record: There is no need to wait for a reply by Tony Prisk, his
address created a bounce (SMTP error from remote mail server after RCPT
TO:[off-list ref]: 550 relay not permitted)
Checking my archives I alread got such a result back in March, so this
doesn't seem to be a temporal problem.
Best regards
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
On Mon, Jun 21, 2021 at 3:04 PM Uwe Kleine-König
[off-list ref] wrote:
vt8500_pwm_remove() is only called after vt8500_pwm_probe() returned
successfully. In this case driver data was set to a non-NULL value
and so chip can never be NULL.
While touching this code also put declaration and assignment in a single
line.
Signed-off-by: Uwe Kleine-König <redacted>
---