pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-hnbgw/+/40252?usp=email )

Change subject: sccp: Introduce UL-related cnlink rate counters
......................................................................

sccp: Introduce UL-related cnlink rate counters

Change-Id: I1878fcc8c265dc4d457332e16556d3ece769ea3e
---
M include/osmocom/hnbgw/hnbgw_cn.h
M src/osmo-hnbgw/cnlink.c
M src/osmo-hnbgw/context_map_sccp.c
M src/osmo-hnbgw/hnbgw_cn.c
4 files changed, 24 insertions(+), 0 deletions(-)

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




diff --git a/include/osmocom/hnbgw/hnbgw_cn.h b/include/osmocom/hnbgw/hnbgw_cn.h
index 917cc07..fc33e5b 100644
--- a/include/osmocom/hnbgw/hnbgw_cn.h
+++ b/include/osmocom/hnbgw/hnbgw_cn.h
@@ -57,9 +57,13 @@
        CNLINK_CTR_RANAP_TX_UDT_RESET_ACK,

        /* SCCP Counters: */
+       CNLINK_CTR_SCCP_N_UNITDATA_REQ,
        CNLINK_CTR_SCCP_N_UNITDATA_IND,
+       CNLINK_CTR_SCCP_N_CONNECT_REQ,
        CNLINK_CTR_SCCP_N_CONNECT_CNF,
+       CNLINK_CTR_SCCP_N_DATA_REQ,
        CNLINK_CTR_SCCP_N_DATA_IND,
+       CNLINK_CTR_SCCP_N_DISCONNECT_REQ,
        CNLINK_CTR_SCCP_N_DISCONNECT_IND,
        CNLINK_CTR_SCCP_N_PCSTATE_IND,
        CNLINK_CTR_SCCP_RLSD_CN_ORIGIN,
diff --git a/src/osmo-hnbgw/cnlink.c b/src/osmo-hnbgw/cnlink.c
index 477bd68..46f53d7 100644
--- a/src/osmo-hnbgw/cnlink.c
+++ b/src/osmo-hnbgw/cnlink.c
@@ -140,6 +140,7 @@

 static int hnbgw_cnlink_tx_sccp_unitdata_req(struct hnbgw_cnlink *cnlink, 
struct msgb *msg)
 {
+       CNLINK_CTR_INC(cnlink, CNLINK_CTR_SCCP_N_UNITDATA_REQ);
        return hnbgw_sccp_user_tx_unitdata_req(cnlink->hnbgw_sccp_user,
                                               &cnlink->remote_addr,
                                               msg);
diff --git a/src/osmo-hnbgw/context_map_sccp.c 
b/src/osmo-hnbgw/context_map_sccp.c
index 3c97789..5b5e77f 100644
--- a/src/osmo-hnbgw/context_map_sccp.c
+++ b/src/osmo-hnbgw/context_map_sccp.c
@@ -128,6 +128,7 @@
                ranap_msg = hnbgw_ranap_msg_alloc("SCCP-CR-empty");
        }

+       CNLINK_CTR_INC(map->cnlink, CNLINK_CTR_SCCP_N_CONNECT_REQ);
        return hnbgw_sccp_user_tx_connect_req(map->cnlink->hnbgw_sccp_user,
                                              &map->cnlink->remote_addr,
                                              map->scu_conn_id,
@@ -146,6 +147,7 @@
                return -1;
        }

+       CNLINK_CTR_INC(map->cnlink, CNLINK_CTR_SCCP_N_DATA_REQ);
        return hnbgw_sccp_user_tx_data_req(map->cnlink->hnbgw_sccp_user,
                                           map->scu_conn_id,
                                           ranap_msg);
@@ -160,6 +162,7 @@
                return -1;
        }

+       CNLINK_CTR_INC(map->cnlink, CNLINK_CTR_SCCP_N_DISCONNECT_REQ);
        return hnbgw_sccp_user_tx_disconnect_req(map->cnlink->hnbgw_sccp_user,
                                                 map->scu_conn_id);
 }
diff --git a/src/osmo-hnbgw/hnbgw_cn.c b/src/osmo-hnbgw/hnbgw_cn.c
index 8a7f88e..121c77f 100644
--- a/src/osmo-hnbgw/hnbgw_cn.c
+++ b/src/osmo-hnbgw/hnbgw_cn.c
@@ -462,18 +462,34 @@
        },

        /* SCCP Counters: */
+       [CNLINK_CTR_SCCP_N_UNITDATA_REQ] = {
+               "sccp:n_unit_data:req",
+               "Submit SCCP N-UNITDATA.req (UL)"
+       },
        [CNLINK_CTR_SCCP_N_UNITDATA_IND] = {
                "sccp:n_unit_data:ind",
                "Received SCCP N-UNITDATA.ind (DL)"
        },
+       [CNLINK_CTR_SCCP_N_CONNECT_REQ] = {
+               "sccp:n_connect:req",
+               "Submit SCCP N-CONNECT.req (UL SCCP CR)"
+       },
        [CNLINK_CTR_SCCP_N_CONNECT_CNF] = {
                "sccp:n_connect:cnf",
                "Received SCCP N-CONNECT.cnf (DL SCCP CC)"
        },
+       [CNLINK_CTR_SCCP_N_DATA_REQ] = {
+               "sccp:n_data:req",
+               "SUBMIT SCCP N-DATA.req (UL)"
+       },
        [CNLINK_CTR_SCCP_N_DATA_IND] = {
                "sccp:n_data:ind",
                "Received SCCP N-DATA.ind (DL)"
        },
+       [CNLINK_CTR_SCCP_N_DISCONNECT_REQ] = {
+               "sccp:n_disconnect:req",
+               "Submit SCCP N-DISCONNECT.req (UL SCCP RLC)"
+       },
        [CNLINK_CTR_SCCP_N_DISCONNECT_IND] = {
                "sccp:n_disconnect:ind",
                "Received SCCP N-DISCONNECT.ind (DL SCCP RLSD)"

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

Gerrit-MessageType: merged
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: I1878fcc8c265dc4d457332e16556d3ece769ea3e
Gerrit-Change-Number: 40252
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pes...@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <lafo...@osmocom.org>
Gerrit-Reviewer: osmith <osm...@sysmocom.de>
Gerrit-Reviewer: pespin <pes...@sysmocom.de>

Reply via email to