summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/sctop.py
diff options
context:
space:
mode:
authorSebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm>2021-09-14 14:18:06 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-11-26 11:58:36 +0100
commited6dd7282ab658daae9064d24ad04b8756dfe120 (patch)
tree17616ea09a8a99980662b5e3e0f729edea6ab2f4 /tools/perf/scripts/python/sctop.py
parent3f8f7b4ef6d97ba0015e675fd46c329869712e7e (diff)
power: supply: max17042_battery: Prevent int underflow in set_soc_threshold
commit e660dbb68c6b3f7b9eb8b9775846a44f9798b719 upstream. max17042_set_soc_threshold gets called with offset set to 1, which means that minimum threshold value would underflow once SOC got down to 0, causing invalid alerts from the gauge. Fixes: e5f3872d2044 ("max17042: Add support for signalling change in SOC") Cc: <stable@vger.kernel.org> Signed-off-by: Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/sctop.py')
0 files changed, 0 insertions, 0 deletions