From ed3413e39740c78148719696b0903874add580e2 Mon Sep 17 00:00:00 2001 From: aravind sirsikar Date: Fri, 11 Nov 2016 17:15:10 +0530 Subject: Handle packet access reject during EPDAN/PDAN with channel description When PDAN/EPDAN with channel description is received, PCU will generate the packet access reject if no resources are present. The encoding is done based on section 7.1.3.2.1 and 8.1.2.5 of 44.060 version 7.27.0 Release 7. This patch also includes the test case to validate the generated packet access reject message. This patch is integration tested on Osmo-trx setup with Ettus B210 board and LG F70 MS with some simulation code changes in Osmo-pcu. Change-Id: I096a3bb44a65533b9e9b091925dd5f70a8696d6 --- src/gprs_rlcmac_sched.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/gprs_rlcmac_sched.cpp') diff --git a/src/gprs_rlcmac_sched.cpp b/src/gprs_rlcmac_sched.cpp index f4860758..a3723df3 100644 --- a/src/gprs_rlcmac_sched.cpp +++ b/src/gprs_rlcmac_sched.cpp @@ -72,7 +72,8 @@ static uint32_t sched_poll(BTS *bts, *poll_tbf = dl_tbf; if (dl_tbf->dl_ass_state == GPRS_RLCMAC_DL_ASS_SEND_ASS) *dl_ass_tbf = dl_tbf; - if (dl_tbf->ul_ass_state == GPRS_RLCMAC_UL_ASS_SEND_ASS) + if (dl_tbf->ul_ass_state == GPRS_RLCMAC_UL_ASS_SEND_ASS + || dl_tbf->ul_ass_state == GPRS_RLCMAC_UL_ASS_SEND_ASS_REJ) *ul_ass_tbf = dl_tbf; } @@ -137,7 +138,11 @@ static struct msgb *sched_select_ctrl_msg( */ if (tbf == ul_ass_tbf && tbf->direction == GPRS_RLCMAC_DL_TBF) - msg = ul_ass_tbf->create_ul_ass(fn, ts); + if (tbf->ul_ass_state == + GPRS_RLCMAC_UL_ASS_SEND_ASS_REJ) + msg = ul_ass_tbf->create_packet_access_reject(); + else + msg = ul_ass_tbf->create_ul_ass(fn, ts); else if (tbf == dl_ass_tbf && tbf->direction == GPRS_RLCMAC_UL_TBF) msg = dl_ass_tbf->create_dl_ass(fn, ts); else if (tbf == ul_ack_tbf) -- cgit v1.2.3