IIO: consumer: allow to set buffer sizes
Add iio consumer API to set buffer size and watermark according to sysfs API. Signed-off-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:

committed by
Mark Brown

parent
eca949800d
commit
16cbca06fa
@@ -133,6 +133,17 @@ struct iio_cb_buffer *iio_channel_get_all_cb(struct device *dev,
|
||||
int (*cb)(const void *data,
|
||||
void *private),
|
||||
void *private);
|
||||
/**
|
||||
* iio_channel_cb_set_buffer_watermark() - set the buffer watermark.
|
||||
* @cb_buffer: The callback buffer from whom we want the channel
|
||||
* information.
|
||||
* @watermark: buffer watermark in bytes.
|
||||
*
|
||||
* This function allows to configure the buffer watermark.
|
||||
*/
|
||||
int iio_channel_cb_set_buffer_watermark(struct iio_cb_buffer *cb_buffer,
|
||||
size_t watermark);
|
||||
|
||||
/**
|
||||
* iio_channel_release_all_cb() - release and unregister the callback.
|
||||
* @cb_buffer: The callback buffer that was allocated.
|
||||
|
Reference in New Issue
Block a user