#include <unistd.h>
#include <stdbool.h>
#include <netinet/sctp.h>
#include <osmocom/core/osmo_io.h>
#include <osmocom/core/linuxlist.h>
#include <osmocom/core/msgb.h>
#include <osmocom/core/select.h>
#include <osmocom/core/socket.h>
#include "../config.h"
Go to the source code of this file.
|
| struct iofd_msghdr * | iofd_msghdr_alloc (struct osmo_io_fd *iofd, enum iofd_msg_action action, struct msgb *msg, size_t cmsg_size) |
| | Allocate the msghdr. More...
|
| |
| void | iofd_msghdr_free (struct iofd_msghdr *msghdr) |
| | Free the msghdr. More...
|
| |
| struct msgb * | iofd_msgb_alloc2 (struct osmo_io_fd *iofd, size_t size) |
| | convenience wrapper to call msgb_alloc with parameters from osmo_io_fd (of given size) More...
|
| |
| struct msgb * | iofd_msgb_alloc (struct osmo_io_fd *iofd) |
| | convenience wrapper to call msgb_alloc with parameters from osmo_io_fd More...
|
| |
| void | iofd_handle_recv (struct osmo_io_fd *iofd, struct msgb *msg, int rc, struct iofd_msghdr *msghdr) |
| | completion handler: Internal function called by osmo_io_backend after a given I/O operation has completed More...
|
| |
| void | iofd_handle_send_completion (struct osmo_io_fd *iofd, int rc, struct iofd_msghdr *msghdr) |
| | completion handler: Internal function called by osmo_io_backend after a given I/O operation has completed More...
|
| |
| void | iofd_handle_segmented_read (struct osmo_io_fd *iofd, struct msgb *msg, int rc) |
| | Restore message boundaries on read() and pass individual messages to the read callback. More...
|
| |
| int | iofd_txqueue_enqueue (struct osmo_io_fd *iofd, struct iofd_msghdr *msghdr) |
| | Enqueue a message to be sent. More...
|
| |
| void | iofd_txqueue_enqueue_front (struct osmo_io_fd *iofd, struct iofd_msghdr *msghdr) |
| | Enqueue a message at the front. More...
|
| |
| struct iofd_msghdr * | iofd_txqueue_dequeue (struct osmo_io_fd *iofd) |
| | Dequeue a message from the front. More...
|
| |
◆ IOFD_FLAG_CLOSED
| #define IOFD_FLAG_CLOSED (1<<0) |
◆ IOFD_FLAG_FD_REGISTERED
| #define IOFD_FLAG_FD_REGISTERED (1<<4) |
◆ IOFD_FLAG_IN_CALLBACK
| #define IOFD_FLAG_IN_CALLBACK (1<<1) |
◆ IOFD_FLAG_ISSET
| #define IOFD_FLAG_ISSET |
( |
|
iofd, |
|
|
|
flag |
|
) |
| ((iofd)->flags & (flag)) |
◆ IOFD_FLAG_NOTIFY_CONNECTED
| #define IOFD_FLAG_NOTIFY_CONNECTED (1<<3) |
◆ IOFD_FLAG_SET
| #define IOFD_FLAG_SET |
( |
|
iofd, |
|
|
|
flag |
|
) |
| (iofd)->flags |= (flag) |
◆ IOFD_FLAG_TO_FREE
| #define IOFD_FLAG_TO_FREE (1<<2) |
◆ IOFD_FLAG_UNSET
| #define IOFD_FLAG_UNSET |
( |
|
iofd, |
|
|
|
flag |
|
) |
| (iofd)->flags &= ~(flag) |
◆ IOFD_MSGHDR_IO_BUFFERS
| #define IOFD_MSGHDR_IO_BUFFERS 8 |
◆ IOFD_MSGHDR_MAX_READ_SQES
| #define IOFD_MSGHDR_MAX_READ_SQES 32 |
◆ OSMO_IO_BACKEND_DEFAULT
| #define OSMO_IO_BACKEND_DEFAULT "POLL" |
◆ OSMO_IO_DEFAULT_MSGB_HEADROOM
| #define OSMO_IO_DEFAULT_MSGB_HEADROOM 128 |
◆ OSMO_IO_DEFAULT_MSGB_SIZE
| #define OSMO_IO_DEFAULT_MSGB_SIZE 1024 |
◆ iofd_msg_action
| Enumerator |
|---|
| IOFD_ACT_READ | |
| IOFD_ACT_WRITE | |
| IOFD_ACT_RECVFROM | |
| IOFD_ACT_SENDTO | |
| IOFD_ACT_RECVMSG | |
| IOFD_ACT_SENDMSG | |
◆ iofd_seg_act
| Enumerator |
|---|
| IOFD_SEG_ACT_HANDLE_ONE | |
| IOFD_SEG_ACT_HANDLE_MORE | |
| IOFD_SEG_ACT_DEFER | |
◆ iofd_poll_ops