Zephyr Project Requirements
Pipes

Pipes

STATEMENT:

SPDX-License-Identifier: Apache-2.0

ZEP-SRS-32-1
1. Pipe definition at compile time
UID: ZEP-SRS-32-1
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

The Zephyr RTOS shall provide a mechanism to define and initialize a pipe at compile time.

ZEP-SRS-32-2
2. Pipe initialization at run time
UID: ZEP-SRS-32-2
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

The Zephyr RTOS shall provide a mechanism to initialize a pipe at run time using a caller-provided buffer.

ZEP-SRS-32-3
3. Writing data to a pipe
UID: ZEP-SRS-32-3
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

The Zephyr RTOS shall provide a mechanism for a thread to write up to a requested number of bytes into a pipe.

ZEP-SRS-32-4
4. Reading data from a pipe
UID: ZEP-SRS-32-4
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

The Zephyr RTOS shall provide a mechanism for a thread to read up to a requested number of bytes from a pipe.

ZEP-SRS-32-5
5. Pipe write timeout
UID: ZEP-SRS-32-5
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

When writing to a pipe, the Zephyr RTOS shall accept a timeout that specifies the maximum time to wait for space to become available.

ZEP-SRS-32-11
6. Pipe write timeout expiry
UID: ZEP-SRS-32-11
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

When writing to a pipe, if no data can be written within the specified maximum time, the Zephyr RTOS shall return an error indicating that no data was written.

ZEP-SRS-32-6
7. Pipe read timeout
UID: ZEP-SRS-32-6
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

When reading from a pipe, the Zephyr RTOS shall accept a timeout that specifies the maximum time to wait for data to become available.

ZEP-SRS-32-12
8. Pipe read timeout expiry
UID: ZEP-SRS-32-12
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

When reading from a pipe, if no data becomes available within the specified maximum time, the Zephyr RTOS shall return an error indicating that no data was read.

ZEP-SRS-32-7
9. Resetting a pipe
UID: ZEP-SRS-32-7
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

The Zephyr RTOS shall provide a mechanism to reset a pipe, discarding any unread data and unblocking threads waiting on the pipe.

ZEP-SRS-32-8
10. Closing a pipe
UID: ZEP-SRS-32-8
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

The Zephyr RTOS shall provide a mechanism to close a pipe, unblocking threads waiting on the pipe.

ZEP-SRS-32-9
11. Operations on a closed pipe
UID: ZEP-SRS-32-9
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

When a read or write operation is attempted on a closed pipe, the Zephyr RTOS shall return an error indicating that the pipe is closed.

ZEP-SRS-32-10
12. Operations interrupted by a reset
UID: ZEP-SRS-32-10
STATUS: Draft
TYPE: Functional
COMPONENT: Pipes
RELATIONS (Parent):
STATEMENT:

When a read or write operation is interrupted by a pipe reset, the Zephyr RTOS shall return an error indicating that the operation was cancelled.