kfifo_in_rec

Langue: en

Version: October 2010 (fedora - 01/12/10)

Section: 9 (Appels noyau Linux)

NAME

kfifo_in_rec - puts some record data into the FIFO

SYNOPSIS

__must_check unsigned int kfifo_in_rec(struct kfifo * fifo, void * from, unsigned int n, unsigned int recsize);

ARGUMENTS

fifo

the fifo to be used.

from

the data to be added.

n

the length of the data to be added.

recsize

size of record field

DESCRIPTION

This function copies n bytes from the from into the FIFO 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 buffer.

Note that with only one concurrent reader and one concurrent writer, you don't need extra locking to use these functions.