diff options
author | Cosmin Tanislav <demonsingur@gmail.com> | 2022-05-14 21:20:10 +0300 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2022-06-11 16:35:27 +0300 |
commit | 0bd0bb1fc1e4430dff6856b59ddd63c72780d9be (patch) | |
tree | 2ba4c300d2f462535f2a6aea251a830dd0a19dee /include/sound/emux_legacy.h | |
parent | d04d46dd82ad10bdc3c9ce6a513e1fa1336719c4 (diff) | |
download | linux-0bd0bb1fc1e4430dff6856b59ddd63c72780d9be.tar.xz |
iio: accel: adxl367: do not update FIFO watermark on scan mode update
Currently, the driver updates the FIFO watermark inside both
update_scan_mode() and hwfifo_set_watermark(). Inside the IIO core,
hwfifo_set_watermark() is called immediately after update_scan_mode(),
making the first call to set_fifo_samples() redundant.
Remove the first call to set_fifo_samples(), and merge the
set_fifo_samples() function into the set_fifo_watermark()
function. Also, since fifo_set_size is always set inside of
update_scan_mode(), and it cannot be set to 0, remove the
zero check from set_fifo_samples().
Signed-off-by: Cosmin Tanislav <cosmin.tanislav@analog.com>
Link: https://lore.kernel.org/r/20220514182010.152784-1-cosmin.tanislav@analog.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'include/sound/emux_legacy.h')
0 files changed, 0 insertions, 0 deletions