aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/common/scheduler.c15
-rw-r--r--src/osmo-bts-trx/trx_if.c11
2 files changed, 18 insertions, 8 deletions
diff --git a/src/common/scheduler.c b/src/common/scheduler.c
index 3adfc498..fe93c32b 100644
--- a/src/common/scheduler.c
+++ b/src/common/scheduler.c
@@ -1349,6 +1349,13 @@ int trx_sched_ul_burst(struct l1sched_trx *l1t, struct trx_ul_burst_ind *bi)
l1cs = &l1ts->chan_state[chan];
func = trx_chan_desc[chan].ul_fn;
+ /* TODO: handle noise measurements */
+ if (chan == TRXC_IDLE && bi->flags & TRX_BI_F_NOPE_IND) {
+ LOGL1S(DL1P, LOGL_DEBUG, l1t, bi->tn, chan, bi->fn,
+ "Rx noise measurement (%d)\n", bi->rssi);
+ return -ENOTSUP;
+ }
+
/* check if channel is active */
if (!TRX_CHAN_IS_ACTIVE(l1cs, chan))
return -EINVAL;
@@ -1364,6 +1371,14 @@ int trx_sched_ul_burst(struct l1sched_trx *l1t, struct trx_ul_burst_ind *bi)
l1cs->last_tdma_fn = bi->fn;
l1cs->proc_tdma_fs++;
+ /* handle NOPE indications (if the handler is present) */
+ if (bi->flags & TRX_BI_F_NOPE_IND) {
+ func = trx_chan_desc[chan].nope_fn;
+ if (!func)
+ return 0;
+ return func(l1t, chan, bid, bi);
+ }
+
/* decrypt */
if (bi->burst_len && l1cs->ul_encr_algo) {
ubit_t ks[114];
diff --git a/src/osmo-bts-trx/trx_if.c b/src/osmo-bts-trx/trx_if.c
index 920f441f..dbf78058 100644
--- a/src/osmo-bts-trx/trx_if.c
+++ b/src/osmo-bts-trx/trx_if.c
@@ -1018,14 +1018,8 @@ static int trx_data_read_cb(struct osmo_fd *ofd, unsigned int what)
if (hdr_len < 0)
return hdr_len;
- /* TODO: we can use NOPE indications to get noise levels on IDLE
- * TDMA frames, and properly drive scheduler if nothing has been
- * detected on non-IDLE channels. */
- if (bi.flags & TRX_BI_F_NOPE_IND) {
- LOGPPHI(l1h->phy_inst, DTRX, LOGL_DEBUG,
- "IDLE / NOPE indications are not (yet) supported\n");
- return -ENOTSUP;
- }
+ if (bi.flags & TRX_BI_F_NOPE_IND)
+ goto skip_burst;
/* We're done with the header now */
buf_len -= hdr_len;
@@ -1047,6 +1041,7 @@ static int trx_data_read_cb(struct osmo_fd *ofd, unsigned int what)
if (rc < 0)
return rc;
+skip_burst:
/* Print header & burst info */
LOGPPHI(l1h->phy_inst, DTRX, LOGL_DEBUG, "Rx %s (hdr_ver=%u): %s\n",
(bi.flags & TRX_BI_F_NOPE_IND) ? "NOPE.ind" : "UL burst",