diff options
| author | Guangshuo Li <liguangshuo@mail.sdu.edu.cn> | 2026-10-31 21:05:38 +0800 |
|---|---|---|
| committer | Jonathan Cameron <jonathan.cameron@oss.qualcomm.com> | 2026-11-02 00:40:39 +0000 |
| commit | fd7334314f63a3a2a4927f209b2ca0e33d111840 (patch) | |
| tree | 8385b67a17ed1c7a9f05c932d32e0bbebc23ecc6 /kernel/debug/debug_core.h | |
| parent | 25d15b4192b9ae45be61670b5424721f5a0e0cf2 (diff) | |
iio: accel: kxsd9: Fix potential use-after-free on removal
Unregistering an IIO device with an active triggered buffer detaches its
poll function. Freeing the poll function first can therefore make
iio_device_unregister() access freed memory.
Unregister the device before cleaning up the triggered buffer.
This issue was found by our static analysis tool under development.
Fixes: 0427a106a98a ("iio: accel: kxsd9: Add triggered buffer handling")
Signed-off-by: Guangshuo Li <liguangshuo@mail.sdu.edu.cn>
Reviewed-by: Joshua Crofts <crofts@kernel.org>
Cc: stable@vger.kernel.org
Signed-off-by: Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>
Diffstat (limited to 'kernel/debug/debug_core.h')
0 files changed, 0 insertions, 0 deletions
