diff options
author | Anson Huang <b20788@freescale.com> | 2013-03-29 09:44:41 +0800 |
---|---|---|
committer | Anson Huang <b20788@freescale.com> | 2013-04-02 17:42:30 +0800 |
commit | 1c3d1f160aa1f7623541403332b216db8ec35868 (patch) | |
tree | 2c1430bbcde317d8909cbc4d117270ec5120116f | |
parent | f242f31ed2f0f680dafc34ff705d45f0997f05f4 (diff) | |
download | linux-1c3d1f160aa1f7623541403332b216db8ec35868.tar.gz |
ENGR00256543 mx6: Update equation for thermal sensor on i.MX6DL
Use universal equation and 25C's calibration data to
get thermal sensor's ratio on i.MX6DL.
Signed-off-by: Anson Huang <b20788@freescale.com>
-rw-r--r-- | drivers/mxc/thermal/thermal.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mxc/thermal/thermal.c b/drivers/mxc/thermal/thermal.c index 21a87b71f549..4931ce1fa252 100644 --- a/drivers/mxc/thermal/thermal.c +++ b/drivers/mxc/thermal/thermal.c @@ -883,13 +883,13 @@ static int anatop_thermal_counting_ratio(unsigned int fuse_data) raw_hot = (fuse_data & 0xfff00) >> 8; hot_temp = fuse_data & 0xff; - if (!calibration_valid && cpu_is_mx6q()) + if (!calibration_valid && !cpu_is_mx6sl()) /* * The universal equation for thermal sensor * is slope = 0.4297157 - (0.0015976 * 25C fuse), * here we convert them to integer to make them * easy for counting, FACTOR1 is 15976, - * FACTORs is 4297157. Our ratio = -100 * slope. + * FACTOR2 is 4297157. Our ratio = -100 * slope. */ ratio = ((FACTOR1 * raw_25c - FACTOR2) + 50000) / 100000; else |