1 /*******************************************************************************
2 ################################################################################
3 # Copyright (c) [2017-2019] [Radisys] #
5 # Licensed under the Apache License, Version 2.0 (the "License"); #
6 # you may not use this file except in compliance with the License. #
7 # You may obtain a copy of the License at #
9 # http://www.apache.org/licenses/LICENSE-2.0 #
11 # Unless required by applicable law or agreed to in writing, software #
12 # distributed under the License is distributed on an "AS IS" BASIS, #
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
14 # See the License for the specific language governing permissions and #
15 # limitations under the License. #
16 ################################################################################
17 *******************************************************************************/
19 #ifndef __DU_CONFIG_H_
20 #define __DU_CONFIG_H__
23 #include "du_app_mac_inf.h"
25 #include "odu_common_codec.h"
30 #define DU_IP_V4_ADDR "192.168.130.81"
31 #define CU_IP_V4_ADDR "10.0.2.25"
32 #define RIC_IP_V4_ADDR "192.168.130.80"
35 #define RIC_PORT 36422
36 #define DU_EGTP_PORT 39001
37 #define CU_EGTP_PORT 39002
40 #define DU_NAME "ORAN_OAM_DU"
41 #define CELL_TYPE SMALL
42 #define DUPLEX_MODE DUP_MODE_FDD
51 #define NR_ARFCN 2079427
53 #define NR_FREQ_BAND 257
54 #define NR_FREQ_BAND_IND 78
60 #define FREQ_SHIFT_7P5KHZ FALSE
61 #define SSB_PBCH_PWR -5
62 #define BCH_PAYLOAD MAC_GEN_FULL_PBCH_PAYLD
63 #define TOTAL_PRB_BW 106
64 #define SUBCARRIER_SPACING 0
65 #define NORMAL_CYCLIC_PREFIX 0
66 #define SCS_CARRIER_BANDWIDTH 273 /* Subcarrier spacing- carrier bandwidth */
67 #define OFFSET_TO_POINT_A 24 /* PRB Offset to Point A */
68 #define BETA_PSS BETA_PSS_0DB
69 #define SSB_PERIODICITY 5
70 #define SSB_SUBCARRIER_OFFSET 0
71 #define SSB_MULT_CARRIER_BAND FALSE
72 #define MULT_CELL_CARRIER FALSE
73 #define FREQ_LOC_BW 1099 /* DL frequency location and bandwidth */
77 /* MACRO defines for PRACH Configuration */
78 #define PRACH_CONFIG_IDX 105
79 #define PRACH_FREQ_START 0
80 #define PRACH_SEQ_LEN SHORT_SEQUENCE
81 #define PRACH_SUBCARRIER_SPACING 1
82 #define PRACH_RESTRICTED_SET_CFG 0
83 #define NUM_PRACH_FDM 1
84 #define ROOT_SEQ_IDX 24
85 #define NUM_ROOT_SEQ 1
86 #define ZERO_CORRELATION_ZONE_CFG 6
87 #define NUM_UNUSED_ROOT_SEQ 0
88 #define UNUSED_ROOT_SEQ 1
89 #define SSB_PER_RACH 1
90 #define PRACH_MULT_CARRIER_BAND FALSE
91 #define PRACH_PREAMBLE_RCVD_TGT_PWR -74
92 #define NUM_RA_PREAMBLE 63
93 #define RSRP_THRESHOLD_SSB 31
94 #define TDD_PERIODICITY TX_PRDCTY_MS_2P5
95 #define RSS_MEASUREMENT_UNIT DONT_REPORT_RSSI
96 #define RA_CONT_RES_TIMER 64
97 #define RA_RSP_WINDOW 180
98 #define PRACH_RESTRICTED_SET 0 /* Unrestricted */
101 /* MACRCO Ddefine for PDCCH Configuration */
102 #define PDCCH_CTRL_RSRC_SET_ZERO 13 /* Control resouce set zero */
103 #define PDCCH_SEARCH_SPACE_ZERO 0 /* Search space zero */
104 #define PDCCH_SEARCH_SPACE_ID 1 /* Common search space id */
105 #define PDCCH_CTRL_RSRC_SET_ID 0 /* Control resource set id */
106 #define PDCCH_SEARCH_SPACE_ID_SIB1 0 /* Search space id for sib1 */
107 #define PDCCH_SEARCH_SPACE_ID_PAGING 1 /* Search space id for paging */
108 #define PDCCH_SEARCH_SPACE_ID_RA 1 /* Search spaced id for random access */
109 #define PDCCH_SERACH_SPACE_DCI_FORMAT 0
110 #define SIB1_VALUE_TAG 10
112 /* MACRCO Ddefine for PDSCH Configuration */
114 #define PDSCH_START_SYMBOL 2
115 #define PDSCH_LENGTH_SYMBOL 12
118 /* MACRO Define for PUSCH Configuration */
120 #define PUSCH_START_SYMBOL 0
121 #define PUSCH_LENGTH_SYMBOL 14
123 #define PUSCH_MSG3_DELTA_PREAMBLE 0
124 #define PUSCH_P0_NOMINAL_WITH_GRANT -70
126 /* Macro define for PUCCH Configuration */
127 #define PUCCH_RSRC_COMMON 0
128 #define PUCCH_P0_NOMINAL -74
130 /* MACRO defines for TDD DL-UL Configuration */
131 #define NUM_DL_SLOTS 3
132 #define NUM_DL_SYMBOLS 12
133 #define NUM_UL_SLOTS 1
134 #define NUM_UL_SYMBOLS 0
139 #define MAX_DU_PORT 2
140 #define F1_INTERFACE 0
141 #define E2_INTERFACE 1
150 #define DU_SELECTOR_LC 0
151 #define DU_SELECTOR_TC 1
152 #define DU_SELECTOR_LWLC 2
155 /* Macro definitions for EGTP procedures */
156 #define EGTP_LCL_TEID 1 /* EGTP local tunnel id */
157 #define EGTP_REM_TEID 10 /* EGTP remote tinnel id */
161 /* Macro definitions for F1 procedures */
162 #define CU_DU_NAME_LEN_MAX 30 /* Max length of CU/DU name string */
163 #define MAX_F1_CONNECTIONS 65536 /* Max num of F1 connections */
164 #define DU_MAX_CELLS 1 /* Max num of cells served by gNB-DU */
165 #define MAX_PLMN 6 /* Max num of broadcast PLMN ids */
166 #define MAXNRARFCN 3279165 /* Maximum values of NRAFCN */
167 #define MAXNRCELLBANDS 2 /* Maximum number of frequency bands */
168 #define MAX_NUM_OF_SLICE_ITEMS 1024 /* Maximum number of signalled slice support items */
169 #define MAXBPLMNNRMINUS1 1 /* Maximum number of PLMN Ids broadcast in an NR cell minus 1 */
170 #define MAXNUMOFSIBTYPES 32 /* Maximum number of SIB types */
171 #define MAX_UEID 512 /* Maximum number of UE Ids */
172 #define MAX_TNL_ASSOC 32 /* Max num of TNL Assoc between CU and DU */
173 #define MAXCELLINENB 256 /* Max num of cells served by eNB */
174 #define MAX_NUM_OF_UE_ID 65536 /* Max num of UEs served by DU */
175 #define MAXNUMOFUACPLMN 12 /* Maximum number of PLMN ids*/
176 #define MAXNUMOFUACPERPLMN 64 /* Maximum number of signalled categories per PLMN */
177 #define NR_RANAC 150 /* RANAC */
178 #define DEFAULT_CELLS 1 /* Max num of broadcast PLMN ids */
181 /* Macro definitions for MIB/SIB1 */
182 #define SYS_FRAME_NUM 0
184 #define SSB_SC_OFFSET 8
185 #define CORESET_ZERO 1
186 #define SEARCH_SPACE_ZERO 8
188 #define CELL_IDENTITY 32
206 INVALID_CU_UE_F1AP_ID,
207 INVALID_DU_UE_F1AP_ID,
208 INTERACTION_WITH_OTHER_PROC,
210 RADIO_RELATED_REASON,
211 INSUFFICIENT_RADIO_RESOURCE,
217 SLICE_RESOURCE_UNAVAILABLE,
218 AMF_ABNORMAL_RELEASE,
224 TRANS_CAUSE_UNSPECIFIED,
225 TRANSPORT_RESOURCE_UNAVAIL
231 ABSTRACT_SYNTAX_ERR_REJECT,
232 ABSTRACT_SYNTAX_ERR_NOTIFY,
233 INCOMPATIBLE_MESSAGE,
235 ABSTRACT_SYNTAX_ERR_MSG_CONSTRUCT,
236 PROTOCOL_CAUSE_UNSPECIFIED
241 CONTROL_PROC_OVERLOAD,
242 INSUFF_USER_PLANE_RESOURCE,
244 O_AND_M_INTERVENTION,
245 MISC_CAUSE_UNSPECIFIED
368 REJECT_RRC_CONN_NON_EMERG_MODT,
369 REJECT_RRC_CONN_SIGNALLING,
370 PERMIT_EMERG_SESSION_AND_MOBILE_TERM_SERVICE,
371 PERMIT_HIGH_PRIOR_SESSION_AND_MOBILE_TERM_SERVICE
372 }F1UacStandardAction;
376 PDSCH_MAPPING_TYPE_A,
377 PDSCH_MAPPING_TYPE_B,
382 PUSCH_MAPPING_TYPE_A,
383 PUSCH_MAPPING_TYPE_B,
387 typedef struct f1RrcVersion
389 char rrcVer[30]; /* Latest RRC Version */
390 uint32_t extRrcVer; /* Latest RRC version extended */
393 typedef struct f1FailCause
397 RadioNwCause radioNwCause; /* Radio Network Layer Cause */
398 TransLayerCause transLayerCause; /* Transport Layer Cause */
399 ProtocolCause protCause; /* Protocol Cause */
400 MiscCause miscCause; /* Miscellaneous Cause */
404 typedef struct f1ProcCode
410 typedef struct f1TriggMsg
416 typedef struct f1ProcCrit
422 typedef struct f1CritDignosIE
424 F1ProcCritVal ieCritVal;
429 typedef struct f1CritDiagnostic
432 F1ProcCode procCode; /* Procedure Code */
433 F1TriggMsg triggeringMsg; /* Triggering Message */
434 F1ProcCrit procCrit; /* Criticality of Triggering msg/proc */
436 F1CritDignosIE diagnosIE;
439 typedef struct f1FailureIE
441 uint32_t transId; /* Uniquely identify transaction */
442 F1FailCause cause; /* Failure cause */
443 uint8_t timeToWait; /* Seconds to be waited before retry */
444 F1CritDiagnostic critDiagnostic; /* Critical diagnostics */
447 typedef struct f1LogicalConnUeAssoc
449 uint32_t gnbCuUeF1apId;
450 uint32_t gnbDuUeF1apId;
451 }F1LogicalConnUeAssoc;
453 typedef struct f1ResetType
457 F1ResetAll resetAll; /* Reset All */
458 F1LogicalConnUeAssoc ueAssocLogicalConn[MAX_F1_CONNECTIONS]; /* In case of Partial Reset : UE associated logical F1 conn list*/
462 typedef struct nrEcgi
468 typedef struct f1SibType
475 typedef struct f1TxBw
477 F1NrScs nrScs; /* NR subcarrier spacing */
478 F1Nrb nrb; /* Transmission bandwidth expressed in units of RBs */
481 typedef struct f1SulInfo
483 uint32_t sulArfcn; /* SUL ARFCN */
484 F1TxBw sulTxBw; /* SUL transmission bandwidth */
487 typedef struct f1FreqBand
490 uint16_t sulBand[MAXNRCELLBANDS];
493 typedef struct f1NrFreqInfo
497 F1FreqBand freqBand[MAXNRCELLBANDS];
500 typedef struct f1NrFddInfo
502 F1NrFreqInfo ulNrFreqInfo; /* UL NR Frequency Info */
503 F1NrFreqInfo dlNrFreqInfo; /* DL NR Frequency Info */
504 F1TxBw ulTxBw; /* UL Transmission bandwidth */
505 F1TxBw dlTxBw; /* DL Transmission bandwidth */
508 typedef struct f1NrTddInfo
510 F1NrFreqInfo nrFreqInfo; /* NR Frequency Info */
511 F1TxBw nrTxBw; /* NR Transmission Bandwidth */
514 typedef struct f1NrModeInfo
523 typedef struct f1EutraFddInfo
525 uint16_t ulOffset; /* UL offset to Point A */
526 uint16_t dlOffset; /* DL offset to Point A */
529 typedef struct f1EutraTddInfo
531 uint16_t tddOffset; /* Offset to Point A */
534 typedef struct f1EutraModeInfo
543 typedef struct f1Snsaai
549 typedef struct epIpAddr
551 char transportAddr[20]; /* Transport Layer Address */
554 typedef struct epIpAddrPort
560 typedef struct f1TaiSliceSuppLst
563 F1Snsaai snssai[MAX_NUM_OF_SLICE_ITEMS];
566 typedef struct f1SrvdPlmn
569 F1TaiSliceSuppLst taiSliceSuppLst;
572 typedef struct f1BrdcstPlmnInfo
574 Plmn plmn[MAX_PLMN]; /* PLMN id list */
575 Plmn extPlmn[MAX_PLMN]; /* Extended PLMN id list */
576 uint16_t tac; /* 5GS-TAC */
577 uint32_t nrCellId; /* NR Cell id */
578 uint8_t ranac; /* RAN Area code */
581 typedef struct f1CellInfo
583 NrEcgi nrCgi; /* Cell global Identity */
584 uint32_t nrPci; /* Physical Cell Identity */
585 Plmn plmn[MAX_PLMN]; /* Available PLMN list */
586 Plmn extPlmn[MAX_PLMN]; /* Extended available PLMN list */
589 typedef struct f1DuCellInfo
591 F1CellInfo cellInfo; /* cell info */
592 uint16_t tac; /* tracking area code */
593 uint16_t epsTac; /* Configured EPS TAC */
594 NrModeInfo f1Mode; /* NR mode info : FDD/TDD */
595 uint8_t measTimeCfg; /* Measurement timing configuration */
596 F1CellDir cellDir; /* Cell Direction */
597 F1CellType cellType; /* Cell Type */
598 F1BrdcstPlmnInfo brdcstPlmnInfo[MAXBPLMNNRMINUS1]; /* Broadcast PLMN Identity Info List */
601 typedef struct f1DuSysInfo
603 uint8_t *mibMsg; /* MIB message */
605 uint8_t *sib1Msg; /* SIB1 message */
609 typedef struct f1CuSysInfo
611 F1SibType sibTypeToUpd[MAXNUMOFSIBTYPES]; /* SIB types to be updated */
614 typedef struct f1DuSrvdCellInfo
616 F1DuCellInfo duCellInfo; /* gNB-DU served cell info */
617 F1DuSysInfo duSysInfo; /* gNB-DU System Information */
620 typedef struct f1DuSrvdCellToDel
622 NrEcgi oldNrCgi; /* Old NR CGI */
623 F1DuSrvdCellInfo srvdCellInfo; /* Info of served cell to be deleted */
626 typedef struct f1CuActCellInfo
628 F1CellInfo cuCellInfo; /* gNB-CU available cell info */
629 F1CuSysInfo cuSysInfo; /* gNB-CU System Information */
632 typedef struct f1ActCellFail
638 typedef struct srvStatus
641 bool switchOffOngoing;
644 typedef struct f1CellStatus
647 SrvStatus status; /* Service status */
650 typedef struct f1DedSIDelUE
652 uint32_t gnbCuUeF1apId;
656 typedef struct tnlAssocInfo
659 EpIpAddr epIpAddr; /* Endpoint-IP Address */
660 EpIpAddrPort epIpAddrport; /* Endpoint-IP Address and Port */
663 typedef struct f1TnlAssocUsage
669 typedef struct f1TnlAssoc
671 F1TnlAssocAddr assocInfo; /* TNL Assoc Transport Layer Info */
672 F1TnlAssocUsage assocUsage; /* TNL Assoc usage */
675 typedef struct f1TnlAssocToRmv
677 F1TnlAssocAddr assocInfoCu; /* TNL Assoc Transport Layer Info of CU */
678 F1TnlAssocAddr assocInfoDu; /* TNL Assoc Transport Layer Info of DU */
681 typedef struct f1TnlAssocSetupFail
683 F1TnlAssocAddr assocInfo;
685 }F1TnlAssocSetupFail;
688 typedef struct f1CellBarred
691 CellBarred cellBarred;
694 typedef struct f1EutraCell
696 uint32_t eutraCellId; /* EUTRA cell id */
697 F1EutraModeInfo mode; /* EUTRA mode info : FDD/TDD */
698 uint8_t rsrcInd; /* Protected EUTRA resource Indication */
701 typedef struct f1ProtectEUTRARsrc
703 uint32_t specShareGrpId; /* Spectrum sharing group id */
704 F1EutraCell eutraCellList[MAXCELLINENB]; /* EUTRA cells list */
707 typedef struct f1UacOperatorDefined
709 uint8_t accessCategory;
711 }F1UacOperatorDefined;
713 typedef struct f1UacCategoryType
717 F1UacStandardAction action; /* UAC standardized action */
718 F1UacOperatorDefined operatorDef; /* UAC operator defined */
722 typedef struct f1UacType
724 uint8_t uacReducInd; /* Value 0 means no access rate reduction. Value 100 means full access rate reduction */
725 F1UacCategoryType uacCategoryType; /* UAC Category type */
728 /* Unified Access Class Assistance Information */
729 typedef struct f1UacAssistInfo
731 Plmn plmn[MAXNUMOFUACPLMN]; /* UAC PLMN list */
732 F1UacType uacType[MAXNUMOFUACPERPLMN]; /* UAC Type list */
735 /* F1 setup related structures */
737 typedef struct f1SetupReq
739 uint32_t transId; /* Uniquely identify transaction */
740 uint32_t duId; /* DU ID */
741 char duName[CU_DU_NAME_LEN_MAX]; /* DU name */
742 F1DuSrvdCellInfo srvdCellLst[DU_MAX_CELLS]; /* Serving cell list */
743 F1RrcVersion rrcVersion; /* RRC version */
746 typedef struct f1setupRsp
748 uint32_t transId; /* Uniquely identify transaction */
749 char cuName[CU_DU_NAME_LEN_MAX]; /* CU Name */
750 F1CuActCellInfo actCellInfo; /* cells to be activated */
751 F1RrcVersion rrcVersion; /* RRC version */
754 typedef struct f1SetupFail
756 F1FailureIE setupFail;
759 /* At reception of the RESET message the gNB-DU shall release all allocated resources on F1
760 * and radio resources related to the UE association(s) indicated explicitly or implicitly in
761 * the RESET message and remove the indicated UE contexts including F1AP ID. */
762 typedef struct f1Reset
764 uint32_t transId; /* Uniquely identify transaction */
765 F1FailCause cause; /* Failure cause */
766 F1ResetType resetType; /* type of reset */
769 /* After the gNB-CU has released all assigned F1 resources and the UE F1AP IDs for all indicated
770 * UE associations which can be used for new UE-associated logical F1-connections over the F1 interface,
771 * the gNB-CU shall respond with the RESET ACKNOWLEDGE message. */
772 typedef struct f1ResetAck
774 uint32_t transId; /* Uniquely identify transaction */
775 F1LogicalConnUeAssoc ueAssocLogicalConn[MAX_F1_CONNECTIONS]; /* UE associated logical F1-connection list */
776 F1CritDiagnostic critDiagnostic; /* Critical diagnostics */
779 typedef struct f1ErrorInd
781 uint32_t transId; /* Uniquely identify transaction */
782 F1Entity errorOrigin; /* Specifies if error is originated at DU or CU */
783 F1FailCause cause; /* Failure cause */
784 /* If failure is due to Ue related message. */
785 uint32_t gnbCuUeF1apId; /* gNB-CU UE F1AP Id */
786 uint32_t gnbDuUeF1apId; /* gNB-DU UE F1AP Id */
787 F1CritDiagnostic critDiagnostic; /* Critical diagnostics */
790 typedef struct f1GnbDuCfgUpd
792 uint32_t transId; /* Uniquely identify transaction */
793 F1DuSrvdCellInfo srvdCellLstAdd[DU_MAX_CELLS]; /* Served cell list to be added */
794 F1DuSrvdCellToDel srvdCellLstMod[DU_MAX_CELLS]; /* Served cell list to be modified */
795 NrEcgi srvdCellLstDel[DU_MAX_CELLS]; /* Served cell list to be deleted */
796 F1CellStatus cellStatus[DU_MAX_CELLS]; /* Cell status */
797 F1DedSIDelUE ueLst[MAX_UEID]; /* Ue list that requires dedicated SI delivery */
799 F1TnlAssocToRmv gnbDuTnlAssocRmv[MAX_TNL_ASSOC]; /* TNL Assoc list to remove */
802 typedef struct f1GnbDuCfgUpdAck
804 uint32_t transId; /* Uniquely identify transaction */
805 F1CuActCellInfo cellLstAct[DU_MAX_CELLS]; /* List of cells to be activated */
806 F1CritDiagnostic critDiagnostic; /* Critical diagnostics */
807 NrEcgi cellLstDeact[DU_MAX_CELLS]; /* List of cells to be deactivated */
810 typedef struct f1GnbDuCfgUpdFail
812 F1FailureIE gnbDuCfgUpdFail;
815 /* Sent by the gNB-CU to transfer updated information associated to an F1-C interface instance */
816 typedef struct f1GnbCuCfgUpd
818 uint32_t transId; /* Uniquely identifies transaction */
819 F1CuActCellInfo cellLstAct[DU_MAX_CELLS]; /* List of cells to be activated */
820 NrEcgi cellLstDeact[DU_MAX_CELLS]; /* List of cells to be deactivated */
821 F1TnlAssoc assocLstAdd[MAX_TNL_ASSOC]; /* List of TNL assocs to be added */
822 F1TnlAssoc assocLstUpd[MAX_TNL_ASSOC]; /* List of TNL assocs to be updated */
823 F1TnlAssocToRmv assocLstRmv[MAX_TNL_ASSOC]; /* List of TNL assocs to be removed */
824 F1CellBarred cellToBarList[DU_MAX_CELLS]; /* List of Cells to be barred */
825 F1ProtectEUTRARsrc protectEutraRsrcList[MAXCELLINENB]; /* List of Protected EUTRA resources */
828 /* Sent by a gNB-DU to a gNB-CU to acknowledge update of information
829 * associated to an F1-C interface instance */
830 typedef struct f1GnbCuCfgUpdAck
832 uint32_t transId; /* Uniquely identify transaction */
833 F1ActCellFail actCellFailList[DU_MAX_CELLS]; /* Cells failed to be activated list */
834 F1CritDiagnostic critDiagnostic; /* Critical diagnostics */
835 F1TnlAssocAddr assocSetupList[MAX_TNL_ASSOC]; /* TNL Assoc Setup list */
836 F1TnlAssocSetupFail assocSetupFailList[MAX_TNL_ASSOC]; /* TNL Assoc Setup fail list */
837 F1DedSIDelUE dedSiDelUelist[MAX_NUM_OF_UE_ID]; /* Dedicated SI delivery needed UE list */
840 typedef struct f1GnbCuCfgUpdFail
842 F1FailureIE gnbCuCfgUpdFail;
845 /* This procedure enables coordination of radio resource allocation between a gNB-CU and
846 * a gNB-DU. Coordination request is sent by CU to DU */
847 typedef struct f1GnbDuRsrcCoordReq
849 uint32_t transId; /* Uniquely identifies transaction */
850 F1ReqType reqType; /* Request type */
851 uint8_t cellResCoordReqCont; /* Container for X2AP E-UTRA - NR cell resource coordination request */
852 F1IgnoreReq ignoreReq; /* Ignore coordination request */
853 }F1GnbDuRsrcCoordReq;
855 /* This message is sent by a gNB-DU to a gNB-CU, to express the desired resource allocation
856 * for data traffic, as a response to the GNB-DU RESOURCE COORDINATION REQUEST. */
857 typedef struct f1GnbDuRsrcCoordRsp
859 uint32_t transId; /* Uniquely identifies transaction */
860 uint8_t cellResCoordRspCont; /* Container for X2AP E-UTRA - NR cell resource coordination response */
861 }F1GnbDuRsrcCoordRsp;
863 /* This message is sent by the gNB-DU to indicate to the gNB-CU its status of overload */
864 typedef struct f1GnbDuStatusInd
866 uint32_t transId; /* Uniquely identifies transaction */
867 F1GnbDuOvrloadInfo ovrloadInfo; /* gNB-DU overloaded information */
870 /* This message is sent by either the gNB-DU or the gNB-CU to intiate the removal
871 * of the interface instance and the related resources */
872 typedef struct f1RmvReq
874 uint32_t transId; /* Uniquely identifies transaction */
877 /* This message acknowledges the initiation of removal of the interface
878 * instance and the related resources */
879 typedef struct f1RmvRsp
881 uint32_t transId; /* Uniquely identifies transaction */
882 F1CritDiagnostic critDiagnos; /* Crititcality diagnostics */
885 /* This message indicates that removing the interface instance and the related
886 * resources cannot be accepted */
887 typedef struct f1RmvFail
889 uint32_t transId; /* Uniquely identifies transaction */
890 F1FailCause cause; /* Failure cause */
891 F1CritDiagnostic critDiagnostic; /* Criticality diagnostics */
894 /* This message is sent by the gNB-CU to indicate to the gNB-DU a need to reduce
895 * the rate at which UEs access the network. */
896 typedef struct f1NwkAccessRateRed
898 uint32_t transId; /* Uniquely identifies transaction */
899 F1UacAssistInfo uacAssistInfo; /* UAC Assistance Information */
902 typedef struct f1Ipaddr
908 typedef struct sctpParams
911 U16 duPort[MAX_DU_PORT];
918 typedef struct f1EgtpParams
920 F1IpAddr localIp; /* Ip address of local node */
921 uint16_t localPort; /* Sender Port at local node */
922 F1IpAddr destIp; /* Ip address of peer node */
923 uint16_t destPort; /* Sender port at peer node */
924 uint32_t minTunnelId;
925 uint32_t maxTunnelId;
928 typedef struct schedulerCfg
930 uint8_t numTxAntPorts; /*!< Number of Tx antenna ports */
931 uint8_t ulSchdType; /*!< Indicates which UL scheduler to use, range
932 * is 0..(number of schedulers - 1) */
933 uint8_t dlSchdType; /*!< Indicates which DL scheduler to use, range
934 * is 0..(number of schedulers - 1) */
935 uint8_t numCells; /*!< Max number of cells */
936 uint8_t maxUlUePerTti; /*!< Max number of UE in UL per TTI */
937 uint8_t maxDlUePerTti; /*!< Max number of UE in DL per TTI */
940 typedef struct mibParams
943 long subCarrierSpacingCommon;
944 long ssb_SubcarrierOffset;
945 long dmrs_TypeA_Position;
946 long controlResourceSetZero;
947 long searchSpaceZero;
949 long intraFreqReselection;
952 typedef struct siSchedInfo
954 long winLen; /* SI Window Length */
955 long broadcastSta; /* Broadcast status */
956 long preiodicity; /* si periodicity */
958 long sibValTag; /* Value tag */
961 typedef struct pdcchCfgCommon
964 long ctrlRsrcSetZero; /* Control resource set zero */
965 long searchSpcZero; /* Search space zero */
966 long searchSpcId; /* Search space id */
967 long ctrlRsrcSetId; /* Control resource set id */
968 uint8_t monitorSlotPrdAndOffPresent;
969 long monitorSlotPrdAndOff; /* Monitoring slot periodicity and offset */
970 uint8_t monitorSymbolsInSlot[2]; /* Monitoring symbols within slot */
971 long numCandAggLvl1; /* Number of candiates at aggregation level 1 */
972 long numCandAggLvl2; /* Number of candiates at aggregation level 2 */
973 long numCandAggLvl4; /* Number of candiates at aggregation level 4 */
974 long numCandAggLvl8; /* Number of candiates at aggregation level 8 */
975 long numCandAggLvl16; /* Number of candiates at aggregation level 16 */
976 uint8_t searchSpcType; /* Search Space type */
977 uint8_t commSrchSpcDciFrmt; /* DCI format of common search space type */
978 long searchSpcSib1; /* Id of serch space for SIB1 */
979 long pagingSearchSpc; /* Id of search space for paging */
980 long raSearchSpc; /* Id of search space for Random Access proc */
983 typedef struct pdschCfgCommon
987 long mapType; /* Mapping Type */
991 typedef struct bcchCfg
993 long modPrdCoeff; /* Modification period co-efficient */
996 typedef struct pcchCfg
998 long dfltPagingCycle; /* Default paging cycle */
999 long nAndPagingFrmOffPresent;
1000 long nAndPagingFrmOff; /* n and Paging Frame offset */
1001 long numPagingOcc; /* Number of paging occassions in paging frame */
1004 typedef struct scsSpecCarrier
1006 long scsOffset; /* Offset to point A considering subcarrier spacing */
1007 long scs; /* subcarrier spacing */
1008 long scsBw; /* Carrier bandwidth considering subcarrier spacing */
1012 typedef struct dlCfgCommon
1014 long freqBandInd; /* Downlink frequency band indicator */
1015 long offsetToPointA; /* DL ofset to point A */
1016 long locAndBw; /* Frequency location and bandwidth */
1017 ScsSpecCarrier dlScsCarrier; /* SCS Specific carrier */
1018 PdcchCfgCommon pdcchCfg;
1019 PdschCfgCommon pdschCfg;
1024 typedef struct rachCfgCommon
1027 long prachCfgIdx; /* PRACH configuration index */
1028 long msg1Fdm; /* Num of PRACH transmission occassions */
1029 long msg1FreqStart; /* Offset of lowest msg1 transmission occassion */
1030 long zeroCorrZoneCfg; /* Zero correlation zone configuration */
1031 long preambleRcvdTgtPwr; /* Traget power level */
1032 long preambleTransMax; /* Max num of preamble transmission */
1033 long pwrRampingStep; /* Power ramping steps for PRACH */
1034 long raRspWindow; /* RA response window */
1035 long numRaPreamble; /* Total num of preamble used in random access */
1036 uint8_t ssbPerRachOccPresent;
1037 long numSsbPerRachOcc; /* Numer of SSBs per RACH Occassion */
1038 long contResTimer; /* Contention resolution timer */
1040 uint8_t rootSeqIdxPresent;
1041 long rootSeqIdx; /* PRACH root sequence index */
1042 long msg1Scs; /* Msg1 subcarrier spacing */
1043 long restrictedSetCfg; /* Restricted set configuration */
1046 typedef struct puschCfgCommon
1052 long msg3DeltaPreamble;
1053 long p0NominalWithGrant;
1056 typedef struct pucchCfgCommon
1064 typedef struct ulCfgCommon
1066 long pMax; /* Max UL transmission power that UE applies */
1067 long locAndBw; /* Frequency location and bandwidth */
1068 ScsSpecCarrier ulScsCarrier; /* SCS Specific carrier */
1069 RachCfgCommon rachCfg;
1070 PuschCfgCommon puschCfg;
1071 PucchCfgCommon pucchCfg;
1072 long timeAlignTimerComm;
1075 typedef struct tddUlDlCfgCommon
1077 long refScs; /* Reference subcarrier spacing */
1078 long txPrd; /* Transmission periodicity */
1085 typedef struct srvCellCfgCommSib
1089 uint8_t ssbPosInBurst;
1090 long ssbPrdServingCell;
1091 TddUlDlCfgCommon tddCfg;
1092 long ssPbchBlockPwr;
1095 typedef struct sib1Params
1100 uint8_t cellIdentity;
1101 long cellResvdForOpUse;
1102 long connEstFailCnt;
1103 long connEstFailOffValidity;
1104 SiSchedInfo siSchedInfo;
1105 SrvCellCfgCommSib srvCellCfgCommSib;
1108 typedef struct duCfgParams
1110 SctpParams sctpParams; /* SCTP Params */
1111 F1EgtpParams egtpParams; /* EGTP Params */
1114 uint8_t duName[CU_DU_NAME_LEN_MAX];
1115 SchedulerCfg schedCfg;
1116 F1DuSrvdCellInfo srvdCellLst[DU_MAX_CELLS]; /* Serving cell list *///TODO: this must be removed eventually
1117 F1RrcVersion rrcVersion; /* RRC version */
1118 MacCellCfg macCellCfg; /* MAC cell configuration */
1119 MibParams mibParams; /* MIB Params */
1120 Sib1Params sib1Params; /* SIB1 Params */
1123 /*function declarations */
1124 void FillSlotConfig();
1128 S16 bitStringToInt(BIT_STRING_t *bitString, uint16_t *val);
1130 #endif /* __DU_CONFIG_H__ */
1132 /**********************************************************************
1134 **********************************************************************/