summaryrefslogtreecommitdiff
path: root/firmware/acenic/tg1.bin.ihex
diff options
context:
space:
mode:
authorNarcisa Ana Maria Vasile <narcisaanamaria12@gmail.com>2017-04-09 13:40:07 +0300
committerJonathan Cameron <jic23@kernel.org>2017-04-14 15:09:06 +0100
commit984fb2443091d51e196662cdaddfe2823b2778ec (patch)
treea27fa15aa9850a522c2ae8a0272110ae74cca13f /firmware/acenic/tg1.bin.ihex
parenta9e9c7153e96ee7f2777b3d5d99a23bf74dcaa21 (diff)
staging: iio: ad5933: Protect DIRECT mode using claim/release helpers
This device operates in DIRECT_MODE and BUFFER_HARDWARE mode. Replace usages of iio_dev->mlock with iio_device_{claim|release}_direct_mode() helper functions to guarantee DIRECT mode and consequently protect BUFFER mode too. Add and use a device private lock to protect against conflicting access of the state data. This helps with IIO subsystem redefining iio_dev->mlock to be used by the IIO core only for protecting device operating mode changes. ie. Changes between INDIO_DIRECT_MODE, INDIO_BUFFER_* modes. Protect changing of attributes inside ad5933_store(). Attributes can no longer be changed while in buffered mode. Remove lock from ad5933_work() because buffer mode should be enabled when we reach this, and claiming DIRECT mode in all the other places should protect it. Signed-off-by: Narcisa Ana Maria Vasile <narcisaanamaria12@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'firmware/acenic/tg1.bin.ihex')
0 files changed, 0 insertions, 0 deletions