rtf_create -- create a realtime fifo


       #include <rtl_fifo.h>

       int rtf_create(unsigned int fifo, int size);


rtf_create creates a realtime fifo (RT-FIFO) of size size and assigns it the identifier fifo. fifo is a value unique within the system, and must be less than RTF_NO.

The RT-FIFO is a mechanism, implemented as a character device, to communicate between realtime tasks and ordinary Linux processes. The rtf_* functions are used by the realtime tasks; Linux processes use standard character device access functions such as read(3), write(3), and select(3).


On success, 0 is returned. On failure, a negative value is returned as described below.



fifo is greater than or equal to RTF_NO.


fifo is already in use. Choose a different ID.


size bytes could not be allocated for the RT-FIFO.


This function should only be used in the Linux init_module() context or in user space via PSC library (please see below). RT-FIFOs created in init_module() should be destroyed with rtf_destroy() in cleanup_module.

rtf_create is a system call made available by PSC, the user-level real-time signal library. It can be called from user space, but not from PSC handlers.


rtf_create_handler(3), rtf_destroy(3), rtf_get(3), rtf_put(3)

1997 Jerry Epplin.

Modifications for RTLinux 2.x and 3.x by Michael Barabanov. 2001 FSMLabs Inc.

All rights reserved.