Lines Matching refs:cur
83 * @cur: Current IO bunch being collected
93 struct io_bunch *cur;
253 struct io_bunch *cur = malloc(sizeof(*cur));
255 memset(cur, 0, sizeof(*cur));
257 cur->hdr.npkts = 0;
258 cur->hdr.time_stamp = stream->start_time = start_time;
260 stream->cur = cur;
272 struct io_bunch *cur = stream->cur;
279 assert(cur != NULL);
280 assert(cur->hdr.npkts < BT_MAX_PKTS);
283 cur->pkts[cur->hdr.npkts++] = iop; // Struct copy
573 struct io_bunch_hdr *hdrp = &stream->cur->hdr;
599 struct io_pkt *p = stream->cur->pkts;
600 size_t npkts = stream->cur->hdr.npkts;
626 struct io_bunch *cur = stream->cur;
628 if (cur) {
629 if (cur->hdr.npkts) {
630 assert(cur->hdr.npkts <= BT_MAX_PKTS);
635 stream->pkts += cur->hdr.npkts;
637 free(cur);
648 if (stream->cur->hdr.npkts >= max_pkts_per_bunch)
665 if (stream->cur == NULL)
699 stream->cur = NULL;