From 27b5ae1bc3325c7457514b110ed1a0b56f665ccc Mon Sep 17 00:00:00 2001 From: winckel <winckel@eurecom.fr> Date: Mon, 18 Nov 2013 08:03:40 +0000 Subject: [PATCH] Fixed some warnings. pre-ci ok. git-svn-id: http://svn.eurecom.fr/openair4G/trunk@4423 818b1a75-f10b-46b9-bf7c-635c3b92a50f --- openair2/LAYER2/MAC/eNB_scheduler.c | 6 +++--- openair2/LAYER2/MAC/ue_procedures.c | 2 +- openair2/UTIL/OTG/otg_tx.c | 2 +- openair2/UTIL/OTG/otg_tx.h | 12 ++++++++++++ targets/SIMU/USER/oaisim_config.c | 3 +-- 5 files changed, 18 insertions(+), 7 deletions(-) diff --git a/openair2/LAYER2/MAC/eNB_scheduler.c b/openair2/LAYER2/MAC/eNB_scheduler.c index a9b3a2f858..d2008436fc 100644 --- a/openair2/LAYER2/MAC/eNB_scheduler.c +++ b/openair2/LAYER2/MAC/eNB_scheduler.c @@ -1374,7 +1374,7 @@ int schedule_MBMS(unsigned char Mod_id,u32 frame, u8 subframe) { mcch_sdu_length = mac_rrc_data_req(Mod_id, frame, MCCH,1, - (char*)&eNB_mac_inst[Mod_id].MCCH_pdu.payload[0], + &eNB_mac_inst[Mod_id].MCCH_pdu.payload[0], 1,// this is eNB Mod_id, // index i); // this is the mbsfn sync area index @@ -1502,7 +1502,7 @@ int schedule_MBMS(unsigned char Mod_id,u32 frame, u8 subframe) { sdu_lengths, sdu_lcids, 255, // no drx - NULL, // no timing advance + 0, // no timing advance NULL, // no contention res id padding, post_padding); @@ -1525,7 +1525,7 @@ int schedule_MBMS(unsigned char Mod_id,u32 frame, u8 subframe) { #if defined(USER_MODE) && defined(OAI_EMU) /* Tracing of PDU is done on UE side */ if (oai_emulation.info.opt_enabled) - trace_pdu(1, (uint8_t *)eNB_mac_inst[Mod_id].MCH_pdu.payload[0], + trace_pdu(1, (uint8_t *)eNB_mac_inst[Mod_id].MCH_pdu.payload, TBS, Mod_id, 6, 0xffff, // M_RNTI = 6 in wirehsark eNB_mac_inst[Mod_id].subframe,0,0); LOG_D(OPT,"[eNB %d][MCH] Frame %d : MAC PDU with size %d\n", diff --git a/openair2/LAYER2/MAC/ue_procedures.c b/openair2/LAYER2/MAC/ue_procedures.c index ed6a749e42..97f3d38bd6 100644 --- a/openair2/LAYER2/MAC/ue_procedures.c +++ b/openair2/LAYER2/MAC/ue_procedures.c @@ -502,7 +502,7 @@ void ue_send_mch_sdu(u8 Mod_id, u32 frame, u8 *sdu, u16 sdu_len, u8 eNB_index, u mac_rrc_data_ind(Mod_id, frame, MCCH, - (char *)payload_ptr, rx_lengths[i], 0, eNB_index, sync_area); + payload_ptr, rx_lengths[i], 0, eNB_index, sync_area); } else if (rx_lcids[i] == MTCH) { if (UE_mac_inst[Mod_id].msi_status==1) { diff --git a/openair2/UTIL/OTG/otg_tx.c b/openair2/UTIL/OTG/otg_tx.c index 2aaf7693f7..dbec0d1ae9 100644 --- a/openair2/UTIL/OTG/otg_tx.c +++ b/openair2/UTIL/OTG/otg_tx.c @@ -298,7 +298,7 @@ Send Packets when: } -unsigned char *packet_gen_multicast(int src, int dst, int ctime, int * pkt_size){ +unsigned char *packet_gen_multicast(int src, int dst, int ctime, unsigned int * pkt_size){ *pkt_size =0; unsigned int size=0; diff --git a/openair2/UTIL/OTG/otg_tx.h b/openair2/UTIL/OTG/otg_tx.h index 6642c5f522..725c959810 100644 --- a/openair2/UTIL/OTG/otg_tx.h +++ b/openair2/UTIL/OTG/otg_tx.h @@ -96,6 +96,17 @@ char * random_string(int size, ALPHABET_GEN mode, ALPHABET_TYPE data_type); */ unsigned char *packet_gen(int src, int dst, int app, int ctime, unsigned int *pkt_size); +/*! \fn int packet_gen(int src, int dst, int state, int ctime) +* \brief return int= 1 if the packet is generated: OTG header + header + payload, else 0 +* \param[in] src source identity +* \param[in] dst destination id +* \param[in] application id that might generate the packet +* \param[out] final packet size +* \param[out] packet_t: the generated packet: otg_header + header + payload +* \note +* @ingroup _otg +*/ +unsigned char *packet_gen_multicast(int src, int dst, int ctime, unsigned int * pkt_size); /*! \fn char *header_gen(int hdr_size); * \brief generate IP (v4/v6) + transport header(TCP/UDP) @@ -155,6 +166,7 @@ int adjust_size(int size); */ void header_size_gen(int src, int dst, int application); +void init_predef_multicast_traffic(); /*! \fn void init_predef_traffic(); * \brief initialise OTG with predifined value for pre-configured traffic: cbr, openarena,etc. diff --git a/targets/SIMU/USER/oaisim_config.c b/targets/SIMU/USER/oaisim_config.c index 575c1b30f8..2ee2247a3f 100644 --- a/targets/SIMU/USER/oaisim_config.c +++ b/targets/SIMU/USER/oaisim_config.c @@ -12,7 +12,7 @@ #include "UTIL/OTG/otg_tx.h" #include "UTIL/OTG/otg.h" #include "UTIL/OTG/otg_vars.h" - +#include "oml.h" mapping log_level_names[] = { @@ -600,7 +600,6 @@ int ocg_config_app(){ char *check_format1; char *check_format2; char *check_format1_dst; - char *check_format2_dst; char *source_id_start; char *source_id_end; char *destination_id_start; -- GitLab