Properly calling init_tun and nas_conf for SA and NSA
This commit is contained in:
@@ -413,24 +413,18 @@ uint64_t nr_pdcp_module_init(uint64_t _pdcp_optmask, int id)
|
||||
nas_getparams();
|
||||
|
||||
if(UE_NAS_USE_TUN) {
|
||||
char *ifsuffix_ue = get_softmodem_params()->nsa ? "nrue" : "ue";
|
||||
int num_if = (NFAPI_MODE == NFAPI_UE_STUB_PNF || IS_SOFTMODEM_SIML1 || NFAPI_MODE == NFAPI_MODE_STANDALONE_PNF)? MAX_MOBILES_PER_ENB : 1;
|
||||
netlink_init_tun("nrue", num_if, id);
|
||||
netlink_init_tun(ifsuffix_ue, num_if, id);
|
||||
//Add --nr-ip-over-lte option check for next line
|
||||
if (IS_SOFTMODEM_NOS1 && get_softmodem_params()->nsa)
|
||||
nas_config(1, 1, 3, "nrue");
|
||||
else if (IS_SOFTMODEM_NOS1)
|
||||
nas_config(1, 1, 2, "ue");
|
||||
if (IS_SOFTMODEM_NOS1)
|
||||
nas_config(1, 1, !get_softmodem_params()->nsa ? 2 : 3, ifsuffix_ue);
|
||||
LOG_I(PDCP, "UE pdcp will use tun interface\n");
|
||||
start_pdcp_tun_ue();
|
||||
} else if(ENB_NAS_USE_TUN) {
|
||||
if (get_softmodem_params()->nsa) {
|
||||
netlink_init_tun("gnb", 1, id);
|
||||
nas_config(1, 1, 1, "gnb");
|
||||
}
|
||||
else {
|
||||
netlink_init_tun("enb", 1, id);
|
||||
nas_config(1, 1, 1, "enb");
|
||||
}
|
||||
char *ifsuffix_base_s = get_softmodem_params()->nsa ? "gnb" : "enb";
|
||||
netlink_init_tun(ifsuffix_base_s, 1, id);
|
||||
nas_config(1, 1, 1, ifsuffix_base_s);
|
||||
LOG_I(PDCP, "ENB pdcp will use tun interface\n");
|
||||
start_pdcp_tun_enb();
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user