Lines Matching refs:length
470 return sprintf(buf, "%d\n", buffer->length); in iio_buffer_read_length()
486 if (val == buffer->length) in iio_buffer_write_length()
498 if (buffer->length && buffer->length < buffer->watermark) in iio_buffer_write_length()
499 buffer->watermark = buffer->length; in iio_buffer_write_length()
519 int length, i; in iio_compute_scan_bytes() local
526 length = ch->scan_type.storagebits / 8 * in iio_compute_scan_bytes()
529 length = ch->scan_type.storagebits / 8; in iio_compute_scan_bytes()
530 bytes = ALIGN(bytes, length); in iio_compute_scan_bytes()
531 bytes += length; in iio_compute_scan_bytes()
537 length = ch->scan_type.storagebits / 8 * in iio_compute_scan_bytes()
540 length = ch->scan_type.storagebits / 8; in iio_compute_scan_bytes()
541 bytes = ALIGN(bytes, length); in iio_compute_scan_bytes()
542 bytes += length; in iio_compute_scan_bytes()
966 if (val > buffer->length) { in iio_buffer_store_watermark()
986 static DEVICE_ATTR(length, S_IRUGO | S_IWUSR, iio_buffer_read_length,
988 static struct device_attribute dev_attr_length_ro = __ATTR(length,
1161 unsigned length; member
1174 datain + t->from, t->length); in iio_demux()
1223 unsigned int length) in iio_buffer_add_demux() argument
1226 if (*p && (*p)->from + (*p)->length == in_loc && in iio_buffer_add_demux()
1227 (*p)->to + (*p)->length == out_loc) { in iio_buffer_add_demux()
1228 (*p)->length += length; in iio_buffer_add_demux()
1235 (*p)->length = length; in iio_buffer_add_demux()
1246 int ret, in_ind = -1, out_ind, length; in iio_buffer_update_demux() local
1274 length = ch->scan_type.storagebits / 8 * in iio_buffer_update_demux()
1277 length = ch->scan_type.storagebits / 8; in iio_buffer_update_demux()
1279 in_loc = roundup(in_loc, length) + length; in iio_buffer_update_demux()
1283 length = ch->scan_type.storagebits / 8 * in iio_buffer_update_demux()
1286 length = ch->scan_type.storagebits / 8; in iio_buffer_update_demux()
1287 out_loc = roundup(out_loc, length); in iio_buffer_update_demux()
1288 in_loc = roundup(in_loc, length); in iio_buffer_update_demux()
1289 ret = iio_buffer_add_demux(buffer, &p, in_loc, out_loc, length); in iio_buffer_update_demux()
1292 out_loc += length; in iio_buffer_update_demux()
1293 in_loc += length; in iio_buffer_update_demux()
1300 length = ch->scan_type.storagebits / 8 * in iio_buffer_update_demux()
1303 length = ch->scan_type.storagebits / 8; in iio_buffer_update_demux()
1304 out_loc = roundup(out_loc, length); in iio_buffer_update_demux()
1305 in_loc = roundup(in_loc, length); in iio_buffer_update_demux()
1306 ret = iio_buffer_add_demux(buffer, &p, in_loc, out_loc, length); in iio_buffer_update_demux()
1309 out_loc += length; in iio_buffer_update_demux()
1310 in_loc += length; in iio_buffer_update_demux()