hwmon: (lm90) Add range check to set_update_interval
When writing the update_interval attribute, the parameter value was not range checked, which could cause an integer overflow and result in an arbitrary update interval. Fix by limiting the value range to <0, 100000>. Reported-by: NJean Delvare <khali@linux-fr.org> Signed-off-by: NGuenter Roeck <linux@roeck-us.net> Signed-off-by: NJean Delvare <khali@linux-fr.org>
Showing
想要评论请 注册 或 登录