Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
openairinterface5G
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
lvguorong
openairinterface5G
Commits
6d565bae
Commit
6d565bae
authored
11 years ago
by
gauthier
Browse files
Options
Downloads
Patches
Plain Diff
git-svn-id:
http://svn.eurecom.fr/openair4G/trunk@5060
818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent
f4e67761
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
openair2/ENB_APP/enb_app.c
+13
-4
13 additions, 4 deletions
openair2/ENB_APP/enb_app.c
openair2/ENB_APP/enb_config.c
+4
-6
4 additions, 6 deletions
openair2/ENB_APP/enb_config.c
with
17 additions
and
10 deletions
openair2/ENB_APP/enb_app.c
+
13
−
4
View file @
6d565bae
...
...
@@ -29,6 +29,7 @@
*******************************************************************************/
#include
<string.h>
#include
<stdio.h>
#include
"enb_app.h"
#include
"enb_config.h"
...
...
@@ -97,10 +98,12 @@ static void configure_rrc(uint32_t enb_id, const Enb_properties_array_t *enb_pro
# if defined(ENABLE_USE_MME)
static
uint32_t
eNB_app_register
(
uint32_t
enb_id_start
,
uint32_t
enb_id_end
,
const
Enb_properties_array_t
*
enb_properties
)
{
uint32_t
enb_id
;
uint32_t
mme_id
;
MessageDef
*
msg_p
;
uint32_t
register_enb_pending
=
0
;
uint32_t
enb_id
;
uint32_t
mme_id
;
MessageDef
*
msg_p
;
uint32_t
register_enb_pending
=
0
;
char
*
str
=
NULL
;
struct
in_addr
addr
;
# if defined(OAI_EMU)
...
...
@@ -143,6 +146,12 @@ static uint32_t eNB_app_register(uint32_t enb_id_start, uint32_t enb_id_end, con
sizeof
(
s1ap_register_eNB
->
mme_ip_address
[
0
].
ipv6_address
));
}
s1ap_register_eNB
->
enb_ip_address
.
ipv6
=
0
;
s1ap_register_eNB
->
enb_ip_address
.
ipv4
=
1
;
addr
.
s_addr
=
enb_properties
->
properties
[
enb_id
]
->
enb_ipv4_address_for_S1_MME
;
str
=
inet_ntoa
(
addr
);
strcpy
(
s1ap_register_eNB
->
enb_ip_address
.
ipv4_address
,
str
);
itti_send_msg_to_task
(
TASK_S1AP
,
enb_id
,
msg_p
);
register_enb_pending
++
;
...
...
This diff is collapsed.
Click to expand it.
openair2/ENB_APP/enb_config.c
+
4
−
6
View file @
6d565bae
...
...
@@ -427,13 +427,13 @@ const Enb_properties_array_t *enb_config_init(char* lib_config_file_name_pP) {
subsetting
=
config_setting_get_member
(
setting_enb
,
ENB_CONFIG_STRING_NETWORK_INTERFACES_CONFIG
);
if
(
subsetting
!=
NULL
)
{
if
(
(
config_setting_lookup_string
(
setting
,
ENB_CONFIG_STRING_ENB_INTERFACE_NAME_FOR_S1_MME
,
config_setting_lookup_string
(
sub
setting
,
ENB_CONFIG_STRING_ENB_INTERFACE_NAME_FOR_S1_MME
,
(
const
char
**
)
&
enb_interface_name_for_S1_MME
)
&&
config_setting_lookup_string
(
setting
,
ENB_CONFIG_STRING_ENB_IPV4_ADDRESS_FOR_S1_MME
,
&&
config_setting_lookup_string
(
sub
setting
,
ENB_CONFIG_STRING_ENB_IPV4_ADDRESS_FOR_S1_MME
,
(
const
char
**
)
&
enb_ipv4_address_for_S1_MME
)
&&
config_setting_lookup_string
(
setting
,
ENB_CONFIG_STRING_ENB_INTERFACE_NAME_FOR_S1U
,
&&
config_setting_lookup_string
(
sub
setting
,
ENB_CONFIG_STRING_ENB_INTERFACE_NAME_FOR_S1U
,
(
const
char
**
)
&
enb_interface_name_for_S1U
)
&&
config_setting_lookup_string
(
setting
,
ENB_CONFIG_STRING_ENB_IPV4_ADDR_FOR_S1U
,
&&
config_setting_lookup_string
(
sub
setting
,
ENB_CONFIG_STRING_ENB_IPV4_ADDR_FOR_S1U
,
(
const
char
**
)
&
enb_ipv4_address_for_S1U
)
)
){
...
...
@@ -441,7 +441,6 @@ const Enb_properties_array_t *enb_config_init(char* lib_config_file_name_pP) {
cidr
=
enb_ipv4_address_for_S1U
;
address
=
strtok
(
cidr
,
"/"
);
if
(
address
)
{
address
=
strdup
(
address
);
IPV4_STR_ADDR_TO_INT_NWBO
(
address
,
enb_properties
.
properties
[
enb_properties_index
]
->
enb_ipv4_address_for_S1U
,
"BAD IP ADDRESS FORMAT FOR eNB S1_U !
\n
"
);
}
...
...
@@ -449,7 +448,6 @@ const Enb_properties_array_t *enb_config_init(char* lib_config_file_name_pP) {
cidr
=
enb_ipv4_address_for_S1_MME
;
address
=
strtok
(
cidr
,
"/"
);
if
(
address
)
{
address
=
strdup
(
address
);
IPV4_STR_ADDR_TO_INT_NWBO
(
address
,
enb_properties
.
properties
[
enb_properties_index
]
->
enb_ipv4_address_for_S1_MME
,
"BAD IP ADDRESS FORMAT FOR eNB S1_MME !
\n
"
);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment