src: use new libosmogsm and include/osmocom/[gsm|core] path to headers
[osmocom-bb.git] / src / host / layer23 / src / misc / rslms.c
index 9092078..93d22fd 100644 (file)
 #include <errno.h>
 #include <stdio.h>
 
-#include <osmocore/msgb.h>
-#include <osmocore/rsl.h>
-#include <osmocore/tlv.h>
-#include <osmocore/protocol/gsm_04_08.h>
-
-#include <osmocom/logging.h>
-#include <osmocom/lapdm.h>
-#include <osmocom/rslms.h>
-#include <osmocom/layer3.h>
-#include <osmocom/osmocom_data.h>
-#include <osmocom/l1ctl.h>
+#include <osmocom/core/msgb.h>
+#include <osmocom/gsm/rsl.h>
+#include <osmocom/gsm/tlv.h>
+#include <osmocom/gsm/protocol/gsm_04_08.h>
+
+#include <osmocom/bb/common/logging.h>
+#include <osmocom/bb/common/lapdm.h>
+#include <osmocom/bb/misc/rslms.h>
+#include <osmocom/bb/misc/layer3.h>
+#include <osmocom/bb/common/osmocom_data.h>
+#include <osmocom/bb/common/l1ctl.h>
 
 /* Send a 'simple' RLL request to L2 */
 int rslms_tx_rll_req(struct osmocom_ms *ms, uint8_t msg_type,
@@ -56,9 +56,6 @@ int rslms_tx_rll_req_l3(struct osmocom_ms *ms, uint8_t msg_type,
        return rslms_recvmsg(msg, ms);
 }
 
-static int ccch_enabled = 0;
-static int rach_count = 0;
-
 static int rslms_rx_udata_ind(struct msgb *msg, struct osmocom_ms *ms)
 {
        struct abis_rsl_rll_hdr *rllh = msgb_l2(msg);
@@ -77,13 +74,8 @@ static int rslms_rx_udata_ind(struct msgb *msg, struct osmocom_ms *ms)
 
        if (rllh->chan_nr == RSL_CHAN_PCH_AGCH) {
                rc = gsm48_rx_ccch(msg, ms);
-               ccch_enabled = 1;
        } else if (rllh->chan_nr == RSL_CHAN_BCCH) {
                rc = gsm48_rx_bcch(msg, ms);
-               if (ccch_enabled && (rach_count < 2)) {
-                       tx_ph_rach_req(ms, rach_count, 27, 0);
-                       rach_count++;
-               }
        }
 
        return rc;