]> git.karo-electronics.de Git - linux-beck.git/commit
hwmon: (emc2103) Fix overflows seen when temperature limit attributes
authorGuenter Roeck <linux@roeck-us.net>
Mon, 5 Dec 2016 02:19:51 +0000 (18:19 -0800)
committerGuenter Roeck <linux@roeck-us.net>
Mon, 12 Dec 2016 19:33:43 +0000 (11:33 -0800)
commitca1b10b8250247fb5f241d1cb894c102203378bb
tree0f6621899fc6c0fcadd0a5886e36a2cd9f7f34e1
parent67b2003485ee48dcfcb5338171defa4093bba02e
hwmon: (emc2103) Fix overflows seen when temperature limit attributes

Writes into temperature limit attributes can overflow due to unbound
values passed to DIV_ROUND_CLOSEST().

Cc: Steve Glendinning <steve.glendinning@shawell.net>
Reviewed-by: Jean Delvare <jdelvare@suse.de>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/emc2103.c