KFIFO_OUT_REC(9) FIFO Buffer KFIFO_OUT_REC(9)
NAME
kfifo_out_rec - gets some record data from the FIFO
SYNOPSIS
__must_check unsigned int kfifo_out_rec(struct kfifo * fifo, void * to, unsigned int n, unsigned int recsize, unsigned int * total);
ARGUMENTS
fifo
the fifo to be used.
to
where the data must be copied.
n
the size of the destination buffer.
recsize
size of record field
total
pointer where the total number of to copied bytes should stored
DESCRIPTION
This function copies at most n bytes from the FIFO to to and returns the number of bytes which cannot be copied. A returned value greater
than the n value means that the record doesn't fit into the to buffer.
Note that with only one concurrent reader and one concurrent writer, you don't need extra locking to use these functions.
COPYRIGHT
Kernel Hackers Manual 2.6. July 2010 KFIFO_OUT_REC(9)