summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorAbdelnasser Hussein <abdelnasserhussein11@gmail.com>2026-09-23 14:07:45 +0300
committerJonathan Cameron <jonathan.cameron@oss.qualcomm.com>2026-09-28 17:07:37 +0100
commitb96187644664d10b641dddeb7ca2eeef97a77c41 (patch)
treeba0ec1c45f0f6618e954c1795bf7a1237a0208b6 /tools/perf/scripts/python/stackcollapse.py
parent696bd6909e77bd5bdddb6b3c2fcbe6cfd5796f1e (diff)
downloadlinux-next-b96187644664d10b641dddeb7ca2eeef97a77c41.tar.gz
linux-next-b96187644664d10b641dddeb7ca2eeef97a77c41.zip
staging: iio: adc: ad7816: Protect sysfs attributes with mutex
The sysfs store functions modify driver state that is critical during SPI transactions. ad7816_store_mode toggles hardware GPIO pins, while ad7816_store_channel updates the internal software state (chip->channel_id). If these are modified concurrently by userspace while an SPI transfer is in progress, it could corrupt the hardware transaction or cause the driver to communicate with the wrong channel. Add the existing chip->lock guard to these functions to serialize access and prevent these race conditions. Fixes: 7924425db04a ("staging: iio: adc: new driver for AD7816 devices") Suggested-by: Joshua Crofts <joshua.crofts1@gmail.com> Reviewed-by: Joshua Crofts <joshua.crofts1@gmail.com> Signed-off-by: Abdelnasser Hussein <abdelnasserhussein11@gmail.com> Signed-off-by: Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions