blob: 898222d8e38ed3b188d5192cf85cc997487b5d92 [file] [log] [blame]
Harald Welteee091892015-09-10 10:22:03 +02001/*
2 * Generated by asn1c-0.9.28 (http://lionet.info/asn1c)
3 * From ASN.1 module "RANAP-PDU"
4 * found in "../../asn1/ranap/RANAP-PDU.asn"
5 */
6
Neels Hofmeyrf1f2d7c2016-01-05 12:00:06 +01007#include <osmocom/ranap/RANAP_RANAP-RelocationInformation.h>
Harald Welteee091892015-09-10 10:22:03 +02008
9static int
Harald Welte49695572015-12-16 17:26:05 +010010memb_ranaP_RelocationInformation_ies_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
Harald Welteee091892015-09-10 10:22:03 +020011 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
12 size_t size;
13
14 if(!sptr) {
15 _ASN_CTFAIL(app_key, td, sptr,
16 "%s: value not given (%s:%d)",
17 td->name, __FILE__, __LINE__);
18 return -1;
19 }
20
21 /* Determine the number of elements */
22 size = _A_CSEQUENCE_FROM_VOID(sptr)->count;
23
24 if((size <= 65535l)) {
25 /* Perform validation of the inner elements */
26 return td->check_constraints(td, sptr, ctfailcb, app_key);
27 } else {
28 _ASN_CTFAIL(app_key, td, sptr,
29 "%s: constraint failed (%s:%d)",
30 td->name, __FILE__, __LINE__);
31 return -1;
32 }
33}
34
Harald Welte49695572015-12-16 17:26:05 +010035static asn_per_constraints_t asn_PER_type_ranaP_RelocationInformation_ies_constr_2 GCC_NOTUSED = {
Harald Welteee091892015-09-10 10:22:03 +020036 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
37 { APC_CONSTRAINED, 16, 16, 0l, 65535l } /* (SIZE(0..65535)) */,
38 0, 0 /* No PER value map */
39};
Harald Welte49695572015-12-16 17:26:05 +010040static asn_per_constraints_t asn_PER_memb_ranaP_RelocationInformation_ies_constr_2 GCC_NOTUSED = {
Harald Welteee091892015-09-10 10:22:03 +020041 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
42 { APC_CONSTRAINED, 16, 16, 0l, 65535l } /* (SIZE(0..65535)) */,
43 0, 0 /* No PER value map */
44};
Harald Welte49695572015-12-16 17:26:05 +010045static asn_TYPE_member_t asn_MBR_ranaP_RelocationInformation_ies_2[] = {
Harald Welteee091892015-09-10 10:22:03 +020046 { ATF_POINTER, 0, 0,
47 -1 /* Ambiguous tag (CHOICE?) */,
48 0,
49 &asn_DEF_RANAP_IE,
50 0, /* Defer constraints checking to the member type */
51 0, /* No PER visible constraints */
52 0,
53 ""
54 },
55};
Harald Welte49695572015-12-16 17:26:05 +010056static const ber_tlv_tag_t asn_DEF_ranaP_RelocationInformation_ies_tags_2[] = {
Harald Welteee091892015-09-10 10:22:03 +020057 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
58 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
59};
Harald Welte49695572015-12-16 17:26:05 +010060static asn_SET_OF_specifics_t asn_SPC_ranaP_RelocationInformation_ies_specs_2 = {
61 sizeof(struct ranaP_RelocationInformation_ies),
62 offsetof(struct ranaP_RelocationInformation_ies, _asn_ctx),
Harald Welteee091892015-09-10 10:22:03 +020063 0, /* XER encoding is XMLDelimitedItemList */
64};
65static /* Use -fall-defs-global to expose */
Harald Welte49695572015-12-16 17:26:05 +010066asn_TYPE_descriptor_t asn_DEF_ranaP_RelocationInformation_ies_2 = {
67 "ranaP-RelocationInformation-ies",
68 "ranaP-RelocationInformation-ies",
Harald Welteee091892015-09-10 10:22:03 +020069 SEQUENCE_OF_free,
70 SEQUENCE_OF_print,
71 SEQUENCE_OF_constraint,
72 SEQUENCE_OF_decode_ber,
73 SEQUENCE_OF_encode_der,
74 SEQUENCE_OF_decode_xer,
75 SEQUENCE_OF_encode_xer,
76 SEQUENCE_OF_decode_uper,
77 SEQUENCE_OF_encode_uper,
78 SEQUENCE_OF_decode_aper,
79 SEQUENCE_OF_encode_aper,
80 0, /* Use generic outmost tag fetcher */
Harald Welte49695572015-12-16 17:26:05 +010081 asn_DEF_ranaP_RelocationInformation_ies_tags_2,
82 sizeof(asn_DEF_ranaP_RelocationInformation_ies_tags_2)
83 /sizeof(asn_DEF_ranaP_RelocationInformation_ies_tags_2[0]) - 1, /* 1 */
84 asn_DEF_ranaP_RelocationInformation_ies_tags_2, /* Same as above */
85 sizeof(asn_DEF_ranaP_RelocationInformation_ies_tags_2)
86 /sizeof(asn_DEF_ranaP_RelocationInformation_ies_tags_2[0]), /* 2 */
87 &asn_PER_type_ranaP_RelocationInformation_ies_constr_2,
88 asn_MBR_ranaP_RelocationInformation_ies_2,
Harald Welteee091892015-09-10 10:22:03 +020089 1, /* Single element */
Harald Welte49695572015-12-16 17:26:05 +010090 &asn_SPC_ranaP_RelocationInformation_ies_specs_2 /* Additional specs */
Harald Welteee091892015-09-10 10:22:03 +020091};
92
93static asn_TYPE_member_t asn_MBR_RANAP_RANAP_RelocationInformation_1[] = {
Harald Welte49695572015-12-16 17:26:05 +010094 { ATF_NOFLAGS, 0, offsetof(struct RANAP_RANAP_RelocationInformation, ranaP_RelocationInformation_ies),
Harald Welteee091892015-09-10 10:22:03 +020095 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
96 0,
Harald Welte49695572015-12-16 17:26:05 +010097 &asn_DEF_ranaP_RelocationInformation_ies_2,
98 memb_ranaP_RelocationInformation_ies_constraint_1,
99 &asn_PER_memb_ranaP_RelocationInformation_ies_constr_2,
Harald Welteee091892015-09-10 10:22:03 +0200100 0,
Harald Welte49695572015-12-16 17:26:05 +0100101 "ranaP-RelocationInformation-ies"
Harald Welteee091892015-09-10 10:22:03 +0200102 },
103};
104static const ber_tlv_tag_t asn_DEF_RANAP_RANAP_RelocationInformation_tags_1[] = {
105 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
106};
107static const asn_TYPE_tag2member_t asn_MAP_RANAP_RANAP_RelocationInformation_tag2el_1[] = {
Harald Welte49695572015-12-16 17:26:05 +0100108 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 } /* ranaP-RelocationInformation-ies */
Harald Welteee091892015-09-10 10:22:03 +0200109};
110static asn_SEQUENCE_specifics_t asn_SPC_RANAP_RANAP_RelocationInformation_specs_1 = {
111 sizeof(struct RANAP_RANAP_RelocationInformation),
112 offsetof(struct RANAP_RANAP_RelocationInformation, _asn_ctx),
113 asn_MAP_RANAP_RANAP_RelocationInformation_tag2el_1,
114 1, /* Count of tags in the map */
115 0, 0, 0, /* Optional elements (not needed) */
116 0, /* Start extensions */
117 2 /* Stop extensions */
118};
119asn_TYPE_descriptor_t asn_DEF_RANAP_RANAP_RelocationInformation = {
120 "RANAP_RANAP-RelocationInformation",
121 "RANAP_RANAP-RelocationInformation",
122 SEQUENCE_free,
123 SEQUENCE_print,
124 SEQUENCE_constraint,
125 SEQUENCE_decode_ber,
126 SEQUENCE_encode_der,
127 SEQUENCE_decode_xer,
128 SEQUENCE_encode_xer,
129 SEQUENCE_decode_uper,
130 SEQUENCE_encode_uper,
131 SEQUENCE_decode_aper,
132 SEQUENCE_encode_aper,
133 0, /* Use generic outmost tag fetcher */
134 asn_DEF_RANAP_RANAP_RelocationInformation_tags_1,
135 sizeof(asn_DEF_RANAP_RANAP_RelocationInformation_tags_1)
136 /sizeof(asn_DEF_RANAP_RANAP_RelocationInformation_tags_1[0]), /* 1 */
137 asn_DEF_RANAP_RANAP_RelocationInformation_tags_1, /* Same as above */
138 sizeof(asn_DEF_RANAP_RANAP_RelocationInformation_tags_1)
139 /sizeof(asn_DEF_RANAP_RANAP_RelocationInformation_tags_1[0]), /* 1 */
140 0, /* No PER visible constraints */
141 asn_MBR_RANAP_RANAP_RelocationInformation_1,
142 1, /* Elements count */
143 &asn_SPC_RANAP_RANAP_RelocationInformation_specs_1 /* Additional specs */
144};
145