diff options
author | Philipp Maier <pmaier@sysmocom.de> | 2016-12-02 19:04:34 +0100 |
---|---|---|
committer | Harald Welte <laforge@gnumonks.org> | 2017-05-25 14:04:08 +0200 |
commit | f8aeb2cccb767c8823e1c851efd8de86a226033e (patch) | |
tree | ce1e791393a0bbf7c66c7519d25f4dd40832c33a /openbsc/src/libbsc/pcu_sock.c | |
parent | f14cb3535cf469632b5da63f35b31aa79fd0c5c3 (diff) |
pcu_sock: Forward imm.ass PCU originated messages
The PCU sends imm.ass messages in response to a rach request. Those
messages need to be forwarded to RSL in order to get them send. This
commit introduces the required functionality for that
Change-Id: Ice099c4ed7008200ed179e581aba1899c6c29455
Diffstat (limited to 'openbsc/src/libbsc/pcu_sock.c')
-rw-r--r-- | openbsc/src/libbsc/pcu_sock.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/openbsc/src/libbsc/pcu_sock.c b/openbsc/src/libbsc/pcu_sock.c index 0ae3a03e4..7e7779796 100644 --- a/openbsc/src/libbsc/pcu_sock.c +++ b/openbsc/src/libbsc/pcu_sock.c @@ -286,6 +286,27 @@ int pcu_tx_rach_ind(struct gsm_bts *bts, int16_t qta, uint16_t ra, uint32_t fn, return pcu_sock_send(bts, msg); } +/* Confirm the sending of an immediate assignment to the pcu */ +int pcu_tx_imm_ass_sent(struct gsm_bts *bts, uint32_t tlli) +{ + struct msgb *msg; + struct gsm_pcu_if *pcu_prim; + struct gsm_pcu_if_data_cnf_dt *data_cnf_dt; + + LOGP(DPCU, LOGL_INFO, "Sending PCH confirm with direct TLLI\n"); + + msg = pcu_msgb_alloc(PCU_IF_MSG_DATA_CNF_DT, bts->nr); + if (!msg) + return -ENOMEM; + pcu_prim = (struct gsm_pcu_if *) msg->data; + data_cnf_dt = &pcu_prim->u.data_cnf_dt; + + data_cnf_dt->sapi = PCU_IF_SAPI_PCH; + data_cnf_dt->tlli = tlli; + + return pcu_sock_send(bts, msg); +} + /* we need to decode the raw RR paging messsage (see PCU code * Encoding::write_paging_request) and extract the mobile identity * (P-TMSI) from it */ |