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
wangjie
OpenXG-RAN
Commits
ce7ba191
Commit
ce7ba191
authored
Dec 05, 2014
by
Lionel Gauthier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
git-svn-id:
http://svn.eurecom.fr/openair4G/trunk@6178
818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent
7d35d3b9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
3 deletions
+14
-3
openair-cn/SGW-LITE/sgw_lite_handlers.c
openair-cn/SGW-LITE/sgw_lite_handlers.c
+7
-1
openair-cn/SGW-LITE/sgw_lite_task.c
openair-cn/SGW-LITE/sgw_lite_task.c
+0
-1
openair-cn/SGW-LITE/spgw_config.c
openair-cn/SGW-LITE/spgw_config.c
+7
-1
No files found.
openair-cn/SGW-LITE/sgw_lite_handlers.c
View file @
ce7ba191
...
@@ -611,6 +611,7 @@ sgw_lite_handle_sgi_endpoint_updated(
...
@@ -611,6 +611,7 @@ sgw_lite_handle_sgi_endpoint_updated(
task_id_t
to_task
;
task_id_t
to_task
;
#if defined (ENABLE_USE_GTPU_IN_KERNEL)
#if defined (ENABLE_USE_GTPU_IN_KERNEL)
static
uint8_t
iptable_uplink_remove_gtpu
=
FALSE
;
static
uint8_t
iptable_uplink_remove_gtpu
=
FALSE
;
char
*
interface_name_p
=
NULL
;
#endif
#endif
#if defined(ENABLE_STANDALONE_EPC)
#if defined(ENABLE_STANDALONE_EPC)
...
@@ -696,11 +697,16 @@ sgw_lite_handle_sgi_endpoint_updated(
...
@@ -696,11 +697,16 @@ sgw_lite_handle_sgi_endpoint_updated(
}
}
if
(
iptable_uplink_remove_gtpu
==
FALSE
)
{
if
(
iptable_uplink_remove_gtpu
==
FALSE
)
{
if
(
strncasecmp
(
"tun"
,
sgw_app
.
sgw_interface_name_for_S1u_S12_S4_up
,
strlen
(
"tun"
))
==
0
)
{
interface_name_p
=
"lo"
;
}
else
{
interface_name_p
=
sgw_app
.
sgw_interface_name_for_S1u_S12_S4_up
;
}
ret
=
snprintf
(
cmd
,
ret
=
snprintf
(
cmd
,
256
,
256
,
// no "-p udp --dport 2152" because of fragmented packets
// no "-p udp --dport 2152" because of fragmented packets
"iptables -t raw -I PREROUTING -i %s -s %u.%u.%u.%u -d %u.%u.%u.%u -p udp --dport 2152 -j GTPURH --action remove"
,
"iptables -t raw -I PREROUTING -i %s -s %u.%u.%u.%u -d %u.%u.%u.%u -p udp --dport 2152 -j GTPURH --action remove"
,
sgw_app
.
sgw_interface_name_for_S1u_S12_S4_u
p
,
interface_name_
p
,
eps_bearer_entry_p
->
enb_ip_address_for_S1u
.
address
.
ipv4_address
[
0
],
eps_bearer_entry_p
->
enb_ip_address_for_S1u
.
address
.
ipv4_address
[
0
],
eps_bearer_entry_p
->
enb_ip_address_for_S1u
.
address
.
ipv4_address
[
1
],
eps_bearer_entry_p
->
enb_ip_address_for_S1u
.
address
.
ipv4_address
[
1
],
eps_bearer_entry_p
->
enb_ip_address_for_S1u
.
address
.
ipv4_address
[
2
],
eps_bearer_entry_p
->
enb_ip_address_for_S1u
.
address
.
ipv4_address
[
2
],
...
...
openair-cn/SGW-LITE/sgw_lite_task.c
View file @
ce7ba191
...
@@ -150,7 +150,6 @@ int sgw_lite_init(char* config_file_name_pP)
...
@@ -150,7 +150,6 @@ int sgw_lite_init(char* config_file_name_pP)
spgw_system
(
"insmod $OPENAIRCN_DIR/GTPV1-U/GTPURH/Bin/xt_GTPURH.ko"
,
1
);
spgw_system
(
"insmod $OPENAIRCN_DIR/GTPV1-U/GTPURH/Bin/xt_GTPURH.ko"
,
1
);
#endif
#endif
spgw_config_init
(
config_file_name_pP
,
&
spgw_config
);
spgw_config_init
(
config_file_name_pP
,
&
spgw_config
);
spgw_config_process
(
&
spgw_config
);
pgw_lite_load_pool_ip_addresses
();
pgw_lite_load_pool_ip_addresses
();
sgw_app
.
s11teid2mme_hashtable
=
hashtable_create
(
8192
,
NULL
,
NULL
);
sgw_app
.
s11teid2mme_hashtable
=
hashtable_create
(
8192
,
NULL
,
NULL
);
...
...
openair-cn/SGW-LITE/spgw_config.c
View file @
ce7ba191
...
@@ -174,8 +174,9 @@ int spgw_config_process(spgw_config_t* config_pP) {
...
@@ -174,8 +174,9 @@ int spgw_config_process(spgw_config_t* config_pP) {
}
}
inaddr
.
s_addr
=
config_pP
->
sgw_config
.
ipv4
.
sgw_ipv4_address_for_S1u_S12_S4_up
;
inaddr
.
s_addr
=
config_pP
->
sgw_config
.
ipv4
.
sgw_ipv4_address_for_S1u_S12_S4_up
;
if
(
snprintf
(
system_cmd
,
256
,
if
(
snprintf
(
system_cmd
,
256
,
"ip -4 addr add %s dev %s"
,
"ip -4 addr add %s
/%d
dev %s"
,
inet_ntoa
(
inaddr
),
inet_ntoa
(
inaddr
),
config_pP
->
sgw_config
.
ipv4
.
sgw_ip_netmask_for_S1u_S12_S4_up
,
config_pP
->
sgw_config
.
ipv4
.
sgw_interface_name_for_S1u_S12_S4_up
)
>
0
)
{
config_pP
->
sgw_config
.
ipv4
.
sgw_interface_name_for_S1u_S12_S4_up
)
>
0
)
{
ret
+=
spgw_system
(
system_cmd
,
1
);
ret
+=
spgw_system
(
system_cmd
,
1
);
}
else
{
}
else
{
...
@@ -479,6 +480,11 @@ int spgw_config_init(char* lib_config_file_name_pP, spgw_config_t* config_pP) {
...
@@ -479,6 +480,11 @@ int spgw_config_init(char* lib_config_file_name_pP, spgw_config_t* config_pP) {
}
else
{
}
else
{
SPGW_APP_WARN
(
"CONFIG P-GW / NETWORK INTERFACES not found
\n
"
);
SPGW_APP_WARN
(
"CONFIG P-GW / NETWORK INTERFACES not found
\n
"
);
}
}
//!!!------------------------------------!!!
spgw_config_process
(
config_pP
);
//!!!------------------------------------!!!
subsetting
=
config_setting_get_member
(
setting_pgw
,
PGW_CONFIG_STRING_IP_ADDRESS_POOL
);
subsetting
=
config_setting_get_member
(
setting_pgw
,
PGW_CONFIG_STRING_IP_ADDRESS_POOL
);
if
(
subsetting
!=
NULL
)
{
if
(
subsetting
!=
NULL
)
{
sub2setting
=
config_setting_get_member
(
subsetting
,
PGW_CONFIG_STRING_IPV4_ADDRESS_LIST
);
sub2setting
=
config_setting_get_member
(
subsetting
,
PGW_CONFIG_STRING_IPV4_ADDRESS_LIST
);
...
...
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