diff options
author | 2018-11-05 14:34:57 +0200 | |
---|---|---|
committer | 2018-11-06 18:16:56 +0200 | |
commit | 1a1a0d5ccefca6f3f7417b448793c753a610da0c (patch) | |
tree | e296cdf745c8de022b2c7daf92e2faa0ed792b72 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | ath10k: snoc: remove 'wcn3990' from generic resource handling (diff) | |
download | wireguard-linux-1a1a0d5ccefca6f3f7417b448793c753a610da0c.tar.xz wireguard-linux-1a1a0d5ccefca6f3f7417b448793c753a610da0c.zip |
ath10k: snoc: fix unabalanced regulator error handling
If a regulator fails to set its voltage, we end up with an unbalanced
call to regulator_disable(), because the error path starts with the
current regulator (which was never enabled).
Factor out the "on" function to perform (and unwind if failed) a single
regulator at a time, and then main loop (ath10k_snoc_vreg_on()) can just
worry about unwinding the regulators that were already enabled.
It also helps to factor out the "off" function, to avoid repeating some
code here.
Signed-off-by: Brian Norris <briannorris@chromium.org>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions