laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-sccp/+/36169?usp=email )
Change subject: cosmetic: rename ss7_asp_*_conn_cb to ss7_asp_*_conn_rx_cb ......................................................................
cosmetic: rename ss7_asp_*_conn_cb to ss7_asp_*_conn_rx_cb
The old/existing name says it is a connection call-back, but not what kind of all-back; let's introduce 'rx' to indicate it is a receive call-back.
Change-Id: Iaaef8128d4a26ea75fbce7067a8ab935a319beb4 --- M src/osmo_ss7_asp.c M src/osmo_ss7_xua_srv.c M src/ss7_internal.h 3 files changed, 23 insertions(+), 10 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-sccp refs/changes/69/36169/1
diff --git a/src/osmo_ss7_asp.c b/src/osmo_ss7_asp.c index e023880..9c2bff3 100644 --- a/src/osmo_ss7_asp.c +++ b/src/osmo_ss7_asp.c @@ -792,7 +792,7 @@ }
/* netif code tells us we can read something from the socket */ -int ss7_asp_ipa_srv_conn_cb(struct osmo_stream_srv *conn, struct msgb *msg) +int ss7_asp_ipa_srv_conn_rx_cb(struct osmo_stream_srv *conn, struct msgb *msg) { int fd = osmo_stream_srv_get_fd(conn); struct osmo_ss7_asp *asp = osmo_stream_srv_get_data(conn); @@ -805,7 +805,7 @@ }
/* netif code tells us we can read something from the socket */ -int ss7_asp_xua_srv_conn_cb(struct osmo_stream_srv *conn, struct msgb *msg) +int ss7_asp_xua_srv_conn_rx_cb(struct osmo_stream_srv *conn, struct msgb *msg) { struct osmo_ss7_asp *asp = osmo_stream_srv_get_data(conn); unsigned int ppid; @@ -865,7 +865,7 @@ }
/* netif code tells us we can read something from the socket */ -int ss7_asp_m3ua_tcp_srv_conn_cb(struct osmo_stream_srv *conn, struct msgb *msg) +int ss7_asp_m3ua_tcp_srv_conn_rx_cb(struct osmo_stream_srv *conn, struct msgb *msg) { struct osmo_ss7_asp *asp = osmo_stream_srv_get_data(conn); const struct xua_common_hdr *hdr; diff --git a/src/osmo_ss7_xua_srv.c b/src/osmo_ss7_xua_srv.c index ce10448..1b6e498 100644 --- a/src/osmo_ss7_xua_srv.c +++ b/src/osmo_ss7_xua_srv.c @@ -82,21 +82,21 @@
switch (oxs->cfg.proto) { case OSMO_SS7_ASP_PROT_IPA: - osmo_stream_srv_set_read_cb(srv, ss7_asp_ipa_srv_conn_cb); + osmo_stream_srv_set_read_cb(srv, ss7_asp_ipa_srv_conn_rx_cb); osmo_stream_srv_set_segmentation_cb(srv, osmo_ipa_segmentation_cb); break; case OSMO_SS7_ASP_PROT_M3UA: if (oxs->cfg.trans_proto == IPPROTO_SCTP) - osmo_stream_srv_set_read_cb(srv, &ss7_asp_xua_srv_conn_cb); + osmo_stream_srv_set_read_cb(srv, &ss7_asp_xua_srv_conn_rx_cb); else if (oxs->cfg.trans_proto == IPPROTO_TCP) { - osmo_stream_srv_set_read_cb(srv, &ss7_asp_m3ua_tcp_srv_conn_cb); + osmo_stream_srv_set_read_cb(srv, &ss7_asp_m3ua_tcp_srv_conn_rx_cb); osmo_stream_srv_set_segmentation_cb(srv, xua_segmentation_cb); } else OSMO_ASSERT(0); break; default: OSMO_ASSERT(oxs->cfg.trans_proto == IPPROTO_SCTP); - osmo_stream_srv_set_read_cb(srv, &ss7_asp_xua_srv_conn_cb); + osmo_stream_srv_set_read_cb(srv, &ss7_asp_xua_srv_conn_rx_cb); osmo_stream_srv_set_segmentation_cb(srv, NULL); break; } diff --git a/src/ss7_internal.h b/src/ss7_internal.h index b737fa2..3466756 100644 --- a/src/ss7_internal.h +++ b/src/ss7_internal.h @@ -24,9 +24,9 @@
bool ss7_asp_protocol_check_trans_proto(enum osmo_ss7_asp_protocol proto, int trans_proto); int ss7_default_trans_proto_for_asp_proto(enum osmo_ss7_asp_protocol proto); -int ss7_asp_ipa_srv_conn_cb(struct osmo_stream_srv *conn, struct msgb *msg); -int ss7_asp_xua_srv_conn_cb(struct osmo_stream_srv *conn, struct msgb *msg); -int ss7_asp_m3ua_tcp_srv_conn_cb(struct osmo_stream_srv *conn, struct msgb *msg); +int ss7_asp_ipa_srv_conn_rx_cb(struct osmo_stream_srv *conn, struct msgb *msg); +int ss7_asp_xua_srv_conn_rx_cb(struct osmo_stream_srv *conn, struct msgb *msg); +int ss7_asp_m3ua_tcp_srv_conn_rx_cb(struct osmo_stream_srv *conn, struct msgb *msg); int ss7_asp_xua_srv_conn_closed_cb(struct osmo_stream_srv *srv); int ss7_asp_apply_peer_primary_address(const struct osmo_ss7_asp *asp); int ss7_asp_apply_primary_address(const struct osmo_ss7_asp *asp);