Commit c9dcaa53 authored by frtabu's avatar frtabu

noS1 woking with tun interfaces and basic simu

parent 17e36b3a
Pipeline #12216 failed with stage
in 0 seconds
......@@ -1287,7 +1287,7 @@ set(L2_SRC
${RLC_DIR}/rlc.c
${RLC_DIR}/rlc_rrc.c
${RLC_DIR}/rlc_mpls.c
${RRC_DIR}/rrc_UE.c
# ${RRC_DIR}/rrc_UE.c
${RRC_DIR}/rrc_eNB.c
${RRC_DIR}/rrc_eNB_S1AP.c
${RRC_DIR}/rrc_eNB_UE_context.c
......
......@@ -93,12 +93,12 @@ static int tun_alloc(char *dev) {
return fd;
}
int netlink_init_tun(void) {
int netlink_init_tun(char *ifprefix) {
int ret;
char ifname[64];
for (int i = 0; i < NUMBER_OF_UE_MAX; i++) {
sprintf(ifname, "oaitun_ue%d",i+1);
sprintf(ifname, "oaitun_%.3s%d",ifprefix,i+1);
nas_sock_fd[i] = tun_alloc(ifname);
if (nas_sock_fd[i] == -1) {
......
......@@ -62,6 +62,6 @@ int multicast_link_read_data_from_sock(uint8_t eNB_flag);
void clear_eNB_transport_info(uint8_t);
void clear_UE_transport_info(uint8_t);
int netlink_init(void);
int netlink_init_tun(void);
int netlink_init_tun(char *ifsuffix);
#endif /* EMU_PROTO_H_ */
......@@ -51,7 +51,7 @@
#include "targets/COMMON/openairinterface5g_limits.h"
#include "SIMULATION/ETH_TRANSPORT/proto.h"
#include "UTIL/OSA/osa_defs.h"
#include "openair2/RRC/NAS/nas_config.h"
# include "intertask_interface.h"
......@@ -1145,9 +1145,10 @@ pdcp_run (
} while(msg_p != NULL);
// IP/NAS -> PDCP traffic : TX, read the pkt from the upper layer buffer
if (LINK_ENB_PDCP_TO_GTPV1U && ctxt_pP->enb_flag == ENB_FLAG_NO) {
pdcp_fifo_read_input_sdus(ctxt_pP);
}
// if (LINK_ENB_PDCP_TO_GTPV1U && ctxt_pP->enb_flag == ENB_FLAG_NO) {
if (!EPC_MODE_ENABLED || ctxt_pP->enb_flag == ENB_FLAG_NO ) {
pdcp_fifo_read_input_sdus(ctxt_pP);
}
// PDCP -> NAS/IP traffic: RX
if (ctxt_pP->enb_flag) {
......@@ -2027,9 +2028,6 @@ rrc_pdcp_config_req (
}
}
//-----------------------------------------------------------------------------
uint64_t pdcp_module_init( uint64_t pdcp_optmask ) {
/* temporary enforce netlink when UE_NAS_USE_TUN is set,
this is while switching from noS1 as build option
......@@ -2045,8 +2043,14 @@ uint64_t pdcp_module_init( uint64_t pdcp_optmask ) {
if (PDCP_USE_NETLINK) {
if(UE_NAS_USE_TUN) {
netlink_init_tun();
netlink_init_tun("ue");
LOG_I(PDCP, "UE pdcp will use tun interface\n");
} else if(ENB_NAS_USE_TUN) {
netlink_init_tun("enb");
nas_config(1, 1, 1, "enb");
LOG_I(PDCP, "ENB pdcp will use tun interface\n");
} else {
LOG_I(PDCP, "pdcp will use kernel modules\n");
netlink_init();
}
}
......@@ -2054,6 +2058,7 @@ uint64_t pdcp_module_init( uint64_t pdcp_optmask ) {
return pdcp_params.optmask ;
}
//-----------------------------------------------------------------------------
void
pdcp_free (
......
......@@ -55,6 +55,7 @@
#define LINK_ENB_PDCP_TO_IP_DRIVER_BIT (1<< 13)
#define LINK_ENB_PDCP_TO_GTPV1U_BIT (1<< 14)
#define UE_NAS_USE_TUN_BIT (1<< 15)
#define ENB_NAS_USE_TUN_BIT (1<< 16)
typedef struct {
uint64_t optmask;
} pdcp_params_t;
......@@ -63,6 +64,7 @@ typedef struct {
#define LINK_ENB_PDCP_TO_IP_DRIVER ( get_pdcp_optmask() & LINK_ENB_PDCP_TO_IP_DRIVER_BIT)
#define LINK_ENB_PDCP_TO_GTPV1U ( get_pdcp_optmask() & LINK_ENB_PDCP_TO_GTPV1U_BIT)
#define UE_NAS_USE_TUN ( get_pdcp_optmask() & UE_NAS_USE_TUN_BIT)
#define ENB_NAS_USE_TUN ( get_pdcp_optmask() & ENB_NAS_USE_TUN_BIT)
uint64_t get_pdcp_optmask(void);
extern pthread_t pdcp_thread;
......
......@@ -125,7 +125,9 @@ int pdcp_fifo_flush_sdus(const protocol_ctxt_t *const ctxt_pP) {
sizeof(sidelink_pc5s_element), 0, (struct sockaddr *)&prose_pdcp_addr,sizeof(prose_pdcp_addr) );
} else if (UE_NAS_USE_TUN) {
ret = write(nas_sock_fd[ctxt_pP->module_id], &(sdu_p->data[sizeof(pdcp_data_ind_header_t)]),sizeToWrite );
} else if (PDCP_USE_NETLINK) {//UE_NAS_USE_TUN
} else if (ENB_NAS_USE_TUN) {
ret = write(nas_sock_fd[0], &(sdu_p->data[sizeof(pdcp_data_ind_header_t)]),sizeToWrite );
} else if (PDCP_USE_NETLINK) {
memcpy(NLMSG_DATA(nas_nlh_tx), (uint8_t *) sdu_p->data, sizeToWrite);
nas_nlh_tx->nlmsg_len = sizeToWrite;
ret = sendmsg(nas_sock_fd[0],&nas_msg_tx,0);
......@@ -143,8 +145,9 @@ int pdcp_fifo_flush_sdus(const protocol_ctxt_t *const ctxt_pP) {
//-----------------------------------------------------------------------------
int pdcp_fifo_read_input_sdus (const protocol_ctxt_t *const ctxt_pP) {
pdcp_data_req_header_t pdcp_read_header_g;
if (UE_NAS_USE_TUN) {
if (UE_NAS_USE_TUN || ENB_NAS_USE_TUN) {
protocol_ctxt_t ctxt = *ctxt_pP;
hash_key_t key = HASHTABLE_NOT_A_KEY_VALUE;
hashtable_rc_t h_rc;
......@@ -155,20 +158,31 @@ int pdcp_fifo_read_input_sdus (const protocol_ctxt_t *const ctxt_pP) {
do {
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_PDCP_FIFO_READ, 1 );
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_PDCP_FIFO_READ_BUFFER, 1 );
len = read(nas_sock_fd[ctxt_pP->module_id], &nl_rx_buf, NL_MAX_PAYLOAD);
len = read(UE_NAS_USE_TUN?nas_sock_fd[ctxt_pP->module_id]:nas_sock_fd[0], &nl_rx_buf, NL_MAX_PAYLOAD);
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_PDCP_FIFO_READ_BUFFER, 0 );
if (len<=0) continue;
LOG_D(PDCP, "PDCP_COLL_KEY_DEFAULT_DRB_VALUE(module_id=%d, rnti=%x, enb_flag=%d)\n",
if (UE_NAS_USE_TUN) {
key = PDCP_COLL_KEY_DEFAULT_DRB_VALUE(ctxt.module_id, ctxt.rnti, ctxt.enb_flag);
h_rc = hashtable_get(pdcp_coll_p, key, (void **)&pdcp_p);
} else {
ctxt.rnti=pdcp_eNB_UE_instance_to_rnti[0];
ctxt.enb_flag=ENB_FLAG_YES;
ctxt.module_id=0;
key = PDCP_COLL_KEY_VALUE(ctxt.module_id, ctxt.rnti, ctxt.enb_flag, rab_id, SRB_FLAG_YES);
h_rc = hashtable_get(pdcp_coll_p, key, (void **)&pdcp_p);
}
LOG_D(PDCP, "PDCP_COLL_KEY_DEFAULT_DRB_VALUE(module_id=%d, rnti=%x, enb_flag=%d)\n",
ctxt.module_id, ctxt.rnti, ctxt.enb_flag);
key = PDCP_COLL_KEY_DEFAULT_DRB_VALUE(ctxt.module_id, ctxt.rnti, ctxt.enb_flag);
h_rc = hashtable_get(pdcp_coll_p, key, (void **)&pdcp_p);
if (h_rc == HASH_TABLE_OK) {
LOG_D(PDCP, "[FRAME %5u][UE][NETLINK][IP->PDCP] INST %d: Received socket with length %d on Rab %d \n",
ctxt.frame, ctxt.instance, len, rab_id);
LOG_D(PDCP, "[FRAME %5u][UE][IP][INSTANCE %u][RB %u][--- PDCP_DATA_REQ / %d Bytes --->][PDCP][MOD %u][UE %u][RB %u]\n",
LOG_D(PDCP, "[FRAME %5u][UE][IP][INSTANCE %u][RB %u][--- PDCP_DATA_REQ / %d Bytes --->][PDCP][MOD %u][UE %04x][RB %u]\n",
ctxt.frame, ctxt.instance, rab_id, len, ctxt.module_id,
ctxt.rnti, rab_id);
MSC_LOG_RX_MESSAGE((ctxt_pP->enb_flag == ENB_FLAG_YES) ? MSC_PDCP_ENB:MSC_PDCP_UE,
......@@ -192,7 +206,7 @@ int pdcp_fifo_read_input_sdus (const protocol_ctxt_t *const ctxt_pP) {
MSC_AS_TIME_ARGS(ctxt_pP),
ctxt.instance, rab_id, rab_id, len);
LOG_D(PDCP,
"[FRAME %5u][UE][IP][INSTANCE %u][RB %u][--- PDCP_DATA_REQ / %d Bytes ---X][PDCP][MOD %u][UE %u][RB %u] NON INSTANCIATED INSTANCE key 0x%"PRIx64", DROPPED\n",
"[FRAME %5u][UE][IP][INSTANCE %u][RB %u][--- PDCP_DATA_REQ / %d Bytes ---X][PDCP][MOD %u][UE %04x][RB %u] NON INSTANCIATED INSTANCE key 0x%"PRIx64", DROPPED\n",
ctxt.frame, ctxt.instance, rab_id, len, ctxt.module_id,
ctxt.rnti, rab_id, key);
}
......
......@@ -584,14 +584,14 @@ void rlc_data_ind (
const sdu_size_t sdu_sizeP,
mem_block_t *sdu_pP) {
//-----------------------------------------------------------------------------
#if defined(TRACE_RLC_PAYLOAD)
LOG_D(RLC, PROTOCOL_CTXT_FMT"[%s %u] Display of rlc_data_ind: size %u\n",
PROTOCOL_CTXT_ARGS(ctxt_pP),
(srb_flagP) ? "SRB" : "DRB",
rb_idP,
sdu_sizeP);
rlc_util_print_hex_octets(RLC, (unsigned char *)sdu_pP->data, sdu_sizeP);
#endif
#if T_TRACER
if (ctxt_pP->enb_flag)
......
......@@ -810,18 +810,18 @@ rrc_ue_establish_drb(
(eNB_index * NB_RB_MAX) + *DRB_config->logicalChannelIdentity,
RADIO_ACCESS_BEARER,Rlc_info_um);
*/
if(!EPC_MODE_ENABLED) {
// if(!EPC_MODE_ENABLED) {
//# if !defined(OAI_NW_DRIVER_TYPE_ETHERNET) && !defined(EXMIMO) && !defined(OAI_USRP) && !defined(OAI_BLADERF) && !defined(ETHERNET) && !defined(LINK_ENB_PDCP_TO_GTPV1U)
ip_addr_offset3 = 0;
ip_addr_offset4 = 1;
LOG_I(OIP,"[UE %d] trying to bring up the OAI interface oai%d, IP 10.0.%d.%d\n", ue_mod_idP, ip_addr_offset3+ue_mod_idP,
LOG_I(OIP,"[UE %d] trying to bring up the OAI interface oip%d, IP 10.0.%d.%d\n", ue_mod_idP, ip_addr_offset3+ue_mod_idP,
ip_addr_offset3+ue_mod_idP+1,ip_addr_offset4+ue_mod_idP+1);
oip_ifup=nas_config(ip_addr_offset3+ue_mod_idP+1, // interface_id
ip_addr_offset3+ue_mod_idP+1, // third_octet
ip_addr_offset4+ue_mod_idP+1, // fourth_octet
"ue"); // interface suffix
"oip"); // interface suffix
if (oip_ifup == 0 && (!IS_SOFTMODEM_NOKRNMOD)) { // interface is up --> send a config the DRB
if (oip_ifup == 0 && (!UE_NAS_USE_TUN)) { // interface is up --> send a config the DRB
LOG_I(OIP,"[UE %d] Config the ue net interface %d to send/receive pkt on DRB %ld to/from the protocol stack\n",
ue_mod_idP,
ip_addr_offset3+ue_mod_idP,
......@@ -837,7 +837,7 @@ rrc_ue_establish_drb(
}
//# endif
}
// }
return(0);
}
......
......@@ -6150,9 +6150,6 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete(
int i, drb_id;
int oip_ifup = 0;
int dest_ip_offset = 0;
/* avoid gcc warnings */
(void)oip_ifup;
(void)dest_ip_offset;
uint8_t *kRRCenc = NULL;
uint8_t *kRRCint = NULL;
uint8_t *kUPenc = NULL;
......@@ -6272,10 +6269,7 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete(
LOG_D(RRC,
"[eNB %d] Frame %d: Establish RLC UM Bidirectional, DRB %d Active\n",
ctxt_pP->module_id, ctxt_pP->frame, (int)DRB_configList->list.array[i]->drb_Identity);
if (!EPC_MODE_ENABLED) {
// if (PDCP_USE_NETLINK && (!LINK_ENB_PDCP_TO_GTPV1U)) {
// can mean also IPV6 since ether -> ipv6 autoconf
//# if !defined(OAI_NW_DRIVER_TYPE_ETHERNET) && !defined(EXMIMO) && !defined(OAI_USRP) && !defined(OAI_BLADERF) && !defined(ETHERNET)
if (!EPC_MODE_ENABLED && !ENB_NAS_USE_TUN) {
LOG_I(OIP, "[eNB %d] trying to bring up the OAI interface oai%d\n",
ctxt_pP->module_id,
ctxt_pP->module_id);
......@@ -6283,7 +6277,7 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete(
ctxt_pP->module_id, // interface index
ctxt_pP->module_id + 1, // thrid octet
ctxt_pP->module_id + 1, // fourth octet
"enb");
"oai");
if (oip_ifup == 0) { // interface is up --> send a config the DRB
module_id_t ue_module_id;
dest_ip_offset = 8;
......@@ -6301,10 +6295,8 @@ rrc_eNB_process_RRCConnectionReconfigurationComplete(
ipv4_address(ctxt_pP->module_id + 1, dest_ip_offset + ue_module_id + 1)); //daddr
LOG_D(RRC, "[eNB %d] State = Attached (UE rnti %x module id %u)\n",
ctxt_pP->module_id, ue_context_pP->ue_context.rnti, ue_module_id);
}
//# endif
}
} /* oip_ifup */
} /* !EPC_MODE_ENABLED && ENB_NAS_USE_TUN*/
LOG_D(RRC,
PROTOCOL_RRC_CTXT_UE_FMT" RRC_eNB --- MAC_CONFIG_REQ (DRB) ---> MAC_eNB\n",
......
......@@ -236,7 +236,7 @@ int NAS_config(char *interfaceName, char *ipAddress, char *networkMask, char *br
}
// non blocking full configuration of the interface (address, and the two lest octets of the address)
int nas_config(int interface_id, int thirdOctet, int fourthOctet, char *ifsuffix)
int nas_config(int interface_id, int thirdOctet, int fourthOctet, char *ifname)
{
//char buf[5];
char ipAddress[20];
......@@ -248,8 +248,8 @@ int nas_config(int interface_id, int thirdOctet, int fourthOctet, char *ifsuffix
sprintf(broadcastAddress, "10.0.%d.255", thirdOctet);
sprintf(interfaceName, "%s%s%d", UE_NAS_USE_TUN?"oaitun_":"oip",
UE_NAS_USE_TUN?ifsuffix:"",interface_id);
sprintf(interfaceName, "%s%s%d", (UE_NAS_USE_TUN || ENB_NAS_USE_TUN)?"oaitun_":ifname,
UE_NAS_USE_TUN?"ue": (ENB_NAS_USE_TUN?"enb":""),interface_id);
bringInterfaceUp(interfaceName, 0);
// sets the machine address
......
......@@ -653,9 +653,12 @@ int main( int argc, char **argv ) {
LOG_I(HW, "Version: %s\n", PACKAGE_VERSION);
printf("Runtime table\n");
fill_modeled_runtime_table(runtime_phy_rx,runtime_phy_tx);
pdcp_module_init( ( IS_SOFTMODEM_NOS1 && !(IS_SOFTMODEM_NOKRNMOD))? ( PDCP_USE_NETLINK_BIT | LINK_ENB_PDCP_TO_IP_DRIVER_BIT) : LINK_ENB_PDCP_TO_GTPV1U_BIT);
uint32_t pdcp_initmask = ( IS_SOFTMODEM_NOS1 )? ( PDCP_USE_NETLINK_BIT | LINK_ENB_PDCP_TO_IP_DRIVER_BIT) : LINK_ENB_PDCP_TO_GTPV1U_BIT;
#
if ( IS_SOFTMODEM_NOS1)
pdcp_initmask = pdcp_initmask | ENB_NAS_USE_TUN_BIT | SOFTMODEM_NOKRNMOD_BIT ;
pdcp_module_init(pdcp_initmask);
if (RC.nb_inst > 0) {
// don't create if node doesn't connect to RRC/S1/GTP
if (create_tasks(1) < 0) {
......
......@@ -578,11 +578,7 @@ static void *UE_thread_synch(void *arg)
case pbch:
#if DISABLE_LOG_X
printf("[UE thread Synch] Running Initial Synch (mode %d)\n",UE->mode);
#else
LOG_I(PHY, "[UE thread Synch] Running Initial Synch (mode %d)\n",UE->mode);
#endif
if (initial_sync( UE, UE->mode ) == 0) {
LOG_I( HW, "Got synch: hw_slot_offset %d, carrier off %d Hz, rxgain %d (DL %u, UL %u), UE_scan_carrier %d\n",
......@@ -702,19 +698,11 @@ static void *UE_thread_synch(void *arg)
return &UE_thread_synch_retval; // not reached
}
}
#if DISABLE_LOG_X
printf("[initial_sync] trying carrier off %d Hz, rxgain %d (DL %u, UL %u)\n",
freq_offset,
UE->rx_total_gain_dB,
downlink_frequency[0][0]+freq_offset,
downlink_frequency[0][0]+uplink_frequency_offset[0][0]+freq_offset );
#else
LOG_I(PHY, "[initial_sync] trying carrier off %d Hz, rxgain %d (DL %u, UL %u)\n",
freq_offset,
UE->rx_total_gain_dB,
downlink_frequency[0][0]+freq_offset,
downlink_frequency[0][0]+uplink_frequency_offset[0][0]+freq_offset );
#endif
for (i=0; i<openair0_cfg[UE->rf_map.card].rx_num_channels; i++) {
openair0_cfg[UE->rf_map.card].rx_freq[UE->rf_map.chain+i] = downlink_frequency[CC_id][i]+freq_offset;
......@@ -793,11 +781,7 @@ static void *UE_thread_rxn_txnp4(void *arg) {
// most of the time, the thread is waiting here
pthread_cond_wait( &proc->cond_rxtx, &proc->mutex_rxtx );
}
if (pthread_mutex_unlock(&proc->mutex_rxtx) != 0) {
LOG_E( PHY, "[SCHED][UE] error unlocking mutex for UE RXn_TXnp4\n" );
exit_fun("nothing to add");
}
//printf("Processing sub frqme %d in %s\n", proc->subframe_rx, threadname);
initRefTimes(t2);
initRefTimes(t3);
pickTime(current);
......@@ -870,12 +854,8 @@ static void *UE_thread_rxn_txnp4(void *arg) {
phy_procedures_UE_S_TX(UE,0,0);
updateTimes(current, &t3, 10000, "Delay to process sub-frame (case 3)");
if (pthread_mutex_lock(&proc->mutex_rxtx) != 0) {
LOG_E( PHY, "[SCHED][UE] error locking mutex for UE RXTX\n" );
exit_fun("noting to add");
}
proc->instance_cnt_rxtx--;
if ( IS_SOFTMODEM_BASICSIM ) {
if ( IS_SOFTMODEM_BASICSIM || IS_SOFTMODEM_RFSIM ) {
if (pthread_cond_signal(&proc->cond_rxtx) != 0) abort();
}
if (pthread_mutex_unlock(&proc->mutex_rxtx) != 0) {
......@@ -1665,7 +1645,7 @@ void *UE_thread(void *arg) {
// update thread index for received subframe
UE->current_thread_id[sub_frame] = thread_idx;
if (IS_SOFTMODEM_BASICSIM) {
if (IS_SOFTMODEM_BASICSIM || IS_SOFTMODEM_RFSIM ) {
int t;
for (t = 0; t < 2; t++) {
UE_rxtx_proc_t *proc = &UE->proc.proc_rxtx[t];
......@@ -1748,8 +1728,21 @@ void *UE_thread(void *arg) {
LOG_E(PHY,"can't compensate: diff =%d\n", first_symbols);
}
pickTime(gotIQs);
struct timespec tv={0};
tv.tv_nsec=10*1000;
if( IS_SOFTMODEM_BASICSIM || IS_SOFTMODEM_RFSIM)
tv.tv_sec=INT_MAX;
// operate on thread sf mod 2
AssertFatal(pthread_mutex_lock(&proc->mutex_rxtx) ==0,"");
if (pthread_mutex_timedlock(&proc->mutex_rxtx, &tv) !=0) {
if ( errno == ETIMEDOUT) {
LOG_E(PHY,"Missed real time\n");
continue;
} else {
LOG_E(PHY,"System error\n");
abort();
}
}
//usleep(3000);
if(sub_frame == 0) {
//UE->proc.proc_rxtx[0].frame_rx++;
//UE->proc.proc_rxtx[1].frame_rx++;
......@@ -1771,11 +1764,6 @@ void *UE_thread(void *arg) {
proc->instance_cnt_rxtx++;
LOG_D( PHY, "[SCHED][UE %d] UE RX instance_cnt_rxtx %d subframe %d !!\n", UE->Mod_id, proc->instance_cnt_rxtx,proc->subframe_rx);
if (proc->instance_cnt_rxtx != 0) {
LOG_E( PHY, "[SCHED][UE %d] UE RX thread busy (IC %d)!!\n", UE->Mod_id, proc->instance_cnt_rxtx);
if (proc->instance_cnt_rxtx > 2)
exit_fun("instance_cnt_rxtx > 2");
}
AssertFatal (pthread_cond_signal(&proc->cond_rxtx) ==0 ,"");
AssertFatal(pthread_mutex_unlock(&proc->mutex_rxtx) ==0,"");
......
......@@ -751,7 +751,6 @@ int main( int argc, char **argv ) {
cpuf=get_cpu_freq_GHz();
pthread_cond_init(&sync_cond,NULL);
pthread_mutex_init(&sync_mutex, NULL);
#if defined(ENABLE_ITTI)
printf("ITTI init\n");
itti_init(TASK_MAX, THREAD_MAX, MESSAGES_ID_MAX, tasks_info, messages_info);
......@@ -761,9 +760,9 @@ int main( int argc, char **argv ) {
}
MSC_INIT(MSC_E_UTRAN, THREAD_MAX+TASK_MAX);
#endif
init_opt();
uint32_t pdcp_initmask = ((!IS_SOFTMODEM_NOS1) || IS_SOFTMODEM_NOKRNMOD)? LINK_ENB_PDCP_TO_GTPV1U_BIT : (LINK_ENB_PDCP_TO_GTPV1U_BIT | PDCP_USE_NETLINK_BIT | LINK_ENB_PDCP_TO_IP_DRIVER_BIT);
uint32_t pdcp_initmask = (!IS_SOFTMODEM_NOS1 )? LINK_ENB_PDCP_TO_GTPV1U_BIT : (LINK_ENB_PDCP_TO_GTPV1U_BIT | PDCP_USE_NETLINK_BIT | LINK_ENB_PDCP_TO_IP_DRIVER_BIT);
if ( IS_SOFTMODEM_BASICSIM || IS_SOFTMODEM_RFSIM || (nfapi_mode == 3) ) {
pdcp_initmask = pdcp_initmask | UE_NAS_USE_TUN_BIT;
......@@ -772,12 +771,11 @@ int main( int argc, char **argv ) {
pdcp_initmask = pdcp_initmask | UE_NAS_USE_TUN_BIT;
pdcp_module_init( pdcp_initmask );
//TTN for D2D
#if (LTE_RRC_VERSION >= MAKE_VERSION(14, 0, 0))
printf ("RRC control socket\n");
rrc_control_socket_init();
printf ("PDCP PC5S socket\n");
pdcp_pc5_socket_init();
#endif
// to make a graceful exit when ctrl-c is pressed
signal(SIGSEGV, signal_handler);
signal(SIGINT, signal_handler);
......
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