aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPhilipp Maier <pmaier@sysmocom.de>2023-08-08 16:06:57 +0200
committerPhilipp Maier <pmaier@sysmocom.de>2023-08-08 16:11:50 +0200
commitbbb3a1ed17961c433e874b799c4e34002bc11392 (patch)
tree7e5650b56c43539bb05fea62f6c928169c06ea62 /src
parent88de4d6789fdf41fbcb79bbe2d9fa54262ec3bc5 (diff)
pcuif_proto: rename tlli to msg_id
To confirm downlink IMMEDIATE ASSIGNMENT messages, we use the TLLI as an identifier and the related struct member is also called "tlli". Unfortunately this is misleading since the message identifier does not necessarly have to be a TLLI. It is just an implementation detail that osmo-pcu uses the TLLI as a message identifier. To make that clear, lets rename the tlli member (and variable and parameter names where it is passed on) to "msg_id". (Since this change only renames variables and struct members it will not break compatibility with other programs that use the PCUIF) Related: OS#5927 Depends: osmo-pcu.git I4a25039dfe329e68879bc68936e49c4b190625e6 Change-Id: Ie6b34d5df64f4bed6b14581c7957dcba6af44136
Diffstat (limited to 'src')
-rw-r--r--src/common/paging.c8
-rw-r--r--src/common/pcu_sock.c6
2 files changed, 7 insertions, 7 deletions
diff --git a/src/common/paging.c b/src/common/paging.c
index 914a4b5e..ebfb84b3 100644
--- a/src/common/paging.c
+++ b/src/common/paging.c
@@ -65,7 +65,7 @@ struct paging_record {
struct {
uint8_t msg[GSM_MACBLOCK_LEN];
bool confirm;
- uint32_t tlli; /* used as identifier for confirmation */
+ uint32_t msg_id; /* used as identifier for confirmation */
} macblock;
} u;
};
@@ -293,7 +293,7 @@ static uint16_t convert_imsi_to_decimal(const char *imsi)
/* Add a ready formatted MAC block message to the paging queue, this can be an IMMEDIATE ASSIGNMENT, or a
* PAGING COMMAND (from the PCU) */
-int paging_add_macblock(struct paging_state *ps, uint32_t tlli, const char *imsi, bool confirm, const uint8_t *macblock)
+int paging_add_macblock(struct paging_state *ps, uint32_t msg_id, const char *imsi, bool confirm, const uint8_t *macblock)
{
struct llist_head *group_q;
struct paging_record *pr;
@@ -322,7 +322,7 @@ int paging_add_macblock(struct paging_state *ps, uint32_t tlli, const char *imsi
paging_group);
memcpy(pr->u.macblock.msg, macblock, GSM_MACBLOCK_LEN);
pr->u.macblock.confirm = confirm;
- pr->u.macblock.tlli = tlli;
+ pr->u.macblock.msg_id = msg_id;
/* enqueue the new message to the HEAD of the queue */
llist_add(&pr->list, group_q);
@@ -734,7 +734,7 @@ int paging_gen_msg(struct paging_state *ps, uint8_t *out_buf, struct gsm_time *g
GSM_MACBLOCK_LEN);
/* send a confirmation back (if required) */
if (pr[num_pr]->u.macblock.confirm)
- pcu_tx_pch_data_cnf(gt->fn, pr[num_pr]->u.macblock.tlli);
+ pcu_tx_pch_data_cnf(gt->fn, pr[num_pr]->u.macblock.msg_id);
talloc_free(pr[num_pr]);
return GSM_MACBLOCK_LEN;
}
diff --git a/src/common/pcu_sock.c b/src/common/pcu_sock.c
index 9e34fe8b..ad645a0b 100644
--- a/src/common/pcu_sock.c
+++ b/src/common/pcu_sock.c
@@ -618,7 +618,7 @@ int pcu_tx_pag_req(const uint8_t *identity_lv, uint8_t chan_needed)
return pcu_sock_send(msg);
}
-int pcu_tx_pch_data_cnf(uint32_t fn, uint32_t tlli)
+int pcu_tx_pch_data_cnf(uint32_t fn, uint32_t msg_id)
{
struct gsm_bts *bts;
struct msgb *msg;
@@ -635,7 +635,7 @@ int pcu_tx_pch_data_cnf(uint32_t fn, uint32_t tlli)
pcu_prim = (struct gsm_pcu_if *) msg->data;
pcu_prim->u.data_cnf_dt = (struct gsm_pcu_if_data_cnf_dt) {
.sapi = PCU_IF_SAPI_PCH_DT,
- .tlli = tlli,
+ .msg_id = msg_id,
.fn = fn,
};
@@ -689,7 +689,7 @@ static int pcu_rx_data_req(struct gsm_bts *bts, uint8_t msg_type,
gsm_pcu_if_pch_dt = (struct gsm_pcu_if_pch_dt *)data_req->data;
gsm48_imm_ass = (struct gsm48_imm_ass *)gsm_pcu_if_pch_dt->data;
confirm = (gsm48_imm_ass->msg_type == GSM48_MT_RR_IMM_ASS);
- rc = paging_add_macblock(bts->paging_state, gsm_pcu_if_pch_dt->tlli,
+ rc = paging_add_macblock(bts->paging_state, gsm_pcu_if_pch_dt->msg_id,
gsm_pcu_if_pch_dt->imsi, confirm, gsm_pcu_if_pch_dt->data);
break;
}