- Fix some more compiler warnings
Pre-ci tests passed git-svn-id: http://svn.eurecom.fr/openair4G/trunk@4389 818b1a75-f10b-46b9-bf7c-635c3b92a50f
This commit is contained in:
@@ -139,4 +139,6 @@
|
||||
#define printk printf
|
||||
#endif
|
||||
|
||||
#endif
|
||||
#define UNUSED_VARIABLE(vARIABLE) (void)(vARIABLE)
|
||||
|
||||
#endif /* __PLATFORM_CONSTANTS_H__ */
|
||||
|
||||
@@ -9,9 +9,8 @@
|
||||
#ifndef __PLATFORM_TYPES_H__
|
||||
# define __PLATFORM_TYPES_H__
|
||||
|
||||
#ifndef USER_MODE
|
||||
#else
|
||||
#include "openair_types.h"
|
||||
#ifdef USER_MODE
|
||||
# include "openair_types.h"
|
||||
#endif
|
||||
|
||||
typedef unsigned char u8_t;
|
||||
|
||||
@@ -229,11 +229,9 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){
|
||||
s32 frame_diff=0;
|
||||
mac_rlc_status_resp_t rlc_status;
|
||||
u8 dcch_header_len=0;
|
||||
u8 dcch_header_len_tmp=0;
|
||||
u16 sdu_lengths[8];
|
||||
u8 sdu_lcids[8],payload_offset=0,num_sdus=0;
|
||||
u8 sdu_lcids[8];
|
||||
u8 ulsch_buff[MAX_ULSCH_PAYLOAD_BYTES];
|
||||
u16 sdu_length_total=0;
|
||||
|
||||
if (UE_mode == PRACH) {
|
||||
if (UE_mac_inst[Mod_id].radioResourceConfigCommon)
|
||||
@@ -313,11 +311,9 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){
|
||||
DCCH,
|
||||
(char *)&ulsch_buff[0]);
|
||||
|
||||
sdu_length_total = sdu_lengths[0];
|
||||
sdu_lcids[0] = DCCH;
|
||||
|
||||
LOG_D(MAC,"[UE %d] TX Got %d bytes for DCCH\n",Mod_id,sdu_lengths[0]);
|
||||
num_sdus = 1;
|
||||
update_bsr(Mod_id, frame, DCCH,UE_mac_inst[Mod_id].scheduling_info.LCGID[DCCH]);
|
||||
//header_len +=2;
|
||||
UE_mac_inst[Mod_id].RA_active = 1;
|
||||
|
||||
@@ -113,7 +113,11 @@ int set_gateway(char *interfaceName, char *gateway)
|
||||
|
||||
rt.rt_dev = interfaceName;
|
||||
//rt.rt_flags = RTF_UP|RTF_GATEWAY|RTF_DEFAULT;
|
||||
rt.rt_flags = RTF_GATEWAY|RTF_DEFAULT;
|
||||
/* SR: rt_flags on 16 bits but RTF_DEFAULT = 0x00010000
|
||||
* therefore doesn't lie in container -> disable it
|
||||
*/
|
||||
//rt.rt_flags = RTF_GATEWAY|RTF_DEFAULT;
|
||||
rt.rt_flags = RTF_GATEWAY;
|
||||
|
||||
if (ioctl(sock_fd, SIOCADDRT, &rt) < 0)
|
||||
{
|
||||
|
||||
@@ -16,7 +16,6 @@
|
||||
|
||||
|
||||
void job_list_init (Job_List * listP) {
|
||||
int i = 0;
|
||||
|
||||
listP->tail = NULL;
|
||||
listP->head = NULL;
|
||||
@@ -24,7 +23,6 @@ void job_list_init (Job_List * listP) {
|
||||
}
|
||||
|
||||
void event_list_init (Event_List * listP) {
|
||||
int i = 0;
|
||||
|
||||
listP->tail = NULL;
|
||||
listP->head = NULL;
|
||||
@@ -32,7 +30,6 @@ void event_list_init (Event_List * listP) {
|
||||
}
|
||||
|
||||
void pkt_list_init (Packet_OTG_List * listP) {
|
||||
int i = 0;
|
||||
|
||||
listP->tail = NULL;
|
||||
listP->head = NULL;
|
||||
|
||||
@@ -47,6 +47,8 @@
|
||||
#include "client_traci_OMG.h"
|
||||
#include "TraCIConstants.h"
|
||||
|
||||
#define UNUSED_VARIABLE(vARIABLE) (void)(vARIABLE)
|
||||
|
||||
int handshake(char *hoststr,int portno){
|
||||
|
||||
check_endianness(); // check endianness
|
||||
@@ -140,13 +142,17 @@ void processSubscriptions() {
|
||||
}
|
||||
char *objID = readString();
|
||||
int varNo = readUnsignedByte();
|
||||
|
||||
|
||||
UNUSED_VARIABLE(objID);
|
||||
UNUSED_VARIABLE(respStart);
|
||||
|
||||
int i;
|
||||
for (i=0; i<varNo; ++i) {
|
||||
int varID = readUnsignedByte();
|
||||
|
||||
bool ok = readUnsignedByte()==RTYPE_OK;
|
||||
int valueDataType = readUnsignedByte();
|
||||
UNUSED_VARIABLE(valueDataType);
|
||||
if (ok&&cmdId==CMD_SUBSCRIBE_SIM_VARIABLE+0x10&&varID==VAR_DEPARTED_VEHICLES_IDS) {
|
||||
tmp_departed = readStringList(tmp_departed);
|
||||
//printf(" OMG Got departed cars\n");
|
||||
@@ -176,7 +182,7 @@ int extractCommandStatus(storage *s, unsigned char commandId, char * description
|
||||
|
||||
// tracker currently points to the begining of the recieved data in the linked list
|
||||
tracker = s;
|
||||
storage *freeTracker = tracker; // save it for calling free
|
||||
// storage *freeTracker = tracker; // save it for calling free
|
||||
|
||||
int commandLength = readUnsignedByte();
|
||||
|
||||
@@ -210,8 +216,11 @@ int extractCommandStatus(storage *s, unsigned char commandId, char * description
|
||||
//free actual message content
|
||||
//depends on the message which is handled
|
||||
|
||||
/* if (commandId != CMD_GET_VEHICLE_VARIABLE)
|
||||
freeStorage(freeTracker);*/
|
||||
/* if (commandId != CMD_GET_VEHICLE_VARIABLE)
|
||||
freeStorage(freeTracker);*/
|
||||
|
||||
UNUSED_VARIABLE(commandLength);
|
||||
UNUSED_VARIABLE(storageLength_);
|
||||
|
||||
return success;
|
||||
}
|
||||
@@ -312,6 +321,10 @@ void commandGetVehicleVariable(char *vehID, int varID)// malloc for vehID and va
|
||||
char* rs = readString();
|
||||
|
||||
int valueDataType = readUnsignedByte();
|
||||
UNUSED_VARIABLE(VariableID);
|
||||
UNUSED_VARIABLE(rs);
|
||||
UNUSED_VARIABLE(valueDataType);
|
||||
UNUSED_VARIABLE(domID);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -375,6 +388,12 @@ int commandGetMaxSUMONodesVariable()
|
||||
else {
|
||||
//LOG_W(OMG, " No Matching Data Type Value \n");
|
||||
}
|
||||
UNUSED_VARIABLE(res);
|
||||
UNUSED_VARIABLE(Length);
|
||||
UNUSED_VARIABLE(flag);
|
||||
UNUSED_VARIABLE(dom);
|
||||
UNUSED_VARIABLE(domID);
|
||||
UNUSED_VARIABLE(VariableID);
|
||||
}
|
||||
|
||||
return max_car;
|
||||
|
||||
@@ -121,13 +121,11 @@ Job_list quick_sort (Job_list list)
|
||||
|
||||
|
||||
Job_list remove_job(Job_list list, int nID, int node_type){
|
||||
|
||||
int found;
|
||||
|
||||
Job_list current, previous;
|
||||
//int cond=0;
|
||||
int i=0;
|
||||
if (list == NULL){
|
||||
found = 1; //false
|
||||
if (list == NULL){
|
||||
return NULL;
|
||||
}
|
||||
else{ //start search
|
||||
@@ -153,12 +151,10 @@ Job_list remove_job(Job_list list, int nID, int node_type){
|
||||
//if (current->pair->b->type == node_type){LOG_D(OMG, "current->pair->b->type == node_type");}
|
||||
|
||||
if (current ==NULL) {
|
||||
found= 1 ;
|
||||
LOG_D(OMG," Job to remove is not found\n "); //LOG_N
|
||||
return NULL;
|
||||
} //value not found
|
||||
else{
|
||||
found = 0; // true value found
|
||||
if (current == list) {
|
||||
list = current->next ;
|
||||
LOG_D(OMG,"Job to remove is found at the beginning\n");
|
||||
|
||||
@@ -69,8 +69,6 @@ int otg_rx_pkt( int src, int dst, int ctime, char *buffer_tx, unsigned int size)
|
||||
unsigned int seq_num_rx;
|
||||
unsigned int nb_loss_pkts;
|
||||
unsigned int lost_packet=0;
|
||||
unsigned int i;
|
||||
char * hdr_payload=NULL;
|
||||
//int header_size;
|
||||
|
||||
if (buffer_tx!=NULL) {
|
||||
|
||||
Reference in New Issue
Block a user