mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] hwmon: (pwm-fan) Let ctx->pwm_value be assigned only in __set_pwm
@ 2021-11-30  3:00 Billy Tsai
  2021-11-30  6:55 ` Uwe Kleine-König
  0 siblings, 1 reply; 3+ messages in thread
From: Billy Tsai @ 2021-11-30  3:00 UTC (permalink / raw)
  To: b.zolnierkie, jdelvare, linux, u.kleine-koenig, linux-hwmon,
	linux-kernel
  Cc: BMC-SW

This patch is used to fix the bug when pwm_fan_probe the pwm_value will
be out of sync with the PWM hardware drivers.

Fixes: 86585c61972f ("hwmon: (pwm-fan) stop using legacy PWM functions and some cleanups")
Signed-off-by: Billy Tsai <billy_tsai@aspeedtech.com>
---
 drivers/hwmon/pwm-fan.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/hwmon/pwm-fan.c b/drivers/hwmon/pwm-fan.c
index 17518b4cab1b..f12b9a28a232 100644
--- a/drivers/hwmon/pwm-fan.c
+++ b/drivers/hwmon/pwm-fan.c
@@ -336,8 +336,6 @@ static int pwm_fan_probe(struct platform_device *pdev)
 			return ret;
 	}
 
-	ctx->pwm_value = MAX_PWM;
-
 	pwm_init_state(ctx->pwm, &ctx->pwm_state);
 
 	/*
-- 
2.25.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-11-30  9:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-30  3:00 [PATCH] hwmon: (pwm-fan) Let ctx->pwm_value be assigned only in __set_pwm Billy Tsai
2021-11-30  6:55 ` Uwe Kleine-König
2021-11-30  9:12   ` Billy Tsai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®