From: Jean Delvare Date: Sun, 26 Oct 2008 16:04:39 +0000 (+0100) Subject: hwmon: (lm90) Fix handling of hysteresis value X-Git-Tag: v2.6.28-rc2~6^2~4 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ec38fa2b35f13e7fa1d676a5bc997d0df1b02574;p=pandora-kernel.git hwmon: (lm90) Fix handling of hysteresis value There are several problems in the way the hysteresis value is handled by the lm90 driver: * In show_temphyst(), specific handling of the MAX6646 is missing, so the hysteresis is reported incorrectly if the critical temperature is over 127 degrees C. * In set_temphyst(), the new hysteresis register value is written to the chip but data->temp_hyst isn't updated accordingly, so there is a short period of time (up to 2 seconds) where the old hystereris value will be returned while the new one is already active. * In set_temphyst(), the critical temperature which is used as a base to compute the value of the hysteresis register lacks device-specific handling. As a result, the value of the hysteresis register might be incorrect for the ADT7461 and MAX6646 chips. Fix these 3 bugs. Signed-off-by: Jean Delvare Cc: Ben Hutchings Cc: Nate Case --- Reading git-diff-tree failed