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
alex037yang
OpenXG-RAN
Commits
2e453eff
Commit
2e453eff
authored
Sep 07, 2018
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
move F1AP_get_next_transaction_identifier() to f1ap_common.c
parent
54aa295e
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
26 additions
and
36 deletions
+26
-36
cmake_targets/CMakeLists.txt
cmake_targets/CMakeLists.txt
+1
-0
openair2/F1AP/CU_F1AP.c
openair2/F1AP/CU_F1AP.c
+0
-11
openair2/F1AP/DU_F1AP.c
openair2/F1AP/DU_F1AP.c
+0
-15
openair2/F1AP/f1ap_common.c
openair2/F1AP/f1ap_common.c
+18
-4
openair2/F1AP/f1ap_common.h
openair2/F1AP/f1ap_common.h
+7
-6
No files found.
cmake_targets/CMakeLists.txt
View file @
2e453eff
...
...
@@ -546,6 +546,7 @@ add_library(F1AP
${
F1AP_DIR
}
/f1ap_encoder.c
${
F1AP_DIR
}
/f1ap_decoder.c
${
F1AP_DIR
}
/f1ap_handlers.c
${
F1AP_DIR
}
/f1ap_common.c
${
F1AP_DIR
}
/sctp_du.c
${
F1AP_DIR
}
/sctp_cu.c
)
...
...
openair2/F1AP/CU_F1AP.c
View file @
2e453eff
...
...
@@ -80,17 +80,6 @@ typedef struct f1ap_info {
}
f1ap_info_t
;
// helper functions
#define F1AP_TRANSACTION_IDENTIFIER_NUMBER 3
#define NUMBER_OF_eNB_MAX 3
uint8_t
F1AP_get_next_transaction_identifier
(
module_id_t
enb_mod_idP
,
module_id_t
cu_mod_idP
)
{
static
uint8_t
transaction_identifier
[
NUMBER_OF_eNB_MAX
];
transaction_identifier
[
enb_mod_idP
+
cu_mod_idP
]
=
(
transaction_identifier
[
enb_mod_idP
+
cu_mod_idP
]
+
1
)
%
F1AP_TRANSACTION_IDENTIFIER_NUMBER
;
//LOG_T(F1AP,"generated xid is %d\n",transaction_identifier[enb_mod_idP+cu_mod_idP]);
return
transaction_identifier
[
enb_mod_idP
+
cu_mod_idP
];
}
// ==============================================================================
static
void
CU_handle_sctp_data_ind
(
sctp_data_ind_t
*
sctp_data_ind
)
{
...
...
openair2/F1AP/DU_F1AP.c
View file @
2e453eff
...
...
@@ -42,14 +42,6 @@
#include "T.h"
// helper functions
#define F1AP_TRANSACTION_IDENTIFIER_NUMBER 3
#define F1AP_UE_IDENTIFIER_NUMBER 3
#define NUMBER_OF_eNB_MAX 3
// #include "common/ran_context.h"
// extern RAN_CONTEXT_t RC;
/* This structure describes association of a DU to a CU */
typedef
struct
f1ap_info
{
...
...
@@ -86,13 +78,6 @@ typedef struct f1ap_info {
void
DU_handle_sctp_association_resp
(
instance_t
instance
,
sctp_new_association_resp_t
*
sctp_new_association_resp
);
uint8_t
F1AP_get_next_transaction_identifier
(
module_id_t
enb_mod_idP
,
module_id_t
du_mod_idP
)
{
static
uint8_t
transaction_identifier
[
NUMBER_OF_eNB_MAX
];
transaction_identifier
[
enb_mod_idP
+
du_mod_idP
]
=
(
transaction_identifier
[
enb_mod_idP
+
du_mod_idP
]
+
1
)
%
F1AP_TRANSACTION_IDENTIFIER_NUMBER
;
//LOG_T(F1AP,"generated xid is %d\n",transaction_identifier[enb_mod_idP+du_mod_idP]);
return
transaction_identifier
[
enb_mod_idP
+
du_mod_idP
];
}
uint8_t
F1AP_get_UE_identifier
(
module_id_t
enb_mod_idP
,
int
CC_idP
,
int
UE_id
)
{
static
uint8_t
UE_identifier
[
NUMBER_OF_eNB_MAX
];
UE_identifier
[
enb_mod_idP
+
CC_idP
+
UE_id
]
=
(
UE_identifier
[
enb_mod_idP
+
CC_idP
+
UE_id
]
+
1
)
%
F1AP_UE_IDENTIFIER_NUMBER
;
...
...
openair2/F1AP/f1ap_common.c
View file @
2e453eff
...
...
@@ -35,10 +35,10 @@
#include "f1ap_common.h"
//#include "S1AP-PDU.h"
#if defined(EMIT_ASN_DEBUG_EXTERN)
int
asn_debug
=
0
;
int
asn1_xer_print
=
0
;
#if defined(EMIT_ASN_DEBUG_EXTERN)
inline
void
ASN_DEBUG
(
const
char
*
fmt
,
...)
{
if
(
asn_debug
)
{
...
...
@@ -56,6 +56,7 @@ inline void ASN_DEBUG(const char *fmt, ...)
}
#endif
/*
ssize_t f1ap_generate_initiating_message(
uint8_t **buffer,
uint32_t *length,
...
...
@@ -76,9 +77,10 @@ ssize_t f1ap_generate_initiating_message(
if (asn1_xer_print) {
xer_fprint(stdout, &asn_DEF_S1AP_PDU, (void *)&pdu);
}
}
*/
/* We can safely free list of IE from sptr */
/*
ASN_STRUCT_FREE_CONTENTS_ONLY(*td, sptr);
if ((encoded = aper_encode_to_new_buffer(&asn_DEF_S1AP_PDU, 0, &pdu,
...
...
@@ -110,9 +112,10 @@ ssize_t f1ap_generate_successfull_outcome(
if (asn1_xer_print) {
xer_fprint(stdout, &asn_DEF_S1AP_PDU, (void *)&pdu);
}
}
*/
/* We can safely free list of IE from sptr */
/*
ASN_STRUCT_FREE_CONTENTS_ONLY(*td, sptr);
if ((encoded = aper_encode_to_new_buffer(&asn_DEF_S1AP_PDU, 0, &pdu,
...
...
@@ -146,8 +149,9 @@ ssize_t f1ap_generate_unsuccessfull_outcome(
if (asn1_xer_print) {
xer_fprint(stdout, &asn_DEF_S1AP_PDU, (void *)&pdu);
}
*/
/* We can safely free list of IE from sptr */
/*
ASN_STRUCT_FREE_CONTENTS_ONLY(*td, sptr);
if ((encoded = aper_encode_to_new_buffer(&asn_DEF_S1AP_PDU, 0, &pdu,
...
...
@@ -197,3 +201,13 @@ void f1ap_handle_criticality(F1ap_Criticality_t criticality)
{
}
*/
uint8_t
F1AP_get_next_transaction_identifier
(
module_id_t
enb_mod_idP
,
module_id_t
cu_mod_idP
)
{
static
uint8_t
transaction_identifier
[
NUMBER_OF_eNB_MAX
];
transaction_identifier
[
enb_mod_idP
+
cu_mod_idP
]
=
(
transaction_identifier
[
enb_mod_idP
+
cu_mod_idP
]
+
1
)
%
F1AP_TRANSACTION_IDENTIFIER_NUMBER
;
//LOG_T(F1AP,"generated xid is %d\n",transaction_identifier[enb_mod_idP+cu_mod_idP]);
return
transaction_identifier
[
enb_mod_idP
+
cu_mod_idP
];
}
openair2/F1AP/f1ap_common.h
View file @
2e453eff
...
...
@@ -37,9 +37,10 @@
#ifndef F1AP_COMMON_H_
#define F1AP_COMMON_H_
/* Defined in asn_internal.h */
// extern int asn_debug_indent;
extern
int
asn_debug
;
#include "openairinterface5g_limits.h"
#define F1AP_UE_IDENTIFIER_NUMBER 3
#define F1AP_TRANSACTION_IDENTIFIER_NUMBER 3
#if defined(EMIT_ASN_DEBUG_EXTERN)
inline
void
ASN_DEBUG
(
const
char
*
fmt
,
...);
...
...
@@ -369,9 +370,6 @@ inline void ASN_DEBUG(const char *fmt, ...);
#define F1AP_UE_ID_FMT "0x%06"PRIX32
extern
int
asn_debug
;
extern
int
asn1_xer_print
;
#include "assertions.h"
#if defined(ENB_MODE)
...
...
@@ -402,4 +400,7 @@ typedef int (*f1ap_message_decoded_callback)(
F1AP_F1AP_PDU_t
*
message_p
);
uint8_t
F1AP_get_next_transaction_identifier
(
module_id_t
enb_mod_idP
,
module_id_t
cu_mod_idP
);
#endif
/* F1AP_COMMON_H_ */
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