[Epic-ID: ODUHIGH-406][Task-ID: ODUHIGH-441]: Update name of Paging RRC Codec
[o-du/l2.git] / src / codec_utils / RRC / FrequencyInfoUL-SIB.c
1 /*
2  * Generated by asn1c-0.9.29 (http://lionet.info/asn1c)
3  * From ASN.1 module "NR-RRC-Definitions"
4  *      found in "./22April22_Paging/rrc_15.3_asn.asn1"
5  *      `asn1c -D ./22April22_Paging -fcompound-names -fno-include-deps -findirect-choice -gen-PER -no-gen-example`
6  */
7
8 #include "FrequencyInfoUL-SIB.h"
9
10 #include "MultiFrequencyBandListNR-SIB.h"
11 #include "SCS-SpecificCarrier.h"
12 /*
13  * This type is implemented using NativeEnumerated,
14  * so here we adjust the DEF accordingly.
15  */
16 static int
17 memb_scs_SpecificCarrierList_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
18                         asn_app_constraint_failed_f *ctfailcb, void *app_key) {
19         size_t size;
20         
21         if(!sptr) {
22                 ASN__CTFAIL(app_key, td, sptr,
23                         "%s: value not given (%s:%d)",
24                         td->name, __FILE__, __LINE__);
25                 return -1;
26         }
27         
28         /* Determine the number of elements */
29         size = _A_CSEQUENCE_FROM_VOID(sptr)->count;
30         
31         if((size >= 1 && size <= 5)) {
32                 /* Perform validation of the inner elements */
33                 return td->encoding_constraints.general_constraints(td, sptr, ctfailcb, app_key);
34         } else {
35                 ASN__CTFAIL(app_key, td, sptr,
36                         "%s: constraint failed (%s:%d)",
37                         td->name, __FILE__, __LINE__);
38                 return -1;
39         }
40 }
41
42 static asn_oer_constraints_t asn_OER_type_scs_SpecificCarrierList_constr_4 CC_NOTUSED = {
43         { 0, 0 },
44         -1      /* (SIZE(1..5)) */};
45 static asn_per_constraints_t asn_PER_type_scs_SpecificCarrierList_constr_4 CC_NOTUSED = {
46         { APC_UNCONSTRAINED,    -1, -1,  0,  0 },
47         { APC_CONSTRAINED,       3,  3,  1,  5 }        /* (SIZE(1..5)) */,
48         0, 0    /* No PER value map */
49 };
50 static asn_oer_constraints_t asn_OER_type_frequencyShift7p5khz_constr_7 CC_NOTUSED = {
51         { 0, 0 },
52         -1};
53 static asn_per_constraints_t asn_PER_type_frequencyShift7p5khz_constr_7 CC_NOTUSED = {
54         { APC_CONSTRAINED,       0,  0,  0,  0 }        /* (0..0) */,
55         { APC_UNCONSTRAINED,    -1, -1,  0,  0 },
56         0, 0    /* No PER value map */
57 };
58 static asn_oer_constraints_t asn_OER_memb_scs_SpecificCarrierList_constr_4 CC_NOTUSED = {
59         { 0, 0 },
60         -1      /* (SIZE(1..5)) */};
61 static asn_per_constraints_t asn_PER_memb_scs_SpecificCarrierList_constr_4 CC_NOTUSED = {
62         { APC_UNCONSTRAINED,    -1, -1,  0,  0 },
63         { APC_CONSTRAINED,       3,  3,  1,  5 }        /* (SIZE(1..5)) */,
64         0, 0    /* No PER value map */
65 };
66 static asn_TYPE_member_t asn_MBR_scs_SpecificCarrierList_4[] = {
67         { ATF_POINTER, 0, 0,
68                 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
69                 0,
70                 &asn_DEF_SCS_SpecificCarrier,
71                 0,
72                 { 0, 0, 0 },
73                 0, 0, /* No default value */
74                 ""
75                 },
76 };
77 static const ber_tlv_tag_t asn_DEF_scs_SpecificCarrierList_tags_4[] = {
78         (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
79         (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
80 };
81 static asn_SET_OF_specifics_t asn_SPC_scs_SpecificCarrierList_specs_4 = {
82         sizeof(struct FrequencyInfoUL_SIB__scs_SpecificCarrierList),
83         offsetof(struct FrequencyInfoUL_SIB__scs_SpecificCarrierList, _asn_ctx),
84         0,      /* XER encoding is XMLDelimitedItemList */
85 };
86 static /* Use -fall-defs-global to expose */
87 asn_TYPE_descriptor_t asn_DEF_scs_SpecificCarrierList_4 = {
88         "scs-SpecificCarrierList",
89         "scs-SpecificCarrierList",
90         &asn_OP_SEQUENCE_OF,
91         asn_DEF_scs_SpecificCarrierList_tags_4,
92         sizeof(asn_DEF_scs_SpecificCarrierList_tags_4)
93                 /sizeof(asn_DEF_scs_SpecificCarrierList_tags_4[0]) - 1, /* 1 */
94         asn_DEF_scs_SpecificCarrierList_tags_4, /* Same as above */
95         sizeof(asn_DEF_scs_SpecificCarrierList_tags_4)
96                 /sizeof(asn_DEF_scs_SpecificCarrierList_tags_4[0]), /* 2 */
97         { &asn_OER_type_scs_SpecificCarrierList_constr_4, &asn_PER_type_scs_SpecificCarrierList_constr_4, SEQUENCE_OF_constraint },
98         asn_MBR_scs_SpecificCarrierList_4,
99         1,      /* Single element */
100         &asn_SPC_scs_SpecificCarrierList_specs_4        /* Additional specs */
101 };
102
103 static const asn_INTEGER_enum_map_t asn_MAP_frequencyShift7p5khz_value2enum_7[] = {
104         { 0,    4,      "true" }
105 };
106 static const unsigned int asn_MAP_frequencyShift7p5khz_enum2value_7[] = {
107         0       /* true(0) */
108 };
109 static const asn_INTEGER_specifics_t asn_SPC_frequencyShift7p5khz_specs_7 = {
110         asn_MAP_frequencyShift7p5khz_value2enum_7,      /* "tag" => N; sorted by tag */
111         asn_MAP_frequencyShift7p5khz_enum2value_7,      /* N => "tag"; sorted by N */
112         1,      /* Number of elements in the maps */
113         0,      /* Enumeration is not extensible */
114         1,      /* Strict enumeration */
115         0,      /* Native long size */
116         0
117 };
118 static const ber_tlv_tag_t asn_DEF_frequencyShift7p5khz_tags_7[] = {
119         (ASN_TAG_CLASS_CONTEXT | (4 << 2)),
120         (ASN_TAG_CLASS_UNIVERSAL | (10 << 2))
121 };
122 static /* Use -fall-defs-global to expose */
123 asn_TYPE_descriptor_t asn_DEF_frequencyShift7p5khz_7 = {
124         "frequencyShift7p5khz",
125         "frequencyShift7p5khz",
126         &asn_OP_NativeEnumerated,
127         asn_DEF_frequencyShift7p5khz_tags_7,
128         sizeof(asn_DEF_frequencyShift7p5khz_tags_7)
129                 /sizeof(asn_DEF_frequencyShift7p5khz_tags_7[0]) - 1, /* 1 */
130         asn_DEF_frequencyShift7p5khz_tags_7,    /* Same as above */
131         sizeof(asn_DEF_frequencyShift7p5khz_tags_7)
132                 /sizeof(asn_DEF_frequencyShift7p5khz_tags_7[0]), /* 2 */
133         { &asn_OER_type_frequencyShift7p5khz_constr_7, &asn_PER_type_frequencyShift7p5khz_constr_7, NativeEnumerated_constraint },
134         0, 0,   /* Defined elsewhere */
135         &asn_SPC_frequencyShift7p5khz_specs_7   /* Additional specs */
136 };
137
138 asn_TYPE_member_t asn_MBR_FrequencyInfoUL_SIB_1[] = {
139         { ATF_POINTER, 2, offsetof(struct FrequencyInfoUL_SIB, frequencyBandList),
140                 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
141                 -1,     /* IMPLICIT tag at current level */
142                 &asn_DEF_MultiFrequencyBandListNR_SIB,
143                 0,
144                 { 0, 0, 0 },
145                 0, 0, /* No default value */
146                 "frequencyBandList"
147                 },
148         { ATF_POINTER, 1, offsetof(struct FrequencyInfoUL_SIB, absoluteFrequencyPointA),
149                 (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
150                 -1,     /* IMPLICIT tag at current level */
151                 &asn_DEF_ARFCN_ValueNR,
152                 0,
153                 { 0, 0, 0 },
154                 0, 0, /* No default value */
155                 "absoluteFrequencyPointA"
156                 },
157         { ATF_NOFLAGS, 0, offsetof(struct FrequencyInfoUL_SIB, scs_SpecificCarrierList),
158                 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
159                 0,
160                 &asn_DEF_scs_SpecificCarrierList_4,
161                 0,
162                 { &asn_OER_memb_scs_SpecificCarrierList_constr_4, &asn_PER_memb_scs_SpecificCarrierList_constr_4,  memb_scs_SpecificCarrierList_constraint_1 },
163                 0, 0, /* No default value */
164                 "scs-SpecificCarrierList"
165                 },
166         { ATF_POINTER, 2, offsetof(struct FrequencyInfoUL_SIB, p_Max),
167                 (ASN_TAG_CLASS_CONTEXT | (3 << 2)),
168                 -1,     /* IMPLICIT tag at current level */
169                 &asn_DEF_P_Max,
170                 0,
171                 { 0, 0, 0 },
172                 0, 0, /* No default value */
173                 "p-Max"
174                 },
175         { ATF_POINTER, 1, offsetof(struct FrequencyInfoUL_SIB, frequencyShift7p5khz),
176                 (ASN_TAG_CLASS_CONTEXT | (4 << 2)),
177                 -1,     /* IMPLICIT tag at current level */
178                 &asn_DEF_frequencyShift7p5khz_7,
179                 0,
180                 { 0, 0, 0 },
181                 0, 0, /* No default value */
182                 "frequencyShift7p5khz"
183                 },
184 };
185 static const int asn_MAP_FrequencyInfoUL_SIB_oms_1[] = { 0, 1, 3, 4 };
186 static const ber_tlv_tag_t asn_DEF_FrequencyInfoUL_SIB_tags_1[] = {
187         (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
188 };
189 static const asn_TYPE_tag2member_t asn_MAP_FrequencyInfoUL_SIB_tag2el_1[] = {
190     { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* frequencyBandList */
191     { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* absoluteFrequencyPointA */
192     { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 }, /* scs-SpecificCarrierList */
193     { (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0 }, /* p-Max */
194     { (ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0 } /* frequencyShift7p5khz */
195 };
196 asn_SEQUENCE_specifics_t asn_SPC_FrequencyInfoUL_SIB_specs_1 = {
197         sizeof(struct FrequencyInfoUL_SIB),
198         offsetof(struct FrequencyInfoUL_SIB, _asn_ctx),
199         asn_MAP_FrequencyInfoUL_SIB_tag2el_1,
200         5,      /* Count of tags in the map */
201         asn_MAP_FrequencyInfoUL_SIB_oms_1,      /* Optional members */
202         4, 0,   /* Root/Additions */
203         5,      /* First extension addition */
204 };
205 asn_TYPE_descriptor_t asn_DEF_FrequencyInfoUL_SIB = {
206         "FrequencyInfoUL-SIB",
207         "FrequencyInfoUL-SIB",
208         &asn_OP_SEQUENCE,
209         asn_DEF_FrequencyInfoUL_SIB_tags_1,
210         sizeof(asn_DEF_FrequencyInfoUL_SIB_tags_1)
211                 /sizeof(asn_DEF_FrequencyInfoUL_SIB_tags_1[0]), /* 1 */
212         asn_DEF_FrequencyInfoUL_SIB_tags_1,     /* Same as above */
213         sizeof(asn_DEF_FrequencyInfoUL_SIB_tags_1)
214                 /sizeof(asn_DEF_FrequencyInfoUL_SIB_tags_1[0]), /* 1 */
215         { 0, 0, SEQUENCE_constraint },
216         asn_MBR_FrequencyInfoUL_SIB_1,
217         5,      /* Elements count */
218         &asn_SPC_FrequencyInfoUL_SIB_specs_1    /* Additional specs */
219 };
220