Lines Matching refs:fifo
18 static int refill_fifo(struct thread_data *td, struct fifo *fifo, int fd) in refill_fifo() argument
25 if (total > fifo_room(fifo)) in refill_fifo()
26 total = fifo_room(fifo); in refill_fifo()
35 ret = fifo_put(fifo, buf, ret); in refill_fifo()
44 static int trace_fifo_get(struct thread_data *td, struct fifo *fifo, int fd, in trace_fifo_get() argument
47 if (fifo_len(fifo) < len) { in trace_fifo_get()
48 int ret = refill_fifo(td, fifo, fd); in trace_fifo_get()
54 return fifo_get(fifo, buf, len); in trace_fifo_get()
60 static int discard_pdu(struct thread_data *td, struct fifo *fifo, int fd, in discard_pdu() argument
67 return trace_fifo_get(td, fifo, fd, NULL, t->pdu_len); in discard_pdu()
374 struct fifo *fifo; in load_blktrace() local
385 fifo = fifo_alloc(TRACE_FIFO_SIZE); in load_blktrace()
398 int ret = trace_fifo_get(td, fifo, fd, &t, sizeof(t)); in load_blktrace()
422 ret = discard_pdu(td, fifo, fd, &t); in load_blktrace()
471 fifo_free(fifo); in load_blktrace()
523 fifo_free(fifo); in load_blktrace()