[statistics] Keep track of OML/RSL failures of the BTS.
diff --git a/openbsc/src/bsc_init.c b/openbsc/src/bsc_init.c
index fccdb0c..94576b7 100644
--- a/openbsc/src/bsc_init.c
+++ b/openbsc/src/bsc_init.c
@@ -918,6 +918,11 @@
 	case EVT_E1_TEI_DN:
 		LOGP(DMI, LOGL_ERROR, "Lost some E1 TEI link: %d %p\n", type, trx);
 
+		if (type == E1INP_SIGN_OML)
+			counter_inc(trx->bts->network->stats.bts.oml_fail);
+		else if (type == E1INP_SIGN_RSL)
+			counter_inc(trx->bts->network->stats.bts.rsl_fail);
+
 		/*
 		 * free all allocated channels. change the nm_state so the
 		 * trx and trx_ts becomes unusable and chan_alloc.c can not