Lines Matching refs:do_count
1193 ssize_t i, do_count, blks, transfer; in st_write() local
1385 do_count = count; in st_write()
1387 do_count = (STp->buffer)->buffer_blocks * STp->block_size - in st_write()
1389 if (do_count > count) in st_write()
1390 do_count = count; in st_write()
1393 i = append_to_buffer(b_point, STp->buffer, do_count); in st_write()
1401 blks = transfer = do_count; in st_write()
1430 residual = do_count; in st_write()
1435 if (residual <= do_count) { in st_write()
1437 pos += do_count - residual; in st_write()
1438 count -= do_count - residual; in st_write()
1441 residual < do_count) in st_write()
1466 dev, do_count)); in st_write()
1493 pos += do_count; in st_write()
1494 b_point += do_count; in st_write()
1495 count -= do_count; in st_write()
3591 static int append_to_buffer(const char *ubp, ST_buffer * st_bp, int do_count) in append_to_buffer() argument
3602 for (; i < st_bp->sg_segs && do_count > 0; i++) { in append_to_buffer()
3603 cnt = st_bp->sg_lengths[i] - offset < do_count ? in append_to_buffer()
3604 st_bp->sg_lengths[i] - offset : do_count; in append_to_buffer()
3608 do_count -= cnt; in append_to_buffer()
3613 if (do_count) { /* Should never happen */ in append_to_buffer()
3615 do_count); in append_to_buffer()
3624 static int from_buffer(ST_buffer * st_bp, char *ubp, int do_count) in from_buffer() argument
3635 for (; i < st_bp->sg_segs && do_count > 0; i++) { in from_buffer()
3636 cnt = st_bp->sg_lengths[i] - offset < do_count ? in from_buffer()
3637 st_bp->sg_lengths[i] - offset : do_count; in from_buffer()
3641 do_count -= cnt; in from_buffer()
3647 if (do_count) { /* Should never happen */ in from_buffer()
3649 do_count); in from_buffer()