[layer23] Fix of signal loss handling

The cell must be kept "selected" in case of loosing radio link. It is
required to perform reselection of that cell or of the given neighbor
cells.
This commit is contained in:
Andreas.Eversberg 2010-10-13 18:30:59 +00:00
parent acbe0f858d
commit 3318b3f622
1 changed files with 10 additions and 5 deletions

View File

@ -2506,15 +2506,16 @@ static void gsm322_cs_loss(void *arg)
LOGP(DCS, LOGL_INFO, "Loss of CCCH.\n");
/* unset selected cell */
gsm322_unselect_cell(cs);
if (cs->state == GSM322_C3_CAMPED_NORMALLY
|| cs->state == GSM322_C7_CAMPED_ANY_CELL) {
if (rr->state == GSM48_RR_ST_IDLE) {
struct msgb *nmsg;
LOGP(DCS, LOGL_INFO, "Trigger re-selection.\n");
LOGP(DCS, LOGL_INFO, "Loss of CCCH, Trigger "
"re-selection.\n");
/* unset selected cell */
gsm322_unselect_cell(cs);
nmsg = gsm322_msgb_alloc(GSM322_EVENT_CELL_RESEL);
if (!nmsg)
@ -2522,7 +2523,11 @@ static void gsm322_cs_loss(void *arg)
gsm322_c_event(ms, nmsg);
msgb_free(nmsg);
} else {
LOGP(DCS, LOGL_INFO, "Trigger RR abort.\n");
LOGP(DCS, LOGL_INFO, "Loss of SACCH, Trigger RR "
"abort.\n");
/* keep cell info for re-selection */
gsm48_rr_los(ms);
/* be shure that nothing else is done after here
* because the function call above may cause