summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorJoshua Crofts <joshua.crofts1@gmail.com>2026-05-05 09:31:27 +0200
committerJonathan Cameron <jic23@kernel.org>2026-05-31 10:59:34 +0100
commit8c50a95ceb230d17801758a9e41ffbbbe46f8b4d (patch)
tree93ba094c779e60b8dc83a39689bc904e56852ff7 /tools/perf/scripts/python/stackcollapse.py
parent0a5f45ed2342aabae1e32c72558d15be28940a95 (diff)
iio: light: si1133: prevent race condition on timeout
Sashiko reported a bug where the si1133_command exits on timeout without halting the sensor or masking the interrupt. If the sensor completes the command later, any subsequent command to the sensor will cause the IRQ handler to complete immediately, returning stale data to the driver all while the command hasn't finished yet, shifting all potential reads in the future. Fix this by masking the IRQ if wait_for_completion_timeout() fails. When initiating a new command, do a dummy read of the IRQ_STATUS register and turn the IRQ back on. Fixes: e01e7eaf37d8 ("iio: light: introduce si1133") Reported-by: sashiko-bot <sashiko-bot@kernel.org> Closes: https://sashiko.dev/#/message/20260428-si1133-checkup-v2-5-70ad14bfefe2%40gmail.com Assisted-by: gemini:gemini-3.1-pro-preview Signed-off-by: Joshua Crofts <joshua.crofts1@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions