X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2F5gnrrlc%2Frlc_utils.h;h=b40c957a4b0d8afae0984801e4e7f186314e3c1d;hb=3330932565e15a749fd5dd5039cdea2862ca51cc;hp=c7126aefa0856fc82a970e62fe4e953e715d9dda;hpb=088bb8763eaf91c139ede025faf2fac7e57d25ed;p=o-du%2Fl2.git diff --git a/src/5gnrrlc/rlc_utils.h b/src/5gnrrlc/rlc_utils.h index c7126aefa..b40c957a4 100644 --- a/src/5gnrrlc/rlc_utils.h +++ b/src/5gnrrlc/rlc_utils.h @@ -25,16 +25,19 @@ #define RLC_UL_INST 0 #define RLC_DL_INST 1 +#define PDCP_SN 1 +#define RLC_REASSEMBLY_TMR_BASE 5 /* Used to calculate timer value from enum values */ + /* Fill Pst structure for sending msg from RLC to DUAPP */ -#define FILL_PST_RLC_TO_DUAPP(_pst, _procId, _srcInst, _event) \ +#define FILL_PST_RLC_TO_DUAPP(_pst, _srcInst, _event) \ { \ _pst.selector = ODU_SELECTOR_LWLC; \ - _pst.srcEnt = ENTRLC; \ + _pst.srcEnt = ENTRLC; \ _pst.dstEnt = ENTDUAPP; \ _pst.dstInst = 0; \ _pst.srcInst = _srcInst; \ - _pst.dstProcId = _procId; \ - _pst.srcProcId = _procId; \ + _pst.dstProcId = ODU_GET_PROCID(); \ + _pst.srcProcId = ODU_GET_PROCID(); \ if(_srcInst == RLC_UL_INST) \ { \ _pst.region = RLC_MEM_REGION_UL; \ @@ -50,7 +53,30 @@ _pst.intfVer = 0; \ } -void reverseFixBuf(uint8_t *buf, uint16_t len); +#define FILL_PST_RLC_TO_MAC(_pst, _srcInst, _event) \ +{ \ + pst.selector = ODU_SELECTOR_LWLC; \ + pst.srcEnt = ENTRLC; \ + pst.dstEnt = ENTMAC; \ + pst.dstInst = 0; \ + pst.srcInst = _srcInst; \ + pst.dstProcId = ODU_GET_PROCID(); \ + pst.srcProcId = ODU_GET_PROCID(); \ + if(_srcInst == RLC_UL_INST) \ + { \ + pst.region = RLC_MEM_REGION_UL; \ + } \ + else if(_srcInst == RLC_DL_INST) \ + { \ + pst.region = RLC_MEM_REGION_DL; \ + } \ + pst.pool = RLC_POOL; \ + pst.event = _event; \ + pst.route = 0; \ + pst.prior = 0; \ + pst.intfVer = 0; \ +} + uint16_t getTransId(); /**********************************************************************