From: Guenter Roeck Date: Mon, 19 Jan 2015 17:16:53 +0000 (-0800) Subject: hwmon: (jc42) Fix integer overflow when writing hysteresis value X-Git-Tag: fixes-v4.0-rc1~186^2~7 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e2c26f058e31619b548046b84fe2c2116cb5016f;p=pandora-kernel.git hwmon: (jc42) Fix integer overflow when writing hysteresis value Subtracting an unsigned long from a signed value causes an overflow with large values. Use clamp_val() to reduce the number range prior to subtracting it from the temperature limit. Signed-off-by: Guenter Roeck Reviewed-by: Jean Delvare --- Reading git-diff-tree failed