[layer23] Bugfix: Loosing CCCH signal must cause unselection of cell.

This commit is contained in:
Andreas.Eversberg 2010-10-12 08:48:08 +00:00
parent 4e9656c819
commit 218303d6ed
1 changed files with 15 additions and 1 deletions

View File

@ -1966,11 +1966,21 @@ static int gsm322_cs_store(struct osmocom_ms *ms)
struct gsm322_ba_list *gsm322_cs_sysinfo_sacch(struct osmocom_ms *ms)
{
struct gsm322_cellsel *cs = &ms->cellsel;
struct gsm48_sysinfo *s = cs->si;
struct gsm48_sysinfo *s;
struct gsm322_ba_list *ba = NULL;
int i;
uint8_t freq[128];
if (!cs) {
LOGP(DCS, LOGL_INFO, "No BA, because no cell selected\n");
return ba;
}
s = cs->si;
if (!s) {
LOGP(DCS, LOGL_INFO, "No BA, because no sysinfo\n");
return ba;
}
/* collect system information received during dedicated mode */
if (s->si5
&& (!s->nb_ext_ind_si5
@ -2495,6 +2505,10 @@ static void gsm322_cs_loss(void *arg)
struct gsm48_rrlayer *rr = &ms->rrlayer;
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) {