Commit c3606017 authored by WEI-TAI CHEN's avatar WEI-TAI CHEN

fix error and warning

parent e8e8c877
......@@ -1471,6 +1471,7 @@ set (MAC_SRC
${NR_MAC_DIR}/config.c
${NR_MAC_DIR}/gNB_scheduler.c
${NR_MAC_DIR}/gNB_scheduler_bch.c
${NR_MAC_DIR}/gNB_scheduler_primitives.c
)
......
......@@ -115,8 +115,9 @@ static uint32_t gNB_app_register(uint32_t gnb_id_start, uint32_t gnb_id_end)//,
return register_gnb_pending;
}
# endif
#endif
*/
#endif
/*------------------------------------------------------------------------------*/
void *gNB_app_task(void *args_p)
......
......@@ -606,11 +606,11 @@ int RCconfig_NRRRC(MessageDef *msg_p, uint32_t i, gNB_RRC_INST *rrc) {
paramdef_t GNBParams[] = GNBPARAMS_DESC;
paramlist_def_t GNBParamList = {GNB_CONFIG_STRING_GNB_LIST,NULL,0};
////////// Physical parameters
//checkedparam_t config_check_CCparams[] = NRCCPARAMS_CHECK;
checkedparam_t config_check_CCparams[] = NRCCPARAMS_CHECK;
paramdef_t CCsParams[] = NRCCPARAMS_DESC;
paramlist_def_t CCsParamList = {GNB_CONFIG_STRING_COMPONENT_CARRIERS,NULL,0};
//paramdef_t SRB1Params[] = SRB1PARAMS_DESC;
paramdef_t SRB1Params[] = SRB1PARAMS_DESC;
/* get global parameters, defined outside any section in the config file */
......
......@@ -176,6 +176,7 @@ void check_nr_ul_failure(module_id_t module_idP,
}
*/
/*
void schedule_nr_SRS(module_id_t module_idP, frame_t frameP, sub_frame_t subframeP)
{
gNB_MAC_INST *gNB = RC.nrmac[module_idP];
......@@ -257,7 +258,7 @@ void schedule_nr_SRS(module_id_t module_idP, frame_t frameP, sub_frame_t subfram
} // SRS config
}
}
*/
void copy_nr_ulreq(module_id_t module_idP, frame_t frameP, sub_frame_t subframeP)
{
int CC_id;
......
......@@ -31,16 +31,20 @@
#include "assertions.h"
#include "LAYER2/MAC/mac.h"
#include "LAYER2/NR_MAC_gNB/mac.h"
#include "LAYER2/MAC/mac_extern.h"
#include "LAYER2/NR_MAC_gNB/mac_proto.h"
#include "LAYER2/NR_MAC_gNB/mac_proto.h"
#include "UTIL/LOG/log.h"
#include "UTIL/LOG/vcd_signal_dumper.h"
#include "UTIL/OPT/opt.h"
#include "OCG.h"
#include "OCG_extern.h"
#include "RRC/LTE/rrc_extern.h"
#include "RRC/NR/nr_rrc_extern.h"
#include "RRC/L2_INTERFACE/openair_rrc_L2_interface.h"
//#include "LAYER2/MAC/pre_processor.c"
#include "pdcp.h"
......@@ -52,7 +56,7 @@
#include "T.h"
#define ENABLE_MAC_PAYLOAD_DEBUG
#define DEBUG_eNB_SCHEDULER 1
#define DEBUG_gNB_SCHEDULER 1
#include "common/ran_context.h"
......@@ -60,8 +64,7 @@ extern RAN_CONTEXT_t RC;
extern int n_active_slices;
int is_nr_UL_sf(NR_COMMON_channels_t * ccP, sub_frame_t subframeP)
{
int is_nr_UL_sf(NR_COMMON_channels_t * ccP, sub_frame_t subframeP){
// if FDD return dummy value
if (ccP->tdd_Config == NULL)
return (0);
......
......@@ -5,8 +5,6 @@
#include "mac.h"
#include "PHY/defs_nr_common.h"
void schedule_nr_mib(module_id_t module_idP, frame_t frameP, sub_frame_t subframeP);
void mac_top_init_gNB(void);
int rrc_mac_config_req_gNB(module_id_t Mod_idP,
......@@ -19,13 +17,17 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
NR_ServingCellConfigCommon_t *servingcellconfigcommon
);
int is_nr_UL_sf(NR_COMMON_channels_t * ccP, sub_frame_t subframeP);
void clear_nr_nfapi_information(gNB_MAC_INST * gNB,
int CC_idP,
frame_t frameP,
sub_frame_t subframeP)
sub_frame_t subframeP);
void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
frame_t frameP,
sub_frame_t subframeP);
void schedule_nr_mib(module_id_t module_idP, frame_t frameP, sub_frame_t subframeP);
#endif /*__LAYER2_NR_MAC_PROTO_H__*/
\ No newline at end of file
......@@ -38,7 +38,7 @@ int8_t mac_rrc_nr_data_req(const module_id_t Mod_idP,
mib = &carrier->mib;
if( (Srb_id & RAB_OFFSET ) == MIBCH) {
mib->message.choice.mib->systemFrameNumber.buf = sfn_msb[0] << 2;
mib->message.choice.mib->systemFrameNumber.buf[0] = sfn_msb << 2;
enc_rval = uper_encode_to_buffer(&asn_DEF_NR_BCCH_BCH_Message,
NULL,
(void *)mib,
......
......@@ -207,7 +207,7 @@ uint8_t do_MIB_NR(rrc_gNB_carrier_data_t *carrier,
//36.331 SFN BIT STRING (SIZE (8) , 38.331 SFN BIT STRING (SIZE (6))
uint8_t sfn_msb = (uint8_t)((frame>>4)&0x3f);
mib->message.choice.mib->systemFrameNumber.buf = CALLOC(1,sizeof(uint8_t));
mib->message.choice.mib->systemFrameNumber.buf = sfn_msb[0] << 2;
mib->message.choice.mib->systemFrameNumber.buf[0] = sfn_msb << 2;
mib->message.choice.mib->systemFrameNumber.size = 1;
mib->message.choice.mib->systemFrameNumber.bits_unused=2;
......
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