aboutsummaryrefslogtreecommitdiffstats
path: root/src/osmo-bsc/lcs_ta_req.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/osmo-bsc/lcs_ta_req.c')
-rw-r--r--src/osmo-bsc/lcs_ta_req.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/osmo-bsc/lcs_ta_req.c b/src/osmo-bsc/lcs_ta_req.c
index 850474cef..f0bb02eb6 100644
--- a/src/osmo-bsc/lcs_ta_req.c
+++ b/src/osmo-bsc/lcs_ta_req.c
@@ -56,14 +56,14 @@ static const struct osmo_tdef_state_timeout lcs_ta_req_fsm_timeouts[32] = {
osmo_tdef_fsm_inst_state_chg(FI, STATE, \
lcs_ta_req_fsm_timeouts, \
(bsc_gsmnet)->T_defs, \
- 5)
+ -1)
#define lcs_ta_req_fail(cause, fmt, args...) do { \
LOG_LCS_TA_REQ(lcs_ta_req, LOGL_ERROR, "BSSLAP TA Request failed in state %s: " fmt "\n", \
- osmo_fsm_inst_state_name(lcs_ta_req->fi), ## args); \
+ lcs_ta_req ? osmo_fsm_inst_state_name(lcs_ta_req->fi) : "NULL", ## args); \
lcs_ta_req->failure_cause = cause; \
lcs_ta_req_fsm_state_chg(lcs_ta_req->fi, LCS_TA_REQ_ST_FAILED); \
- } while(0)
+ } while (0)
static struct osmo_fsm lcs_ta_req_fsm;
@@ -122,17 +122,6 @@ void lcs_ta_req_wait_ta_onenter(struct osmo_fsm_inst *fi, uint32_t prev_state)
return;
}
- paging = (struct bsc_paging_params){
- .reason = BSC_PAGING_FOR_LCS,
- .msc = loc_req->conn->sccp.msc,
- .bsub = loc_req->conn->bsub,
- .tmsi = GSM_RESERVED_TMSI,
- .imsi = loc_req->req.imsi,
- .chan_needed = RSL_CHANNEED_ANY,
- };
- if (paging.bsub)
- bsc_subscr_get(paging.bsub, BSUB_USE_PAGING_START);
-
/* Do we already have an active lchan with knowledge of TA? */
lchan = loc_req->conn->lchan;
if (lchan) {
@@ -147,6 +136,17 @@ void lcs_ta_req_wait_ta_onenter(struct osmo_fsm_inst *fi, uint32_t prev_state)
return;
}
+ paging = (struct bsc_paging_params){
+ .reason = BSC_PAGING_FOR_LCS,
+ .msc = loc_req->conn->sccp.msc,
+ .bsub = loc_req->conn->bsub,
+ .tmsi = GSM_RESERVED_TMSI,
+ .imsi = loc_req->req.imsi,
+ .chan_needed = RSL_CHANNEED_ANY,
+ };
+ if (paging.bsub)
+ bsc_subscr_get(paging.bsub, BSUB_USE_PAGING_START);
+
if (!loc_req->req.cell_id_present) {
LOG_LCS_TA_REQ(lcs_ta_req, LOGL_DEBUG,
"No Cell Identity in BSSMAP Location Request, paging entire BSS\n");
@@ -210,7 +210,7 @@ void lcs_ta_req_got_ta_onenter(struct osmo_fsm_inst *fi, uint32_t prev_state)
.msg_type = BSSLAP_MSGT_TA_RESPONSE,
.ta_response = {
.cell_id = lchan->ts->trx->bts->cell_identity,
- .ta = lchan->rqd_ta,
+ .ta = lchan->last_ta,
},
},
},