diff options
author | Vadim Yanitskiy <vyanitskiy@sysmocom.de> | 2021-10-27 11:49:59 +0300 |
---|---|---|
committer | Vadim Yanitskiy <vyanitskiy@sysmocom.de> | 2021-10-27 18:12:09 +0300 |
commit | a1377d90808351145187b434fdccea49ed2882c0 (patch) | |
tree | 7a1db314619839f1d70cfd10af889bca5989445f | |
parent | 03cf6042fb32ed17b52cafe5c3e2c32a23df9e9e (diff) |
l1sap: move false PTCCH/U detection into PDCH branch
This check is only relevant for PDCH timeslots.
Change-Id: I187fef8f3de0b41b502b0b18acfb11c56c5551f0
-rw-r--r-- | src/common/l1sap.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/common/l1sap.c b/src/common/l1sap.c index 6eb08ba0..d9e27b26 100644 --- a/src/common/l1sap.c +++ b/src/common/l1sap.c @@ -1494,15 +1494,6 @@ static int l1sap_ph_data_ind(struct gsm_bts_trx *trx, DEBUGPGT(DL1P, &g_time, "Rx PH-DATA.ind chan_nr=%s link_id=0x%02x len=%d\n", rsl_chan_nr_str(chan_nr), link_id, len); - /* Actually, there can be no DATA.ind on PTCCH/U (rather RACH.ind instead), - * but some BTS models with buggy implementation may still be sending them - * to us. Let's keep this for backwards compatibility. */ - if (L1SAP_IS_CHAN_PDCH(chan_nr) && L1SAP_IS_PTCCH(fn)) { - LOGPGT(DL1P, LOGL_NOTICE, &g_time, "There can be no DATA.ind on PTCCH/U. " - "This is probably a bug of the BTS model you're using, please fix!\n"); - return -EINVAL; - } - /* The ph_data_param contained in the l1sap primitive may contain * measurement data. If this data is present, forward it for * processing */ @@ -1525,6 +1516,14 @@ static int l1sap_ph_data_ind(struct gsm_bts_trx *trx, return 1; } + /* There can be no DATA.ind on PTCCH/U (rather RACH.ind instead), but some + * BTS models with buggy implementation may still be sending them to us. */ + if (L1SAP_IS_PTCCH(fn)) { + LOGPGT(DL1P, LOGL_NOTICE, &g_time, "There can be no DATA.ind on PTCCH/U. " + "This is probably a bug of the BTS model you're using, please fix!\n"); + return -EINVAL; + } + /* Drop all data from incomplete UL block */ if (pr_info != PRES_INFO_BOTH) len = 0; |