Commit 60b04f0c authored by Romain Beurdouche's avatar Romain Beurdouche

feat(nr_unitary_defs): Apply clang-format to openair1/SIMULATION/NR_PHY/nr_unitary_defs.h

parent a2d13f75
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
* \email turker.yilmaz@eurecom.fr * \email turker.yilmaz@eurecom.fr
* \note * \note
* \warning * \warning
*/ */
#ifndef __NR_UNITARY_DEFS__H__ #ifndef __NR_UNITARY_DEFS__H__
#define __NR_UNITARY_DEFS__H__ #define __NR_UNITARY_DEFS__H__
...@@ -41,21 +41,21 @@ extern bool stop; ...@@ -41,21 +41,21 @@ extern bool stop;
void sigint_handler(int arg); void sigint_handler(int arg);
const struct sigaction sigint_action = { const struct sigaction sigint_action = {.sa_handler = sigint_handler,
.sa_handler = sigint_handler, // restore handler to default upon entry to the signal handler
// restore handler to default upon entry to the signal handler .sa_flags = SA_RESETHAND};
.sa_flags = SA_RESETHAND
};
int oai_exit=0; int oai_exit = 0;
void exit_function(const char* file, const char* function, const int line, const char *s, const int assert) { void exit_function(const char *file, const char *function, const int line, const char *s, const int assert)
const char * msg= s==NULL ? "no comment": s; {
const char *msg = s == NULL ? "no comment" : s;
printf("Exiting at: %s:%d %s(), %s\n", file, line, function, msg); printf("Exiting at: %s:%d %s(), %s\n", file, line, function, msg);
exit(-1); exit(-1);
} }
signed char quantize(double D, double x, unsigned char B) { signed char quantize(double D, double x, unsigned char B)
{
double qxd; double qxd;
short maxlev; short maxlev;
qxd = floor(x / D); qxd = floor(x / D);
...@@ -66,18 +66,27 @@ signed char quantize(double D, double x, unsigned char B) { ...@@ -66,18 +66,27 @@ signed char quantize(double D, double x, unsigned char B) {
else if (qxd >= maxlev) else if (qxd >= maxlev)
qxd = maxlev - 1; qxd = maxlev - 1;
return ((char) qxd); return ((char)qxd);
} }
int oai_nfapi_rach_ind(nfapi_rach_indication_t *rach_ind) {return(0);} int oai_nfapi_rach_ind(nfapi_rach_indication_t *rach_ind)
//NR_IF_Module_t *NR_IF_Module_init(int Mod_id){return(NULL);} {
int oai_nfapi_ul_config_req(nfapi_ul_config_request_t *ul_config_req) { return(0); } return (0);
}
// NR_IF_Module_t *NR_IF_Module_init(int Mod_id){return(NULL);}
int oai_nfapi_ul_config_req(nfapi_ul_config_request_t *ul_config_req)
{
return (0);
}
void fill_scc_sim(NR_ServingCellConfigCommon_t *scc,uint64_t *ssb_bitmap,int N_RB_DL,int N_RB_UL,int mu_dl,int mu_ul); void fill_scc_sim(NR_ServingCellConfigCommon_t *scc, uint64_t *ssb_bitmap, int N_RB_DL, int N_RB_UL, int mu_dl, int mu_ul);
void fix_scc(NR_ServingCellConfigCommon_t *scc,uint64_t ssbmap); void fix_scc(NR_ServingCellConfigCommon_t *scc, uint64_t ssbmap);
void prepare_scc(NR_ServingCellConfigCommon_t *scc); void prepare_scc(NR_ServingCellConfigCommon_t *scc);
void prepare_msgA_scc(NR_ServingCellConfigCommon_t *scc); void prepare_msgA_scc(NR_ServingCellConfigCommon_t *scc);
void prepare_scd(NR_ServingCellConfig_t *scd); void prepare_scd(NR_ServingCellConfig_t *scd);
uint32_t ngap_generate_gNB_id(void) {return 0;} uint32_t ngap_generate_gNB_id(void)
{
return 0;
}
#endif #endif
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