All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] hwmon: (aspeed-pwm-tacho) Using falling edge.
@ 2021-06-24  3:58 ` Billy Tsai
  0 siblings, 0 replies; 12+ messages in thread
From: Billy Tsai @ 2021-06-24  3:58 UTC (permalink / raw)
  To: jdelvare, linux, joel, andrew, linux-hwmon, linux-arm-kernel,
	linux-aspeed, linux-kernel
  Cc: BMC-SW

The tach shouldn't use both edges to measure. When the tach input
duty cycle isn't 50% the return value will inaccurate.

Signed-off-by: Billy Tsai <billy_tsai@aspeedtech.com>
---
 drivers/hwmon/aspeed-pwm-tacho.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/hwmon/aspeed-pwm-tacho.c b/drivers/hwmon/aspeed-pwm-tacho.c
index 3d8239fd66ed..0a70a0e22acf 100644
--- a/drivers/hwmon/aspeed-pwm-tacho.c
+++ b/drivers/hwmon/aspeed-pwm-tacho.c
@@ -158,7 +158,7 @@
  * 10: both
  * 11: reserved.
  */
-#define M_TACH_MODE 0x02 /* 10b */
+#define M_TACH_MODE 0x00 /* 10b */
 #define M_TACH_UNIT 0x0210
 #define INIT_FAN_CTRL 0xFF
 
-- 
2.25.1


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

end of thread, other threads:[~2021-06-29 13:39 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-24  3:58 [PATCH] hwmon: (aspeed-pwm-tacho) Using falling edge Billy Tsai
2021-06-24  3:58 ` Billy Tsai
2021-06-24 12:44 ` Guenter Roeck
2021-06-24 12:44   ` Guenter Roeck
2021-06-25  3:35   ` Billy Tsai
2021-06-25  3:35     ` Billy Tsai
2021-06-28 13:56     ` Guenter Roeck
2021-06-28 13:56       ` Guenter Roeck
2021-06-29  5:26       ` Billy Tsai
2021-06-29  5:26         ` Billy Tsai
2021-06-29 13:14         ` Guenter Roeck
2021-06-29 13:14           ` Guenter Roeck

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.