[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-29 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

 (

4 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted 
one.
 )Change subject: osmo_io: Move notify_connected function to backend
..

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
---
M src/core/osmo_io.c
M src/core/osmo_io_internal.h
M src/core/osmo_io_poll.c
M src/core/osmo_io_uring.c
4 files changed, 54 insertions(+), 2 deletions(-)

Approvals:
  laforge: Looks good to me, but someone else must approve
  pespin: Looks good to me, approved
  Jenkins Builder: Verified




diff --git a/src/core/osmo_io.c b/src/core/osmo_io.c
index 9de9e2e..71249cf 100644
--- a/src/core/osmo_io.c
+++ b/src/core/osmo_io.c
@@ -781,7 +781,8 @@
 void osmo_iofd_notify_connected(struct osmo_io_fd *iofd)
 {
OSMO_ASSERT(iofd->mode == OSMO_IO_FD_MODE_READ_WRITE);
-   osmo_iofd_ops.write_enable(iofd);
+   OSMO_ASSERT(osmo_iofd_ops.notify_connected);
+   osmo_iofd_ops.notify_connected(iofd);
 }


diff --git a/src/core/osmo_io_internal.h b/src/core/osmo_io_internal.h
index e8f4ea2..9c86e05 100644
--- a/src/core/osmo_io_internal.h
+++ b/src/core/osmo_io_internal.h
@@ -31,12 +31,14 @@
void (*write_disable)(struct osmo_io_fd *iofd);
void (*read_enable)(struct osmo_io_fd *iofd);
void (*read_disable)(struct osmo_io_fd *iofd);
+   void (*notify_connected)(struct osmo_io_fd *iofd);
 };

 #define IOFD_FLAG_CLOSED (1<<0)
 #define IOFD_FLAG_IN_CALLBACK (1<<1)
 #define IOFD_FLAG_TO_FREE (1<<2)
 #define IOFD_FLAG_NOTIFY_CONNECTED (1<<3)
+#define IOFD_FLAG_FD_REGISTERED (1<<4)

 #define IOFD_FLAG_SET(iofd, flag) \
(iofd)->flags |= (flag)
diff --git a/src/core/osmo_io_poll.c b/src/core/osmo_io_poll.c
index d7f80c0..8398a30 100644
--- a/src/core/osmo_io_poll.c
+++ b/src/core/osmo_io_poll.c
@@ -119,20 +119,32 @@
 int iofd_poll_register(struct osmo_io_fd *iofd)
 {
struct osmo_fd *ofd = &iofd->u.poll.ofd;
+   int rc;
+
+   if (IOFD_FLAG_ISSET(iofd, IOFD_FLAG_FD_REGISTERED))
+   return 0;
osmo_fd_setup(ofd, iofd->fd, 0, &iofd_poll_ofd_cb_dispatch, iofd, 0);
-   return osmo_fd_register(ofd);
+   rc = osmo_fd_register(ofd);
+   if (!rc)
+   IOFD_FLAG_SET(iofd, IOFD_FLAG_FD_REGISTERED);
+   return rc;
 }

 int iofd_poll_unregister(struct osmo_io_fd *iofd)
 {
struct osmo_fd *ofd = &iofd->u.poll.ofd;
+
+   if (!IOFD_FLAG_ISSET(iofd, IOFD_FLAG_FD_REGISTERED))
+   return 0;
osmo_fd_unregister(ofd);
+   IOFD_FLAG_UNSET(iofd, IOFD_FLAG_FD_REGISTERED);

return 0;
 }

 int iofd_poll_close(struct osmo_io_fd *iofd)
 {
+   iofd_poll_unregister(iofd);
osmo_fd_close(&iofd->u.poll.ofd);

return 0;
@@ -158,6 +170,16 @@
osmo_fd_write_disable(&iofd->u.poll.ofd);
 }

+void iofd_poll_notify_connected(struct osmo_io_fd *iofd)
+{
+   int rc;
+
+   rc = iofd_poll_register(iofd);
+   if (rc < 0)
+   return;
+   osmo_fd_write_enable(&iofd->u.poll.ofd);
+}
+
 const struct iofd_backend_ops iofd_poll_ops = {
.register_fd = iofd_poll_register,
.unregister_fd = iofd_poll_unregister,
@@ -166,6 +188,7 @@
.write_disable = iofd_poll_write_disable,
.read_enable = iofd_poll_read_enable,
.read_disable = iofd_poll_read_disable,
+   .notify_connected = iofd_poll_notify_connected,
 };

 #endif /* defined(__linux__) */
diff --git a/src/core/osmo_io_uring.c b/src/core/osmo_io_uring.c
index 1aa17d4..24d1e08 100644
--- a/src/core/osmo_io_uring.c
+++ b/src/core/osmo_io_uring.c
@@ -402,6 +402,7 @@
.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__) */

--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
G

[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-29 Thread jolly
Attention is currently required from: daniel, laforge.

Hello Jenkins Builder, daniel, laforge, pespin,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email

to look at the new patch set (#6).

The following approvals got outdated and were removed:
Verified+1 by Jenkins Builder

The change is no longer submittable: Verified is unsatisfied now.


Change subject: osmo_io: Move notify_connected function to backend
..

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
---
M src/core/osmo_io.c
M src/core/osmo_io_internal.h
M src/core/osmo_io_poll.c
M src/core/osmo_io_uring.c
4 files changed, 54 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/09/35909/6
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 6
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: laforge 
Gerrit-Attention: daniel 
Gerrit-MessageType: newpatchset


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-28 Thread jolly
Attention is currently required from: daniel, laforge.

jolly has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 5:

(1 comment)

File src/core/osmo_io_poll.c:

https://gerrit.osmocom.org/c/libosmocore/+/35909/comment/214f5e38_39197e3a
PS4, Line 116:  if (IOFD_FLAG_ISSET(iofd, IOFD_FLAG_FD_REGISTERED))
> is this something we silently want to accept? or something which should be 
> debugged and hence at lea […]
If the user enables notification when the socket is connects 
(osmo_iofd_notify_connected) and also wants to register the file descriptor 
(osmo_iofd_register) at the same time, this function is called twice.

The user does not need to wait until the socket is connected before calling 
osmo_iofd_register() this way.

This means that no error should be logged here.



--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 5
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: laforge 
Gerrit-Attention: daniel 
Gerrit-Comment-Date: Wed, 28 Feb 2024 15:45:49 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin 
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-23 Thread laforge
Attention is currently required from: daniel, jolly.

laforge has uploaded a new patch set (#5) to the change originally created by 
jolly. ( https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

The following approvals got outdated and were removed:
Verified+1 by Jenkins Builder

The change is no longer submittable: Verified is unsatisfied now.


Change subject: osmo_io: Move notify_connected function to backend
..

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
---
M src/core/osmo_io.c
M src/core/osmo_io_internal.h
M src/core/osmo_io_poll.c
M src/core/osmo_io_uring.c
4 files changed, 54 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/09/35909/5
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 5
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: daniel 
Gerrit-MessageType: newpatchset


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-23 Thread pespin
Attention is currently required from: daniel, jolly.

pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 4: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 4
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: daniel 
Gerrit-Comment-Date: Fri, 23 Feb 2024 13:29:30 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-23 Thread pespin
Attention is currently required from: daniel, jolly.

pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 4: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 4
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: daniel 
Gerrit-Comment-Date: Fri, 23 Feb 2024 13:22:42 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-22 Thread laforge
Attention is currently required from: daniel, jolly.

laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 4: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 4
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: daniel 
Gerrit-Comment-Date: Thu, 22 Feb 2024 21:23:41 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-22 Thread pespin
Attention is currently required from: daniel, jolly, laforge.

pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 4:

(1 comment)

File src/core/osmo_io_poll.c:

https://gerrit.osmocom.org/c/libosmocore/+/35909/comment/458b4ada_7d5b8d39
PS4, Line 116:  if (IOFD_FLAG_ISSET(iofd, IOFD_FLAG_FD_REGISTERED))
is this something we silently want to accept? or something which should be 
debugged and hence at least logged through ERROR?



--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 4
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: laforge 
Gerrit-Attention: daniel 
Gerrit-Comment-Date: Thu, 22 Feb 2024 15:36:59 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-22 Thread jolly
Attention is currently required from: daniel, laforge, pespin.

jolly has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 4:

(1 comment)

Commit Message:

https://gerrit.osmocom.org/c/libosmocore/+/35909/comment/a9f90d52_4271a40e
PS3, Line 17: file descriptior
> I would always use 'iofd' when talking about an iofd, as otherwise it's 
> getting confusing as 'file d […]
But the "integer value" is what I mean. I rephrased it and hope is is clear now.



--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 4
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: laforge 
Gerrit-Attention: pespin 
Gerrit-Attention: daniel 
Gerrit-Comment-Date: Thu, 22 Feb 2024 15:03:44 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge 
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-22 Thread jolly
Attention is currently required from: daniel, jolly, laforge, pespin.

Hello Jenkins Builder, daniel, laforge, pespin,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email

to look at the new patch set (#4).

The following approvals got outdated and were removed:
Code-Review+1 by daniel, Code-Review+1 by laforge


Change subject: osmo_io: Move notify_connected function to backend
..

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
---
M src/core/osmo_io.c
M src/core/osmo_io_internal.h
M src/core/osmo_io_poll.c
M src/core/osmo_io_uring.c
4 files changed, 54 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/09/35909/4
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 4
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: laforge 
Gerrit-Attention: pespin 
Gerrit-Attention: daniel 
Gerrit-MessageType: newpatchset


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-22 Thread daniel
Attention is currently required from: jolly, pespin.

daniel has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 3: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 3
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: pespin 
Gerrit-Comment-Date: Thu, 22 Feb 2024 10:40:28 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-22 Thread laforge
Attention is currently required from: daniel, jolly, pespin.

laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email )

Change subject: osmo_io: Move notify_connected function to backend
..


Patch Set 3: Code-Review+1

(1 comment)

Commit Message:

https://gerrit.osmocom.org/c/libosmocore/+/35909/comment/670e0230_aefcbe78
PS3, Line 17: file descriptior
I would always use 'iofd' when talking about an iofd, as otherwise it's getting 
confusing as 'file descriptor' normally referst to the integer value, or 
traditionally an osmo_fd.  I had to read this twice and the code in order to 
understand what you're referring-to here.



--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 3
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: pespin 
Gerrit-Attention: daniel 
Gerrit-Comment-Date: Thu, 22 Feb 2024 10:15:21 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


[M] Change in libosmocore[master]: osmo_io: Move notify_connected function to backend

2024-02-22 Thread jolly
Attention is currently required from: daniel, jolly, pespin.

Hello Jenkins Builder, daniel, laforge, pespin,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email

to look at the new patch set (#3).

The following approvals got outdated and were removed:
Code-Review-1 by pespin, Verified+1 by Jenkins Builder


Change subject: osmo_io: Move notify_connected function to backend
..

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, the file descriptior must be
registered. If read/write notification is requested by application, the
file descriptior must be registered also. A flag is used prevent
registering/unregistering file descriptor multiple times causing a
crash.

Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Related: OS#5751
---
M src/core/osmo_io.c
M src/core/osmo_io_internal.h
M src/core/osmo_io_poll.c
M src/core/osmo_io_uring.c
4 files changed, 53 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/09/35909/3
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35909?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I905ec85210570aff8addadfc9603335d04eb057a
Gerrit-Change-Number: 35909
Gerrit-PatchSet: 3
Gerrit-Owner: jolly 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Attention: jolly 
Gerrit-Attention: pespin 
Gerrit-Attention: daniel 
Gerrit-MessageType: newpatchset