Attention is currently required from: daniel, neels.
laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/35095?usp=email )
Change subject: early-IA: use the correct TRX
......................................................................
Patch Set 3:
(1 comment)
Patchset:
PS3:
ping? This has been idle 2 weeks; let's ad the error report and get it merged.
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/35095?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: Id9a930e5c67122812b229dc27ea2bfe246b67611
Gerrit-Change-Number: 35095
Gerrit-PatchSet: 3
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: daniel <dwillmann(a)sysmocom.de>
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Sun, 17 Dec 2023 10:48:38 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
laforge has submitted this change. ( https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35218?usp=email )
Change subject: epdg_gtpc_s2b: add TLV Serving Network
......................................................................
epdg_gtpc_s2b: add TLV Serving Network
The open5gs requires Serving Network TLV.
Change-Id: I2a9459859fc660e6433cd8178ab9d1f92ae74fc0
---
M src/epdg_gtpc_s2b.erl
A src/gtp_utils.erl
2 files changed, 63 insertions(+), 3 deletions(-)
Approvals:
pespin: Looks good to me, but someone else must approve
Jenkins Builder: Verified
laforge: Looks good to me, approved
diff --git a/src/epdg_gtpc_s2b.erl b/src/epdg_gtpc_s2b.erl
index a5658f1..152036f 100644
--- a/src/epdg_gtpc_s2b.erl
+++ b/src/epdg_gtpc_s2b.erl
@@ -59,6 +59,9 @@
%% TODO: make APN configurable? get it from HSS?
-define(APN, <<"internet">>).
+-define(MCC, 901).
+-define(MNC, 42).
+-define(MNC_SIZE, 3).
-record(gtp_state, {
socket,
@@ -330,7 +333,10 @@
#v2_access_point_name{instance = 0, apn = [Apn]},
#v2_selection_mode{mode = 0},
#v2_pdn_address_allocation{type = ipv4, address = <<0,0,0,0>>},
- #v2_bearer_context{group = BearersIE}
+ #v2_bearer_context{group = BearersIE},
+ #v2_serving_network{
+ plmn_id = gtp_utils:plmn_to_bin(?MCC, ?MNC, ?MNC_SIZE)
+ }
],
#gtp{version = v2, type = create_session_request, tei = 0, seq_no = SeqNo, ie = IEs}.
@@ -346,5 +352,3 @@
tei = RemoteCtlTEI,
seq_no = Req#gtp.seq_no,
ie = IEs}.
-
-
diff --git a/src/gtp_utils.erl b/src/gtp_utils.erl
new file mode 100644
index 0000000..b899530
--- /dev/null
+++ b/src/gtp_utils.erl
@@ -0,0 +1,45 @@
+% GTP utilities
+%
+% (C) 2023 by sysmocom - s.f.m.c. GmbH <info(a)sysmocom.de>
+% Author: Alexander Couzens <lynxis(a)fe80.eu>
+%
+% All Rights Reserved
+%
+% This program is free software; you can redistribute it and/or modify
+% it under the terms of the GNU Affero General Public License as
+% published by the Free Software Foundation; either version 3 of the
+% License, or (at your option) any later version.
+%
+% This program is distributed in the hope that it will be useful,
+% but WITHOUT ANY WARRANTY; without even the implied warranty of
+% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+% GNU General Public License for more details.
+%
+% You should have received a copy of the GNU Affero General Public License
+% along with this program. If not, see <http://www.gnu.org/licenses/>.
+%
+% Additional Permission under GNU AGPL version 3 section 7:
+%
+% If you modify this Program, or any covered work, by linking or
+% combining it with runtime libraries of Erlang/OTP as released by
+% Ericsson on http://www.erlang.org (or a modified version of these
+% libraries), containing parts covered by the terms of the Erlang Public
+% License (http://www.erlang.org/EPLICENSE), the licensors of this
+% Program grant you additional permission to convey the resulting work
+% without the need to license the runtime libraries of Erlang/OTP under
+% the GNU Affero General Public License. Corresponding Source for a
+% non-source form of such a combination shall include the source code
+% for the parts of the runtime libraries of Erlang/OTP used as well as
+% that of the covered work.
+
+-module(gtp_utils).
+-author('Alexander Couzens <lynxis(a)fe80.eu>').
+
+-export([plmn_to_bin/3]).
+
+% ergw/apps/ergw/test/*.erl
+% under GPLv2+
+plmn_to_bin(CC, NC, NCSize) ->
+ MCC = iolist_to_binary(io_lib:format("~3..0b", [CC])),
+ MNC = iolist_to_binary(io_lib:format("~*..0b", [NCSize, NC])),
+ {MCC, MNC}.
--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35218?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9459859fc660e6433cd8178ab9d1f92ae74fc0
Gerrit-Change-Number: 35218
Gerrit-PatchSet: 4
Gerrit-Owner: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged