Skip to content

Commit

Permalink
hwmon: (mr75203) fix wrong power-up delay value
Browse files Browse the repository at this point in the history
[ Upstream commit a8d6d49 ]

In the file mr75203.c we have a macro named POWER_DELAY_CYCLE_256,
the correct value should be 0x100. The register ip_tmr is expressed
in units of IP clk cycles, in accordance with the datasheet.
Typical power-up delays for Temperature Sensor are 256 cycles i.e. 0x100.

Fixes: 9d82335 ("hwmon: Add hardware monitoring driver for Moortec MR75203 PVT controller")
Signed-off-by: Arseny Demidov <a.demidov@yadro.com>
Link: https://lore.kernel.org/r/20211219102239.1112-1-a.demidov@yadro.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
arsdemal authored and gregkh committed Jan 27, 2022
1 parent 81c6534 commit 6857d17
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/hwmon/mr75203.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
#define VM_CH_REQ BIT(21)

#define IP_TMR 0x05
#define POWER_DELAY_CYCLE_256 0x80
#define POWER_DELAY_CYCLE_256 0x100
#define POWER_DELAY_CYCLE_64 0x40

#define PVT_POLL_DELAY_US 20
Expand Down

0 comments on commit 6857d17

Please sign in to comment.