Attention is currently required from: pespin.
arehbein has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/33892 )
Change subject: bsc (WIP): Make socket queue max. length configurable ......................................................................
Patch Set 2:
(3 comments)
File src/osmo-bsc/bsc_vty.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/33892/comment/be28330f_ed6aefd5 PS1, Line 2487: if (fd >= 0 && ((ofd = osmo_fd_get_by_fd(fd)) != NULL)) {
why do you care about the socket being opened here? […]
I guess it doesn't really matter here. I viewed it as a check to make sure `pcu_sock_init()` has been run before, in case there are any other states permitting `net->pcu_state` without `net->pcu_state->upqueue` being allocated. I checked the code and it looks like there are no such states.
https://gerrit.osmocom.org/c/osmo-bsc/+/33892/comment/8d91cc21_656855d8 PS1, Line 2491: }
ah I thought there may be an API so I didn't see it sorry. […]
I suppose it's possible to check if the current wqueue length is larger than the new maximum right inside this command when it's called, and then drop extra messages. Otherwise.. why should there be a new API? What kind?
Do we really want to drop messages from previously 'legal' enqueue actions though?
File src/osmo-bsc/pcu_sock.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/33892/comment/da802a47_9e38c4c5 PS1, Line 956: net->pcu_sock_fd = rc;
That check is not needed imho.
Done