X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=src%2F5gnrmac%2Fmac_utils.c;h=91f421c38083ef33e1f1e4ee1310d73952096f93;hb=9f07d42c8d327e4009833fc4c673e4086c4e726e;hp=c661f02af02461cba1718f250c04f77359b16373;hpb=fe5d6711157dc1d3308a9754893b58b3872cd81a;p=o-du%2Fl2.git diff --git a/src/5gnrmac/mac_utils.c b/src/5gnrmac/mac_utils.c index c661f02af..91f421c38 100644 --- a/src/5gnrmac/mac_utils.c +++ b/src/5gnrmac/mac_utils.c @@ -64,39 +64,6 @@ uint32_t longBsrBytesTable[MAX_LONG_BSR_TABLE_ENTRIES] = { /* TODO Last Buffer Size is reserved [Now set as 0]*/ }; -/******************************************************************* - * - * @brief Allocates a crnti for new UE - * - * @details - * - * Function : getNewCrnti - * - * Functionality: Allocates a crnti for new UE - * - * @params[in] CRNTI bit map - * @return ROK - success - * RFAILED - failure - * - * ****************************************************************/ -uint16_t getNewCrnti(uint8_t *crntiMap) -{ - uint8_t bitIdx = 0; /* bit position */ - uint8_t mask = 1; /* bit mask */ - uint16_t newCrnti; /* new crnti */ - - while(bitIdx < 8) - { - /* Find the first unset bit in crntiMap and allocate - * this as new crnti */ - if((*crntiMap & (mask << bitIdx)) == 0) - { - newCrnti = ODU_START_CRNTI + bitIdx; - SET_ONE_BIT(bitIdx, *crntiMap); - return newCrnti; - } - else - bitIdx++; - } - return -1; -} +/********************************************************************** + End of file + **********************************************************************/