aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-sqlite.py
diff options
context:
space:
mode:
authorLars-Peter Clausen <[email protected]>2021-10-24 11:26:59 +0200
committerJonathan Cameron <[email protected]>2021-11-17 17:52:34 +0000
commitcd0082235783f814241a1c9483fb89e405f4f892 (patch)
treea69da39c93b6cc42aea2ed27873ce17186cbce82 /tools/perf/scripts/python/export-to-sqlite.py
parent8e1eeca5afa7ba84d885987165dbdc5decf15413 (diff)
iio: mma8452: Fix trigger reference couting
The mma8452 driver directly assigns a trigger to the struct iio_dev. The IIO core when done using this trigger will call `iio_trigger_put()` to drop the reference count by 1. Without the matching `iio_trigger_get()` in the driver the reference count can reach 0 too early, the trigger gets freed while still in use and a use-after-free occurs. Fix this by getting a reference to the trigger before assigning it to the IIO device. Fixes: ae6d9ce05691 ("iio: mma8452: Add support for interrupt driven triggers.") Signed-off-by: Lars-Peter Clausen <[email protected]> Link: https://lore.kernel.org/r/[email protected] Cc: <[email protected]> Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions