aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2021-09-22 13:30:39 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2021-09-22 14:24:08 +0200
commit6e27b1776e929bf36e681f2abe12af3f5ea4aec3 (patch)
treed102ca676b095239cffca55ad26a0cc56df2ba63
parent03c74baa83f4f3f699fac49affca9903dccb33f1 (diff)
l1sap: Support rx of empty rlcmac blocks from PCUpespin/pcu
This way the PCU can signal idle RLCMAC blocks (no transmission required) to the BTS, which can then send dummy/fill blocks aplying power reduction as needed by TRX. The block with len=0 is submitted to lower layers up to the scheduler, which will finally drop it in trx_sched_ph_data_req(). Change-Id: I734c66e236bf3e2015a4571ea1fd84849a9ef02c Related: SYS#4919
-rw-r--r--src/common/l1sap.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/common/l1sap.c b/src/common/l1sap.c
index 8aa80e75..b9bc6755 100644
--- a/src/common/l1sap.c
+++ b/src/common/l1sap.c
@@ -1977,8 +1977,12 @@ int l1sap_pdch_req(struct gsm_bts_trx_ts *ts, int is_ptcch, uint32_t fn,
l1sap->u.data.chan_nr = RSL_CHAN_OSMO_PDCH | ts->nr;
l1sap->u.data.link_id = 0x00;
l1sap->u.data.fn = fn;
- msg->l2h = msgb_put(msg, len);
- memcpy(msg->l2h, data, len);
+ if (len) {
+ msg->l2h = msgb_put(msg, len);
+ memcpy(msg->l2h, data, len);
+ } else {
+ msg->l2h = NULL; /* Idle block */
+ }
return l1sap_down(ts->trx, l1sap);
}