Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
canghaiwuhen
OpenXG-RAN
Commits
908bad77
Commit
908bad77
authored
Apr 12, 2017
by
Michele Paffetti
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
RRC state machine first implementation, code not tested, SRBs not managed
parent
4f359646
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
2889 additions
and
75 deletions
+2889
-75
openair2/RRC/LITE/MESSAGES/asn1_msg_nb_iot.c
openair2/RRC/LITE/MESSAGES/asn1_msg_nb_iot.c
+22
-51
openair2/RRC/LITE/defs_nb_iot.h
openair2/RRC/LITE/defs_nb_iot.h
+23
-24
openair2/RRC/LITE/rrc_eNB_nb_iot.c
openair2/RRC/LITE/rrc_eNB_nb_iot.c
+2844
-0
No files found.
openair2/RRC/LITE/MESSAGES/asn1_msg_nb_iot.c
View file @
908bad77
...
@@ -224,7 +224,6 @@ uint8_t do_MIB_NB(
...
@@ -224,7 +224,6 @@ uint8_t do_MIB_NB(
//no DL_Bandwidth, no PCHIC
//no DL_Bandwidth, no PCHIC
//setting is correct? (cambia tutti in ->)
mib_NB
->
message
.
systemFrameNumber_MSB_r13
.
buf
=
&
sfn_MSB
;
mib_NB
->
message
.
systemFrameNumber_MSB_r13
.
buf
=
&
sfn_MSB
;
mib_NB
->
message
.
systemFrameNumber_MSB_r13
.
size
=
1
;
//if expressed in byte
mib_NB
->
message
.
systemFrameNumber_MSB_r13
.
size
=
1
;
//if expressed in byte
mib_NB
->
message
.
systemFrameNumber_MSB_r13
.
bits_unused
=
4
;
mib_NB
->
message
.
systemFrameNumber_MSB_r13
.
bits_unused
=
4
;
...
@@ -280,8 +279,7 @@ uint8_t do_SIB1_NB(uint8_t Mod_id, int CC_id,
...
@@ -280,8 +279,7 @@ uint8_t do_SIB1_NB(uint8_t Mod_id, int CC_id,
RrcConfigurationReq
*
configuration
RrcConfigurationReq
*
configuration
)
)
{
{
//giusto?-->chiedi a C.
BCCH_DL_SCH_Message_NB_t
*
bcch_message
=
&
(
carrier
->
siblock1_NB
);
BCCH_DL_SCH_Message_NB_t
*
bcch_message
=
&
(
carrier
->
siblock1_NB
);
//bcch message punta all'aria di memoria di sibblock1
SystemInformationBlockType1_NB_t
*
sib1_NB
;
SystemInformationBlockType1_NB_t
*
sib1_NB
;
asn_enc_rval_t
enc_rval
;
asn_enc_rval_t
enc_rval
;
...
@@ -293,6 +291,7 @@ uint8_t do_SIB1_NB(uint8_t Mod_id, int CC_id,
...
@@ -293,6 +291,7 @@ uint8_t do_SIB1_NB(uint8_t Mod_id, int CC_id,
//New parameters
//New parameters
//uint8_t hyperSFN_MSB_r13 ?? (BITSTRING)
//uint8_t hyperSFN_MSB_r13 ?? (BITSTRING)
long
*
attachWithoutPDN_Connectivity
=
NULL
;
long
*
attachWithoutPDN_Connectivity
=
NULL
;
attachWithoutPDN_Connectivity
=
CALLOC
(
1
,
sizeof
(
long
));
attachWithoutPDN_Connectivity
=
CALLOC
(
1
,
sizeof
(
long
));
long
*
nrs_CRS_PowerOffset
=
NULL
;
long
*
nrs_CRS_PowerOffset
=
NULL
;
...
@@ -885,8 +884,8 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -885,8 +884,8 @@ uint8_t do_RRCConnectionSetup_NB(
int
CC_id
,
int
CC_id
,
uint8_t
*
const
buffer
,
uint8_t
*
const
buffer
,
const
uint8_t
Transaction_id
,
const
uint8_t
Transaction_id
,
const
LTE_DL_FRAME_PARMS
*
const
frame_parms
,
//to be changed
const
LTE_DL_FRAME_PARMS
*
const
frame_parms
,
//to be changed
ora maybe not used
SRB_ToAddModList_NB_r13_t
**
SRB_configList_NB
,
// we maintain 1 list only for SRB1 and SRB1bis?
SRB_ToAddModList_NB_r13_t
**
SRB_configList_NB
,
struct
PhysicalConfigDedicated_NB_r13
**
physicalConfigDedicated_NB
struct
PhysicalConfigDedicated_NB_r13
**
physicalConfigDedicated_NB
)
)
...
@@ -897,8 +896,7 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -897,8 +896,7 @@ uint8_t do_RRCConnectionSetup_NB(
//logical channel group not defined for Nb-IoT
//logical channel group not defined for Nb-IoT
//to be used?
long
*
prioritySRB1
=
NULL
;
//logical channel priority pag 605 (is 1 for SRB1 and for SRB1bis? is the same?)
long
*
prioritySRB1
=
NULL
;
//logical channel priority pag 605
long
*
prioritySRB1bis
=
NULL
;
long
*
prioritySRB1bis
=
NULL
;
BOOLEAN_t
*
logicalChannelSR_Prohibit
=
NULL
;
//pag 605
BOOLEAN_t
*
logicalChannelSR_Prohibit
=
NULL
;
//pag 605
...
@@ -925,13 +923,11 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -925,13 +923,11 @@ uint8_t do_RRCConnectionSetup_NB(
if
(
*
SRB_configList_NB
)
{
if
(
*
SRB_configList_NB
)
{
free
(
*
SRB_configList_NB
);
free
(
*
SRB_configList_NB
);
}
}
*
SRB_configList_NB
=
CALLOC
(
1
,
sizeof
(
SRB_ToAddModList_NB_r13_t
));
*
SRB_configList_NB
=
CALLOC
(
1
,
sizeof
(
SRB_ToAddModList_NB_r13_t
));
/// SRB1
/// SRB1
//logical channel identity = 1
-->where to set it? is only inside DRB_ToAddMod_NB
//logical channel identity = 1
for SRB1
SRB1_config_NB
=
CALLOC
(
1
,
sizeof
(
*
SRB1_config_NB
));
SRB1_config_NB
=
CALLOC
(
1
,
sizeof
(
*
SRB1_config_NB
));
...
@@ -963,20 +959,19 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -963,20 +959,19 @@ uint8_t do_RRCConnectionSetup_NB(
prioritySRB1
=
CALLOC
(
1
,
sizeof
(
long
));
prioritySRB1
=
CALLOC
(
1
,
sizeof
(
long
));
*
prioritySRB1
=
1
;
*
prioritySRB1
=
1
;
SRB1_lchan_config_NB
->
choice
.
explicitValue
->
priority_r13
=
prioritySRB1
;
SRB1_lchan_config_NB
->
choice
.
explicitValue
.
priority_r13
=
prioritySRB1
;
logicalChannelSR_Prohibit
=
CALLOC
(
1
,
sizeof
(
BOOLEAN_t
));
logicalChannelSR_Prohibit
=
CALLOC
(
1
,
sizeof
(
BOOLEAN_t
));
*
logicalChannelSR_Prohibit
=
1
;
*
logicalChannelSR_Prohibit
=
1
;
//schould be set to TRUE (specs pag 641)
//schould be set to TRUE (specs pag 641)
SRB1_lchan_config_NB
->
choice
.
explicitValue
->
logicalChannelSR_Prohibit_r13
=
logicalChannelSR_Prohibit
;
SRB1_lchan_config_NB
->
choice
.
explicitValue
->
logicalChannelSR_Prohibit_r13
=
logicalChannelSR_Prohibit
;
ASN_SEQUENCE_ADD
(
&
(
*
SRB_configList_NB
)
->
list
,
SRB1_config_NB
);
//butto SRB1 nella SRB list
//ADD SRB1
ASN_SEQUENCE_ADD
(
&
(
*
SRB_configList_NB
)
->
list
,
SRB1_config_NB
);
///SRB1bis (The configuration for SRB1 and SRB1bis is the same)
///SRB1bis (The configuration for SRB1 and SRB1bis is the same)
// the only difference is the logical channel identity = 3 -->where to set it? is only inside
// the only difference is the logical channel identity = 3 but not setted here
//RadioResourceconfig-IE-->DRB_ToAddMod_NB but we are setting to NULL drb_toAddModList!!!
//they are assumng that 2 RLC-AM entities are used for SRB1 and SRB1bis--> what means?
//they are assumng that 2 RLC-AM entities are used for SRB1 and SRB1bis--> what means?
SRB1bis_config_NB
=
CALLOC
(
1
,
sizeof
(
*
SRB1bis_config_NB
));
SRB1bis_config_NB
=
CALLOC
(
1
,
sizeof
(
*
SRB1bis_config_NB
));
...
@@ -989,17 +984,10 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -989,17 +984,10 @@ uint8_t do_RRCConnectionSetup_NB(
SRB1bis_rlc_config_NB
->
present
=
SRB_ToAddMod_NB_r13__rlc_Config_r13_PR_explicitValue
;
SRB1bis_rlc_config_NB
->
present
=
SRB_ToAddMod_NB_r13__rlc_Config_r13_PR_explicitValue
;
SRB1bis_rlc_config_NB
->
choice
.
explicitValue
.
present
=
RLC_Config_NB_r13_PR_am
;
//the only possible in NB_IoT
SRB1bis_rlc_config_NB
->
choice
.
explicitValue
.
present
=
RLC_Config_NB_r13_PR_am
;
//the only possible in NB_IoT
#if defined(ENABLE_ITTI)//togliere solo if?
SRB1bis_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
ul_AM_RLC_r13
.
t_PollRetransmit_r13
=
enb_properties
.
properties
[
ctxt_pP
->
module_id
]
->
srb1bis_timer_poll_retransmit_r13
;
SRB1bis_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
ul_AM_RLC_r13
.
t_PollRetransmit_r13
=
enb_properties
.
properties
[
ctxt_pP
->
module_id
]
->
srb1bis_timer_poll_retransmit_r13
;
SRB1bis_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
ul_AM_RLC_r13
.
maxRetxThreshold_r13
=
enb_properties
.
properties
[
ctxt_pP
->
module_id
]
->
srb1bis_max_retx_threshold_r13
;
SRB1bis_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
ul_AM_RLC_r13
.
maxRetxThreshold_r13
=
enb_properties
.
properties
[
ctxt_pP
->
module_id
]
->
srb1bis_max_retx_threshold_r13
;
//(musT be disabled--> SRB1 config pag 640 specs )
//(musT be disabled--> SRB1 config pag 640 specs )
SRB1_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
dl_AM_RLC_r13
.
enableStatusReportSN_Gap_r13
=
NULL
;
SRB1_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
dl_AM_RLC_r13
.
enableStatusReportSN_Gap_r13
=
NULL
;
#else
SRB1_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
ul_AM_RLC_r13
.
t_PollRetransmit_r13
=
T_PollRetransmit_NB_r13_ms25000
;
SRB1_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
ul_AM_RLC_r13
.
maxRetxThreshold_r13
=
UL_AM_RLC_NB_r13__maxRetxThreshold_r13_t8
;
//(musT be disabled--> SRB1 config pag 640 specs )
SRB1_rlc_config_NB
->
choice
.
explicitValue
.
choice
.
am
.
dl_AM_RLC_r13
.
enableStatusReportSN_Gap_r13
=
NULL
;
#endif
SRB1bis_lchan_config_NB
=
CALLOC
(
1
,
sizeof
(
*
SRB1bis_lchan_config_NB
));
SRB1bis_lchan_config_NB
=
CALLOC
(
1
,
sizeof
(
*
SRB1bis_lchan_config_NB
));
SRB1bis_config_NB
->
logicalChannelConfig_r13
=
SRB1bis_lchan_config_NB
;
SRB1bis_config_NB
->
logicalChannelConfig_r13
=
SRB1bis_lchan_config_NB
;
...
@@ -1007,15 +995,15 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -1007,15 +995,15 @@ uint8_t do_RRCConnectionSetup_NB(
SRB1bis_lchan_config_NB
->
present
=
SRB_ToAddMod_NB_r13__logicalChannelConfig_r13_PR_explicitValue
;
SRB1bis_lchan_config_NB
->
present
=
SRB_ToAddMod_NB_r13__logicalChannelConfig_r13_PR_explicitValue
;
prioritySRB1bis
=
CALLOC
(
1
,
sizeof
(
long
));
prioritySRB1bis
=
CALLOC
(
1
,
sizeof
(
long
));
*
prioritySRB1bis
=
1
;
*
prioritySRB1bis
=
1
;
//same as SRB1?
SRB1bis_lchan_config_NB
->
choice
.
explicitValue
->
priority_r13
=
prioritySRB1bis
;
SRB1bis_lchan_config_NB
->
choice
.
explicitValue
.
priority_r13
=
prioritySRB1bis
;
logicalChannelSR_Prohibit
=
CALLOC
(
1
,
sizeof
(
BOOLEAN_t
));
logicalChannelSR_Prohibit
=
CALLOC
(
1
,
sizeof
(
BOOLEAN_t
));
*
logicalChannelSR_Prohibit
=
1
;
*
logicalChannelSR_Prohibit
=
1
;
//schould be set to TRUE (specs pag 641)
//schould be set to TRUE (specs pag 641)
SRB1bis_lchan_config_NB
->
choice
.
explicitValue
->
logicalChannelSR_Prohibit_r13
=
logicalChannelSR_Prohibit
;
SRB1bis_lchan_config_NB
->
choice
.
explicitValue
->
logicalChannelSR_Prohibit_r13
=
logicalChannelSR_Prohibit
;
//
butto SRB1bis nella solita lista?
//
ADD SRB1bis //FIXME: actually there is no way to distinguish SRB1 and SRB1bis, maybe MAC doesn't care
ASN_SEQUENCE_ADD
(
&
(
*
SRB_configList_NB
)
->
list
,
SRB1bis_config_NB
);
ASN_SEQUENCE_ADD
(
&
(
*
SRB_configList_NB
)
->
list
,
SRB1bis_config_NB
);
...
@@ -1082,24 +1070,6 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -1082,24 +1070,6 @@ uint8_t do_RRCConnectionSetup_NB(
AssertFatal
(
enc_rval
.
encoded
>
0
,
"ASN1 message encoding failed (%s, %lu)!
\n
"
,
AssertFatal
(
enc_rval
.
encoded
>
0
,
"ASN1 message encoding failed (%s, %lu)!
\n
"
,
enc_rval
.
failed_type
->
name
,
enc_rval
.
encoded
);
enc_rval
.
failed_type
->
name
,
enc_rval
.
encoded
);
//change only "asn_DEF_DL_CCCH_Message_NB"
# if !defined(DISABLE_XER_SPRINT)
{
char
message_string
[
20000
];
size_t
message_string_size
;
if
((
message_string_size
=
xer_sprint
(
message_string
,
sizeof
(
message_string
),
&
asn_DEF_DL_CCCH_Message_NB
,
(
void
*
)
&
dl_ccch_msg
))
>
0
)
{
MessageDef
*
msg_p
;
msg_p
=
itti_alloc_new_message_sized
(
TASK_RRC_ENB
,
RRC_DL_CCCH
,
message_string_size
+
sizeof
(
IttiMsgText
));
msg_p
->
ittiMsg
.
rrc_dl_ccch
.
size
=
message_string_size
;
memcpy
(
&
msg_p
->
ittiMsg
.
rrc_dl_ccch
.
text
,
message_string
,
message_string_size
);
itti_send_msg_to_task
(
TASK_UNKNOWN
,
ctxt_pP
->
instance
,
msg_p
);
}
}
# endif
#ifdef USER_MODE
#ifdef USER_MODE
LOG_D
(
RRC
,
"RRCConnectionSetup-NB Encoded %d bits (%d bytes), ecause %d
\n
"
,
LOG_D
(
RRC
,
"RRCConnectionSetup-NB Encoded %d bits (%d bytes), ecause %d
\n
"
,
...
@@ -1116,7 +1086,7 @@ uint8_t do_RRCConnectionSetup_NB(
...
@@ -1116,7 +1086,7 @@ uint8_t do_RRCConnectionSetup_NB(
}
}
/*do_SecurityModeCommand - exactly the same as previous implementation*/
/*do_SecurityModeCommand - exactly the same as previous implementation*/
uint8_t
do_SecurityModeCommand
(
uint8_t
do_SecurityModeCommand
_NB
(
const
protocol_ctxt_t
*
const
ctxt_pP
,
const
protocol_ctxt_t
*
const
ctxt_pP
,
uint8_t
*
const
buffer
,
uint8_t
*
const
buffer
,
const
uint8_t
Transaction_id
,
const
uint8_t
Transaction_id
,
...
@@ -1154,7 +1124,8 @@ uint8_t do_SecurityModeCommand(
...
@@ -1154,7 +1124,8 @@ uint8_t do_SecurityModeCommand(
100
);
100
);
AssertFatal
(
enc_rval
.
encoded
>
0
,
"ASN1 message encoding failed (%s, %lu)!
\n
"
,
AssertFatal
(
enc_rval
.
encoded
>
0
,
"ASN1 message encoding failed (%s, %lu)!
\n
"
,
enc_rval
.
failed_type
->
name
,
enc_rval
.
encoded
);
enc_rval
.
failed_type
->
name
,
enc_rval
.
encoded
);
//changed only "asn_DEF_DL_DCCH_Message_NB"
//changed only "asn_DEF_DL_DCCH_Message_NB" //to be left?
#if defined(ENABLE_ITTI)
#if defined(ENABLE_ITTI)
# if !defined(DISABLE_XER_SPRINT)
# if !defined(DISABLE_XER_SPRINT)
{
{
...
@@ -1175,7 +1146,7 @@ uint8_t do_SecurityModeCommand(
...
@@ -1175,7 +1146,7 @@ uint8_t do_SecurityModeCommand(
#endif
#endif
#ifdef USER_MODE
#ifdef USER_MODE
LOG_D
(
RRC
,
"[eNB %d] securityModeCommand for UE %x Encoded %d bits (%d bytes)
\n
"
,
LOG_D
(
RRC
,
"[eNB %d] securityModeCommand
-NB
for UE %x Encoded %d bits (%d bytes)
\n
"
,
ctxt_pP
->
module_id
,
ctxt_pP
->
module_id
,
ctxt_pP
->
rnti
,
ctxt_pP
->
rnti
,
enc_rval
.
encoded
,
enc_rval
.
encoded
,
...
@@ -1183,7 +1154,7 @@ uint8_t do_SecurityModeCommand(
...
@@ -1183,7 +1154,7 @@ uint8_t do_SecurityModeCommand(
#endif
#endif
if
(
enc_rval
.
encoded
==-
1
)
{
if
(
enc_rval
.
encoded
==-
1
)
{
LOG_E
(
RRC
,
"[eNB %d] ASN1 : securityModeCommand encoding failed for UE %x
\n
"
,
LOG_E
(
RRC
,
"[eNB %d] ASN1 : securityModeCommand
-NB
encoding failed for UE %x
\n
"
,
ctxt_pP
->
module_id
,
ctxt_pP
->
module_id
,
ctxt_pP
->
rnti
);
ctxt_pP
->
rnti
);
return
(
-
1
);
return
(
-
1
);
...
@@ -1249,7 +1220,7 @@ uint8_t do_UECapabilityEnquiry_NB(
...
@@ -1249,7 +1220,7 @@ uint8_t do_UECapabilityEnquiry_NB(
#endif
#endif
#ifdef USER_MODE
#ifdef USER_MODE
LOG_D
(
RRC
,
"[eNB %d] UECapability
Request
-NB for UE %x Encoded %d bits (%d bytes)
\n
"
,
LOG_D
(
RRC
,
"[eNB %d] UECapability
Enquiry
-NB for UE %x Encoded %d bits (%d bytes)
\n
"
,
ctxt_pP
->
module_id
,
ctxt_pP
->
module_id
,
ctxt_pP
->
rnti
,
ctxt_pP
->
rnti
,
enc_rval
.
encoded
,
enc_rval
.
encoded
,
...
@@ -1257,7 +1228,7 @@ uint8_t do_UECapabilityEnquiry_NB(
...
@@ -1257,7 +1228,7 @@ uint8_t do_UECapabilityEnquiry_NB(
#endif
#endif
if
(
enc_rval
.
encoded
==-
1
)
{
if
(
enc_rval
.
encoded
==-
1
)
{
LOG_E
(
RRC
,
"[eNB %d] ASN1 : UECapability
Request
-NB encoding failed for UE %x
\n
"
,
LOG_E
(
RRC
,
"[eNB %d] ASN1 : UECapability
Enquiry
-NB encoding failed for UE %x
\n
"
,
ctxt_pP
->
module_id
,
ctxt_pP
->
module_id
,
ctxt_pP
->
rnti
);
ctxt_pP
->
rnti
);
return
(
-
1
);
return
(
-
1
);
...
@@ -1369,7 +1340,7 @@ uint16_t do_RRCConnectionReconfiguration_NB(
...
@@ -1369,7 +1340,7 @@ uint16_t do_RRCConnectionReconfiguration_NB(
}
}
/*do_RRCConnectionReestablishmentReject - exactly the same as legacy LTE*/
/*do_RRCConnectionReestablishmentReject - exactly the same as legacy LTE*/
uint8_t
do_RRCConnectionReestablishmentReject
(
uint8_t
do_RRCConnectionReestablishmentReject
_NB
(
uint8_t
Mod_id
,
uint8_t
Mod_id
,
uint8_t
*
const
buffer
)
uint8_t
*
const
buffer
)
{
{
...
@@ -1384,7 +1355,7 @@ uint8_t do_RRCConnectionReestablishmentReject(
...
@@ -1384,7 +1355,7 @@ uint8_t do_RRCConnectionReestablishmentReject(
dl_ccch_msg_NB
.
message
.
choice
.
c1
.
present
=
DL_CCCH_MessageType_NB__c1_PR_rrcConnectionReestablishmentReject_r13
;
dl_ccch_msg_NB
.
message
.
choice
.
c1
.
present
=
DL_CCCH_MessageType_NB__c1_PR_rrcConnectionReestablishmentReject_r13
;
rrcConnectionReestablishmentReject
=
&
dl_ccch_msg_NB
.
message
.
choice
.
c1
.
choice
.
rrcConnectionReestablishmentReject_r13
;
rrcConnectionReestablishmentReject
=
&
dl_ccch_msg_NB
.
message
.
choice
.
c1
.
choice
.
rrcConnectionReestablishmentReject_r13
;
// RRCConnectionReestablishmentReject
// RRCConnectionReestablishmentReject
//exactly the same as LTE
rrcConnectionReestablishmentReject
->
criticalExtensions
.
present
=
RRCConnectionReestablishmentReject__criticalExtensions_PR_rrcConnectionReestablishmentReject_r8
;
rrcConnectionReestablishmentReject
->
criticalExtensions
.
present
=
RRCConnectionReestablishmentReject__criticalExtensions_PR_rrcConnectionReestablishmentReject_r8
;
//Only change in "asn_DEF_DL_CCCH_Message_NB"
//Only change in "asn_DEF_DL_CCCH_Message_NB"
...
...
openair2/RRC/LITE/defs_nb_iot.h
View file @
908bad77
...
@@ -195,7 +195,7 @@
...
@@ -195,7 +195,7 @@
//-------------------
//-------------------
//?? left
typedef
unsigned
int
uid_t
;
typedef
unsigned
int
uid_t
;
#define UID_LINEAR_ALLOCATOR_BITMAP_SIZE (((NUMBER_OF_UE_MAX/8)/sizeof(unsigned int)) + 1)
#define UID_LINEAR_ALLOCATOR_BITMAP_SIZE (((NUMBER_OF_UE_MAX/8)/sizeof(unsigned int)) + 1)
typedef
struct
uid_linear_allocator_s
{
typedef
struct
uid_linear_allocator_s
{
...
@@ -316,8 +316,6 @@ typedef struct UE_S_TMSI_s {
...
@@ -316,8 +316,6 @@ typedef struct UE_S_TMSI_s {
}
__attribute__
((
__packed__
))
UE_S_TMSI
;
}
__attribute__
((
__packed__
))
UE_S_TMSI
;
/*maybe not necessary puts in comment -->it seems is not used anywhere
#if defined(ENABLE_ITTI)
typedef
enum
e_rab_satus_e
{
typedef
enum
e_rab_satus_e
{
E_RAB_STATUS_NEW
,
E_RAB_STATUS_NEW
,
E_RAB_STATUS_DONE
,
// from the eNB perspective
E_RAB_STATUS_DONE
,
// from the eNB perspective
...
@@ -330,8 +328,7 @@ typedef struct e_rab_param_s {
...
@@ -330,8 +328,7 @@ typedef struct e_rab_param_s {
uint8_t
status
;
uint8_t
status
;
uint8_t
xid
;
// transaction_id
uint8_t
xid
;
// transaction_id
}
__attribute__
((
__packed__
))
e_rab_param_t
;
}
__attribute__
((
__packed__
))
e_rab_param_t
;
#endif
*/
//HANDOVER_INFO not implemented in NB-IoT delete
//HANDOVER_INFO not implemented in NB-IoT delete
...
@@ -353,7 +350,7 @@ typedef struct RB_INFO_s {
...
@@ -353,7 +350,7 @@ typedef struct RB_INFO_s {
}
RB_INFO
;
}
RB_INFO
;
typedef
struct
SRB_INFO_s
{
typedef
struct
SRB_INFO_s
{
uint16_t
Srb_id
;
//=Lchan_id
uint16_t
Srb_id
;
//=Lchan_id
---> questo potrebbe esserci utile per distinguere ???
RRC_BUFFER
Rx_buffer
;
RRC_BUFFER
Rx_buffer
;
RRC_BUFFER
Tx_buffer
;
RRC_BUFFER
Tx_buffer
;
LCHAN_DESC
Lchan_desc
[
2
];
//LCHAN_DESC should be changed for NB-IoT
LCHAN_DESC
Lchan_desc
[
2
];
//LCHAN_DESC should be changed for NB-IoT
...
@@ -369,7 +366,7 @@ typedef struct RB_INFO_TABLE_ENTRY_s {
...
@@ -369,7 +366,7 @@ typedef struct RB_INFO_TABLE_ENTRY_s {
uint8_t
Status
;
uint8_t
Status
;
}
RB_INFO_TABLE_ENTRY
;
}
RB_INFO_TABLE_ENTRY
;
typedef
struct
SRB_INFO_TABLE_ENTRY_s
{
//togli
typedef
struct
SRB_INFO_TABLE_ENTRY_s
{
SRB_INFO
Srb_info
;
SRB_INFO
Srb_info
;
uint8_t
Active
;
uint8_t
Active
;
uint8_t
Status
;
uint8_t
Status
;
...
@@ -453,7 +450,7 @@ typedef struct eNB_RRC_UE_s { //used in rrc_eNB_ue_context
...
@@ -453,7 +450,7 @@ typedef struct eNB_RRC_UE_s { //used in rrc_eNB_ue_context
*/
*/
//NB-IoT eNB_RRC_UE_s--(used as a context
--> ue_context in rrc_eNB_ue_context)-------------------------
------
//NB-IoT eNB_RRC_UE_s--(used as a context
in eNB --> ue_context in rrc_eNB_ue_context)
------
typedef
struct
eNB_RRC_UE_s
{
typedef
struct
eNB_RRC_UE_s
{
uint8_t
primaryCC_id
;
uint8_t
primaryCC_id
;
...
@@ -461,11 +458,13 @@ typedef struct eNB_RRC_UE_s {
...
@@ -461,11 +458,13 @@ typedef struct eNB_RRC_UE_s {
//used in generate_default/dedicatedRRCConnectionReconfiguration (rrc_eNB.c)
//used in generate_default/dedicatedRRCConnectionReconfiguration (rrc_eNB.c)
//in NB-IoT only SRB0, SRB1 and SRB1bis (until AS security activation) exist
//in NB-IoT only SRB0, SRB1 and SRB1bis (until AS security activation) exist
SRB_ToAddModList_NB_r13_t
*
SRB_configList_NB
;
//for SRB1 and SRB1bis
SRB_ToAddModList_NB_r13_t
*
SRB_configList
;
//for SRB1 and SRB1bis
SRB_ToAddModList_NB_r13_t
*
SRB_configListBis_NB
[
RRC_TRANSACTION_IDENTIFIER_NUMBER
];
//for SRB1bis
// SRB_ToAddModList_NB_r13_t* SRB1_configList_NB; //for SRB1
DRB_ToAddModList_NB_r13_t
*
DRB_configList_NB
;
//for all the DRBs
// SRB_ToAddModList_NB_r13_t* SRB1bis_configList_NB; //only for SRB1bis
DRB_ToAddModList_NB_r13_t
*
DRB_configList2_NB
[
RRC_TRANSACTION_IDENTIFIER_NUMBER
];
//for the configured DRBs of a xid
SRB_ToAddModList_NB_r13_t
*
SRB_configList2
[
RRC_TRANSACTION_IDENTIFIER_NUMBER
];
//only for SRB1
uint8_t
DRB_active
[
8
];
//??
DRB_ToAddModList_NB_r13_t
*
DRB_configList
;
//for all the DRBs
DRB_ToAddModList_NB_r13_t
*
DRB_configList2
[
RRC_TRANSACTION_IDENTIFIER_NUMBER
];
//for the configured DRBs of a xid
uint8_t
DRB_active
[
2
];
//in LTE was 8 --> at most 2 for NB-IoT
struct
PhysicalConfigDedicated_NB_r13
*
physicalConfigDedicated_NB
;
struct
PhysicalConfigDedicated_NB_r13
*
physicalConfigDedicated_NB
;
MAC_MainConfig_NB_r13_t
*
mac_MainConfig_NB
;
MAC_MainConfig_NB_r13_t
*
mac_MainConfig_NB
;
...
@@ -492,7 +491,6 @@ typedef struct eNB_RRC_UE_s {
...
@@ -492,7 +491,6 @@ typedef struct eNB_RRC_UE_s {
uint64_t
random_ue_identity
;
uint64_t
random_ue_identity
;
#if defined(ENABLE_ITTI)
/* Information from UE RRC ConnectionRequest-NB-r13_IE--> NB-IoT */
/* Information from UE RRC ConnectionRequest-NB-r13_IE--> NB-IoT */
UE_S_TMSI
Initialue_identity_s_TMSI
;
UE_S_TMSI
Initialue_identity_s_TMSI
;
...
@@ -501,7 +499,7 @@ typedef struct eNB_RRC_UE_s {
...
@@ -501,7 +499,7 @@ typedef struct eNB_RRC_UE_s {
/* Information from UE RRC ConnectionReestablishmentRequest-NB--> NB-IoT */
/* Information from UE RRC ConnectionReestablishmentRequest-NB--> NB-IoT */
ReestablishmentCause_NB_r13_t
reestablishment_cause_NB
;
//different set for NB_IoT
ReestablishmentCause_NB_r13_t
reestablishment_cause_NB
;
//different set for NB_IoT
//nothing to be changed for NB-IoT?----------
///nothing to be changed for NB-IoT?
/* UE id for initial connection to S1AP */
/* UE id for initial connection to S1AP */
uint16_t
ue_initial_id
;
uint16_t
ue_initial_id
;
...
@@ -510,9 +508,9 @@ typedef struct eNB_RRC_UE_s {
...
@@ -510,9 +508,9 @@ typedef struct eNB_RRC_UE_s {
security_capabilities_t
security_capabilities
;
security_capabilities_t
security_capabilities
;
/* Total number of e_rab already setup in the list */
/* Total number of e_rab already setup in the list */
//NAS list?
uint8_t
setup_e_rabs
;
uint8_t
setup_e_rabs
;
/* Number of e_rab to be setup in the list */
/* Number of e_rab to be setup in the list */
//NAS list?
uint8_t
nb_of_e_rabs
;
uint8_t
nb_of_e_rabs
;
/* list of e_rab to be setup by RRC layers */
/* list of e_rab to be setup by RRC layers */
e_rab_param_t
e_rab
[
NB_RB_MAX
];
//[S1AP_MAX_E_RAB];
e_rab_param_t
e_rab
[
NB_RB_MAX
];
//[S1AP_MAX_E_RAB];
...
@@ -521,8 +519,8 @@ typedef struct eNB_RRC_UE_s {
...
@@ -521,8 +519,8 @@ typedef struct eNB_RRC_UE_s {
uint32_t
enb_gtp_teid
[
S1AP_MAX_E_RAB
];
uint32_t
enb_gtp_teid
[
S1AP_MAX_E_RAB
];
transport_layer_addr_t
enb_gtp_addrs
[
S1AP_MAX_E_RAB
];
transport_layer_addr_t
enb_gtp_addrs
[
S1AP_MAX_E_RAB
];
rb_id_t
enb_gtp_ebi
[
S1AP_MAX_E_RAB
];
rb_id_t
enb_gtp_ebi
[
S1AP_MAX_E_RAB
];
//------------------
#endif
uint32_t
ul_failure_timer
;
uint32_t
ul_failure_timer
;
uint32_t
ue_release_timer
;
uint32_t
ue_release_timer
;
uint32_t
ue_release_timer_thres
;
uint32_t
ue_release_timer_thres
;
...
@@ -534,6 +532,7 @@ typedef uid_t ue_uid_t;
...
@@ -534,6 +532,7 @@ typedef uid_t ue_uid_t;
//Not touched - generally variable called: ue_context_pP
//Not touched - generally variable called: ue_context_pP
typedef
struct
rrc_eNB_ue_context_s
{
typedef
struct
rrc_eNB_ue_context_s
{
/* Tree related data */
/* Tree related data */
RB_ENTRY
(
rrc_eNB_ue_context_s
)
entries
;
RB_ENTRY
(
rrc_eNB_ue_context_s
)
entries
;
...
@@ -555,7 +554,8 @@ typedef struct rrc_eNB_ue_context_s {
...
@@ -555,7 +554,8 @@ typedef struct rrc_eNB_ue_context_s {
//---NB-IoT (completely changed)-------------------------------
//---NB-IoT (completely changed)-------------------------------
//called "carrier"--> data from PHY layer
//called "carrier"--> data from PHY layer
typedef
struct
{
typedef
struct
{
//a cosa servono questi int? buffer that contains the encoded messages
// buffer that contains the encoded messages
uint8_t
*
MIB_NB
;
uint8_t
*
MIB_NB
;
uint8_t
sizeof_MIB_NB
;
uint8_t
sizeof_MIB_NB
;
uint8_t
*
SIB1_NB
;
uint8_t
*
SIB1_NB
;
...
@@ -597,7 +597,7 @@ typedef struct {
...
@@ -597,7 +597,7 @@ typedef struct {
BCCH_DL_SCH_Message_NB_t
siblock1_NB
;
//SIB1-NB
BCCH_DL_SCH_Message_NB_t
siblock1_NB
;
//SIB1-NB
BCCH_DL_SCH_Message_NB_t
systemInformation_NB
;
//SI
BCCH_DL_SCH_Message_NB_t
systemInformation_NB
;
//SI
//memory should be allocated--> in principle are only for commodity
//memory should be allocated--> in principle are only for commodity
?
SystemInformationBlockType1_NB_t
*
sib1_NB
;
SystemInformationBlockType1_NB_t
*
sib1_NB
;
SystemInformationBlockType2_NB_r13_t
*
sib2_NB
;
SystemInformationBlockType2_NB_r13_t
*
sib2_NB
;
SystemInformationBlockType3_NB_r13_t
*
sib3_NB
;
SystemInformationBlockType3_NB_r13_t
*
sib3_NB
;
...
@@ -625,6 +625,7 @@ typedef struct {
...
@@ -625,6 +625,7 @@ typedef struct {
//---NB-IoT---(completely change)---------------------
//---NB-IoT---(completely change)---------------------
typedef
struct
eNB_RRC_INST_s
{
typedef
struct
eNB_RRC_INST_s
{
rrc_eNB_carrier_data_t
carrier
[
MAX_NUM_CCs
];
rrc_eNB_carrier_data_t
carrier
[
MAX_NUM_CCs
];
uid_allocator_t
uid_allocator
;
// for rrc_ue_head
uid_allocator_t
uid_allocator
;
// for rrc_ue_head
...
@@ -636,9 +637,7 @@ typedef struct eNB_RRC_INST_s {
...
@@ -636,9 +637,7 @@ typedef struct eNB_RRC_INST_s {
hash_table_t
*
s1ap_id2_s1ap_ids
;
// key is content is rrc_ue_s1ap_ids_t
hash_table_t
*
s1ap_id2_s1ap_ids
;
// key is content is rrc_ue_s1ap_ids_t
//RRC configuration
//RRC configuration
#if defined(ENABLE_ITTI)
RrcConfigurationReq
configuration
;
//should be changed but need PHY specs also
RrcConfigurationReq
configuration
;
//should be changed but need PHY specs also
#endif
//new--> to be check
//new--> to be check
// other PLMN parameters
// other PLMN parameters
...
@@ -667,7 +666,7 @@ typedef struct OAI_UECapability_s {
...
@@ -667,7 +666,7 @@ typedef struct OAI_UECapability_s {
uint8_t
sdu
[
MAX_UE_CAPABILITY_SIZE
];
uint8_t
sdu
[
MAX_UE_CAPABILITY_SIZE
];
uint8_t
sdu_size
;
uint8_t
sdu_size
;
//NB-IoT------
//NB-IoT------
UE_Capability_NB_r13_t
UE_Capability_NB
;
UE_Capability_NB_r13_t
UE_Capability_NB
;
//replace the UE_EUTRA_Capability of LTE
}
OAI_UECapability_t
;
}
OAI_UECapability_t
;
...
...
openair2/RRC/LITE/rrc_eNB_nb_iot.c
0 → 100644
View file @
908bad77
This source diff could not be displayed because it is too large. You can
view the blob
instead.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment