---
name: "rtf_ipc_create"
section: "2"
platform: "linux"
package: "rtlinux"
version: "2.0rel-1"
release: "Debian 2.2 (Potato)"
platforms: ["linux"]
url: "https://new.carta.tech/rtf_ipc_create"
---

# rtf\_ipc\_create(2)

create a real-time fifo

## NAME

rtf\_ipc\_create - create a real-time fifo

## SYNOPSIS

```
#define MODULE
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/version.h>
#include <linux/errno.h>
#include <linux/rtf.h>
#include rt_ipc.h
```

**int rtf\_ipc\_create(unsigned int** *fifo***, int** *size***, int** *rtl\_to\_linux***);**

## DESCRIPTION

**rtf\_ipc\_create** creates a real-time 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 IPC\_RTF\_NO. If  *rtl\_to\_linux* is 1, the fifo is used for transferring data from RT-Linux tasks to a Linux process.  If *rtl\_to\_linux* is 0, the fifo is used for transferring data from a Linux process to one or more RT-Linux tasks.

The rt\_ipc RT-FIFO is a mechanism, implemented as a character device, to communicate between real-time tasks and ordinary Linux processes.  It is based on the Real-Time Linux RT-FIFO mechanism.  The rtf\_\* functions are used by the real-time tasks; Linux processes use standard character device access functions such as **[read(2)](/read/2.md)**, **[write(2)](/write/2.md)**, and **[select(2)](/select/2.md)**.

## RETURN VALUE

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

## ERRORS

- **-ENODEV**

  *fifo* is not less than IPC\_RTF\_NO and RTF\_NO.

- **-EBUSY**

  *fifo* is already in use.  Choose a different ID.

- **-ENOMEM**

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

## AUTHOR

Jerry Epplin \<JerryEpplin@worldnet.att.net\>

## SEE ALSO

[**rtf\_ipc\_destroy**(2)](/rtf_ipc_destroy/2.md), [**rtf\_receive**(2)](/rtf_receive/2.md), [**rtf\_send**(2)](/rtf_send/2.md)
