From c9519466918157245f8aae93c5be11a7c28b65a3 Mon Sep 17 00:00:00 2001 From: Sylvain Munaut Date: Mon, 17 Oct 2011 14:04:55 +0200 Subject: libbsc/nokia_site: Fix reset procedure and add option to skip it. do_reset was not initialized anywhere anymore, so the reset was never triggered. It's now fixed and we add an option to skip it in the config so that when in production, you can restart without config changes quickly. Signed-off-by: Sylvain Munaut --- openbsc/src/libbsc/bts_nokia_site.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'openbsc/src/libbsc/bts_nokia_site.c') diff --git a/openbsc/src/libbsc/bts_nokia_site.c b/openbsc/src/libbsc/bts_nokia_site.c index c43eb5fde..dfe4c0347 100644 --- a/openbsc/src/libbsc/bts_nokia_site.c +++ b/openbsc/src/libbsc/bts_nokia_site.c @@ -57,8 +57,11 @@ static void bootstrap_om_bts(struct gsm_bts *bts) { LOGP(DNM, LOGL_NOTICE, "bootstrapping OML for BTS %u\n", bts->nr); - if (bts->nokia.do_reset) - abis_nm_reset(bts, 1); + if (!bts->nokia.skip_reset) { + if (!bts->nokia.did_reset) + abis_nm_reset(bts, 1); + } else + bts->nokia.did_reset = 1; } static void bootstrap_om_trx(struct gsm_bts_trx *trx) @@ -1543,8 +1546,8 @@ static int abis_nm_rcvmsg_fom(struct msgb *mb) /* TODO: the assumption for the following is that no NACK was received */ /* ACK for reset message ? */ - if (bts->nokia.do_reset != 0) { - bts->nokia.do_reset = 0; + if (!bts->nokia.did_reset) { + bts->nokia.did_reset = 1; /* TODO: For the InSite processing the received data is -- cgit v1.2.3