aboutsummaryrefslogtreecommitdiff
path: root/scripts/bpf_doc.py
diff options
context:
space:
mode:
authorGuenter Roeck <[email protected]>2021-11-17 09:51:47 -0800
committerGuenter Roeck <[email protected]>2021-12-12 16:22:53 -0800
commit55840b9eae5367b5d5b29619dc2fb7e4596dba46 (patch)
tree61bb69db6a6d8c3de293f49eb0c5380727f268c7 /scripts/bpf_doc.py
parentfce15c45d3fbd9fc1feaaf3210d8e3f8b33dfd3a (diff)
hwmon: (lm90) Prevent integer overflow/underflow in hysteresis calculations
Commit b50aa49638c7 ("hwmon: (lm90) Prevent integer underflows of temperature calculations") addressed a number of underflow situations when writing temperature limits. However, it missed one situation, seen when an attempt is made to set the hysteresis value to MAX_LONG and the critical temperature limit is negative. Use clamp_val() when setting the hysteresis temperature to ensure that the provided value can never overflow or underflow. Fixes: b50aa49638c7 ("hwmon: (lm90) Prevent integer underflows of temperature calculations") Cc: Dmitry Osipenko <[email protected]> Reviewed-by: Dmitry Osipenko <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
Diffstat (limited to 'scripts/bpf_doc.py')
0 files changed, 0 insertions, 0 deletions