Attention is currently required from: osmith.
pespin has posted comments on this change by osmith. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37884?usp=email )
Change subject: testenv: cmd: pass all env vars without --podman
......................................................................
Patch Set 1: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37884?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I5e710a1ee7185a3f6f4f1e98f201f3f6fda2be55
Gerrit-Change-Number: 37884
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 21 Aug 2024 09:18:29 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37884?usp=email )
Change subject: testenv: cmd: pass all env vars without --podman
......................................................................
testenv: cmd: pass all env vars without --podman
As suggested by Pau, pass all environment variables to through testenv
if it is running without podman. This way a custom TTCN3_DIR,
TTCN3_BIN_DIR and more variables that may make sense when running
directly on the host, work as expected.
Closes: OS#6544
Change-Id: I5e710a1ee7185a3f6f4f1e98f201f3f6fda2be55
---
M _testenv/testenv/cmd.py
1 file changed, 7 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/84/37884/1
diff --git a/_testenv/testenv/cmd.py b/_testenv/testenv/cmd.py
index cb8386a..6f502fc 100644
--- a/_testenv/testenv/cmd.py
+++ b/_testenv/testenv/cmd.py
@@ -78,6 +78,13 @@
for var in env:
ret[var] = env[var]
+
+ # Without podman: pass all environment variables from host (OS#6544)
+ if not podman:
+ for var in os.environ:
+ if var not in ret:
+ ret[var] = os.environ.get(var)
+
return ret
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37884?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I5e710a1ee7185a3f6f4f1e98f201f3f6fda2be55
Gerrit-Change-Number: 37884
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
laforge has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/37874?usp=email )
Change subject: core/socket.c: Fix socket binding on IPv4-only hosts
......................................................................
core/socket.c: Fix socket binding on IPv4-only hosts
Let's avoid attempting to use IPv6 addresses on hosts that do not
have IPv6 capability.
Change-Id: I5690a25af98089e3a8a092cb91dfc969720abdc0
Closes: SYS#7047
---
M src/core/socket.c
1 file changed, 24 insertions(+), 1 deletion(-)
Approvals:
Jenkins Builder: Verified
Hoernchen: Looks good to me, approved
pespin: Looks good to me, but someone else must approve
diff --git a/src/core/socket.c b/src/core/socket.c
index e394cf9..da20981 100644
--- a/src/core/socket.c
+++ b/src/core/socket.c
@@ -278,6 +278,24 @@
return 0;
}
+/*! Determine if the system supports AF_INET6 sockets at all.
+ * We call socket(AF_INET6) once and cache the result value. */
+static bool system_supports_inet6(void)
+{
+ static int cached_val = -1;
+
+ if (cached_val < 0) {
+ int rc = socket(AF_INET6, SOCK_DGRAM, IPPROTO_UDP);
+ if (rc < 0 && errno == EAFNOSUPPORT) {
+ cached_val = 0;
+ } else {
+ cached_val = 1;
+ close(rc);
+ }
+ }
+ return cached_val == 1;
+}
+
/*! Initialize a socket (including bind and/or connect)
* \param[in] family Address Family like AF_INET, AF_INET6, AF_UNSPEC
* \param[in] type Socket type like SOCK_DGRAM, SOCK_STREAM
@@ -343,7 +361,12 @@
/* It must do a full run to ensure AF_UNSPEC does not fail.
* In case first local valid entry is IPv4 and only remote valid entry
* is IPv6 or vice versa */
- if (family == AF_UNSPEC) {
+ if (!system_supports_inet6()) {
+ /* if no AF_INET6 is supported, then the decision is easy...*/
+ local_ipv4 = true;
+ remote_ipv4 = true;
+ family = AF_INET;
+ } else if (family == AF_UNSPEC) {
for (rp = local; rp != NULL; rp = rp->ai_next) {
switch (rp->ai_family) {
case AF_INET:
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/37874?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I5690a25af98089e3a8a092cb91dfc969720abdc0
Gerrit-Change-Number: 37874
Gerrit-PatchSet: 5
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Hoernchen <ewild(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Attention is currently required from: neels.
laforge has posted comments on this change by neels. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/37880?usp=email )
Change subject: fixup: initialize g_hnbp_ctr_id = 0
......................................................................
Patch Set 1: Code-Review-1
(1 comment)
Patchset:
PS1:
all static variables are always guaranteed to be initialized with 0. That's how the linker initializes the bss segment...
--
To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/37880?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: I353e026d6e3d2c3c8b13a0ca8bd4c09609632b84
Gerrit-Change-Number: 37880
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 21 Aug 2024 06:20:10 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Attention is currently required from: neels.
laforge has posted comments on this change by neels. ( https://gerrit.osmocom.org/c/libosmocore/+/37881?usp=email )
Change subject: CTRL: get rate_ctr_group by the id from rate_ctr_group_set_name()
......................................................................
Patch Set 2:
(1 comment)
Patchset:
PS2:
the obvious potential problem here is of course the inefficiency of a linear-list iteration in case there are many such requests. So either we accept that cost, or we introduce some kind of hashing scheme, or we don't offer such a look-up function...
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/37881?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I841a12f76e6fcb2bd7aecb5f4b1707d9ec927137
Gerrit-Change-Number: 37881
Gerrit-PatchSet: 2
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 21 Aug 2024 06:19:19 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Attention is currently required from: fixeria, laforge.
Hello Jenkins Builder, fixeria, laforge,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-upf/+/37830?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Code-Review+1 by laforge, Code-Review-1 by fixeria, Verified+1 by Jenkins Builder
Change subject: add VTY 'gtp-echo' command
......................................................................
add VTY 'gtp-echo' command
Allow sending GTPv1-U Echo Requests to GTP peers via new VTY command
gtp-echo tx to 1.2.3.4 [from (dev|ip) (apn0|5.6.7.8)]
(pseudocode)
Related: OS#6541
Change-Id: I970dccd7a27b098eea9e660822e24e2c4b059fc6
---
M include/osmocom/upf/upf.h
M include/osmocom/upf/upf_gtpu_echo.h
M src/osmo-upf/upf_gtpu_echo.c
M src/osmo-upf/upf_vty.c
A tests/gtp-echo.vty
5 files changed, 160 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-upf refs/changes/30/37830/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-upf/+/37830?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: osmo-upf
Gerrit-Branch: master
Gerrit-Change-Id: I970dccd7a27b098eea9e660822e24e2c4b059fc6
Gerrit-Change-Number: 37830
Gerrit-PatchSet: 2
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Attention is currently required from: fixeria.
neels has posted comments on this change by neels. ( https://gerrit.osmocom.org/c/osmo-upf/+/37830?usp=email )
Change subject: add VTY 'gtp-echo' command
......................................................................
Patch Set 1:
(3 comments)
File src/osmo-upf/upf_vty.c:
https://gerrit.osmocom.org/c/osmo-upf/+/37830/comment/d3d76587_487cbd22?usp… :
PS1, Line 491: tx to
> The command vector looks overloaded to me: […]
Would you accept this?
gtp-echo tx remote-ip IP_ADDR [(local-ip|local-dev)] [IP_ADDR_OR_DEV]
The reason i sprinkle these words in between is to allow future extensions to the vty language.
When arguments have no explicit prefix like 'gtp-echo REMOTE_ADDR', then future 'gtp-echo' commands are prone to have conflicts. What if we want to allow resolving a hostname (stupid example but..). What then if a user wants to use a hostname that is the same as some other vty token that an alternative command offers in the same place.
I've faced such situations before, so I would much prefer to explicitly name each argument.
I agree that 'tx to' doesn't seem nice, but think semantically, inserting 'foo' for arbitrary future extensions:
```
gtp-echo
|- gtp-echo tx
| |- to
| |- from
| | |- ip
| | |- dev
| |- foo
|- gtp-echo foo
```
That is my idea behind it: the "tx" is one branch, the "to" a sub-branch of the argument logic. I thought somewhat about this but would like to keep those keywords in there. Is that too future paranoid?
https://gerrit.osmocom.org/c/osmo-upf/+/37830/comment/74265275_b829a746?usp… :
PS1, Line 556: %%Error
> cosmetic: missing space
missing space?
File tests/gtp-echo.vty:
https://gerrit.osmocom.org/c/osmo-upf/+/37830/comment/e9563e63_dde20d69?usp… :
PS1, Line 2: show pid
: show uptime
: show version
: show online-help
: list [with-flags]
: exit
: help
: show vty-attributes
: show vty-attributes (application|library|global)
: enable [expert-mode]
: terminal length <0-512>
: terminal no length
:
> these lines (and more below), for obvious reasons, shall not be part of the VTY test
oof, got so annoyed from removing them every time that i just left them in while testing ... and forgot! thanks
--
To view, visit https://gerrit.osmocom.org/c/osmo-upf/+/37830?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-upf
Gerrit-Branch: master
Gerrit-Change-Id: I970dccd7a27b098eea9e660822e24e2c4b059fc6
Gerrit-Change-Number: 37830
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 20 Aug 2024 22:30:31 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Hello Jenkins Builder,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37883?usp=email
to look at the new patch set (#3).
Change subject: ctrl: tweak errmsg for counter mismatch
......................................................................
ctrl: tweak errmsg for counter mismatch
- instead of "-1", print "not present", so humans know what is
happening.
- the comma separated args in setverdict() create a lot of weird quotes.
Use string concatenation to have only one set of quotes around the
entire error message.
Related: OS#6545
Change-Id: I672fcef819a6542a5b3bcfa0a6d9c84d34b468f3
---
M library/Osmocom_CTRL_Functions.ttcn
1 file changed, 12 insertions(+), 3 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/83/37883/3
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/37883?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I672fcef819a6542a5b3bcfa0a6d9c84d34b468f3
Gerrit-Change-Number: 37883
Gerrit-PatchSet: 3
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder