Change in osmo-mgw[master]: osmux: Introduce mgcp_conn_rtp_is_osmux() helper

Harald Welte gerrit-no-reply at lists.osmocom.org
Sun May 19 07:15:53 UTC 2019


Harald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/14023 )

Change subject: osmux: Introduce mgcp_conn_rtp_is_osmux() helper
......................................................................

osmux: Introduce mgcp_conn_rtp_is_osmux() helper

This is going to be useful to know if a conn is to use Osmux without
looking at implementation details. Currently we have some duplicated
information (type, osmux.state, etc.) which we may want to refactor
later. This will allow changing implementation details without caring
much about rest of code.

Change-Id: Ib5a239fdbc319bcb16317f5e959d9a724b7a444a
---
M include/osmocom/mgcp/mgcp_internal.h
1 file changed, 5 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  Harald Welte: Looks good to me, approved



diff --git a/include/osmocom/mgcp/mgcp_internal.h b/include/osmocom/mgcp/mgcp_internal.h
index 82ff6c8..e9d5d2d 100644
--- a/include/osmocom/mgcp/mgcp_internal.h
+++ b/include/osmocom/mgcp/mgcp_internal.h
@@ -312,6 +312,11 @@
 
 int mgcp_set_ip_tos(int fd, int tos);
 
+/* Was conn configured to handle Osmux? */
+static inline bool mgcp_conn_rtp_is_osmux(const struct mgcp_conn_rtp *conn) {
+	return conn->type == MGCP_OSMUX_BSC || conn->type == MGCP_OSMUX_BSC_NAT;
+}
+
 enum {
 	MGCP_DEST_NET = 0,
 	MGCP_DEST_BTS,

-- 
To view, visit https://gerrit.osmocom.org/14023
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-mgw
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib5a239fdbc319bcb16317f5e959d9a724b7a444a
Gerrit-Change-Number: 14023
Gerrit-PatchSet: 1
Gerrit-Owner: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder (1000002)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190519/3a8a1f75/attachment.html>


More information about the gerrit-log mailing list