Commit 356785af authored by Cedric Roux's avatar Cedric Roux

- Fixed some more compiler warnings

pre-ci tests passed

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@4401 818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent 64c5020b
......@@ -86,6 +86,11 @@ int lte_dl_msbfn_channel_estimation(PHY_VARS_UE *phy_vars_ue,
unsigned char l,
unsigned char symbol);
int lte_dl_mbsfn_channel_estimation(PHY_VARS_UE *phy_vars_ue,
u8 eNB_id,
u8 eNB_offset,
int subframe,
unsigned char l);
/*
#ifdef EMOS
......
......@@ -81,7 +81,10 @@ int generate_pbch(LTE_eNB_PBCH *eNB_pbch,
u8 RCC;
u32 nsymb = (frame_parms->Ncp==NORMAL) ? 14:12;
u32 pilots,pilots_2;
u32 pilots;
#ifdef INTERFERENCE_MITIGATION
u32 pilots_2;
#endif
u32 second_pilot = (frame_parms->Ncp==NORMAL) ? 4 : 3;
u32 jj=0;
u32 re_allocated=0;
......@@ -230,10 +233,14 @@ int generate_pbch(LTE_eNB_PBCH *eNB_pbch,
for (l=(nsymb>>1);l<(nsymb>>1)+4;l++) {
pilots=0;
#ifdef INTERFERENCE_MITIGATION
pilots_2 = 0;
#endif
if ((l==0) || (l==(nsymb>>1))){
pilots=1;
#ifdef INTERFERENCE_MITIGATION
pilots_2=1;
#endif
}
if ((l==1) || (l==(nsymb>>1)+1)){
......
......@@ -625,7 +625,8 @@ void mch_64qam_llr(LTE_DL_FRAME_PARMS *frame_parms,
__m128i xmm1,xmm2,*ch_mag,*ch_magb;
__m128i *rxF = (__m128i*)&rxdataF_comp[0][(symbol*frame_parms->N_RB_DL*12)];
int j=0,i,len,len2;
int i,len,len2;
// int j=0;
unsigned char len_mod4;
short *llr;
s16 *llr2;
......
......@@ -21,7 +21,7 @@ int slot_fep_mbsfn(PHY_VARS_UE *phy_vars_ue,
unsigned int nb_prefix_samples0 = frame_parms->ofdm_symbol_size>>2;//(no_prefix ? 0 : frame_parms->nb_prefix_samples0);
unsigned int subframe_offset;
int i;
// int i;
unsigned int frame_length_samples = frame_parms->samples_per_tti * 10;
void (*dft)(int16_t *,int16_t *, int);
......@@ -161,7 +161,7 @@ int slot_fep_mbsfn(PHY_VARS_UE *phy_vars_ue,
i+1,
subframe,
l);
/* lte_dl_channel_estimation(phy_vars_ue,eNB_id,0,
lte_dl_channel_estimation(phy_vars_ue,eNB_id,0,
Ns,
aa,
l,
......
......@@ -230,7 +230,6 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){
mac_rlc_status_resp_t rlc_status;
u8 dcch_header_len=0;
u16 sdu_lengths[8];
u8 sdu_lcids[8];
u8 ulsch_buff[MAX_ULSCH_PAYLOAD_BYTES];
if (UE_mode == PRACH) {
......@@ -310,8 +309,6 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){
sdu_lengths[0] = mac_rlc_data_req(Mod_id+NB_eNB_INST,frame,RLC_MBMS_NO,
DCCH,
(char *)&ulsch_buff[0]);
sdu_lcids[0] = DCCH;
LOG_D(MAC,"[UE %d] TX Got %d bytes for DCCH\n",Mod_id,sdu_lengths[0]);
update_bsr(Mod_id, frame, DCCH,UE_mac_inst[Mod_id].scheduling_info.LCGID[DCCH]);
......
......@@ -43,6 +43,9 @@
#include "UTIL/LOG/log.h"
#include "OCG.h"
#include "OCG_extern.h"
#if defined(USER_MODE) && defined(OAI_EMU)
# include "UTIL/OPT/opt.h"
#endif
#define DEBUG_RAR
......
......@@ -101,9 +101,12 @@ int pdcp_fifo_flush_sdus (u32_t frame,u8 eNB_flag)
int bytes_wrote = 0;
int pdcp_nb_sdu_sent = 0;
u8 cont = 1;
int ret;
int mcs_inst;
#if defined(NAS_NETLINK) && defined(LINUX)
int ret = 0;
#endif
while (sdu && cont) {
#if defined(OAI_EMU)
......@@ -701,6 +704,8 @@ void pdcp_fifo_read_input_sdus_from_otg (u32_t frame, u8_t eNB_flag, u8 UE_index
u8 pdcp_mode, is_ue=0;
Packet_otg_elt * otg_pkt_info;
src_id = eNB_index;
// we need to add conditions to avoid transmitting data when the UE is not RRC connected.
#if defined(USER_MODE) && defined(OAI_EMU)
if (oai_emulation.info.otg_enabled ==1 ){
......@@ -744,7 +749,6 @@ void pdcp_fifo_read_input_sdus_from_otg (u32_t frame, u8_t eNB_flag, u8 UE_index
#else
if ((otg_enabled==1) && (eNB_flag == 1)) { // generate DL traffic
unsigned int ctime=0;
src_id = eNB_index;
ctime = frame * 100;
/*if ((mac_get_rrc_status(eNB_index, eNB_flag, 0 ) > 2) &&
......
......@@ -68,7 +68,7 @@ static mapping rrc_status_names[] = {
int dump_eNB_l2_stats(char *buffer, int length){
u8 eNB_id,UE_id,lcid,i,j,number_of_cards;
u8 eNB_id,UE_id,number_of_cards;
int len= length;
#ifdef EXMIMO
......
......@@ -356,8 +356,8 @@ void logRecord(const char *file, const char *func, int line, int comp,
va_end(args);
//2 first parameters must be passed as 'const' to the thread function
log_params.file = file;
log_params.func = func;
log_params.file = strdup(file);
log_params.func = strdup(func);
log_params.line = line;
log_params.comp = comp;
log_params.level = level;
......
......@@ -179,11 +179,11 @@ int get_oai_entry(char *sumo_id, Map_list Map_Vector) {
Map_list remove_oai_entry(char *sumo_id, Map_list Map_Vector) {
Map_list tmp = Map_Vector;
Map_list entry;
// Map_list entry;
//printf("removing entry %s \n",sumo_id);
if (strcmp(tmp->map->sumo_id, sumo_id) == 0) {
//printf("1: found it %s \n",tmp->map->sumo_id);
int id = tmp->map->oai_id;
// int id = tmp->map->oai_id;
// free(tmp);
if(tmp->next == NULL)
return NULL;
......@@ -202,8 +202,8 @@ Map_list remove_oai_entry(char *sumo_id, Map_list Map_Vector) {
while (tmp->next != NULL){
if (strcmp(tmp->next->map->sumo_id, sumo_id) == 0) {
//printf("2: found it %s \n",tmp->next->map->sumo_id);
int id = tmp->next->map->oai_id;
entry = tmp->next; // save the entry to remove
// int id = tmp->next->map->oai_id;
// entry = tmp->next; // save the entry to remove
tmp->next = tmp->next->next; // jump over the entry to be removed
// free(entry); // freeing the entry
//if(strcmp(tmp->next->map->sumo_id, "0") == 0)
......
......@@ -148,7 +148,7 @@ storage * receiveExact(){
tracker = writePacket(bufLength, 4);
// store pointer to free the space later
storage *freeTracker = tracker;
// storage *freeTracker = tracker;
int s= readInt();
int NN = s - 4;
printf("debug \n");
......
......@@ -78,7 +78,7 @@ sprintf(sumo_line, "%s -c %s ",omg_param_list.sumo_command, omg_param_list.sumo_
arrived = NULL;
// switch on error to return to OAI
int error = handshake(omg_param_list.sumo_host,omg_param_list.sumo_port);
handshake(omg_param_list.sumo_host,omg_param_list.sumo_port);
init(omg_param_list.sumo_end - omg_param_list.sumo_start);
......
......@@ -50,7 +50,6 @@ extern hash_table_t* table;
int start_trace_generator(omg_global_param omg_param_list) {
NodePtr node = NULL;
// MobilityPtr mobility = NULL;
//read the mobility file here
......@@ -85,7 +84,7 @@ int deploy_nodes() {
NodePtr node = NULL;
int count = 0;
// int count = 0;
node_info * head_node = head_node_info;
while (head_node!=NULL){
......@@ -235,7 +234,7 @@ Pair move_trace_node(NodePtr node, double cur_time) {
return keep_awake_trace_node(node,cur_time,9999,1);
}
else{ // location discription available
Job_list tmp1 = Job_Vector;
// Job_list tmp1 = Job_Vector;
LOG_D(OMG, "Location fetch : (%.2f, %.2f)\n", next_loc->x, next_loc->y);
double X_next;
......
......@@ -56,7 +56,7 @@ This header file must be included */
#ifndef project_include
#define project_include
#include "UTIL/LOG/log_if.h"
#include "UTIL/LOG/log_extern.h"
// #include "UTIL/LOG/log_extern.h"
#include "PHY/defs.h"
#include "PHY/extern.h"
#include "PHY/impl_defs_lte.h"
......
#include "otg_form.h"
#include "otg_vars.h"
#include "otg_kpi.h"
extern unsigned char NB_eNB_INST;
extern unsigned char NB_UE_INST;
......@@ -150,7 +150,7 @@ if (otg_forms_info->idx_ul[src][dst]==MAX_SAMPLES-1){
nb_loss_pkts();
otg_kpi_nb_loss_pkts();
sprintf(loss_rate, "%s%d","NB Loss pkts UL=", otg_info->total_loss_ul);
fl_set_object_label(form_ul->loss_ratio, loss_rate);
sprintf(simu_time, "%s%d","Simulation Time(ms)=", ctime);
......@@ -170,7 +170,7 @@ if (otg_forms_info->idx_ul[src][dst]==MAX_SAMPLES-1){
fl_set_xyplot_key(form_ul->throughput, 0, curve_label);
fl_set_xyplot_key_position(form_ul->throughput, x_key_position,y_key_position , FL_ALIGN_BOTTOM_LEFT);
nb_loss_pkts();
otg_kpi_nb_loss_pkts();
sprintf(loss_rate, "%s%d","NB Loss pkts UL=",otg_info->total_loss_ul);
fl_set_object_label(form_ul->loss_ratio, loss_rate);
sprintf(simu_time, "%s%d","Simulation Time(ms)=", ctime);
......@@ -245,7 +245,7 @@ if (otg_forms_info->idx_dl[src][dst]==MAX_SAMPLES-1){
sprintf(curve_label, "%d%s%d", src,"-->", dst);
fl_set_xyplot_key(form_dl->throughput, 0, curve_label);
fl_set_xyplot_key_position(form_dl->throughput, x_key_position,y_key_position, FL_ALIGN_BOTTOM_LEFT);
nb_loss_pkts();
otg_kpi_nb_loss_pkts();
sprintf(loss_rate, "%s%d","NB Loss pkts DL=",otg_info->total_loss_dl);
fl_set_object_label(form_dl->loss_ratio, loss_rate);
......@@ -265,7 +265,7 @@ if (otg_forms_info->idx_dl[src][dst]==MAX_SAMPLES-1){
fl_set_xyplot_key(form_dl->throughput, 0, curve_label);
fl_set_xyplot_key_position(form_dl->throughput,x_key_position,y_key_position, FL_ALIGN_BOTTOM_LEFT);
nb_loss_pkts();
otg_kpi_nb_loss_pkts();
sprintf(loss_rate, "%s%d","NB Loss pkts DL=",otg_info->total_loss_dl);
fl_set_object_label(form_dl->loss_ratio, loss_rate);
sprintf(simu_time, "%s%d","Simulation Time(ms)=", ctime);
......
......@@ -122,7 +122,7 @@ void rx_loss_rate_bytes(int src, int dst, int application){
}
void nb_loss_pkts(){
void otg_kpi_nb_loss_pkts(void){
unsigned int i,j,k;
otg_info->total_loss_dl=0;
......
......@@ -105,6 +105,6 @@ void add_log_metric(int src, int dst, int ctime, double metric, unsigned int lab
void add_log_label(unsigned int label, unsigned int * start_log_metric);
void nb_loss_pkts();
void otg_kpi_nb_loss_pkts(void);
#endif
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