]> git.karo-electronics.de Git - karo-tx-linux.git/commit
hwmon: (sht15) Fix integer overflow in humidity calculation
authorVivien Didelot <vivien.didelot@savoirfairelinux.com>
Mon, 21 Mar 2011 16:59:35 +0000 (17:59 +0100)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Sun, 26 Jun 2011 16:47:11 +0000 (12:47 -0400)
commit6362caf82ffba0b81e26a292135dcaf1abf6f8c6
tree043c3987f477084203a0163643cf6465e2f31874
parent346e7c6095e53c6b3ba0138e3c625b21dfddce6f
hwmon: (sht15) Fix integer overflow in humidity calculation

commit ccd32e735de7a941906e093f8dca924bb05c5794 upstream.

An integer overflow occurs in the calculation of RHlinear when the
relative humidity is greater than around 30%. The consequence is a subtle
(but noticeable) error in the resulting humidity measurement.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
drivers/hwmon/sht15.c