Lines Matching refs:fifo
19 static int refill_fifo(struct thread_data *td, struct fifo *fifo, int fd) in refill_fifo() argument
26 if (total > fifo_room(fifo)) in refill_fifo()
27 total = fifo_room(fifo); in refill_fifo()
36 ret = fifo_put(fifo, buf, ret); in refill_fifo()
45 static int trace_fifo_get(struct thread_data *td, struct fifo *fifo, int fd, in trace_fifo_get() argument
48 if (fifo_len(fifo) < len) { in trace_fifo_get()
49 int ret = refill_fifo(td, fifo, fd); in trace_fifo_get()
55 return fifo_get(fifo, buf, len); in trace_fifo_get()
61 static int discard_pdu(struct thread_data *td, struct fifo *fifo, int fd, in discard_pdu() argument
68 return trace_fifo_get(td, fifo, fd, NULL, t->pdu_len); in discard_pdu()
339 struct fifo *fifo; in load_blktrace() local
350 fifo = fifo_alloc(TRACE_FIFO_SIZE); in load_blktrace()
361 int ret = trace_fifo_get(td, fifo, fd, &t, sizeof(t)); in load_blktrace()
385 ret = discard_pdu(td, fifo, fd, &t); in load_blktrace()
415 fifo_free(fifo); in load_blktrace()
468 fifo_free(fifo); in load_blktrace()