aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorTimur Tabi <timur@codeaurora.org>2018-03-29 13:29:12 -0500
committerLinus Walleij <linus.walleij@linaro.org>2018-04-26 11:27:18 +0200
commitab3dbcf78f60f46d6a0ad63b1f4b690b7a427140 (patch)
tree54dc4dd788f1bed7ed77eec19ecb7cfd08daf6b8 /tools/perf/scripts/python
parentf241632fd087d3d9fbd5450f4d8c8604badd8348 (diff)
gpioib: do not free unrequested descriptors
If the main loop in linehandle_create() encounters an error, it unwinds completely by freeing all previously requested GPIO descriptors. However, if the error occurs in the beginning of the loop before that GPIO is requested, then the exit code attempts to free a null descriptor. If extrachecks is enabled, gpiod_free() triggers a WARN_ON. Instead, keep a separate count of legitimate GPIOs so that only those are freed. Cc: stable@vger.kernel.org Fixes: d7c51b47ac11 ("gpio: userspace ABI for reading/writing GPIO lines") Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Timur Tabi <timur@codeaurora.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions