Commit 069ce49e authored by wujing's avatar wujing Committed by Xu Bo

Merge remote-tracking branch 'other/issue289_tdd_config1' into sp3_master

parents 3ea62dbd ba8a111e
This diff is collapsed.
......@@ -101,8 +101,6 @@ Options
Specify conf_nvram_path (default \"$conf_nvram_path\")
--UE-gen-nvram [output path]
Specify gen_nvram_path (default \"$gen_nvram_path\")
--RRH
Makes the RRH
-a | --agent
Enables agent for software-defined control of the eNB
-r | --3gpp-release
......@@ -200,7 +198,7 @@ function main() {
GDB=1
CMAKE_BUILD_TYPE="Debug"
echo_info "Will Compile with gdb symbols and disable compiler optimization"
CMAKE_CMD="$CMAKE_CMD -DCMAKE_BUILD_TYPE=Debug"
CMAKE_CMD="$CMAKE_CMD -DCMAKE_BUILD_TYPE=Debug --trace-expand"
shift;;
--eNB)
eNB=1
......@@ -224,10 +222,6 @@ function main() {
--UE-gen-nvram)
gen_nvram_path=$(readlink -f $2)
shift 2;;
--RRH)
RRH=1
echo_info "Will compile RRH"
shift;;
-r | --3gpp-release)
REL=$2
echo_info "Setting release to: $REL"
......@@ -376,7 +370,7 @@ function main() {
echo_info "CMAKE_CMD=$CMAKE_CMD"
#########################################################
# check validity of HW and TP parameters for RRH and eNB
# check validity of HW and TP parameters for eNB
#########################################################
# to be discussed
......@@ -392,15 +386,6 @@ function main() {
fi
fi
if [ "$RRH" = "1" ] ; then
if [ "$TP" = "None" ] ; then
echo_fatal "A transport protocol (e.g. -t ETHERNET) must be defined!"
fi
if [ "$HW" = "None" ] ; then
echo_info "No radio head has been selected (HW set to $HW)"
fi
fi
echo_info "RF HW set to $HW"
#Now we set flags to enable deadline scheduler settings
#By default: USRP: disable,
......@@ -801,36 +786,6 @@ function main() {
# oaisim_mme $dbin/oaisim_mme.$REL
fi
# RRH compilation
#####################
if [ "$RRH" = "1" ] ; then
rrh_exec=rrh_gw
rrh_build_dir=rrh_gw
echo_info "Compiling $rrh_exec ..."
[ "$CLEAN" = "1" ] && rm -rf $DIR/rrh_gw/build
mkdir -p $DIR/$rrh_build_dir/build
cmake_file=$DIR/$rrh_build_dir/CMakeLists.txt
echo "cmake_minimum_required(VERSION 2.8)" > $cmake_file
echo "set ( CMAKE_BUILD_TYPE $CMAKE_BUILD_TYPE )" >> $cmake_file
echo "set ( ENABLE_VCD_FIFO $VCD_TIMING )" >> $cmake_file
echo "set ( ENABLE_ITTI False )" >> $cmake_file
echo "set ( RF_BOARD \"${HW}\")" >> $cmake_file
echo "set ( TRANSP_PRO \"${TP}\")" >> $cmake_file
echo 'set ( PACKAGE_NAME "\"rrh_gw\"")' >> $cmake_file
echo "set ( DEADLINE_SCHEDULER \"${DEADLINE_SCHEDULER_FLAG_USER}\" )" >>$cmake_file
echo "set ( CPU_AFFINITY \"${CPU_AFFINITY_FLAG_USER}\" )" >>$cmake_file
echo "set ( T_TRACER $T_TRACER )" >> $cmake_file
echo 'include(${CMAKE_CURRENT_SOURCE_DIR}/../CMakeLists.txt)' >> $cmake_file
cd $DIR/$rrh_build_dir/build
eval $CMAKE_CMD
compilations \
rrh_gw rrh_gw \
rrh_gw $dbin/rrh_gw
fi
# Telnet server compilation
#####################
if [ "$BUILD_TELNETSRV" = "1" ] ; then
......@@ -849,13 +804,9 @@ function main() {
fi
# build RF device and transport protocol libraries
#####################################
if [ "$eNB" = "1" -o "$UE" = "1" -o "$RRH" = "1" ] ; then
if [ "$eNB" = "1" -o "$UE" = "1" ] ; then
if [ "$eNB" = "1" -o "$UE" = "1" ] ; then
build_dir=$lte_build_dir
else
build_dir=$rrh_build_dir
fi
build_dir=$lte_build_dir
# build RF device libraries
if [ "$HW" != "None" ] ; then
......
......@@ -2,17 +2,13 @@ cmake_minimum_required(VERSION 2.8)
set ( CMAKE_BUILD_TYPE "RelWithDebInfo" )
set ( ASN_DEBUG False)
set ( ADDR_CONF False )
set ( DEBUG_OMG False )
set ( DISABLE_XER_PRINT False )
set ( DRIVER2013 True )
set ( EMOS False )
set ( EMIT_ASN_DEBUG False )
set ( ENABLE_FXP True )
set ( ENABLE_ITTI True )
set ( ENABLE_NAS_UE_LOGGING True )
set ( ENABLE_NEW_MULTICAST True )
set ( ENABLE_PGM_TRANSPORT True )
set ( ENABLE_SECURITY True )
set ( ENABLE_STANDALONE_EPC False)
set ( ENABLE_USE_CPU_EXECUTION_TIME True )
......@@ -21,7 +17,6 @@ set ( ENABLE_USE_RAW_SOCKET_FOR_SGI True)
set ( ENABLE_VCD_FIFO False )
set ( ENB_MODE True )
set ( EXMIMO_IOT True )
set ( HARD_RT False )
set ( JUMBO_FRAME True )
set ( LARGE_SCALE False )
set ( LINK_ENB_PDCP_TO_GTPV1U True)
......@@ -33,7 +28,6 @@ set ( DEADLINE_SCHEDULER False )
set ( MAC_CONTEXT 1 )
set ( MAX_NUM_CCs 1 )
set ( MESSAGE_CHART_GENERATOR False)
set ( MIH_C_MEDIEVAL_EXTENSIONS False )
set ( MSG_PRINT False )
set ( MU_RECEIVER False )
set ( NAS_ADDRESS_FIX False )
......@@ -42,38 +36,25 @@ set ( NAS_MME False )
set ( NAS_UE True )
set ( NB_ANTENNAS_RX "2" )
set ( NB_ANTENNAS_TX "2" )
set ( NB_ANTENNAS_TXRX "2" )
set ( NEW_FFT True )
set ( NO_RRM True )
set ( OAI_EMU False )
set ( OAISIM False )
set ( OAI_NW_DRIVER_TYPE_ETHERNET False )
set ( OAI_NW_DRIVER_USE_NETLINK True )
set ( OPENAIR1 True )
set ( OPENAIR2 True )
set ( OPENAIR_LTE True )
set ( PACKAGE_NAME "epc_test" )
set ( PBS_SIM False )
set ( PDCP_USE_NETLINK True )
set ( PC_DSP True )
set ( PC_TARGET True )
set ( PDCP_MSG_PRINT False )
set ( PERFECT_CE False )
set ( PHY_ABSTRACTION True )
set ( PHY_CONTEXT False )
set ( PHY_EMUL False )
set ( PHYSIM True )
set ( PUCCH True )
set ( RANDOM_BF False )
set ( RF_BOARD "False" )
set ( RLC_STOP_ON_LOST_PDU False )
set ( RRC_ASN1_VERSION "Rel10" )
set ( RRC_DEFAULT_RAB_IS_AM True)
set ( RRC_MSG_PRINT False )
set ( RTAI False )
set ( SECU False )
set ( SMBV False )
set ( TEST_OMG False )
set ( USE_MME "R10" )
set ( USER_MODE True )
set ( XER_PRINT True )
......@@ -6,9 +6,6 @@ set(XFORMS True)
set(ENABLE_ITTI False)
set(DEBUG_PHY False)
set(MU_RECIEVER False)
set(RANDOM_BF False)
set(PBS_SIM False)
set(PERFECT_CE True)
set(NAS_UE False)
set(MESSAGE_CHART_GENERATOR False)
......
cmake_minimum_required(VERSION 2.8)
set ( CMAKE_BUILD_TYPE "RelWithDebInfo" )
set ( ADDR_CONF False )
set ( DEBUG_OMG False )
set ( DISABLE_XER_PRINT False )
set ( DRIVER2013 True )
set ( EMOS False )
set ( ENABLE_FXP True )
set ( ENABLE_ITTI True )
set ( ENABLE_NAS_UE_LOGGING True )
set ( ENABLE_NEW_MULTICAST True )
set ( ENABLE_PGM_TRANSPORT True )
set ( ENABLE_RAL False )
set ( ENABLE_SECURITY True )
set ( ENABLE_STANDALONE_EPC False)
......@@ -20,7 +16,6 @@ set ( ENABLE_USE_RAW_SOCKET_FOR_SGI True)
set ( ENABLE_VCD_FIFO False )
set ( ENB_MODE True )
set ( EXMIMO_IOT True )
set ( HARD_RT False )
set ( JUMBO_FRAME True )
set ( LARGE_SCALE False )
set ( LINK_ENB_PDCP_TO_GTPV1U True)
......@@ -32,7 +27,6 @@ set ( DEADLINE_SCHEDULER False )
set ( MAC_CONTEXT 1 )
set ( MAX_NUM_CCs 1 )
set ( MESSAGE_CHART_GENERATOR False)
set ( MIH_C_MEDIEVAL_EXTENSIONS False )
set ( MSG_PRINT False )
set ( MU_RECEIVER False )
set ( NAS_ADDRESS_FIX False )
......@@ -41,40 +35,26 @@ set ( NAS_MME False )
set ( NAS_UE True )
set ( NB_ANTENNAS_RX "2" )
set ( NB_ANTENNAS_TX "2" )
set ( NB_ANTENNAS_TXRX "2" )
set ( NEW_FFT True )
set ( NO_RRM True )
set ( OAI_EMU True )
set ( OAISIM True )
set ( OAI_NW_DRIVER_TYPE_ETHERNET False )
set ( OAI_NW_DRIVER_USE_NETLINK True )
set ( OPENAIR1 True )
set ( OPENAIR2 True )
set ( OPENAIR_LTE True )
set ( PACKAGE_NAME "oaisim" )
set ( PBS_SIM False )
set ( PDCP_USE_NETLINK True )
set ( PC_DSP True )
set ( PC_TARGET True )
set ( PDCP_MSG_PRINT False )
set ( PERFECT_CE False )
set ( PHY_ABSTRACTION True )
set ( PHY_CONTEXT False )
set ( PHY_EMUL False )
set ( PHYSIM True )
set ( PUCCH True )
set ( RANDOM_BF False )
set ( RF_BOARD "False" )
set ( RLC_STOP_ON_LOST_PDU False )
set ( RRC_ASN1_VERSION "Rel10" )
set ( RRC_DEFAULT_RAB_IS_AM True)
set ( RRC_MSG_PRINT False )
set ( RTAI False )
set ( SECU False )
set ( SMBV False )
set ( SPECTRA False )
set ( TEST_OMG False )
set ( USE_3GPP_ADDR_AS_LINK_ADDR False )
set ( USE_MME "R10" )
set ( USER_MODE True )
set ( XER_PRINT False )
cmake_minimum_required(VERSION 2.8)
set ( CMAKE_BUILD_TYPE "RelWithDebInfo" )
set ( ADDR_CONF False )
set ( DEBUG_OMG False )
set ( DISABLE_XER_PRINT False )
set ( DRIVER2013 False )
set ( EMOS False )
set ( ENABLE_FXP False )
set ( ENABLE_ITTI True )
set ( ENABLE_NAS_UE_LOGGING False )
set ( ENABLE_NEW_MULTICAST False )
set ( ENABLE_PGM_TRANSPORT False )
set ( ENABLE_RAL False )
set ( ENABLE_SECURITY False )
set ( ENABLE_STANDALONE_EPC False )
......@@ -21,7 +17,6 @@ set ( ENABLE_VCD_FIFO False )
set ( ENB_MODE False )
set ( EPC_BUILD True )
set ( EXMIMO_IOT False )
set ( HARD_RT False )
set ( JUMBO_FRAME False )
set ( LARGE_SCALE False )
set ( LINK_ENB_PDCP_TO_GTPV1U True)
......@@ -32,7 +27,6 @@ set ( LOG_NO_THREAD False )
set ( DEADLINE_SCHEDULER False )
set ( MAC_CONTEXT 1 )
set ( MAX_NUM_CCs 1 )
set ( MIH_C_MEDIEVAL_EXTENSIONS False )
set ( MSG_PRINT False )
set ( MU_RECEIVER False )
set ( NAS_ADDRESS_FIX False )
......@@ -42,42 +36,27 @@ set ( NAS_NETLINK False )
set ( NAS_UE False )
set ( NB_ANTENNAS_RX "2" )
set ( NB_ANTENNAS_TX "2" )
set ( NB_ANTENNAS_TXRX "2" )
set ( NEW_FFT False )
set ( NO_RRM False )
set ( OAI_EMU False )
set ( OAISIM False )
set ( OAI_NW_DRIVER_TYPE_ETHERNET False )
set ( OAI_NW_DRIVER_USE_NETLINK False )
set ( OPENAIR1 False )
set ( OPENAIR2 False )
set ( OPENAIR_EMU False )
set ( OPENAIR_LTE False )
set ( PACKAGE_NAME "EPC" )
set ( PBS_SIM False )
set ( PC_DSP False )
set ( PC_TARGET False )
set ( PDCP_MSG_PRINT False )
set ( PERFECT_CE False )
set ( PHY_ABSTRACTION False )
set ( PHY_CONTEXT False )
set ( PHY_EMUL False )
set ( PHYSIM False )
set ( PUCCH False )
set ( RANDOM_BF False )
set ( RF_BOARD "False" )
set ( RRC_ASN1_VERSION "Rel10" )
set ( RLC_STOP_ON_LOST_PDU False )
set ( RRC_MSG_PRINT False )
set ( RTAI False )
set ( SECU False )
set ( SMBV False )
set ( SPECTRA False )
set ( TEST_OMG False )
set ( UPDATE_RELEASE_9 True)
set ( UPDATE_RELEASE_10 True)
set ( USE_3GPP_ADDR_AS_LINK_ADDR False )
set ( USE_MME "R10" )
set ( USER_MODE True )
set ( XER_PRINT False )
set ( XFORMS False )
cmake_minimum_required(VERSION 2.8)
set ( ADDR_CONF False )
set ( DEBUG_OMG False )
set ( DISABLE_XER_PRINT False )
set ( DRIVER2013 True )
set ( EMOS False )
set ( ENABLE_FXP True )
set ( ENABLE_ITTI True )
set ( ENABLE_NAS_UE_LOGGING False )
set ( ENABLE_NEW_MULTICAST True )
set ( ENABLE_PGM_TRANSPORT True )
set ( ENABLE_RAL False )
set ( ENABLE_SECURITY False )
set ( ENABLE_STANDALONE_EPC False)
......@@ -19,7 +15,6 @@ set ( ENABLE_USE_RAW_SOCKET_FOR_SGI False)
set ( ENABLE_VCD_FIFO False )
set ( ENB_MODE True )
set ( EXMIMO_IOT True )
set ( HARD_RT False )
set ( JUMBO_FRAME True )
set ( LARGE_SCALE False )
set ( LINK_ENB_PDCP_TO_GTPV1U False)
......@@ -33,7 +28,6 @@ set ( MAX_NUM_CCs 1 )
set ( MESSAGE_CHART_GENERATOR False )
set ( MESSAGE_CHART_GENERATOR_RLC_MAC False )
set ( MESSAGE_CHART_GENERATOR_PHY False )
set ( MIH_C_MEDIEVAL_EXTENSIONS False )
set ( MSG_PRINT False )
set ( MU_RECEIVER False )
set ( NAS_ADDRESS_FIX True )
......@@ -42,42 +36,27 @@ set ( NAS_MME False )
set ( NAS_UE False )
set ( NB_ANTENNAS_RX "2" )
set ( NB_ANTENNAS_TX "2" )
set ( NB_ANTENNAS_TXRX "2" )
set ( NEW_FFT True )
set ( NO_RRM True )
set ( OAI_EMU True )
set ( OAISIM True )
set ( OAI_NW_DRIVER_TYPE_ETHERNET False )
set ( OAI_NW_DRIVER_USE_NETLINK True )
set ( OPENAIR1 True )
set ( OPENAIR2 True )
set ( OPENAIR_EMU False )
set ( OPENAIR_LTE True )
set ( PACKAGE_NAME "oaisim" )
set ( PBS_SIM False )
set ( PDCP_USE_NETLINK True )
set ( PC_DSP True )
set ( PC_TARGET True )
set ( PDCP_MSG_PRINT False )
set ( PERFECT_CE False )
set ( PHY_ABSTRACTION True )
set ( PHY_CONTEXT False )
set ( PHY_EMUL False )
set ( PHYSIM True )
set ( PUCCH True )
set ( RANDOM_BF False )
set ( RF_BOARD "False" )
set ( RRC_ASN1_VERSION "Rel10" )
set ( RLC_STOP_ON_LOST_PDU False )
set ( RRC_MSG_PRINT False )
set ( RTAI False )
set ( SECU False )
set ( SMBV False )
set ( SPECTRA False )
set ( TEST_OMG False )
set ( USE_3GPP_ADDR_AS_LINK_ADDR False )
set ( USE_MME "R10" )
set ( USER_MODE True )
set ( XER_PRINT False )
set ( DEBUG_PHY False )
set ( DEBUG_PHY_PROC False)
......
cmake_minimum_required(VERSION 2.8)
set ( CMAKE_BUILD_TYPE "RelWithDebInfo" )
set ( ADDR_CONF False )
set ( DEBUG_OMG False )
set ( DISABLE_XER_PRINT False )
set ( DRIVER2013 True )
set ( EMOS False )
set ( ENABLE_FXP True )
set ( ENABLE_ITTI True )
set ( ENABLE_NAS_UE_LOGGING True )
set ( ENABLE_NEW_MULTICAST True )
set ( ENABLE_PDCP_NETLINK_FIFO False )
set ( ENABLE_PGM_TRANSPORT True )
set ( ENABLE_RAL False )
set ( ENABLE_SECURITY True )
set ( ENABLE_STANDALONE_EPC False)
......@@ -21,7 +17,6 @@ set ( ENABLE_USE_RAW_SOCKET_FOR_SGI True)
set ( ENABLE_VCD_FIFO False )
set ( ENB_MODE True )
set ( EXMIMO_IOT True )
set ( HARD_RT False )
set ( JUMBO_FRAME True )
set ( LARGE_SCALE False )
set ( LINK_ENB_PDCP_TO_GTPV1U True)
......@@ -33,7 +28,6 @@ set ( DEADLINE_SCHEDULER False )
set ( MAC_CONTEXT 1 )
set ( MAX_NUM_CCs 1 )
set ( MESSAGE_CHART_GENERATOR False)
set ( MIH_C_MEDIEVAL_EXTENSIONS False )
set ( MSG_PRINT False )
set ( MU_RECEIVER False )
set ( NAS_ADDRESS_FIX False )
......@@ -42,44 +36,30 @@ set ( NAS_MME False )
set ( NAS_UE True )
set ( NB_ANTENNAS_RX "2" )
set ( NB_ANTENNAS_TX "2" )
set ( NB_ANTENNAS_TXRX "2" )
set ( NEW_FFT True )
set ( NO_RRM True )
set ( OAI_EMU True )
set ( OAISIM True )
set ( OAI_NW_DRIVER_TYPE_ETHERNET False )
set ( OAI_NW_DRIVER_USE_NETLINK True )
set ( OPENAIR1 True )
set ( OPENAIR2 True )
set ( OPENAIR_LTE True )
set ( PACKAGE_NAME "oaisim" )
set ( PBS_SIM False )
set ( PDCP_USE_NETLINK True )
set ( PC_DSP True )
set ( PC_TARGET True )
set ( PDCP_MSG_PRINT False )
set ( PERFECT_CE False )
set ( PHY_ABSTRACTION True )
set ( PHY_CONTEXT False )
set ( PHY_EMUL False )
set ( PHYSIM True )
set ( PUCCH True )
set ( RANDOM_BF False )
set ( RF_BOARD "False" )
set ( RLC_STOP_ON_LOST_PDU False )
set ( RRC_ASN1_VERSION "Rel10" )
set ( RRC_DEFAULT_RAB_IS_AM True)
set ( RRC_MSG_PRINT False )
set ( RTAI False )
set ( SECU False )
set ( SMBV False )
set ( SPECTRA False )
set ( TEST_OMG False )
set ( TEST_S1C_MME True )
set ( USE_3GPP_ADDR_AS_LINK_ADDR False )
set ( USE_MME "R10" )
set ( USER_MODE True )
set ( XER_PRINT False )
set ( XFORMS False )
......@@ -95,6 +95,8 @@ get_distribution_release() {
check_supported_distribution() {
local distribution=$(get_distribution_release)
case "$distribution" in
"ubuntu17.10") return 0 ;;
"ubuntu17.04") return 0 ;;
"ubuntu16.04") return 0 ;;
"ubuntu14.04") return 0 ;;
"fedora24") return 0 ;;
......@@ -230,6 +232,7 @@ install_protobuf_c_from_source(){
rm -rf /tmp/protobuf-c
git clone https://github.com/protobuf-c/protobuf-c.git
cd protobuf-c
git checkout 2a46af42784abf86804d536f6e0122d47cfeea45
./autogen.sh
./configure
echo "Compiling protobuf-c"
......@@ -479,16 +482,26 @@ check_install_oai_software() {
fi
$SUDO $INSTALLER update -y
if [[ "$OS_DISTRO" == "ubuntu" ]]; then
local LAPACK_LIBNAME="liblapack.so"
local LAPACK_TARGET="/usr/lib/atlas-base/atlas/liblapack.so"
$SUDO apt install -y software-properties-common
case "$(get_distribution_release)" in
"ubuntu14.04")
specific_packages="libtasn1-3-dev"
specific_packages="libtasn1-3-dev gccxml libgnutls-dev libatlas-dev"
# For iperf3
$SUDO add-apt-repository "deb http://archive.ubuntu.com/ubuntu trusty-backports universe"
$SUDO apt-get update
;;
"ubuntu16.04")
specific_packages="libtasn1-6-dev"
specific_packages="libtasn1-6-dev gccxml libgnutls-dev libatlas-dev"
;;
"ubuntu17.04")
specific_packages="libtasn1-6-dev castxml libgnutls28-dev libatlas-dev"
;;
"ubuntu17.10")
specific_packages="libtasn1-6-dev castxml libgnutls28-dev"
LAPACK_LIBNAME="liblapack.so-x86_64-linux-gnu"
LAPACK_TARGET="/usr/lib/x86_64-linux-gnu/atlas/liblapack.so"
;;
esac
$SUDO apt-get install -y \
......@@ -504,7 +517,6 @@ check_install_oai_software() {
texlive-latex-base \
ethtool \
flex \
gccxml \
gdb \
git \
graphviz \
......@@ -515,7 +527,6 @@ check_install_oai_software() {
iptables \
iptables-dev \
libatlas-base-dev \
libatlas-dev \
libblas-dev \
libconfig8-dev \
libffi-dev \
......@@ -553,11 +564,9 @@ check_install_oai_software() {
wget \
libxpm-dev
$SUDO update-alternatives --set liblapack.so /usr/lib/atlas-base/atlas/liblapack.so
$SUDO apt-get install -y nettle-dev nettle-bin
$SUDO update-alternatives --set "$LAPACK_LIBNAME" "$LAPACK_TARGET"
$SUDO apt-get install -y libgnutls-dev
$SUDO apt-get install -y nettle-dev nettle-bin
elif [[ "$OS_BASEDISTRO" == "fedora" ]]; then
if [[ "$OS_DISTRO" == "rhel" ]] || [[ "$OS_DISTRO" == "centos" ]]; then
if rpm -q epel-release > /dev/null; then
......
......@@ -128,6 +128,7 @@ int config_get(paramdef_t *params,int numparams, char *prefix)
{
int ret= -1;
printf("numparams:%d prefix:%s\n", numparams, prefix);
if (CONFIG_ISFLAGSET(CONFIG_ABORT)) {
fprintf(stderr,"[CONFIG] config_get skipped, config module not properly initialized\n");
return ret;
......
......@@ -29,7 +29,7 @@ typedef struct {
#define T_SHM_FILENAME "/T_shm_segment"
/* number of VCD functions (to be kept up to date! see in T_messages.txt) */
#define VCD_NUM_FUNCTIONS 178
#define VCD_NUM_FUNCTIONS 187
/* number of VCD variables (to be kept up to date! see in T_messages.txt) */
#define VCD_NUM_VARIABLES 128
......
......@@ -185,6 +185,10 @@ ID = ENB_RRC_CONNECTION_REESTABLISHMENT_REQUEST
DESC = RRC connection reestablishment request
GROUP = ALL:RRC:ENB
FORMAT = int,eNB_ID : int,frame : int,subframe : int,rnti
ID = ENB_RRC_CONNECTION_REESTABLISHMENT
DESC = RRC connection reestablishment
GROUP = ALL:RRC:ENB
FORMAT = int,eNB_ID : int,frame : int,subframe : int,rnti
ID = ENB_RRC_CONNECTION_REESTABLISHMENT_COMPLETE
DESC = RRC connection reestablishment complete
GROUP = ALL:RRC:ENB
......@@ -2157,3 +2161,39 @@ ID = VCD_FUNCTION_TRX_DECOMPR_IF
DESC = VCD function TRX_DECOMPR_IF
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_NFAPI
DESC = VCD function NFAPI
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_GENERATE_PCFICH
DESC = VCD function GENERATE_PCFICH
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_GENERATE_DCI0
DESC = VCD function GENERATE_DCI0
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_GENERATE_DLSCH
DESC = VCD function GENERATE_DLSCH
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_GENERATE_PHICH
DESC = VCD function GENERATE_PHICH
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_PDCCH_SCRAMBLING
DESC = VCD function PDCCH_SCRAMBLING
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_PDCCH_MODULATION
DESC = VCD function PDCCH_MODULATION
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_PDCCH_INTERLEAVING
DESC = VCD function PDCCH_INTERLEAVING
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
ID = VCD_FUNCTION_PDCCH_TX
DESC = VCD function PDCCH_TX
GROUP = ALL:VCD:ENB:VCD_FUNCTION
FORMAT = int,value
This diff is collapsed.
......@@ -27,10 +27,6 @@
#include <sys/epoll.h>
#ifdef RTAI
# include <rtai_sem.h>
#endif
#ifndef INTERTASK_INTERFACE_H_
#define INTERTASK_INTERFACE_H_
......@@ -155,12 +151,10 @@ int itti_create_task(task_id_t task_id,
void *(*start_routine) (void *),
void *args_p);
//#ifdef RTAI
/** \brief Mark the task as a real time task
* \param task_id task to mark as real time
**/
void itti_set_task_real_time(task_id_t task_id);
//#endif
/** \brief Indicates to ITTI if newly created tasks should wait for all tasks to be ready
* \param wait_tasks non 0 to make new created tasks to wait, 0 to let created tasks to run
......
......@@ -51,23 +51,14 @@
#include "intertask_interface.h"
#include "intertask_interface_dump.h"
#if defined(OAI_EMU) || defined(RTAI)
#include "vcd_signal_dumper.h"
#endif
#if T_TRACER
#include "T.h"
#endif
static const int itti_dump_debug = 0; // 0x8 | 0x4 | 0x2;
#ifdef RTAI
# define ITTI_DUMP_DEBUG(m, x, args...) do { if ((m) & itti_dump_debug) rt_printk("[ITTI_DUMP][D]"x, ##args); } \
while(0)
#else
# define ITTI_DUMP_DEBUG(m, x, args...) do { if ((m) & itti_dump_debug) fprintf(stdout, "[ITTI_DUMP][D]"x, ##args); } \
while(0)
#endif
#define ITTI_DUMP_ERROR(x, args...) do { fprintf(stdout, "[ITTI_DUMP][E]"x, ##args); } \
while(0)
......@@ -99,13 +90,8 @@ typedef struct itti_desc_s {
int nb_connected;
#ifndef RTAI
/* Event fd used to notify new messages (semaphore) */
int event_fd;
#else
unsigned long messages_in_queue __attribute__((aligned(8)));
#endif
int itti_listen_socket;
itti_client_desc_t itti_clients[ITTI_DUMP_MAX_CON];
......@@ -194,9 +180,7 @@ static int itti_dump_fwrite_message(itti_dump_queue_item_t *message)
fwrite (&new_message_header, sizeof(itti_dump_message_t), 1, dump_file);
fwrite (message->data, message->data_size, 1, dump_file);
fwrite (&itti_dump_message_type_end, sizeof(itti_message_types_t), 1, dump_file);
// #if !defined(RTAI)
fflush (dump_file);
// #endif
return (1);
}
......@@ -280,10 +264,6 @@ static int itti_dump_enqueue_message(itti_dump_queue_item_t *new, uint32_t messa
int overwrite_flag;
AssertFatal (new != NULL, "Message to queue is NULL!\n");
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_ITTI_DUMP_ENQUEUE_MESSAGE, VCD_FUNCTION_IN);
#endif
new->message_type = message_type;
new->message_size = message_size;
......@@ -303,9 +283,6 @@ static int itti_dump_enqueue_message(itti_dump_queue_item_t *new, uint32_t messa
lfds611_ringbuffer_put_write_element(itti_dump_queue.itti_message_queue, new_queue_element);
if (overwrite_flag == 0) {
#ifdef RTAI
__sync_fetch_and_add (&itti_dump_queue.messages_in_queue, 1);
#else
{
ssize_t write_ret;
eventfd_t sem_counter = 1;
......@@ -314,25 +291,18 @@ static int itti_dump_enqueue_message(itti_dump_queue_item_t *new, uint32_t messa
write_ret = write(itti_dump_queue.event_fd, &sem_counter, sizeof(sem_counter));
AssertFatal (write_ret == sizeof(sem_counter), "Write to dump event failed (%d/%d)!\n", (int) write_ret, (int) sizeof(sem_counter));
}
#endif
// add one to pending_messages, atomically
__sync_fetch_and_add (&pending_messages, 1);
}
ITTI_DUMP_DEBUG (0x2, " Added element to queue %p %p, pending %u, type %u\n", new_queue_element, new, pending_messages, message_type);
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_ITTI_DUMP_ENQUEUE_MESSAGE, VCD_FUNCTION_OUT);
#endif
return 0;
}
static void itti_dump_socket_exit(void)
{
#ifndef RTAI
close(itti_dump_queue.event_fd);
#endif
close(itti_dump_queue.itti_listen_socket);
/* Leave the thread as we detected end signal */
......@@ -346,10 +316,6 @@ static int itti_dump_flush_ring_buffer(int flush_all)
int j;
int consumer;
#ifdef RTAI
unsigned long number_of_messages;
#endif
/* Check if there is a least one consumer */
consumer = 0;
......@@ -365,18 +331,6 @@ static int itti_dump_flush_ring_buffer(int flush_all)
}
if (consumer > 0) {
#ifdef RTAI
number_of_messages = itti_dump_queue.messages_in_queue;
ITTI_DUMP_DEBUG(0x4, "%lu elements in queue\n", number_of_messages);
if (number_of_messages == 0) {
return (consumer);
}
__sync_sub_and_fetch(&itti_dump_queue.messages_in_queue, number_of_messages);
#endif
do {
/* Acquire the ring element */
lfds611_ringbuffer_get_read_element(itti_dump_queue.itti_message_queue, &element);
......@@ -419,9 +373,6 @@ static int itti_dump_flush_ring_buffer(int flush_all)
lfds611_ringbuffer_put_read_element(itti_dump_queue.itti_message_queue, element);
}
} while(flush_all
#ifdef RTAI
&& --number_of_messages
#endif
);
}
......@@ -478,9 +429,6 @@ static void *itti_dump_socket(void *arg_p)
struct sockaddr_in servaddr; /* socket address structure */
struct timeval *timeout_p = NULL;
#ifdef RTAI
struct timeval timeout;
#endif
ITTI_DUMP_DEBUG(0x2, " Creating TCP dump socket on port %u\n", ITTI_PORT);
......@@ -536,15 +484,11 @@ static void *itti_dump_socket(void *arg_p)
/* Add the listener */
FD_SET(itti_listen_socket, &read_set);
#ifndef RTAI
/* Add the event fd */
FD_SET(itti_dump_queue.event_fd, &read_set);
/* Max of both sd */
max_sd = itti_listen_socket > itti_dump_queue.event_fd ? itti_listen_socket : itti_dump_queue.event_fd;
#else
max_sd = itti_listen_socket;
#endif
itti_dump_queue.itti_listen_socket = itti_listen_socket;
......@@ -557,14 +501,7 @@ static void *itti_dump_socket(void *arg_p)
int i;
memcpy(&working_set, &read_set, sizeof(read_set));
#ifdef RTAI
timeout.tv_sec = 0;
timeout.tv_usec = 100000;
timeout_p = &timeout;
#else
timeout_p = NULL;
#endif
/* No timeout: select blocks till a new event has to be handled
* on sd's.
......@@ -592,8 +529,6 @@ static void *itti_dump_socket(void *arg_p)
if (FD_ISSET(i, &working_set)) {
desc_ready -= 1;
#ifndef RTAI
if (i == itti_dump_queue.event_fd) {
/* Notification of new element to dump from other tasks */
eventfd_t sem_counter;
......@@ -613,7 +548,6 @@ static void *itti_dump_socket(void *arg_p)
if (itti_dump_running) {
ITTI_DUMP_DEBUG (0x4, " No messages consumers, waiting ...\n");
usleep(100 * 1000);
#ifndef RTAI
{
ssize_t write_ret;
......@@ -622,7 +556,6 @@ static void *itti_dump_socket(void *arg_p)
write_ret = write(itti_dump_queue.event_fd, &sem_counter, sizeof(sem_counter));
AssertFatal (write_ret == sizeof(sem_counter), "Failed to write to dump event FD (%d/%d)!\n", (int) write_ret, (int) sem_counter);
}
#endif
} else {
itti_dump_socket_exit();
}
......@@ -630,7 +563,6 @@ static void *itti_dump_socket(void *arg_p)
ITTI_DUMP_DEBUG(0x1, " Write element to file\n");
}
} else
#endif
if (i == itti_listen_socket) {
do {
client_socket = accept(itti_listen_socket, NULL, NULL);
......@@ -719,21 +651,9 @@ int itti_dump_queue_message(task_id_t sender_task,
AssertFatal (message_name != NULL, "Message name is NULL!\n");
AssertFatal (message_p != NULL, "Message is NULL!\n");
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_ITTI_DUMP_ENQUEUE_MESSAGE_MALLOC, VCD_FUNCTION_IN);
#endif
new = itti_malloc(sender_task, TASK_MAX, sizeof(itti_dump_queue_item_t));
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_ITTI_DUMP_ENQUEUE_MESSAGE_MALLOC, VCD_FUNCTION_OUT);
#endif
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_ITTI_DUMP_ENQUEUE_MESSAGE_MALLOC, VCD_FUNCTION_IN);
#endif
new->data = itti_malloc(sender_task, TASK_MAX, message_size);
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_ITTI_DUMP_ENQUEUE_MESSAGE_MALLOC, VCD_FUNCTION_OUT);
#endif
memcpy(new->data, message_p, message_size);
new->data_size = message_size;
......@@ -791,9 +711,6 @@ int itti_dump_init(const char * const messages_definition_xml, const char * cons
AssertFatal (0, " Failed to create ring buffer!\n");
}
#ifdef RTAI
itti_dump_queue.messages_in_queue = 0;
#else
itti_dump_queue.event_fd = eventfd(0, EFD_SEMAPHORE);
if (itti_dump_queue.event_fd == -1) {
......@@ -801,8 +718,6 @@ int itti_dump_init(const char * const messages_definition_xml, const char * cons
AssertFatal (0, "eventfd failed: %s!\n", strerror(errno));
}
#endif
itti_dump_queue.nb_connected = 0;
for(i = 0; i < ITTI_DUMP_MAX_CON; i++) {
......
......@@ -27,11 +27,7 @@
#ifndef _ITTI_TYPES_H_
#define _ITTI_TYPES_H_
#ifdef USER_MODE
#include <stdint.h>
#else
#include <linux/types.h>
#endif
#define CHARS_TO_UINT32(c1, c2, c3, c4) (((c4) << 24) | ((c3) << 16) | ((c2) << 8) | (c1))
......
......@@ -19,15 +19,8 @@
* contact@openairinterface.org
*/
#ifdef RTAI
# include <rtai_shm.h>
#endif
#include "assertions.h"
#include "memory_pools.h"
#if defined(OAI_EMU) || defined(RTAI)
# include "vcd_signal_dumper.h"
#endif
#if T_TRACER
#include <string.h>
......@@ -37,18 +30,8 @@
/*------------------------------------------------------------------------------*/
const static int mp_debug = 0;
#ifdef RTAI
# define MP_DEBUG(x, args...) do { if (mp_debug) rt_printk("[MP][D]"x, ##args); } \
while(0)
#else
# define MP_DEBUG(x, args...) do { if (mp_debug) fprintf(stdout, "[MP][D]"x, ##args); fflush (stdout); } \
while(0)
#endif
#if defined(OAI_EMU) || defined(RTAI)
uint64_t vcd_mp_alloc;
uint64_t vcd_mp_free;
#endif
/*------------------------------------------------------------------------------*/
#ifndef CHARS_TO_UINT32
......@@ -414,11 +397,6 @@ memory_pool_item_handle_t memory_pools_allocate (memory_pools_handle_t memory_po
pool_id_t pool;
items_group_index_t item_index = ITEMS_GROUP_INDEX_INVALID;
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME(VCD_SIGNAL_DUMPER_VARIABLE_MP_ALLOC,
__sync_or_and_fetch (&vcd_mp_alloc, 1L << info_0));
#endif
/* Recover memory_pools */
memory_pools = memory_pools_from_handler (memory_pools_handle);
AssertError (memory_pools != NULL, {}, "Failed to retrieve memory pool for handle %p!\n", memory_pools_handle);
......@@ -464,11 +442,6 @@ memory_pool_item_handle_t memory_pools_allocate (memory_pools_handle_t memory_po
MP_DEBUG(" Alloc [--][------]{------}, %3u %3u, %6u, failed!\n", info_0, info_1, item_size);
}
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME(VCD_SIGNAL_DUMPER_VARIABLE_MP_ALLOC,
__sync_and_and_fetch (&vcd_mp_alloc, ~(1L << info_0)));
#endif
return memory_pool_item_handle;
}
......@@ -493,11 +466,6 @@ int memory_pools_free (memory_pools_handle_t memory_pools_handle, memory_pool_it
info_1 = memory_pool_item->start.info[1];
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME(VCD_SIGNAL_DUMPER_VARIABLE_MP_FREE,
__sync_or_and_fetch (&vcd_mp_free, 1L << info_1));
#endif
/* Recover pool index */
pool = memory_pool_item->start.pool_id;
AssertFatal (pool < memory_pools->pools_defined, "Pool index is invalid (%u/%u)!\n", pool, memory_pools->pools_defined);
......@@ -531,11 +499,6 @@ int memory_pools_free (memory_pools_handle_t memory_pools_handle, memory_pool_it
AssertError (result == EXIT_SUCCESS, {}, "Failed to free memory pool item (pool %u, item %d)!\n", pool, item_index);
#if defined(OAI_EMU) || defined(RTAI)
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME(VCD_SIGNAL_DUMPER_VARIABLE_MP_FREE,
__sync_and_and_fetch (&vcd_mp_free, ~(1L << info_1)));
#endif
return (result);
}
......
......@@ -24,7 +24,7 @@ set(OPENAIR_NFAPIINC $ENV{NFAPI_DIR} )
set(CMAKE_INSTALL_PREFIX $ENV{OPENAIR_TARGETS})
add_definitions (-DRel14 -DCMAKER -DENABLE_FXP -DENABLE_ITTI -DENABLE_NAS_UE_LOGGING -DENABLE_SECURITY -DENABLE_USE_CPU_EXECUTION_TIME -DENABLE_USE_MME -DENABLE_VCD -DENB_AGENT -DENB_MODE -DETHERNET=1 -DEXMIMO_IOT -DJUMBO_FRAME -DLINK_ENB_PDCP_TO_GTPV1U -DLOG_NO_THREAD -DMAC_CONTEXT -DMAX_NUM_CCs=1 -DNAS_BUILT_IN_UE -DNAS_UE -DNB_ANTENNAS_RX=2 -DNB_ANTENNAS_TX=2 -DNB_ANTENNAS_TXRX=2 -DNEW_FFT -DNO_RRM -DNone=1 -DOAI_NW_DRIVER_USE_NETLINK -DOPENAIR1 -DOPENAIR2 -DOPENAIR_LTE -DPC_DSP -DPC_TARGET -DPHYSIM -DPHY_CONTEXT -DPUCCH -DRel10=1 -DS1AP_VERSION=R10 -DTRACE_RLC_MUTEX -DUSER_MODE -DX2AP_VERSION=R11 -DXFORMS -mavx2 -msse4.1 -mssse3)
add_definitions (-DRel14 -DCMAKER -DENABLE_ITTI -DENABLE_NAS_UE_LOGGING -DENABLE_SECURITY -DENABLE_USE_CPU_EXECUTION_TIME -DENABLE_USE_MME -DENABLE_VCD -DENB_AGENT -DENB_MODE -DETHERNET=1 -DEXMIMO_IOT -DJUMBO_FRAME -DLINK_ENB_PDCP_TO_GTPV1U -DLOG_NO_THREAD -DMAC_CONTEXT -DMAX_NUM_CCs=1 -DNAS_BUILT_IN_UE -DNAS_UE -DNB_ANTENNAS_RX=2 -DNB_ANTENNAS_TX=2 -DNO_RRM -DNone=1 -DOAI_NW_DRIVER_USE_NETLINK -DOPENAIR2 -DOPENAIR_LTE -DPHYSIM -DPHY_CONTEXT -DRel10=1 -DS1AP_VERSION=R10 -DTRACE_RLC_MUTEX -DX2AP_VERSION=R11 -DXFORMS -mavx2 -msse4.1 -mssse3)
add_compile_options( -fPIC -march=native -Ofast)
include_directories( ./ ${OPENAIR_COMMON_DIR} ${OPENAIR_DIR} ${OPENAIR1_DIR} ${OPENAIR2_DIR} ${OPENAIR2_COMMON_DIR} ${OPENAIR2_DIR}/UTIL/LOG
......
This directory contains the NFAPI code.
It comes in two parts:
1 - open-nFAPI
This is a clone of the github repository
(https://github.com/cisco/open-nFAPI,
commit b3bc579b1697eab829d5d8a2de59c93a61b88fa4).
The patch open-nfapi.oai.patch has then been applied.
2 - oai_integration
This is code written by David Price from Cisco to integrate
open-nFAPI into OpenAirInterface.
......@@ -19,31 +19,33 @@
* contact@openairinterface.org
*/
#ifndef _IOCTL_H
#define _IOCTL_H
#include <sys/ioctl.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <net/if.h>
#include <linux/ipv6.h>
#include <linux/in.h>
#include <linux/in6.h>
//#include <linux/netdevice.h>
#include <pthread.h>
void set_thread_priority(int priority)
{
//printf("%s(priority:%d)\n", __FUNCTION__, priority);
pthread_attr_t ptAttr;
//#include <graal_constant.h>
//#define GRAAL_STATE_IDLE 0
//#define GRAAL_STATE_CONNECTED 1
//#define GRAAL_STATE_ESTABLISHMENT_REQUEST 2
//#define GRAAL_STATE_ESTABLISHMENT_FAILURE 3
//#define GRAAL_STATE_RELEASE_FAILURE 4
struct sched_param schedParam;
schedParam.__sched_priority = priority; //79;
if(sched_setscheduler(0, SCHED_RR, &schedParam) != 0)
{
printf("Failed to set scheduler to SCHED_RR\n");
}
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
if(pthread_attr_setschedpolicy(&ptAttr, SCHED_RR) != 0)
{
printf("Failed to set pthread sched policy SCHED_RR\n");
}
extern int inet_pton(int af, const char *src, void *dst);
extern char *inet_ntop(int af, const void *src, char *dst, size_t sise);
pthread_attr_setinheritsched(&ptAttr, PTHREAD_EXPLICIT_SCHED);
#endif //_IOCTL_H
struct sched_param thread_params;
thread_params.sched_priority = 20;
if(pthread_attr_setschedparam(&ptAttr, &thread_params) != 0)
{
printf("failed to set sched param\n");
}
}
This diff is collapsed.
......@@ -19,20 +19,9 @@
* contact@openairinterface.org
*/
#ifndef PGM_LINK_H_
#define PGM_LINK_H_
#if !defined(NFAPI_PNF_H__)
#define NFAPI_PNF_H__
/* Define prototypes only if enabled */
#if defined(ENABLE_PGM_TRANSPORT)
void bypass_tx_nack(unsigned int frame, unsigned int next_slot);
int pgm_oai_init(char *if_name);
int pgm_recv_msg(int group, uint8_t *buffer, uint32_t length,
unsigned int frame, unsigned int next_slot);
int pgm_link_send_msg(int group, uint8_t *data, uint32_t len);
void configure_nfapi_pnf(char *vnf_ip_addr, int vnf_p5_port, char *pnf_ip_addr, int pnf_p7_port, int vnf_p7_port);
#endif
#endif /* PGM_LINK_H_ */
This diff is collapsed.
......@@ -19,26 +19,9 @@
* contact@openairinterface.org
*/
/*! \file rtai_mem.h
* \brief a wrapper for Unified RTAI real-time memory management.
* \author Florian Kaltenberger
* \date 2011-04-06
* \version 0.1
* \company Eurecom
* \email: florian.kaltenberger@eurecom.fr
* \note
* \bug
* \warning
*/
#if !defined(NFAPI_VNF_H__)
#define NFAPI_VNF_H__
/*
void* rt_alloc_wrapper(int size);
int rt_free_wrapper(void* ptr);
void* rt_realloc_wrapper(void* oldptr, int size);
*/
void* rt_realloc(void* oldptr, int size);
void configure_nfapi_vnf(char *vnf_addr, int vnf_p5_port);
void* rt_calloc(int nmemb, int size);
#endif
/*
* Copyright 2017 Cisco Systems, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef _VENDOR_EXT_H_
#define _VENDOR_EXT_H_
#include "nfapi_interface.h"
typedef enum {
P5_VENDOR_EXT_REQ = NFAPI_VENDOR_EXT_MSG_MIN,
P5_VENDOR_EXT_RSP,
P7_VENDOR_EXT_REQ,
P7_VENDOR_EXT_IND
} vendor_ext_message_id_e;
typedef struct {
nfapi_p4_p5_message_header_t header;
uint16_t dummy1;
uint16_t dummy2;
} vendor_ext_p5_req;
typedef struct {
nfapi_p4_p5_message_header_t header;
uint16_t error_code;
} vendor_ext_p5_rsp;
typedef struct {
nfapi_p7_message_header_t header;
uint16_t dummy1;
uint16_t dummy2;
} vendor_ext_p7_req;
typedef struct {
nfapi_p7_message_header_t header;
uint16_t error_code;
} vendor_ext_p7_ind;
typedef struct {
nfapi_tl_t tl;
uint32_t dummy;
} vendor_ext_tlv_1;
#define VENDOR_EXT_TLV_1_TAG 0xF001
typedef struct {
nfapi_tl_t tl;
uint32_t dummy;
} vendor_ext_tlv_2;
#define VENDOR_EXT_TLV_2_TAG 0xF002
#endif // _VENDOR_EXT_
env:
global:
# The next declaration is the encrypted COVERITY_SCAN_TOKEN, created
# via the "travis encrypt" command using the project repo's public key
- secure: "oNj8JhGBN/zjzrAU7y2Nn/wxSxA/MDp2Y8fVLLp6fhx+y2mWdlMZhgCjeKSpdbGtroUnxErX1P8t+8EPz2+mMoq+G809Q9t7eJjd1+6nkVhEEfDXN83BmJkvIylC0/IKJiT2wCa8LzbdhpQUFyZ1Gk1WKZozAW5HotfFjm6/NFi/GX4uA7S0tU5E4yC3r4yqH9cLZ+arWMOEY/X0lrx0n6tLjDe921kFwkZQGFzAzrbXN2fZXKQ3xFcpREWEgEWsY7H2n4T7oJI3nEPY4P/4kvCjeQMjnlATEwtcciBiUbHRew4WWSTndF54crRlqFlzFcEf/Ouz27U/d2xYHJWcWNi88l+/qsb+V0uobwhiGUJGbVhf9IkgEO3tr/zbwkPDFrXpa/1xuSoc6jDm8i61gKQkcBhQsRFXlciPvwLhiL07gzeAfZD1Yke3tE+0geHPbEA0czzwtHe35jorAKYWsFXOXmcoK9t9SpnvBRFz6JuEsHPooafze43sTJg3qkgBszkU+U38CneeAVwo/uTA3Zw1ZrtOQv56v0UvAHze/VAF5z3rFJPl1oJl60OI8V5UBg4yIa2bySKhO//zwd4MGmsBpcWwDuu2BHUVasfk0vaetVxVVtdXG/2BuBP+IXinpJtI48NSFs6PT82dHz4cDF/iLDs0hPC6sbV258PY8F0="
language: cpp
dist: trusty
sudo: required
compiler:
- g++
before_install:
- sudo apt-get install doxygen
- sudo apt-get install libcunit1-dev
- sudo apt-get install libz-dev
- sudo apt-get install libsctp-dev
- sudo apt-get install libboost-all-dev
- autoreconf -i
addons:
coverity_scan:
project:
name: cisco-open-nFAPI
version: 1.0
description: Build submitted via Travis CI
notification_email: xxx@cisco.com
build_command_prepend: ./configure
build_command: make
branch_pattern: coverity_scan
script:
- ./configure && make && make check
This diff is collapsed.
ACLOCAL_AMFLAGS = -I m4
SUBDIRS =common/ \
sim_common/ \
nfapi/ \
pnf/ \
vnf/ \
nfapi/tests \
pnf/tests \
vnf/tests \
pnf_sim/ \
vnf_sim/ \
integration_tests/ \
docs/ \
$(NULL)
[![Build Status](https://travis-ci.org/cisco/open-nFAPI.svg?branch=master)](https://travis-ci.org/cisco/open-nFAPI)
[![Coverity Status](https://scan.coverity.com/projects/11791/badge.svg)](https://scan.coverity.com/projects/cisco-open-nfapi)
# open-nFAPI
Open-nFAPI is implementation of the Small Cell Forum's network functional API or nFAPI for short.
nFAPI defines a network protocol that is used to connect a Physical Network Function (PNF)
running LTE Layer 1 to a Virtual Network Function (VNF) running LTE layer 2 and above. The specification
can be found at http://scf.io/documents/082.
The aim of open-nFAPI is to provide an open interface between LTE layer 1 and layer 2 to allow for
interoperability between the PNF and VNF & also to facilitate the sharing of PNF's between
different VNF's
Open-nFAPI implements the P4, P5 and P7 interfaces as defined by the nFAPI specification.
* The P5 interface allows the VNF to query and configure the 'resources' of the PNF; i.e slice it into
1 or more PHY instances.
* The P7 interface is used to send the subframe information between the PNF and VNF for a PHY instance
* The P4 interface allows the VNF to request the PNF PHY instance to perform measurements of the surrounding network
The remaining interfaces are currently outside of the scope of this project.
Supports release 082.09.05 of the nFAPI specification
**The Small Cell Forum cordially requests that any derivative work that looks to
extend the nFAPI libraries use the specified vendor extension techniques,
so ensuring the widest interoperability of the baseline nFAPI specification
in those derivative works.**
## Awards
The Open-nFAPI project has won the Small Cell Forum Judges Choice award 2017. (http://www.smallcellforum.org/awards-2/winners-2017/)
## Licensing
The open-nFAPI libraries are release by CISCO under an Apache 2 license. See `LICENSE.md` file for details
## Downloading
The open-nFAPI project can be pulled from git hub
```
git clone https://github.com/cisco/open-nFAPI.git nfapi
```
The following dependencies are required. These are based on a fresh ubuntu installation.
```
sudo apt-get install autoconf
sudo apt-get install gcc
sudo apt-get install g++
sudo apt-get install libtool
sudo apt-get install make
sudo apt-get install doxygen
sudo apt-get install libcunit1-dev
sudo apt-get install libz-dev
sudo apt-get install libsctp-dev
sudo apt-get install libboost-all-dev
```
## Building
To build the open-nFAPI project
```
autoreconf -i
./configure
make
```
To run the unit and integration tests
```
make check
```
You may notice in the console output of the final integration tests the following
```
*** Missing subframe 123 125
```
Out of the box the machine on which you are running has not be configured for real time operation as a result
the vnf may not be scheduled at the correct times and hence it may risk 'missing' subframe opportunities. This
warning indicates this has happened.
## Running the simulator
The vnf and pnf simulator can be run using the following commands. The pnf and vnf simulator support sourcing and sinking
data over udp. Review the xml configuration files for the details of the port and address to configure. Console logging will show
which address:port is being used
Note : Pinning the simulators to unused cores will produce more consistent behaviour.
Note : You may have to run the processes with sudo to be able to set the real time scheduling and priority
### vnf simulator
To run the vnf simulator you need to specify the port the vnf will listen for p5 connection request upon and also the xml configuration file
```
vnfsim <port> <xml config file>
```
### pnf simulator
To run the vnf simulator you need to specify the addrss & port the pnf will connect to the vnf on and also the xml configuration file
```
pnfsim <address> <port> <xml config file>
```
## Directory structure
```
docs doxgen documentation
common common code used by the nfapi libraries
nfapi the nfapi library including message definitions & encode/decode functions
pnf the pnf library for p4, p5, & p7 interfaces
vnf the vnf library for p4, p5, & p7 interfaces
sim_common common simulation for used by the vnf and pnf sim
vnf_sim a vnf simulator including a stub mac implementation
pnf_sim a pnf simualtor including a fapi interface defintion and stub implementation
xml xml configuration files for the vnf and pnf simulator
wireshark code for a wireshark dissector for the nFAPI protocol
```
## Coverity
Coverity runs on the coverity-scan branch. Changes must be merged to the coverity-scan branch to be checked.
## eNB Integration - Open Air Interface
The open-nFAPI implementation has been integrated with the Open Air Interface solution here (https://gitlab.eurecom.fr/oai/openairinterface5g) and is (at the time of writing) here (https://gitlab.eurecom.fr/daveprice/openairinterface5g/tree/nfapi-ru-rau-split). The open-nFAPI implementation is integrated with the source eNB implementation with any changes required applied as a patch on top of the baseline open-nFAPI library. Any extensions required must be implemented through the vendor extensions as specified by the Small Cell Forum documentation. Any integration wrapping of functionality must be done within the target environment as shown in the Open Air Interface implementation nfapi directory which is defined by the $NFAPI_DIR location at the top level.
#
# Copyright 2017 Cisco Systems, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
AM_CPPFLAGS = -I$(top_srcdir)/common/public_inc -g -Wall -Werror
noinst_LIBRARIES =libnfapi_common.a
libnfapi_common_a_SOURCES = src/debug.c
libnfapi_common_a_CFLAGS =$(AM_CFLAGS)
lib_LTLIBRARIES =libnfapi_common.la
libnfapi_common_la_SOURCES = src/debug.c
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/*
* Copyright 2017 Cisco Systems, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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