Source Code Guide: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
Line 3: | Line 3: | ||
== Directory structure == | == Directory structure == | ||
* cmake: This directory contains some CMake additions for building O7s. | *cmake: This directory contains some CMake additions for building O7s. | ||
* doc: This directory holds some documentation, most notably the man pages. | *doc: This directory holds some documentation, most notably the man pages. | ||
* include: Includes public O7s headers for implementing Ouroboros programs and management tools, and some internal headers that expose functions of the library needed by other O7s components. | *include: Includes public O7s headers for implementing Ouroboros programs and management tools, and some internal headers that expose functions of the library needed by other O7s components. | ||
* src: The main implementation, which holds | *src: The main implementation, which holds | ||
** ipcpd: Reference implementation of the different [[IPCP]]s. | **ipcpd: Reference implementation of the different [[IPCP]]s. | ||
** irmd: Reference implementation of a basic IRMd. | **irmd: Reference implementation of a basic IRMd. | ||
** lib: Implementation of various library functions. | **lib: Implementation of various library functions. | ||
** tools: Some tools, such as small test programs and the ''IPC Resource Management'' CLI for managing O7s. | **tools: Some tools, such as small test programs and the ''IPC Resource Management'' CLI for managing O7s. | ||
== Variable guide == | == Variable guide == |
Revision as of 08:33, 18 June 2022
This page is under construction
Directory structure
- cmake: This directory contains some CMake additions for building O7s.
- doc: This directory holds some documentation, most notably the man pages.
- include: Includes public O7s headers for implementing Ouroboros programs and management tools, and some internal headers that expose functions of the library needed by other O7s components.
- src: The main implementation, which holds
- ipcpd: Reference implementation of the different IPCPs.
- irmd: Reference implementation of a basic IRMd.
- lib: Implementation of various library functions.
- tools: Some tools, such as small test programs and the IPC Resource Management CLI for managing O7s.
Variable guide
type | name | Description |
---|---|---|
int | fd | flow descriptor. It's the flow analogue to a file descriptor. |
struct fcrti * | frcti | An instance of the flow and retransmission control task, the logic that implements the FRCP protocol. |
size_t | idx | This idx is an index in the packet buffer (rdrbuff) and used to calculate the location of the packet in reference the base pointer at which the rdrbuff is mapped into each process' memory space. |
struct shm_du_buff * | sdb | shared memory (shm) data unit (du) buffer. The ouroboros 'flavored' skb. An sdb is a (fixed size) buffer that contains the actual packet data and room for packet headers (and packet tails such as CRC), in addition to some metadata for managing the buffer (head and tail offset to the start of the packet, total size of the buffer, ...). The term 'data unit' stems from the OSI SDU (service data unit) and PDU (protocol data unit), which were adopted by RINA. |
struct shm_rbuff * | tx_rb, rx_rb, rb | ring buffer. These (small) ring buffers are shared between 2 processes, used to efficiently move packets through the local pipeline. They pass an index that points to an sdb in the rdrbuff, and are the entry and exit structures with which the application (either a user application or an IPCP) interacts with the end-to-end flow. Writing happens to the transmit ring buffer tx_rb, reading from the receive ring buffer rx_rb. |
struct shm_rdrbuff * | rdrb | random deletion ring buffer, This is the block of memory in which Ouroboros stores actual packet data (and metadata) in a (ring buffer) of sdbs. Packets are allocated at the head of the ringbuffer and removed from the tail. Packets are marked on deletion, and deleting the tail causes a cleanup operation of all marked packets. Basically a quick-and-dirty memory allocator that needs to be replaced with something more efficient. |