gprs_bssgp: use BVCI_SIGNALLING/BVCI_PTM instead of 0/1
Makes more understandable and clear what's meant in the code.
Related: OS#3879
Change-Id: I9d0545fac0af0dcc1783040a376a9b8e65a92699
diff --git a/src/gb/gprs_bssgp.c b/src/gb/gprs_bssgp.c
index c91abd6..207c9a8 100644
--- a/src/gb/gprs_bssgp.c
+++ b/src/gb/gprs_bssgp.c
@@ -113,10 +113,9 @@
OSMO_ASSERT(pdu == BSSGP_PDUT_BVC_RESET || pdu == BSSGP_PDUT_BVC_RESET_ACK);
msgb_nsei(msg) = nsei;
- msgb_bvci(msg) = 0; /* Signalling */
+ msgb_bvci(msg) = BVCI_SIGNALLING;
bgph->pdu_type = pdu;
-
msgb_tvlv_put(msg, BSSGP_IE_BVCI, 2, (uint8_t *) &_bvci);
if (pdu == BSSGP_PDUT_BVC_RESET) {
@@ -388,7 +387,7 @@
/* When we receive a BVC-RESET PDU (at least of a PTP BVCI), the BSS
* informs us about its RAC + Cell ID, so we can create a mapping */
- if (bctx->is_sgsn && bvci != 0 && bvci != 1) {
+ if (bctx->is_sgsn && bvci != BVCI_SIGNALLING && bvci != BVCI_PTM) {
if (!TLVP_PRES_LEN(tp, BSSGP_IE_CELL_ID, 8)) {
LOGP(DLBSSGP, LOGL_ERROR, "BSSGP BVCI=%u Rx RESET "
"missing mandatory IE\n", bvci);
@@ -402,7 +401,7 @@
}
/* Acknowledge the RESET to the BTS */
- if (bvci == 0 || bvci == 1 || bctx->is_sgsn)
+ if (bvci == BVCI_SIGNALLING || bvci == BVCI_PTM || bctx->is_sgsn)
bssgp_tx_simple_bvci(BSSGP_PDUT_BVC_RESET_ACK,
nsei, bvci, ns_bvci);
else