aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/osmo_io_uring.c
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2024-02-09 12:38:17 +0100
committerAndreas Eversberg <jolly@eversberg.eu>2024-02-28 16:42:53 +0100
commit848faf9256b4b2f147b6c112a0a5c6d85b22551c (patch)
tree9803dabc8e6bcc4bfe4fceb20ca2c324cf1737e1 /src/core/osmo_io_uring.c
parent3938dfba5cc9ec23c0b4046be48dad260c29199f (diff)
osmo_io: Move notify_connected function to backend
This relocation is necessary as the backend (osmo_io_fd or osmo_io_uring) requires a different approach in handling connect notifications. As a result, a function call has been introduced to struct iofd_backend_ops. In a subsequent patch, the process for the osmo_io_uring backend will be modified to handle SCTP connect notifications using poll/select. If connect notification is requested using poll/select, the file descriptior must be registered to osmo_fd, using osmo_fd_register. If read / write notification is requested by application, the file descriptior must be registered also. A flag is used prevent calling osmo_fd_register / osmo_fd_unregister multiple times, which would cause a crash. Change-Id: I905ec85210570aff8addadfc9603335d04eb057a Related: OS#5751
Diffstat (limited to 'src/core/osmo_io_uring.c')
-rw-r--r--src/core/osmo_io_uring.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/core/osmo_io_uring.c b/src/core/osmo_io_uring.c
index 1aa17d4f..24d1e085 100644
--- a/src/core/osmo_io_uring.c
+++ b/src/core/osmo_io_uring.c
@@ -402,6 +402,7 @@ const struct iofd_backend_ops iofd_uring_ops = {
.write_disable = iofd_uring_write_disable,
.read_enable = iofd_uring_read_enable,
.read_disable = iofd_uring_read_disable,
+ .notify_connected = iofd_uring_write_enable,
};
#endif /* defined(__linux__) */