mirror of
https://gitea.osmocom.org/cellular-infrastructure/osmo-mgw.git
synced 2025-10-23 08:12:01 +00:00
mgcp-cli: Allow submitting X-Osmux on MDCX request
Change-Id: I41243f3ed212ace6087d5b0341e3a52f4069e37d
This commit is contained in:
@@ -173,6 +173,11 @@ static struct msgb *make_mdcx_msg(struct mgcp_ctx *mgcp_ctx)
|
|||||||
|
|
||||||
set_conn_mode(&mgcp_msg, &mgcp_ctx->conn_peer_local);
|
set_conn_mode(&mgcp_msg, &mgcp_ctx->conn_peer_local);
|
||||||
|
|
||||||
|
if (mgcp_ctx->conn_peer_local.x_osmo_osmux_use) {
|
||||||
|
mgcp_msg.x_osmo_osmux_cid = mgcp_ctx->conn_peer_local.x_osmo_osmux_cid;
|
||||||
|
mgcp_msg.presence |= MGCP_MSG_PRESENCE_X_OSMO_OSMUX_CID;
|
||||||
|
}
|
||||||
|
|
||||||
/* Note: We take the endpoint and the call_id from the remote
|
/* Note: We take the endpoint and the call_id from the remote
|
||||||
* connection info, because we can be confident that the
|
* connection info, because we can be confident that the
|
||||||
* information there is valid. For the local info, we explicitly
|
* information there is valid. For the local info, we explicitly
|
||||||
|
@@ -276,6 +276,17 @@ void test_mgcp_msg(void)
|
|||||||
msg = mgcp_msg_gen(mgcp, &mgcp_msg);
|
msg = mgcp_msg_gen(mgcp, &mgcp_msg);
|
||||||
printf("%s\n", (char *)msg->data);
|
printf("%s\n", (char *)msg->data);
|
||||||
|
|
||||||
|
printf("Generate X-Osmo-Osmux message (MDCX):\n");
|
||||||
|
msg = mgcp_msg_gen(mgcp, &mgcp_msg);
|
||||||
|
mgcp_msg.verb = MGCP_VERB_MDCX;
|
||||||
|
mgcp_msg.x_osmo_osmux_cid = 2;
|
||||||
|
mgcp_msg.presence =
|
||||||
|
(MGCP_MSG_PRESENCE_ENDPOINT | MGCP_MSG_PRESENCE_CALL_ID |
|
||||||
|
MGCP_MSG_PRESENCE_CONN_ID | MGCP_MSG_PRESENCE_CONN_MODE
|
||||||
|
| MGCP_MSG_PRESENCE_X_OSMO_OSMUX_CID);
|
||||||
|
msg = mgcp_msg_gen(mgcp, &mgcp_msg);
|
||||||
|
printf("%s\n", (char *)msg->data);
|
||||||
|
|
||||||
printf("Overfolow test:\n");
|
printf("Overfolow test:\n");
|
||||||
mgcp_msg.verb = MGCP_VERB_MDCX;
|
mgcp_msg.verb = MGCP_VERB_MDCX;
|
||||||
mgcp_msg.presence =
|
mgcp_msg.presence =
|
||||||
|
@@ -100,6 +100,14 @@ L: p:20, a:GSM, nt:IN
|
|||||||
M: sendrecv
|
M: sendrecv
|
||||||
X-Osmux: 2
|
X-Osmux: 2
|
||||||
|
|
||||||
|
Generate X-Osmo-Osmux message (MDCX):
|
||||||
|
MDCX 17 23@mgw MGCP 1.0
|
||||||
|
C: 2f
|
||||||
|
I: 11
|
||||||
|
L: p:20, a:GSM, nt:IN
|
||||||
|
M: sendrecv
|
||||||
|
X-Osmux: 2
|
||||||
|
|
||||||
Overfolow test:
|
Overfolow test:
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user