Commit 0f42c092 authored by winckel's avatar winckel

Fixed an issue with long BSR.

Fixed some warnings.

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@4840 818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent d365405a
...@@ -1124,7 +1124,7 @@ void init_ue_sched_info(void); ...@@ -1124,7 +1124,7 @@ void init_ue_sched_info(void);
void add_ue_ulsch_info(u8 Mod_id, u8 UE_id, u8 subframe,UE_ULSCH_STATUS status); void add_ue_ulsch_info(u8 Mod_id, u8 UE_id, u8 subframe,UE_ULSCH_STATUS status);
void add_ue_dlsch_info(u8 Mod_id, u8 UE_id, u8 subframe,UE_DLSCH_STATUS status); void add_ue_dlsch_info(u8 Mod_id, u8 UE_id, u8 subframe,UE_DLSCH_STATUS status);
s8 find_UE_id(u8 Mod_id,u16 rnti) ; s8 find_UE_id(u8 Mod_id,u16 rnti) ;
s16 find_UE_RNTI(u8 Mod_id, u8 UE_id); u16 find_UE_RNTI(u8 Mod_id, u8 UE_id);
s8 find_active_UEs(u8 Mod_id); s8 find_active_UEs(u8 Mod_id);
u8 is_UE_active(unsigned char Mod_id, unsigned char UE_id ); u8 is_UE_active(unsigned char Mod_id, unsigned char UE_id );
u16 find_ulgranted_UEs(u8 Mod_id); u16 find_ulgranted_UEs(u8 Mod_id);
......
...@@ -307,7 +307,7 @@ s8 find_UE_id(unsigned char Mod_id,u16 rnti) { ...@@ -307,7 +307,7 @@ s8 find_UE_id(unsigned char Mod_id,u16 rnti) {
} }
s16 find_UE_RNTI(unsigned char Mod_id, unsigned char UE_id) { u16 find_UE_RNTI(unsigned char Mod_id, unsigned char UE_id) {
return (eNB_mac_inst[Mod_id].UE_template[UE_id].rnti); return (eNB_mac_inst[Mod_id].UE_template[UE_id].rnti);
...@@ -472,14 +472,14 @@ unsigned char *parse_ulsch_header(unsigned char *mac_header, ...@@ -472,14 +472,14 @@ unsigned char *parse_ulsch_header(unsigned char *mac_header,
length -= rx_lengths[num_sdu_cnt]; length -= rx_lengths[num_sdu_cnt];
} }
else { else {
if (((SCH_SUBHEADER_SHORT *)mac_header_ptr)->F == 0) { if (((SCH_SUBHEADER_SHORT *)mac_header_ptr)->F == 0) {
length = ((SCH_SUBHEADER_SHORT *)mac_header_ptr)->L; length = ((SCH_SUBHEADER_SHORT *)mac_header_ptr)->L;
mac_header_ptr += 2;//sizeof(SCH_SUBHEADER_SHORT); mac_header_ptr += 2;//sizeof(SCH_SUBHEADER_SHORT);
} }
else { // F = 1 else { // F = 1
length = ((((SCH_SUBHEADER_LONG *)mac_header_ptr)->L_MSB & 0x7f ) << 8 ) | (((SCH_SUBHEADER_LONG *)mac_header_ptr)->L_LSB & 0xff); length = ((((SCH_SUBHEADER_LONG *)mac_header_ptr)->L_MSB & 0x7f ) << 8 ) | (((SCH_SUBHEADER_LONG *)mac_header_ptr)->L_LSB & 0xff);
mac_header_ptr += 3;//sizeof(SCH_SUBHEADER_LONG); mac_header_ptr += 3;//sizeof(SCH_SUBHEADER_LONG);
} }
} }
LOG_D(MAC,"[eNB] sdu %d lcid %d tb_length %d length %d (offset now %d)\n", LOG_D(MAC,"[eNB] sdu %d lcid %d tb_length %d length %d (offset now %d)\n",
num_sdus,lcid,tb_length, length,mac_header_ptr-mac_header); num_sdus,lcid,tb_length, length,mac_header_ptr-mac_header);
...@@ -573,6 +573,7 @@ void rx_sdu(u8 Mod_id,u32 frame,u16 rnti,u8 *sdu, u16 sdu_len) { ...@@ -573,6 +573,7 @@ void rx_sdu(u8 Mod_id,u32 frame,u16 rnti,u8 *sdu, u16 sdu_len) {
eNB_mac_inst[Mod_id].UE_template[UE_id].bsr_info[LCGID1], eNB_mac_inst[Mod_id].UE_template[UE_id].bsr_info[LCGID1],
eNB_mac_inst[Mod_id].UE_template[UE_id].bsr_info[LCGID2], eNB_mac_inst[Mod_id].UE_template[UE_id].bsr_info[LCGID2],
eNB_mac_inst[Mod_id].UE_template[UE_id].bsr_info[LCGID3]); eNB_mac_inst[Mod_id].UE_template[UE_id].bsr_info[LCGID3]);
payload_ptr += 3;////sizeof(LONG_BSR);
break; break;
default: default:
LOG_E(MAC, "[eNB] Received unknown MAC header (0x%02x)\n", rx_ces[i]); LOG_E(MAC, "[eNB] Received unknown MAC header (0x%02x)\n", rx_ces[i]);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment