Commit a98bf76d authored by ChenWeiTai's avatar ChenWeiTai

-Solving some of warning

"implicit declaration of function"
"incompatible pointer type'
parent 5eb919e2
......@@ -33,6 +33,9 @@
#include "assertions.h"
#include <math.h>
#include "PHY/NR_REFSIG/defs.h"
#include "PHY/LTE_REFSIG/lte_refsig.h"
extern uint32_t from_earfcn(int eutra_bandP,uint32_t dl_earfcn);
extern int32_t get_uldl_offset(int eutra_bandP);
......@@ -62,7 +65,6 @@ int l1_north_init_gNB() {
LOG_I(PHY,"%s() RC.gNB[%d][%d] installing callbacks\n", __FUNCTION__, i, j);
RC.gNB[i][j]->if_inst->PHY_config_req = nr_phy_config_request;
nr_phy_config_request(&RC.gNB[i][j]->gNB_config);
RC.gNB[i][j]->if_inst->schedule_response = schedule_response;
}
}
......
......@@ -26,12 +26,12 @@
uint32_t nr_subcarrier_spacing[MAX_NUM_SUBCARRIER_SPACING] = {15e3, 30e3, 60e3, 120e3, 240e3};
uint16_t nr_slots_per_subframe[MAX_NUM_SUBCARRIER_SPACING] = {1, 2, 4, 16, 32};
int nr_init_frame_parms(nfapi_config_request_t* config,
int nr_init_frame_parms(nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms)
{
int N_RB = config->rf_config.dl_channel_bandwidth.value;
int Ncp = config->subframe_config.dl_cyclic_prefix_type.value;
int N_RB = config->rf_config.dl_carrierBandwidth.value;
int Ncp = config->subframe_config.dl_prefix_type.value;
int mu = config->subframe_config.numerology_index_mu.value;
#if DISABLE_LOG_X
......
......@@ -374,12 +374,13 @@ void phy_config_request(PHY_Config_t *phy_config);
int init_frame_parms(LTE_DL_FRAME_PARMS *frame_parms,uint8_t osf);
void dump_frame_parms(LTE_DL_FRAME_PARMS *frame_parms);
int nr_init_frame_parms(nfapi_config_request_t* config, NR_DL_FRAME_PARMS *frame_parms);
int nr_init_frame_parms(nfapi_nr_config_request_t* config, NR_DL_FRAME_PARMS *frame_parms);
int nr_init_frame_parms_ue(nfapi_config_request_t* config, NR_DL_FRAME_PARMS *frame_parms);
void nr_dump_frame_parms(NR_DL_FRAME_PARMS *frame_parms);
int phy_init_nr_gNB(PHY_VARS_gNB *gNB, unsigned char is_secondary_gNB, unsigned char abstraction_flag);
void nr_phy_config_request(NR_PHY_Config_t *gNB);
void phy_free_nr_gNB(PHY_VARS_gNB *gNB);
int l1_north_init_gNB(void);
/** @} */
#endif
......
......@@ -27,7 +27,7 @@ void nr_init_pbch_dmrs(PHY_VARS_gNB* gNB)
unsigned int n, x1, x2;
unsigned char Nid, i_ssb, i_ssb2;
unsigned char Lmax, l, n_hf, N_hf;
nfapi_config_request_t *cfg = &gNB->gNB_config;
nfapi_nr_config_request_t *cfg = &gNB->gNB_config;
NR_DL_FRAME_PARMS *fp = &gNB->frame_parms;
Nid = cfg->sch_config.physical_cell_id.value;
......
......@@ -46,7 +46,7 @@ int nr_generate_pbch_dmrs(uint32_t *gold_pbch_dmrs,
int16_t amp,
uint8_t ssb_start_symbol,
uint8_t nushift,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms)
{
int k,l;
......@@ -159,7 +159,7 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
uint8_t n_hf,
int sfn,
int frame_mod8,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms)
{
......
......@@ -28,7 +28,7 @@ int nr_generate_pss( int16_t *d_pss,
int32_t **txdataF,
int16_t amp,
uint8_t ssb_start_symbol,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms)
{
int i,k,l,m;
......
......@@ -27,7 +27,7 @@ int nr_generate_sss( int16_t *d_sss,
int32_t **txdataF,
int16_t amp,
uint8_t ssb_start_symbol,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms)
{
int i,k,l;
......
......@@ -36,7 +36,7 @@ int nr_generate_pss( int16_t *d_pss,
int32_t **txdataF,
int16_t amp,
uint8_t ssb_start_symbol,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms);
/*!
......@@ -49,7 +49,7 @@ int nr_generate_sss( int16_t *d_sss,
int32_t **txdataF,
int16_t amp,
uint8_t ssb_start_symbol,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms);
/*!
......@@ -63,7 +63,7 @@ int nr_generate_pbch_dmrs(uint32_t *gold_pbch_dmrs,
int16_t amp,
uint8_t ssb_start_symbol,
uint8_t nushift,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms);
/*!
......@@ -91,7 +91,7 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
uint8_t n_hf,
int sfn,
int frame_mod8,
nfapi_config_request_t* config,
nfapi_nr_config_request_t* config,
NR_DL_FRAME_PARMS *frame_parms);
#endif /*__NR_TRANSPORT__H__*/
......@@ -117,7 +117,7 @@ typedef struct PHY_VARS_gNB_s {
nfapi_nr_config_request_t gNB_config;
NR_DL_FRAME_PARMS frame_parms;
PHY_MEASUREMENTS_gNB measurements;
IF_Module_t *if_inst;
NR_IF_Module_t *if_inst;
UL_IND_t UL_INFO;
pthread_mutex_t UL_INFO_mutex;
/// NFAPI RX ULSCH information
......
......@@ -240,10 +240,10 @@ typedef struct PHY_VARS_gNB_s {
int rx_total_gain_dB;
int (*start_if)(struct RU_t_s *ru,struct PHY_VARS_gNB_s *gNB);
uint8_t local_flag;
nfapi_config_request_t gNB_config;
nfapi_nr_config_request_t gNB_config;
NR_DL_FRAME_PARMS frame_parms;
PHY_MEASUREMENTS_gNB measurements;
IF_Module_t *if_inst;
NR_IF_Module_t *if_inst;
UL_IND_t UL_INFO;
pthread_mutex_t UL_INFO_mutex;
/// NFAPI RX ULSCH information
......
......@@ -32,7 +32,6 @@
#include "PHY_INTERFACE/phy_interface.h"
#include "SCHED/sched_eNB.h"
lte_subframe_t nr_subframe_select (nfapi_config_request_t *cfg, unsigned char subframe);
int nr_generate_pss( int16_t *d_pss,
int32_t **txdataF,
int16_t amp,
......
......@@ -34,7 +34,7 @@
#include "SCHED_NR/defs.h"
nr_subframe_t nr_subframe_select(nfapi_config_request_t *cfg,unsigned char subframe)
nr_subframe_t nr_subframe_select(nfapi_nr_config_request_t *cfg,unsigned char subframe)
{
if (cfg->subframe_config.duplex_mode.value == FDD)
return(SF_DL);
......
......@@ -75,7 +75,7 @@ int return_ssb_type(nfapi_config_request_t *cfg)
}*/
// First SSB starting symbol candidate is used and type B is chosen for 30kHz SCS
int nr_get_ssb_start_symbol(nfapi_config_request_t *cfg, NR_DL_FRAME_PARMS *fp)
int nr_get_ssb_start_symbol(nfapi_nr_config_request_t *cfg, NR_DL_FRAME_PARMS *fp)
{
int mu = cfg->subframe_config.numerology_index_mu.value;
int symbol = 0;
......@@ -118,7 +118,7 @@ void nr_set_ssb_first_subcarrier(nfapi_config_request_t *cfg, NR_DL_FRAME_PARMS
void nr_common_signal_procedures (PHY_VARS_gNB *gNB,int frame, int subframe) {
NR_DL_FRAME_PARMS *fp=&gNB->frame_parms;
nfapi_config_request_t *cfg = &gNB->gNB_config;
nfapi_nr_config_request_t *cfg = &gNB->gNB_config;
int **txdataF = gNB->common_vars.txdataF;
uint8_t *pbch_pdu=&gNB->pbch_pdu[0];
int ss_subframe = (cfg->sch_config.half_frame_index.value)? 5 : 0;
......@@ -161,7 +161,7 @@ void phy_procedures_gNB_TX(PHY_VARS_gNB *gNB,
int subframe=proc->subframe_tx;
NR_DL_FRAME_PARMS *fp=&gNB->frame_parms;
nfapi_config_request_t *cfg = &gNB->gNB_config;
nfapi_nr_config_request_t *cfg = &gNB->gNB_config;
int offset = gNB->CC_id;
......
......@@ -46,6 +46,8 @@
# include "gtpv1u_eNB_task.h"
# endif
# include "PHY/INIT/phy_init.h"
extern unsigned char NB_gNB_INST;
#endif
......
This diff is collapsed.
......@@ -73,6 +73,11 @@
#include "targets/ARCH/COMMON/common_lib.h"
//solve implicit declaration
#include "PHY/LTE_ESTIMATION/lte_estimation.h"
#include "PHY/LTE_TRANSPORT/transport_proto.h"
#include "PHY/LTE_TRANSPORT/transport_common_proto.h"
/** @defgroup _mac MAC
* @ingroup _oai2
* @{
......
......@@ -32,6 +32,7 @@
#include "LAYER2/MAC/mac.h"
#include "PHY/defs_common.h" // for PRACH_RESOURCES_t and lte_subframe_t
/** \addtogroup _mac
* @{
*/
......
This diff is collapsed.
......@@ -94,6 +94,8 @@
#include "SIMULATION/TOOLS/sim.h" // for taus
#include "PHY/LTE_TRANSPORT/transport_proto.h"
//#define XER_PRINT
extern RAN_CONTEXT_t RC;
......
......@@ -185,11 +185,11 @@ typedef enum {
LOCALIZE,
RRH,
X2AP,
MAX_LOG_COMPONENTS,
GNB_APP,
NR_RRC,
NR_MAC,
NR_PHY,
MAX_LOG_COMPONENTS,
}
comp_name_t;
......
......@@ -926,9 +926,9 @@ void init_gNB(int single_thread_flag,int wait_for_sync) {
#endif
LOG_I(PHY,"Registering with MAC interface module\n");
AssertFatal((gNB->if_inst = IF_Module_init(inst))!=NULL,"Cannot register interface");
AssertFatal((gNB->if_inst = NR_IF_Module_init(inst))!=NULL,"Cannot register interface");
gNB->if_inst->schedule_response = schedule_response;
gNB->if_inst->PHY_config_req = phy_config_request;
gNB->if_inst->PHY_config_req = nr_phy_config_request;
nr_phy_config_request(gNB);
memset((void*)&gNB->UL_INFO,0,sizeof(gNB->UL_INFO));
memset((void*)&gNB->Sched_INFO,0,sizeof(gNB->Sched_INFO));
......
......@@ -56,7 +56,7 @@
#include "LAYER2/MAC/mac_proto.h"
#include "RRC/LTE/rrc_vars.h"
#include "PHY_INTERFACE/phy_interface_vars.h"
#include "gnb_config.h"
#ifdef SMBV
#include "PHY/TOOLS/smbv.h"
unsigned short config_frames[4] = {2,9,11,13};
......
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