[S] Change in libosmocore[master]: write_queue: Fix Doxygen comment
arehbein has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/34695?usp=email ) Change subject: write_queue: Fix Doxygen comment .. write_queue: Fix Doxygen comment Change-Id: Ib2508411ae46e2456466beaae63d3f401e34d0d4 --- M src/core/write_queue.c 1 file changed, 10 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/95/34695/1 diff --git a/src/core/write_queue.c b/src/core/write_queue.c index ffa7704..8fb73a6 100644 --- a/src/core/write_queue.c +++ b/src/core/write_queue.c @@ -147,7 +147,7 @@ queue->bfd.when &= ~OSMO_FD_WRITE; } -/* Update write queue length & drop excess messages. +/*! Update write queue length & drop excess messages. * \param[in] queue linked list header of message queue * \param[in] len new max. wqueue length * \returns Number of messages dropped. -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/34695?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: Ib2508411ae46e2456466beaae63d3f401e34d0d4 Gerrit-Change-Number: 34695 Gerrit-PatchSet: 1 Gerrit-Owner: arehbein Gerrit-MessageType: newchange
[S] Change in libosmocore[master]: write_queue: Fix Doxygen comment
Attention is currently required from: arehbein. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/34695?usp=email ) Change subject: write_queue: Fix Doxygen comment .. Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/34695?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: Ib2508411ae46e2456466beaae63d3f401e34d0d4 Gerrit-Change-Number: 34695 Gerrit-PatchSet: 1 Gerrit-Owner: arehbein Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin Gerrit-Attention: arehbein Gerrit-Comment-Date: Tue, 10 Oct 2023 08:21:37 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in osmo-bsc[master]: bsc: Make socket queue max. length configurable
Attention is currently required from: dexter, pespin. arehbein has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/33892?usp=email ) Change subject: bsc: Make socket queue max. length configurable .. Patch Set 6: (1 comment) This change is ready for review. File src/osmo-bsc/bsc_vty.c: https://gerrit.osmocom.org/c/osmo-bsc/+/33892/comment/b5ff566b_ed26488b PS1, Line 2491: } > I have added a patch so that the write queue length can be updated and any > excess messages are dropp […] I have just added usage of `osmo_wqueue_set_maxlen()` in `src/osmo-bsc/bsc_vty.c` -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/33892?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Ic5f19f4613bccaf582997a4d02b689adee083a0b Gerrit-Change-Number: 33892 Gerrit-PatchSet: 6 Gerrit-Owner: arehbein Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter Gerrit-Reviewer: pespin Gerrit-CC: laforge Gerrit-Attention: pespin Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 08:43:57 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: arehbein Comment-In-Reply-To: pespin Gerrit-MessageType: comment
[M] Change in pysim[master]: pySim-prog, pySim-shell do not use global variables
dexter has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/34688?usp=email ) Change subject: pySim-prog, pySim-shell do not use global variables .. pySim-prog, pySim-shell do not use global variables When __main__ runs different variables get assigned. In particular opts, scc, sl and ch. Those variables are available in any scope and technically it is possible to access them. However, lets not do this since it leads to confusion. Also, pylint will complain about those code locations. In pySim-shell.py - Let's use the proper locations (sl and ch are stored in PysimApp. - Scc can be assigned in init_card. - In method walk, the use of the variable opts to call ection_df is wrong, lets use **kwargs (see also usage of action_ef). - The constructor of Cmd2ApduTracer has a parameter cmd2_app, but usese the global variable app. Let's use cmd2_app instead. In pySim-prog.py - Do not use opts.num in find_row_in_csv_file, use num instead. - Pass scc to process_card as parameter so that it won't access scc in the global scope. Change-Id: I7f09e9a6a6bfc658de75e86f7383ce73726f Related: OS#6210 --- M pySim-prog.py M pySim-shell.py 2 files changed, 41 insertions(+), 12 deletions(-) Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified fixeria: Looks good to me, but someone else must approve osmith: Looks good to me, but someone else must approve diff --git a/pySim-prog.py b/pySim-prog.py index c07bfd1..a16928c 100755 --- a/pySim-prog.py +++ b/pySim-prog.py @@ -567,7 +567,7 @@ for row in cr: # Pick a specific row by line number (num) if num is not None and iccid is None and imsi is None: -if opts.num == i: +if num == i: f.close() return row @@ -727,7 +727,7 @@ fh.close() -def process_card(opts, first, ch): +def process_card(scc, opts, first, ch): # Connect transport ch.get(first) @@ -821,7 +821,7 @@ while 1: try: -rc = process_card(opts, first, ch) +rc = process_card(scc, opts, first, ch) except (KeyboardInterrupt): print("") print("Terminated by user!") diff --git a/pySim-shell.py b/pySim-shell.py index c7b2607..3b6945c 100755 --- a/pySim-shell.py +++ b/pySim-shell.py @@ -88,6 +88,9 @@ state object (rs) is required for all pySim-shell commands. """ +# Create command layer +scc = SimCardCommands(transport=sl) + # Wait up to three seconds for a card in reader and try to detect # the card type. print("Waiting for card...") @@ -276,7 +279,7 @@ class Cmd2ApduTracer(ApduTracer): def __init__(self, cmd2_app): -self.cmd2 = app +self.cmd2 = cmd2_app def trace_response(self, cmd, sw, resp): self.cmd2.poutput("-> %s %s" % (cmd[:10], cmd[10:])) @@ -307,7 +310,7 @@ if self.rs and self.rs.profile: for cmd_set in self.rs.profile.shell_cmdsets: self.unregister_command_set(cmd_set) -rs, card = init_card(sl) +rs, card = init_card(self.sl) self.equip(card, rs) apdu_cmd_parser = argparse.ArgumentParser() @@ -440,7 +443,7 @@ # In case of failure, try multiple times. for i in range(opts.tries): # fetch card into reader bay -ch.get(first) +self.ch.get(first) # if necessary execute an action before we start processing the card if(opts.pre_card_action): @@ -463,9 +466,9 @@ # Depending on success or failure, the card goes either in the "error" bin or in the # "done" bin. if rc < 0: -ch.error() +self.ch.error() else: -ch.done() +self.ch.done() # In most cases it is possible to proceed with the next card, but the # user may decide to halt immediately when an error occurs @@ -559,7 +562,7 @@ if isinstance(self._cmd.lchan.selected_file, CardDF): if action_df: -action_df(context, opts) +action_df(context, **kwargs) files = self._cmd.lchan.selected_file.get_selectables( flags=['FNAMES', 'ANAMES']) @@ -1015,9 +1018,6 @@ if sl is None: exit(1) -# Create command layer -scc = SimCardCommands(transport=sl) - # Create a card handler (for bulk provisioning) if opts.card_handler_config: ch = CardHandlerAuto(None, opts.card_handler_config) -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34688?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I7
[S] Change in pysim[master]: pySim-shell: do not pass failed card object to PysimApp
Attention is currently required from: dexter. Hello Jenkins Builder, fixeria, laforge, osmith, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/pysim/+/34691?usp=email to look at the new patch set (#2). The following approvals got outdated and were removed: Verified+1 by Jenkins Builder The change is no longer submittable: Verified is unsatisfied now. Change subject: pySim-shell: do not pass failed card object to PysimApp .. pySim-shell: do not pass failed card object to PysimApp When the try block in which we also call init_card() fails, there may be no card object, so we must not pass the card object to PysimApp in the except block. This is also no problem, PysimApp will run without the card object until the user executes do_equip for a second attempt. Related: OS#6210 Change-Id: I28195f442ce007f05f7610c882bbc4a6520a8ce6 --- M pySim-shell.py 1 file changed, 16 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/91/34691/2 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34691?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I28195f442ce007f05f7610c882bbc4a6520a8ce6 Gerrit-Change-Number: 34691 Gerrit-PatchSet: 2 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: laforge Gerrit-Reviewer: osmith Gerrit-Attention: dexter Gerrit-MessageType: newpatchset
[S] Change in pysim[master]: transport: show full traceback on failed reader init
Attention is currently required from: dexter, laforge, osmith. Hello Jenkins Builder, laforge, osmith, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/pysim/+/34687?usp=email to look at the new patch set (#5). The following approvals got outdated and were removed: Code-Review+1 by osmith, Verified+1 by Jenkins Builder Change subject: transport: show full traceback on failed reader init .. transport: show full traceback on failed reader init When the reader initialization fails with an exception we may have a major hardware problem and it may not be enough to print only the exception message. Also in some rare cases an exception message may not be available. To make it easier to debug problems lets print the full traceback like we already do it in pySim-shell.py. Related: OS#6210 Change-Id: I46e913a516dbc13f7610512484f515ab25d3fbae --- M pySim/transport/__init__.py 1 file changed, 22 insertions(+), 5 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/87/34687/5 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34687?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I46e913a516dbc13f7610512484f515ab25d3fbae Gerrit-Change-Number: 34687 Gerrit-PatchSet: 5 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge Gerrit-Reviewer: osmith Gerrit-CC: fixeria Gerrit-Attention: osmith Gerrit-Attention: laforge Gerrit-Attention: dexter Gerrit-MessageType: newpatchset
[S] Change in pysim[master]: pySim-shell: do not pass failed card object to PysimApp
dexter has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/34691?usp=email ) ( 1 is the latest approved patch-set. No files were changed between the latest approved patch-set and the submitted one. )Change subject: pySim-shell: do not pass failed card object to PysimApp .. pySim-shell: do not pass failed card object to PysimApp When the try block in which we also call init_card() fails, there may be no card object, so we must not pass the card object to PysimApp in the except block. This is also no problem, PysimApp will run without the card object until the user executes do_equip for a second attempt. Related: OS#6210 Change-Id: I28195f442ce007f05f7610c882bbc4a6520a8ce6 --- M pySim-shell.py 1 file changed, 16 insertions(+), 1 deletion(-) Approvals: laforge: Looks good to me, approved fixeria: Looks good to me, approved Jenkins Builder: Verified osmith: Looks good to me, but someone else must approve diff --git a/pySim-shell.py b/pySim-shell.py index 3b6945c..79b4d8b 100755 --- a/pySim-shell.py +++ b/pySim-shell.py @@ -1040,7 +1040,7 @@ " it should also be noted that some readers may behave strangely when no card") print(" is inserted.)") print("") -app = PysimApp(card, None, sl, ch, opts.script) +app = PysimApp(None, None, sl, ch, opts.script) # If the user supplies an ADM PIN at via commandline args authenticate # immediately so that the user does not have to use the shell commands -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34691?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I28195f442ce007f05f7610c882bbc4a6520a8ce6 Gerrit-Change-Number: 34691 Gerrit-PatchSet: 2 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter Gerrit-Reviewer: fixeria Gerrit-Reviewer: laforge Gerrit-Reviewer: osmith Gerrit-MessageType: merged
[S] Change in pysim[master]: pySim-shell: print device info in case an exception occurs
Attention is currently required from: dexter. Hello Jenkins Builder, fixeria, laforge, osmith, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/pysim/+/34692?usp=email to look at the new patch set (#6). The following approvals got outdated and were removed: Verified+1 by Jenkins Builder The change is no longer submittable: Verified is unsatisfied now. Change subject: pySim-shell: print device info in case an exception occurs .. pySim-shell: print device info in case an exception occurs When an exception occurs while initializing or handling the card we print a traceback, but we do not print any info that allows us to identify the device that was involved when the exception occurred. Let's include the device path or number in the error message before we print the traceback. In order to make it easier to print the device information, let's add a __str__() method to all of our devices. This method shall return the device number or path. Related: OS#6210 Change-Id: I200463e692245da40ea6d5b609bfc0ca02d15bdb --- M pySim-shell.py M pySim-trace.py M pySim/transport/__init__.py M pySim/transport/calypso.py M pySim/transport/modem_atcmd.py M pySim/transport/pcsc.py M pySim/transport/serial.py 7 files changed, 46 insertions(+), 3 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/92/34692/6 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34692?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I200463e692245da40ea6d5b609bfc0ca02d15bdb Gerrit-Change-Number: 34692 Gerrit-PatchSet: 6 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: laforge Gerrit-Reviewer: osmith Gerrit-Attention: dexter Gerrit-MessageType: newpatchset
[S] Change in pysim[master]: transport: show full traceback on failed reader init
Attention is currently required from: fixeria, laforge, osmith. dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34687?usp=email ) Change subject: transport: show full traceback on failed reader init .. Patch Set 6: (1 comment) Commit Message: https://gerrit.osmocom.org/c/pysim/+/34687/comment/c4fdd4c7_b92988cd PS4, Line 9: failes > fails? Done -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34687?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I46e913a516dbc13f7610512484f515ab25d3fbae Gerrit-Change-Number: 34687 Gerrit-PatchSet: 6 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge Gerrit-Reviewer: osmith Gerrit-CC: fixeria Gerrit-Attention: osmith Gerrit-Attention: laforge Gerrit-Attention: fixeria Gerrit-Comment-Date: Tue, 10 Oct 2023 09:51:30 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: fixeria Gerrit-MessageType: comment
[S] Change in pysim[master]: pySim-shell: print device info in case an exception occurs
dexter has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/34692?usp=email ) ( 4 is the latest approved patch-set. No files were changed between the latest approved patch-set and the submitted one. )Change subject: pySim-shell: print device info in case an exception occurs .. pySim-shell: print device info in case an exception occurs When an exception occurs while initializing or handling the card we print a traceback, but we do not print any info that allows us to identify the device that was involved when the exception occurred. Let's include the device path or number in the error message before we print the traceback. In order to make it easier to print the device information, let's add a __str__() method to all of our devices. This method shall return the device number or path. Related: OS#6210 Change-Id: I200463e692245da40ea6d5b609bfc0ca02d15bdb --- M pySim-shell.py M pySim-trace.py M pySim/transport/__init__.py M pySim/transport/calypso.py M pySim/transport/modem_atcmd.py M pySim/transport/pcsc.py M pySim/transport/serial.py 7 files changed, 46 insertions(+), 3 deletions(-) Approvals: osmith: Looks good to me, but someone else must approve laforge: Looks good to me, but someone else must approve Jenkins Builder: Verified fixeria: Looks good to me, approved diff --git a/pySim-shell.py b/pySim-shell.py index 79b4d8b..56655ba 100755 --- a/pySim-shell.py +++ b/pySim-shell.py @@ -374,7 +374,7 @@ rc = self.equip(card, rs) except: self.poutput("") -self.poutput("Card initialization failed with an exception:") +self.poutput("Card initialization (%s) failed with an exception:" % str(self.sl)) self.poutput("-8<-") traceback.print_exc() self.poutput("-8<-") @@ -489,7 +489,7 @@ return except: self.poutput("") -self.poutput("Card handling failed with an exception:") +self.poutput("Card handling (%s) failed with an exception:" % str(self.sl)) self.poutput("-8<-") traceback.print_exc() self.poutput("-8<-") @@ -1031,7 +1031,7 @@ rs, card = init_card(sl) app = PysimApp(card, rs, sl, ch, opts.script) except: -print("Card initialization failed with an exception:") +print("Card initialization (%s) failed with an exception:" % str(sl)) print("-8<-") traceback.print_exc() print("-8<-") diff --git a/pySim-trace.py b/pySim-trace.py index 325fb8c..eb29ed1 100755 --- a/pySim-trace.py +++ b/pySim-trace.py @@ -48,6 +48,9 @@ self._debug = debug self._atr = h2i('3B9F96801F878031E073FE211B674A4C753034054BA9') +def __str__(self): +return "dummy" + def _send_apdu_raw(self, pdu): #print("DummySimLink-apdu: %s" % pdu) return [], '9000' diff --git a/pySim/transport/__init__.py b/pySim/transport/__init__.py index c8079f6..1dd8d18 100644 --- a/pySim/transport/__init__.py +++ b/pySim/transport/__init__.py @@ -68,6 +68,10 @@ self.proactive_handler = proactive_handler @abc.abstractmethod +def __str__(self): +"""Implementation specific method for printing an information to identify the device.""" + +@abc.abstractmethod def _send_apdu_raw(self, pdu: Hexstr) -> ResTuple: """Implementation specific method for sending the PDU.""" diff --git a/pySim/transport/calypso.py b/pySim/transport/calypso.py index 34fc646..b827d88 100644 --- a/pySim/transport/calypso.py +++ b/pySim/transport/calypso.py @@ -90,6 +90,9 @@ self.sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) self.sock.connect(sock_path) +# Remember socket path +self._sock_path = sock_path + def __del__(self): self.sock.close() @@ -156,3 +159,6 @@ sw = rsp[-2:] return b2h(data), b2h(sw) + +def __str__(self): +return "osmocon:%s" % (self._sock_path) diff --git a/pySim/transport/modem_atcmd.py b/pySim/transport/modem_atcmd.py index e99762d..58d6f9d 100644 --- a/pySim/transport/modem_atcmd.py +++ b/pySim/transport/modem_atcmd.py @@ -169,3 +169,6 @@ sw = rsp_pdu[-4:].decode().lower() log.debug('Command response: %s, %s', data, sw) return data, sw + +def __str__(self): +return "modem:%s" % self._device diff --git a/pySim/transport/pcsc.py b/pySim/transport/pcsc.py index a01917f..41c4c19 100644 --- a/pySim/transport/pcsc.py +++ b/pySim/transport/pcsc.py @@ -39,6 +39,7 @@ raise ReaderError('No reader found for number %d' % reader_n
[S] Change in pysim[master]: transport: print device path/number on initialization failure
Attention is currently required from: fixeria, laforge. dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34693?usp=email ) Change subject: transport: print device path/number on initialization failure .. Patch Set 6: (1 comment) File pySim/transport/__init__.py: https://gerrit.osmocom.org/c/pysim/+/34693/comment/cf2808bc_d753c987 PS4, Line 330: devinfo = "serial:%s" % opts.device > I don't think that common code should contain clauses for each specific > backend. […] Ack -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34693?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I3f5387508ccc2aa349adc7aec3d04d8fc977690b Gerrit-Change-Number: 34693 Gerrit-PatchSet: 6 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge Gerrit-Reviewer: osmith Gerrit-CC: fixeria Gerrit-Attention: laforge Gerrit-Attention: fixeria Gerrit-Comment-Date: Tue, 10 Oct 2023 10:06:13 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: laforge Gerrit-MessageType: comment
[S] Change in pysim[master]: transport: add return type annotation to method __str__
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/34696?usp=email ) Change subject: transport: add return type annotation to method __str__ .. transport: add return type annotation to method __str__ The abstract class LinkBase has no return type annotation on its __str__ method. Related: OS#6210 Change-Id: I26d3d2714708dbe957704b60d17ba2afa325b2c4 --- M pySim/transport/__init__.py M pySim/transport/calypso.py M pySim/transport/modem_atcmd.py M pySim/transport/pcsc.py M pySim/transport/serial.py 5 files changed, 18 insertions(+), 5 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/96/34696/1 diff --git a/pySim/transport/__init__.py b/pySim/transport/__init__.py index 1dd8d18..0b50a4f 100644 --- a/pySim/transport/__init__.py +++ b/pySim/transport/__init__.py @@ -68,7 +68,7 @@ self.proactive_handler = proactive_handler @abc.abstractmethod -def __str__(self): +def __str__(self) -> str: """Implementation specific method for printing an information to identify the device.""" @abc.abstractmethod diff --git a/pySim/transport/calypso.py b/pySim/transport/calypso.py index b827d88..d7d9649 100644 --- a/pySim/transport/calypso.py +++ b/pySim/transport/calypso.py @@ -160,5 +160,5 @@ return b2h(data), b2h(sw) -def __str__(self): +def __str__(self) -> str: return "osmocon:%s" % (self._sock_path) diff --git a/pySim/transport/modem_atcmd.py b/pySim/transport/modem_atcmd.py index 58d6f9d..5e5a3dd 100644 --- a/pySim/transport/modem_atcmd.py +++ b/pySim/transport/modem_atcmd.py @@ -170,5 +170,5 @@ log.debug('Command response: %s, %s', data, sw) return data, sw -def __str__(self): +def __str__(self) -> str: return "modem:%s" % self._device diff --git a/pySim/transport/pcsc.py b/pySim/transport/pcsc.py index 41c4c19..c7b5878 100644 --- a/pySim/transport/pcsc.py +++ b/pySim/transport/pcsc.py @@ -93,5 +93,5 @@ # Return value return i2h(data), i2h(sw) -def __str__(self): +def __str__(self) -> str: return "PCSC:%u[%s]" % (self._reader_number, self._reader) diff --git a/pySim/transport/serial.py b/pySim/transport/serial.py index f4b1621..e5f7bdb 100644 --- a/pySim/transport/serial.py +++ b/pySim/transport/serial.py @@ -237,5 +237,5 @@ # Return value return b2h(data), b2h(sw) -def __str__(self): +def __str__(self) -> str: return "serial:%s" % (self._sl.name) -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34696?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I26d3d2714708dbe957704b60d17ba2afa325b2c4 Gerrit-Change-Number: 34696 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-MessageType: newchange
[M] Change in pysim[master]: transport: do not catch exceptions in init_reader
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/34697?usp=email ) Change subject: transport: do not catch exceptions in init_reader .. transport: do not catch exceptions in init_reader We currently catch any exceptions that may occur when the card reader is initialized. Then we print the exception string or the exception type when no string is available. However, a failure during the reader initialization is usually a severe problem, so a traceback would provde a lot of helpful information to debug the issue. So lets not catch any exceptions at this level so that we get the full backtrace. Related: OS#6210 Change-Id: I4c4807576fe63cf71a7d33b243a3f8fea0b7ff23 --- M pySim/transport/__init__.py 1 file changed, 36 insertions(+), 27 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/97/34697/1 diff --git a/pySim/transport/__init__.py b/pySim/transport/__init__.py index 0b50a4f..3e62668 100644 --- a/pySim/transport/__init__.py +++ b/pySim/transport/__init__.py @@ -297,30 +297,22 @@ Init card reader driver """ sl = None # type : :Optional[LinkBase] -try: -if opts.pcsc_dev is not None: -print("Using PC/SC reader interface") -from pySim.transport.pcsc import PcscSimLink -sl = PcscSimLink(opts.pcsc_dev, **kwargs) -elif opts.osmocon_sock is not None: -print("Using Calypso-based (OsmocomBB) reader interface") -from pySim.transport.calypso import CalypsoSimLink -sl = CalypsoSimLink(sock_path=opts.osmocon_sock, **kwargs) -elif opts.modem_dev is not None: -print("Using modem for Generic SIM Access (3GPP TS 27.007)") -from pySim.transport.modem_atcmd import ModemATCommandLink -sl = ModemATCommandLink( -device=opts.modem_dev, baudrate=opts.modem_baud, **kwargs) -else: # Serial reader is default -print("Using serial reader interface") -from pySim.transport.serial import SerialSimLink -sl = SerialSimLink(device=opts.device, - baudrate=opts.baudrate, **kwargs) -return sl -except Exception as e: -if str(e): -print("Card reader initialization failed with exception:\n" + str(e)) -else: -print( -"Card reader initialization failed with an exception of type:\n" + str(type(e))) -return None +if opts.pcsc_dev is not None: +print("Using PC/SC reader interface") +from pySim.transport.pcsc import PcscSimLink +sl = PcscSimLink(opts.pcsc_dev, **kwargs) +elif opts.osmocon_sock is not None: +print("Using Calypso-based (OsmocomBB) reader interface") +from pySim.transport.calypso import CalypsoSimLink +sl = CalypsoSimLink(sock_path=opts.osmocon_sock, **kwargs) +elif opts.modem_dev is not None: +print("Using modem for Generic SIM Access (3GPP TS 27.007)") +from pySim.transport.modem_atcmd import ModemATCommandLink +sl = ModemATCommandLink( + device=opts.modem_dev, baudrate=opts.modem_baud, **kwargs) +else: # Serial reader is default +print("Using serial reader interface") +from pySim.transport.serial import SerialSimLink +sl = SerialSimLink(device=opts.device, + baudrate=opts.baudrate, **kwargs) +return sl -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34697?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I4c4807576fe63cf71a7d33b243a3f8fea0b7ff23 Gerrit-Change-Number: 34697 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-MessageType: newchange
[S] Change in pysim[master]: transport: show full traceback on failed reader init
Attention is currently required from: fixeria, laforge, osmith. dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34687?usp=email ) Change subject: transport: show full traceback on failed reader init .. Patch Set 6: (1 comment) File pySim/transport/__init__.py: https://gerrit.osmocom.org/c/pysim/+/34687/comment/fea4e2d2_348abe47 PS4, Line 318: except Exception as e > I am wondering if we really need to catch exceptions here. […] I also think that not catching the exception at all would be the better solution. The caller still has the option to handle the exception and print it nicely if he wants to. I submitted the new approach here: I4c4807576fe63cf71a7d33b243a3f8fea0b7ff23 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34687?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I46e913a516dbc13f7610512484f515ab25d3fbae Gerrit-Change-Number: 34687 Gerrit-PatchSet: 6 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge Gerrit-Reviewer: osmith Gerrit-CC: fixeria Gerrit-Attention: osmith Gerrit-Attention: laforge Gerrit-Attention: fixeria Gerrit-Comment-Date: Tue, 10 Oct 2023 10:38:43 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: fixeria Gerrit-MessageType: comment
[M] Change in pysim[master]: transport: do not catch exceptions in init_reader
Attention is currently required from: fixeria, laforge. dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34697?usp=email ) Change subject: transport: do not catch exceptions in init_reader .. Patch Set 1: (1 comment) Patchset: PS1: This patch now removes the exception handling. When this patch is merged we can take on the layer violation problem that @lafo...@gnumonks.org mentioned. -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34697?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I4c4807576fe63cf71a7d33b243a3f8fea0b7ff23 Gerrit-Change-Number: 34697 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: laforge Gerrit-Attention: laforge Gerrit-Attention: fixeria Gerrit-Comment-Date: Tue, 10 Oct 2023 10:40:06 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment
[S] Change in pysim[master]: transport: add return type annotation to method __str__
Attention is currently required from: dexter, laforge. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34696?usp=email ) Change subject: transport: add return type annotation to method __str__ .. Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34696?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I26d3d2714708dbe957704b60d17ba2afa325b2c4 Gerrit-Change-Number: 34696 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: laforge Gerrit-Attention: laforge Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 11:01:16 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[M] Change in pysim[master]: transport: do not catch exceptions in init_reader
Attention is currently required from: dexter, laforge. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/pysim/+/34697?usp=email ) Change subject: transport: do not catch exceptions in init_reader .. Patch Set 1: Code-Review-1 (3 comments) Patchset: PS1: You also need to revisit all the callers of this function and remove checking the returned value against `None`. File pySim/transport/__init__.py: https://gerrit.osmocom.org/c/pysim/+/34697/comment/820824d2_7fd9f482 PS1, Line 295: Optional no more `Optional` https://gerrit.osmocom.org/c/pysim/+/34697/comment/37749619_b883fcb3 PS1, Line 299: sl = None # type : :Optional[LinkBase] not needed anymore -- To view, visit https://gerrit.osmocom.org/c/pysim/+/34697?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I4c4807576fe63cf71a7d33b243a3f8fea0b7ff23 Gerrit-Change-Number: 34697 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: laforge Gerrit-Attention: laforge Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 11:02:57 + Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in osmo-pcu[master]: pcu_l1_if: signal BTS model via PCUIF
Attention is currently required from: fixeria, pespin. dexter has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/34647?usp=email ) Change subject: pcu_l1_if: signal BTS model via PCUIF .. Patch Set 1: (2 comments) Patchset: PS1: > This is something that needs to be done carefully: you're adding a new field, > but the PCUIF version […] I have had a look at this. I think CHECK_IF_MSG_SIZE may tolerate this. It checks if the length of the date it received is smaller than the indication. In case more data is received, the check won't be set off. This would mean newer osmo-bts/osmo-bsc would definetly work with older osmo-pcu versions, but the other way around there may be problems (I didn't count out the bytes) So yes, I also think this means that we must increment the PCUIF version again. But before we do this we should drop the backward compatibility clutter in osmo-pcu and the TTCN3 tests to have a clean path. File include/osmocom/pcu/pcuif_proto.h: https://gerrit.osmocom.org/c/osmo-pcu/+/34647/comment/3233b29d_d9bd2d85 PS1, Line 70: #define PCU_IF_BTS_MODEL_UNSPEC 0x00 > can we please have an enum? I have opted against an enum since the other fields also do not use enums (see the defines above). I think an enum will look a bit out of place there. What do you think? Shall I still migrate this to an enum? -- To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/34647?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-pcu Gerrit-Branch: master Gerrit-Change-Id: I48eb75f65ab54fdec41ef913e24c1f18cd4a4047 Gerrit-Change-Number: 34647 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: pespin Gerrit-Attention: pespin Gerrit-Attention: fixeria Gerrit-Comment-Date: Tue, 10 Oct 2023 11:17:02 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: fixeria Comment-In-Reply-To: pespin Gerrit-MessageType: comment
[S] Change in osmo-pcu[master]: pcu_l1_if: signal BTS model via PCUIF
Attention is currently required from: dexter, fixeria. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/34647?usp=email ) Change subject: pcu_l1_if: signal BTS model via PCUIF .. Patch Set 1: (1 comment) File include/osmocom/pcu/pcuif_proto.h: https://gerrit.osmocom.org/c/osmo-pcu/+/34647/comment/558bfaf8_4e38ec73 PS1, Line 70: #define PCU_IF_BTS_MODEL_UNSPEC 0x00 > I have opted against an enum since the other fields also do not use enums > (see the defines above). […] I definetly want an enum here. The field in the struct can remain a uint of known size. -- To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/34647?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-pcu Gerrit-Branch: master Gerrit-Change-Id: I48eb75f65ab54fdec41ef913e24c1f18cd4a4047 Gerrit-Change-Number: 34647 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: pespin Gerrit-Attention: fixeria Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 11:36:27 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: pespin Comment-In-Reply-To: dexter Gerrit-MessageType: comment
[S] Change in docker-playground[master]: ttcn3-pcu-test: use PFUIF v10 for 2023q1
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email ) Change subject: ttcn3-pcu-test: use PFUIF v10 for 2023q1 .. ttcn3-pcu-test: use PFUIF v10 for 2023q1 Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 --- M jenkins-common.sh M ttcn3-pcu-test/PCU_Tests.cfg M ttcn3-pcu-test/jenkins-sns.sh M ttcn3-pcu-test/jenkins.sh M ttcn3-pcu-test/sns/PCU_Tests.cfg 5 files changed, 35 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/98/34698/1 diff --git a/jenkins-common.sh b/jenkins-common.sh index 72eaec2..90ad8cc 100644 --- a/jenkins-common.sh +++ b/jenkins-common.sh @@ -502,6 +502,15 @@ esac } +# Check if IMAGE_SUFFIX starts with "2023q1" (e.g. "2023q1-centos8") +image_suffix_is_2023q1() { + case "$IMAGE_SUFFIX" in + 2023q1*) return 0 ;; + *) return 1 ;; + esac +} + + # Write the Osmocom repository to the TTCN3 config file, so the tests may take # different code paths (OS#5327) # $1: path to TTCN3 config file (e.g. BSC_Tests.cfg) diff --git a/ttcn3-pcu-test/PCU_Tests.cfg b/ttcn3-pcu-test/PCU_Tests.cfg index 40b8e2c..b3f3b8f 100644 --- a/ttcn3-pcu-test/PCU_Tests.cfg +++ b/ttcn3-pcu-test/PCU_Tests.cfg @@ -34,7 +34,8 @@ } } } -Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoPCU"; +Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoPCU" +PCUIF_Types.mp_pcuif_version := 11 [MAIN_CONTROLLER] diff --git a/ttcn3-pcu-test/jenkins-sns.sh b/ttcn3-pcu-test/jenkins-sns.sh index 393e828..50027d3 100755 --- a/ttcn3-pcu-test/jenkins-sns.sh +++ b/ttcn3-pcu-test/jenkins-sns.sh @@ -9,10 +9,17 @@ set_clean_up_trap set -e +set_pcuif_version() { + if image_suffix_is_2023q1; then + sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 10/g' $1 + fi +} + mkdir $VOL_BASE_DIR/pcu-tester mkdir $VOL_BASE_DIR/pcu-tester/unix cp sns/PCU_Tests.cfg $VOL_BASE_DIR/pcu-tester/ write_mp_osmo_repo "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" +set_pcuif_version "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" mkdir $VOL_BASE_DIR/pcu mkdir $VOL_BASE_DIR/pcu/unix diff --git a/ttcn3-pcu-test/jenkins.sh b/ttcn3-pcu-test/jenkins.sh index ee53bb7..0a1eb67 100755 --- a/ttcn3-pcu-test/jenkins.sh +++ b/ttcn3-pcu-test/jenkins.sh @@ -9,10 +9,17 @@ set_clean_up_trap set -e +set_pcuif_version() { + if image_suffix_is_2023q1; then + sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 10/g' $1 + fi +} + mkdir $VOL_BASE_DIR/pcu-tester mkdir $VOL_BASE_DIR/pcu-tester/unix cp PCU_Tests.cfg $VOL_BASE_DIR/pcu-tester/ write_mp_osmo_repo "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" +set_pcuif_version "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" mkdir $VOL_BASE_DIR/pcu mkdir $VOL_BASE_DIR/pcu/unix diff --git a/ttcn3-pcu-test/sns/PCU_Tests.cfg b/ttcn3-pcu-test/sns/PCU_Tests.cfg index 1036f5a..d62f52d 100644 --- a/ttcn3-pcu-test/sns/PCU_Tests.cfg +++ b/ttcn3-pcu-test/sns/PCU_Tests.cfg @@ -59,6 +59,7 @@ } } } +PCUIF_Types.mp_pcuif_version := 11 [MAIN_CONTROLLER] -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 Gerrit-Change-Number: 34698 Gerrit-PatchSet: 1 Gerrit-Owner: osmith Gerrit-MessageType: newchange
[S] Change in docker-playground[master]: ttcn3-pcu-test: use PFUIF v10 for 2023q1
Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email to look at the new patch set (#2). The following approvals got outdated and were removed: Verified+1 by Jenkins Builder Change subject: ttcn3-pcu-test: use PFUIF v10 for 2023q1 .. ttcn3-pcu-test: use PFUIF v10 for 2023q1 Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 --- M jenkins-common.sh M ttcn3-pcu-test/PCU_Tests.cfg M ttcn3-pcu-test/jenkins-sns.sh M ttcn3-pcu-test/jenkins.sh M ttcn3-pcu-test/sns/PCU_Tests.cfg 5 files changed, 34 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/98/34698/2 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 Gerrit-Change-Number: 34698 Gerrit-PatchSet: 2 Gerrit-Owner: osmith Gerrit-Reviewer: Jenkins Builder Gerrit-MessageType: newpatchset
[S] Change in osmo-dev[master]: ttcn3.sh: use ccache
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-dev/+/34701?usp=email ) Change subject: ttcn3.sh: use ccache .. ttcn3.sh: use ccache Use ccache for building Osmocom programs and TTCN-3 testsuites. Change-Id: I800062d0379295a6905851db29e820ff16217653 --- M .gitignore M ttcn3/scripts/docker_configure_make.sh M ttcn3/ttcn3.opts M ttcn3/ttcn3.sh 4 files changed, 20 insertions(+), 2 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-dev refs/changes/01/34701/1 diff --git a/.gitignore b/.gitignore index 6aa1dd0..2e88651 100644 --- a/.gitignore +++ b/.gitignore @@ -15,6 +15,7 @@ !net/README !net/fill_config.py ttcn3/3G+2G_ttcn3.deps +ttcn3/ccache/ ttcn3/out/ ttcn3/make/ ttcn3/.run.sh diff --git a/ttcn3/scripts/docker_configure_make.sh b/ttcn3/scripts/docker_configure_make.sh index 25cedb4..56fee71 100755 --- a/ttcn3/scripts/docker_configure_make.sh +++ b/ttcn3/scripts/docker_configure_make.sh @@ -7,12 +7,13 @@ DIR_OSMODEV="$(readlink -f "$(dirname $0)/../..")" DIR_MAKE="$DIR_OSMODEV/ttcn3/make" DIR_USR_LOCAL="$DIR_OSMODEV/ttcn3/usr_local" +DIR_CCACHE="$DIR_OSMODEV/ttcn3/ccache/osmocom-programs" RUN_SCRIPT="$DIR_OSMODEV/ttcn3/.run.sh" DOCKER_IMG="$1" UID="$(id -u)" shift -mkdir -p "$DIR_MAKE" +mkdir -p "$DIR_MAKE" "$DIR_CCACHE" # Script running as user inside docker echo "#!/bin/sh -ex" > "$RUN_SCRIPT" @@ -29,6 +30,7 @@ -v "$DIR_OSMODEV:$DIR_OSMODEV" \ -v "$DIR_USR_LOCAL:/usr/local" \ -v "$RUN_SCRIPT:/tmp/run.sh:ro" \ + -v "$DIR_CCACHE:/home/build/.ccache" \ "$DOCKER_IMG" \ sh -ex -c " if ! id -u $UID 2>/dev/null; then diff --git a/ttcn3/ttcn3.opts b/ttcn3/ttcn3.opts index 8acec2d..bf2f472 100644 --- a/ttcn3/ttcn3.opts +++ b/ttcn3/ttcn3.opts @@ -1 +1,2 @@ osmo-bts --enable-trx +ALL CC="/usr/lib/ccache/gcc" CXX="/usr/lib/ccache/g++" diff --git a/ttcn3/ttcn3.sh b/ttcn3/ttcn3.sh index 68dec64..5c5f711 100755 --- a/ttcn3/ttcn3.sh +++ b/ttcn3/ttcn3.sh @@ -338,16 +338,19 @@ local testsuite_image="$(get_testsuite_image)" echo "testsuite_image: $testsuite_image" + mkdir -p "$"$DIR_OSMODEV/ttcn3/ccache/ttcn3 + # -t: add a tty, so we get color output from the compiler docker run \ --rm \ -t \ -v "$hacks:/osmo-ttcn3-hacks" \ + -v "$DIR_OSMODEV/ttcn3/ccache/ttcn3:/root/.ccache" \ "$testsuite_image" \ sh -exc " cd /osmo-ttcn3-hacks/$(basename "$(get_testsuite_dir)"); ./gen_links.sh; - ./regen_makefile.sh; + USE_CCACHE=1 ./regen_makefile.sh; make compile; make -j"$JOBS" " -- To view, visit https://gerrit.osmocom.org/c/osmo-dev/+/34701?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-dev Gerrit-Branch: master Gerrit-Change-Id: I800062d0379295a6905851db29e820ff16217653 Gerrit-Change-Number: 34701 Gerrit-PatchSet: 1 Gerrit-Owner: osmith Gerrit-MessageType: newchange
[S] Change in osmo-dev[master]: ttcn3.sh: add clean argument
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-dev/+/34700?usp=email ) Change subject: ttcn3.sh: add clean argument .. ttcn3.sh: add clean argument Change-Id: If779b87c02d01b877e44118db34bdf2c83dbf619 --- M ttcn3/ttcn3.sh 1 file changed, 27 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-dev refs/changes/00/34700/1 diff --git a/ttcn3/ttcn3.sh b/ttcn3/ttcn3.sh index 3563062..68dec64 100755 --- a/ttcn3/ttcn3.sh +++ b/ttcn3/ttcn3.sh @@ -14,12 +14,29 @@ DOCKER_IMG_BUILD="debian-bookworm-build" DOCKER_IMG_TITAN="debian-bookworm-titan" +clean() { + if [ "$1" != "clean" ]; then + return + fi + if [ "$#" != 1 ]; then + parse_args -h + fi + + set -x + rm -rf \ + "$DIR_MAKE" \ + "$DIR_OUTPUT" \ + "$DIR_USR_LOCAL" + exit 0 +} + parse_args() { while getopts 'h' OPTION; do case "$OPTION" in h|*) local name="$(basename $0)" echo "usage: $name [-h] PROJECT" + echo " or: $name clean" echo "arguments:" echo " -h show help" echo " PROJECT the testsuite project to run" @@ -380,6 +397,7 @@ echo "---" } +clean "$@" parse_args "$@" check_usage check_ttcn3_install -- To view, visit https://gerrit.osmocom.org/c/osmo-dev/+/34700?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-dev Gerrit-Branch: master Gerrit-Change-Id: If779b87c02d01b877e44118db34bdf2c83dbf619 Gerrit-Change-Number: 34700 Gerrit-PatchSet: 1 Gerrit-Owner: osmith Gerrit-MessageType: newchange
[M] Change in osmo-dev[master]: ttcn3.sh: add getopts
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-dev/+/34699?usp=email ) Change subject: ttcn3.sh: add getopts .. ttcn3.sh: add getopts Add getopts parsing. The idea was to add support for setting a different IMAGE_SUFFIX argument, but later on it became clear it is not worth implementing here. Add the getopts logic anyway because it can be used to add other arguments in the future. Change-Id: If55a982d92b2a24a175ab7f3a8f048f054033dc2 --- M ttcn3/ttcn3.sh 1 file changed, 45 insertions(+), 9 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-dev refs/changes/99/34699/1 diff --git a/ttcn3/ttcn3.sh b/ttcn3/ttcn3.sh index 74e87cc..3563062 100755 --- a/ttcn3/ttcn3.sh +++ b/ttcn3/ttcn3.sh @@ -1,6 +1,6 @@ #!/bin/sh -e -PROJECT="$1" -PROJECT_UPPER="$(echo "$PROJECT" | tr '[:lower:]' '[:upper:]')" +PROJECT="" +PROJECT_UPPER="" DIR_OSMODEV="$(readlink -f "$(dirname $0)/..")" DIR_MAKE="${DIR_MAKE:-${DIR_OSMODEV}/ttcn3/make}" DIR_OUTPUT="${DIR_OUTPUT:-${DIR_OSMODEV}/ttcn3/out}" @@ -14,15 +14,36 @@ DOCKER_IMG_BUILD="debian-bookworm-build" DOCKER_IMG_TITAN="debian-bookworm-titan" +parse_args() { + while getopts 'h' OPTION; do + case "$OPTION" in + h|*) + local name="$(basename $0)" + echo "usage: $name [-h] PROJECT" + echo "arguments:" + echo " -h show help" + echo " PROJECT the testsuite project to run" + echo "examples:" + echo " $name bsc" + echo " $name bsc-sccplite" + echo " $name hlr" + exit 1 + ;; + esac + done + shift "$(($OPTIND - 1))" + + if [ "$#" != "1" ]; then + parse_args -h + fi + + PROJECT="$1" + PROJECT_UPPER="$(echo "$PROJECT" | tr '[:lower:]' '[:upper:]')" +} + check_usage() { - local name="$(basename $0)" if [ -z "$PROJECT" ]; then - echo "usage: $name PROJECT" - echo "examples:" - echo " * $name bsc" - echo " * $name bsc-sccplite" - echo " * $name hlr" - exit 1 + parse_args -h fi } @@ -359,6 +380,7 @@ echo "---" } +parse_args "$@" check_usage check_ttcn3_install setup_dir_make -- To view, visit https://gerrit.osmocom.org/c/osmo-dev/+/34699?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-dev Gerrit-Branch: master Gerrit-Change-Id: If55a982d92b2a24a175ab7f3a8f048f054033dc2 Gerrit-Change-Number: 34699 Gerrit-PatchSet: 1 Gerrit-Owner: osmith Gerrit-MessageType: newchange
[S] Change in osmo-dev[master]: ttcn3.sh: use nproc for JOBS
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-dev/+/34702?usp=email ) Change subject: ttcn3.sh: use nproc for JOBS .. ttcn3.sh: use nproc for JOBS Change-Id: I1971e7758e67a4260ae1398d510cb719db45d101 --- M ttcn3/ttcn3.sh 1 file changed, 10 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/osmo-dev refs/changes/02/34702/1 diff --git a/ttcn3/ttcn3.sh b/ttcn3/ttcn3.sh index 5c5f711..54b4328 100755 --- a/ttcn3/ttcn3.sh +++ b/ttcn3/ttcn3.sh @@ -5,7 +5,7 @@ DIR_MAKE="${DIR_MAKE:-${DIR_OSMODEV}/ttcn3/make}" DIR_OUTPUT="${DIR_OUTPUT:-${DIR_OSMODEV}/ttcn3/out}" DIR_USR_LOCAL="$DIR_OSMODEV/ttcn3/usr_local" -JOBS="${JOBS:-9}" +JOBS="$(nproc)" # Osmocom libraries and programs relevant for the current testsuite will be # built in this container. It must have all build dependencies available and -- To view, visit https://gerrit.osmocom.org/c/osmo-dev/+/34702?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-dev Gerrit-Branch: master Gerrit-Change-Id: I1971e7758e67a4260ae1398d510cb719db45d101 Gerrit-Change-Number: 34702 Gerrit-PatchSet: 1 Gerrit-Owner: osmith Gerrit-MessageType: newchange
[S] Change in docker-playground[master]: debian-bookworm-titan: add ccache
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/34703?usp=email ) Change subject: debian-bookworm-titan: add ccache .. debian-bookworm-titan: add ccache Add ccache, so it can be used when rebuilding the testsuite from source from a development branch. Ccache is not used by default. Related: osmo-dev I800062d0379295a6905851db29e820ff16217653 Change-Id: I94d22b8da9f897974c5913b2a8138c653c215446 --- M debian-bookworm-titan/Dockerfile 1 file changed, 14 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/03/34703/1 diff --git a/debian-bookworm-titan/Dockerfile b/debian-bookworm-titan/Dockerfile index 99a79c8..b0cfaba 100644 --- a/debian-bookworm-titan/Dockerfile +++ b/debian-bookworm-titan/Dockerfile @@ -19,6 +19,7 @@ apt-get install -y --no-install-recommends \ build-essential \ ca-certificates \ + ccache \ git \ iputils-ping \ netcat-openbsd \ -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34703?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I94d22b8da9f897974c5913b2a8138c653c215446 Gerrit-Change-Number: 34703 Gerrit-PatchSet: 1 Gerrit-Owner: osmith Gerrit-MessageType: newchange
[S] Change in docker-playground[master]: ttcn3-pcu-test: use PFUIF v10 for 2023q1
Attention is currently required from: osmith. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email ) Change subject: ttcn3-pcu-test: use PFUIF v10 for 2023q1 .. Patch Set 2: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 Gerrit-Change-Number: 34698 Gerrit-PatchSet: 2 Gerrit-Owner: osmith Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: pespin Gerrit-Attention: osmith Gerrit-Comment-Date: Tue, 10 Oct 2023 12:18:46 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in docker-playground[master]: ttcn3-pcu-test: use PFUIF v10 for 2023q1
osmith has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email ) Change subject: ttcn3-pcu-test: use PFUIF v10 for 2023q1 .. ttcn3-pcu-test: use PFUIF v10 for 2023q1 Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 --- M jenkins-common.sh M ttcn3-pcu-test/PCU_Tests.cfg M ttcn3-pcu-test/jenkins-sns.sh M ttcn3-pcu-test/jenkins.sh M ttcn3-pcu-test/sns/PCU_Tests.cfg 5 files changed, 34 insertions(+), 1 deletion(-) Approvals: Jenkins Builder: Verified pespin: Looks good to me, approved diff --git a/jenkins-common.sh b/jenkins-common.sh index e72a28d..c9299df 100644 --- a/jenkins-common.sh +++ b/jenkins-common.sh @@ -503,6 +503,14 @@ esac } +# Check if IMAGE_SUFFIX starts with "2023q1" (e.g. "2023q1-centos8") +image_suffix_is_2023q1() { + case "$IMAGE_SUFFIX" in + 2023q1*) return 0 ;; + *) return 1 ;; + esac +} + # Write the Osmocom repository to the TTCN3 config file, so the tests may take # different code paths (OS#5327) # $1: path to TTCN3 config file (e.g. BSC_Tests.cfg) diff --git a/ttcn3-pcu-test/PCU_Tests.cfg b/ttcn3-pcu-test/PCU_Tests.cfg index 40b8e2c..b3f3b8f 100644 --- a/ttcn3-pcu-test/PCU_Tests.cfg +++ b/ttcn3-pcu-test/PCU_Tests.cfg @@ -34,7 +34,8 @@ } } } -Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoPCU"; +Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoPCU" +PCUIF_Types.mp_pcuif_version := 11 [MAIN_CONTROLLER] diff --git a/ttcn3-pcu-test/jenkins-sns.sh b/ttcn3-pcu-test/jenkins-sns.sh index 393e828..50027d3 100755 --- a/ttcn3-pcu-test/jenkins-sns.sh +++ b/ttcn3-pcu-test/jenkins-sns.sh @@ -9,10 +9,17 @@ set_clean_up_trap set -e +set_pcuif_version() { + if image_suffix_is_2023q1; then + sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 10/g' $1 + fi +} + mkdir $VOL_BASE_DIR/pcu-tester mkdir $VOL_BASE_DIR/pcu-tester/unix cp sns/PCU_Tests.cfg $VOL_BASE_DIR/pcu-tester/ write_mp_osmo_repo "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" +set_pcuif_version "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" mkdir $VOL_BASE_DIR/pcu mkdir $VOL_BASE_DIR/pcu/unix diff --git a/ttcn3-pcu-test/jenkins.sh b/ttcn3-pcu-test/jenkins.sh index ee53bb7..0a1eb67 100755 --- a/ttcn3-pcu-test/jenkins.sh +++ b/ttcn3-pcu-test/jenkins.sh @@ -9,10 +9,17 @@ set_clean_up_trap set -e +set_pcuif_version() { + if image_suffix_is_2023q1; then + sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 10/g' $1 + fi +} + mkdir $VOL_BASE_DIR/pcu-tester mkdir $VOL_BASE_DIR/pcu-tester/unix cp PCU_Tests.cfg $VOL_BASE_DIR/pcu-tester/ write_mp_osmo_repo "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" +set_pcuif_version "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" mkdir $VOL_BASE_DIR/pcu mkdir $VOL_BASE_DIR/pcu/unix diff --git a/ttcn3-pcu-test/sns/PCU_Tests.cfg b/ttcn3-pcu-test/sns/PCU_Tests.cfg index 1036f5a..d62f52d 100644 --- a/ttcn3-pcu-test/sns/PCU_Tests.cfg +++ b/ttcn3-pcu-test/sns/PCU_Tests.cfg @@ -59,6 +59,7 @@ } } } +PCUIF_Types.mp_pcuif_version := 11 [MAIN_CONTROLLER] -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34698?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 Gerrit-Change-Number: 34698 Gerrit-PatchSet: 3 Gerrit-Owner: osmith Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: osmith Gerrit-Reviewer: pespin Gerrit-MessageType: merged
[S] Change in osmocom-bb[master]: Fix selection of correct ARFCN at arfcn_from_freq_index()
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34657?usp=email ) Change subject: Fix selection of correct ARFCN at arfcn_from_freq_index() .. Fix selection of correct ARFCN at arfcn_from_freq_index() The selection of ARFCN is described in TS 44.018 §10.5.2.20. The frequencies found in SI5 and SI5bis are counted first, in the following order: ARFCN 1..1023,0. The frequencies found in SI5ter are counted afterwards, in the following order: ARFCN 1..1023,0. Related: OS#5782 Change-Id: I090d84a5550d89743e8f5a886f400df6483f50d7 --- M src/host/layer23/src/common/sysinfo.c 1 file changed, 28 insertions(+), 15 deletions(-) Approvals: Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve fixeria: Looks good to me, approved diff --git a/src/host/layer23/src/common/sysinfo.c b/src/host/layer23/src/common/sysinfo.c index 356f8eb..f541c85 100644 --- a/src/host/layer23/src/common/sysinfo.c +++ b/src/host/layer23/src/common/sysinfo.c @@ -1078,30 +1078,25 @@ return 0; } -static int16_t arfcn_from_freq_index(struct gsm48_sysinfo *s, uint16_t index) +/* Get ARFCN from BCCH allocation found in SI5/SI5bis an SI5ter. See TS 44.018 §10.5.2.20. */ +int16_t arfcn_from_freq_index(const struct gsm48_sysinfo *s, uint16_t index) { uint16_t arfcn, i = 0; - /* First, search for the P-GSM ARFCN. */ - for (arfcn = 1; arfcn < 124; arfcn++) { - if (!(s->freq[arfcn].mask & FREQ_TYPE_REP)) + /* Search for ARFCN found in SI5 or SI5bis. (first sub list) */ + for (arfcn = 1; arfcn <= 1024; arfcn++) { + if (!(s->freq[arfcn & 1023].mask & (FREQ_TYPE_REP_5 | FREQ_TYPE_REP_5bis))) continue; if (index == i++) - return arfcn; + return arfcn & 1023; } - /* Second, search for ARFCN 0. */ - if ((s->freq[arfcn].mask & FREQ_TYPE_REP)) { - if (index == i++) - return arfcn; - } - - /* Third, search for all other ARFCN. */ - for (arfcn = 125; arfcn < 1024; arfcn++) { - if (!(s->freq[arfcn].mask & FREQ_TYPE_REP)) + /* Search for ARFCN found in SI5ter. (second sub list) */ + for (arfcn = 1; arfcn <= 1024; arfcn++) { + if (!(s->freq[arfcn & 1023].mask & FREQ_TYPE_REP_5ter)) continue; if (index == i++) - return arfcn; + return arfcn & 1023; } /* If not found, return EOF (-1) as idicator. */ -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34657?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I090d84a5550d89743e8f5a886f400df6483f50d7 Gerrit-Change-Number: 34657 Gerrit-PatchSet: 1 Gerrit-Owner: jolly Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: pespin Gerrit-MessageType: merged
[M] Change in osmocom-bb[master]: Fix indices of ARFCNs for measurement report
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34658?usp=email ) Change subject: Fix indices of ARFCNs for measurement report .. Fix indices of ARFCNs for measurement report The order of ARFCNs are described in TS 44.018 §10.5.2.20. The function arfcn_from_freq_index() is re-used to get the ARFCNs in correct order for the report. Change-Id: I0674467eb5a38a341cf65f95a25aa5f7232df069 --- M src/host/layer23/include/osmocom/bb/common/sysinfo.h M src/host/layer23/src/mobile/gsm48_rr.c 2 files changed, 32 insertions(+), 19 deletions(-) Approvals: fixeria: Looks good to me, approved Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve laforge: Looks good to me, approved diff --git a/src/host/layer23/include/osmocom/bb/common/sysinfo.h b/src/host/layer23/include/osmocom/bb/common/sysinfo.h index 89d38ac..9efb248 100644 --- a/src/host/layer23/include/osmocom/bb/common/sysinfo.h +++ b/src/host/layer23/include/osmocom/bb/common/sysinfo.h @@ -219,5 +219,6 @@ int gsm48_decode_mobile_alloc(struct gsm_sysinfo_freq *freq, const uint8_t *ma, uint8_t len, uint16_t *hopping, uint8_t *hopp_len, int si4); +int16_t arfcn_from_freq_index(const struct gsm48_sysinfo *s, uint16_t index); #endif /* _SYSINFO_H */ diff --git a/src/host/layer23/src/mobile/gsm48_rr.c b/src/host/layer23/src/mobile/gsm48_rr.c index 8dca379..3200412 100644 --- a/src/host/layer23/src/mobile/gsm48_rr.c +++ b/src/host/layer23/src/mobile/gsm48_rr.c @@ -2538,32 +2538,30 @@ && s->si5 && (!s->nb_ext_ind_si5 || s->si5bis)) { struct gsm48_rr_meas *rrmeas = &ms->rrlayer.meas; - int n = 0, i, refer_pcs; + int i, refer_pcs; + int16_t arfcn; LOGP(DRR, LOGL_NOTICE, "Complete set of SI5* for BA(%d)\n", s->nb_ba_ind_si5); rrmeas->nc_num = 0; refer_pcs = gsm_refer_pcs(cs->arfcn, s); - /* collect channels from freq list (1..1023,0) */ - for (i = 1; i <= 1024; i++) { - if ((s->freq[i & 1023].mask & FREQ_TYPE_REP)) { - if (n == 32) { - LOGP(DRR, LOGL_NOTICE, "SI5* report " - "exceeds 32 BCCHs\n"); - break; - } - if (refer_pcs && i >= 512 && i <= 810) - rrmeas->nc_arfcn[n] = i | ARFCN_PCS; - else - rrmeas->nc_arfcn[n] = i & 1023; - rrmeas->nc_rxlev_dbm[n] = -128; - LOGP(DRR, LOGL_NOTICE, "SI5* report arfcn %s\n", - gsm_print_arfcn(rrmeas->nc_arfcn[n])); - n++; - } + /* Collect channels from freq list in correct order. */ + for (i = 1; i < 32; i++) { + arfcn = arfcn_from_freq_index(s, i); + if (arfcn < 0) + break; + if (refer_pcs && arfcn >= 512 && arfcn <= 810) + rrmeas->nc_arfcn[i] = arfcn | ARFCN_PCS; + else + rrmeas->nc_arfcn[i] = arfcn; + rrmeas->nc_rxlev_dbm[i] = -128; + LOGP(DRR, LOGL_NOTICE, "SI5/SI5bis report arfcn %s (index %d)\n", +gsm_print_arfcn(rrmeas->nc_arfcn[i]), i); } - rrmeas->nc_num = n; + rrmeas->nc_num = i; + if (i == 32 && arfcn_from_freq_index(s, i) >= 0) + LOGP(DRR, LOGL_NOTICE, "SI5/SI5bis/SI5ter define more than 32 channels.\n"); } /* send sysinfo event to other layers */ -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34658?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I0674467eb5a38a341cf65f95a25aa5f7232df069 Gerrit-Change-Number: 34658 Gerrit-PatchSet: 1 Gerrit-Owner: jolly Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: laforge Gerrit-Reviewer: pespin Gerrit-MessageType: merged
[S] Change in osmocom-bb[master]: Correctly detect the follow-on proceed information element
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34704?usp=email ) Change subject: Correctly detect the follow-on proceed information element .. Correctly detect the follow-on proceed information element Even if follow-on proceed is not supported, the warning message about not beeing supported should only show when the follow-on proceed information element is included in the location update accept messages. Change-Id: I2b1aceb8b85bdd9faabe354501f9036f1fc6fe33 --- M src/host/layer23/src/mobile/gsm48_mm.c 1 file changed, 14 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/04/34704/1 diff --git a/src/host/layer23/src/mobile/gsm48_mm.c b/src/host/layer23/src/mobile/gsm48_mm.c index 810dfa7..bcd2c64 100644 --- a/src/host/layer23/src/mobile/gsm48_mm.c +++ b/src/host/layer23/src/mobile/gsm48_mm.c @@ -2710,7 +2710,7 @@ gsm322_plmn_sendmsg(ms, nmsg); /* follow on proceed */ - if (TLVP_PRESENT(&tp, GSM48_IE_MOBILE_ID)) + if (TLVP_PRESENT(&tp, GSM48_IE_FOLLOW_ON_PROC)) LOGP(DMM, LOGL_NOTICE, "follow-on proceed not supported.\n"); /* start RR release timer */ -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34704?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I2b1aceb8b85bdd9faabe354501f9036f1fc6fe33 Gerrit-Change-Number: 34704 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria Gerrit-CC: jolly Gerrit-MessageType: newchange
[S] Change in osmocom-bb[master]: Provide create_conn_and_push_mm_hdr() with correct SAPI
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34705?usp=email ) Change subject: Provide create_conn_and_push_mm_hdr() with correct SAPI .. Provide create_conn_and_push_mm_hdr() with correct SAPI Change-Id: I454178f45aed49417f8cd7744155be66b9ac509f Fixes: 00507bdc "Cleaning gsm48_mm_data_ind()" Related: OS#6216 --- M src/host/layer23/src/mobile/gsm48_mm.c 1 file changed, 20 insertions(+), 8 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/05/34705/1 diff --git a/src/host/layer23/src/mobile/gsm48_mm.c b/src/host/layer23/src/mobile/gsm48_mm.c index bcd2c64..995c5d1 100644 --- a/src/host/layer23/src/mobile/gsm48_mm.c +++ b/src/host/layer23/src/mobile/gsm48_mm.c @@ -4632,10 +4632,9 @@ #define MMDATASLLEN \ (sizeof(mmdatastatelist) / sizeof(struct mmdatastate)) -static int create_conn_and_push_mm_hdr(struct gsm48_mmlayer *mm, struct msgb *msg, int rr_est, int rr_prim) +static int create_conn_and_push_mm_hdr(struct gsm48_mmlayer *mm, struct msgb *msg, int rr_est, int rr_prim, + uint8_t sapi) { - struct gsm48_rr_hdr *rrh = (struct gsm48_rr_hdr *)msg->data; - uint8_t sapi = rrh->sapi; struct gsm48_hdr *gh = msgb_l3(msg); uint8_t pdisc = gh->proto_discr & 0x0f; uint8_t transaction_id; @@ -4694,6 +4693,8 @@ static int gsm48_mm_data_ind(struct osmocom_ms *ms, struct msgb *msg) { struct gsm48_mmlayer *mm = &ms->mmlayer; + struct gsm48_rr_hdr *rrh = (struct gsm48_rr_hdr *)msg->data; + uint8_t sapi = rrh->sapi; struct gsm48_hdr *gh = msgb_l3(msg); uint8_t pdisc = gh->proto_discr & 0x0f; uint8_t msg_type = gh->msg_type & 0xbf; @@ -4729,34 +4730,34 @@ break; /* follow the selection procedure below */ case GSM48_PDISC_CC: - rc = create_conn_and_push_mm_hdr(mm, msg, GSM48_MMCC_EST_IND, GSM48_MMCC_DATA_IND); + rc = create_conn_and_push_mm_hdr(mm, msg, GSM48_MMCC_EST_IND, GSM48_MMCC_DATA_IND, sapi); if (rc == 0) rc = gsm48_rcv_cc(ms, msg); msgb_free(msg); return rc; case GSM48_PDISC_NC_SS: - rc = create_conn_and_push_mm_hdr(mm, msg, GSM48_MMSS_EST_IND, GSM48_MMSS_DATA_IND); + rc = create_conn_and_push_mm_hdr(mm, msg, GSM48_MMSS_EST_IND, GSM48_MMSS_DATA_IND, sapi); if (rc == 0) rc = gsm480_rcv_ss(ms, msg); msgb_free(msg); return rc; case GSM48_PDISC_SMS: - rc = create_conn_and_push_mm_hdr(mm, msg, GSM48_MMSMS_EST_IND, GSM48_MMSMS_DATA_IND); + rc = create_conn_and_push_mm_hdr(mm, msg, GSM48_MMSMS_EST_IND, GSM48_MMSMS_DATA_IND, sapi); if (rc == 0) rc = gsm411_rcv_sms(ms, msg); msgb_free(msg); return rc; case GSM48_PDISC_GROUP_CC: - rc = create_conn_and_push_mm_hdr(mm, msg, -1, GSM48_MMGCC_DATA_IND); + rc = create_conn_and_push_mm_hdr(mm, msg, -1, GSM48_MMGCC_DATA_IND, sapi); if (rc == 0) rc = gsm44068_rcv_gcc_bcc(ms, msg); msgb_free(msg); return rc; case GSM48_PDISC_BCAST_CC: - rc = create_conn_and_push_mm_hdr(mm, msg, -1, GSM48_MMBCC_DATA_IND); + rc = create_conn_and_push_mm_hdr(mm, msg, -1, GSM48_MMBCC_DATA_IND, sapi); if (rc == 0) rc = gsm44068_rcv_gcc_bcc(ms, msg); msgb_free(msg); -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34705?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I454178f45aed49417f8cd7744155be66b9ac509f Gerrit-Change-Number: 34705 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria Gerrit-CC: jolly Gerrit-MessageType: newchange
[S] Change in osmocom-bb[master]: Correctly detect the follow-on proceed information element
Attention is currently required from: osmith, pespin. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34704?usp=email ) Change subject: Correctly detect the follow-on proceed information element .. Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34704?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I2b1aceb8b85bdd9faabe354501f9036f1fc6fe33 Gerrit-Change-Number: 34704 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: osmith Gerrit-Reviewer: pespin Gerrit-CC: jolly Gerrit-Attention: osmith Gerrit-Attention: pespin Gerrit-Comment-Date: Tue, 10 Oct 2023 12:35:31 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in osmocom-bb[master]: Correctly detect the follow-on proceed information element
jolly has submitted this change. ( https://gerrit.osmocom.org/c/osmocom-bb/+/34704?usp=email ) Change subject: Correctly detect the follow-on proceed information element .. Correctly detect the follow-on proceed information element Even if follow-on proceed is not supported, the warning message about not beeing supported should only show when the follow-on proceed information element is included in the location update accept messages. Change-Id: I2b1aceb8b85bdd9faabe354501f9036f1fc6fe33 --- M src/host/layer23/src/mobile/gsm48_mm.c 1 file changed, 14 insertions(+), 1 deletion(-) Approvals: fixeria: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/host/layer23/src/mobile/gsm48_mm.c b/src/host/layer23/src/mobile/gsm48_mm.c index 810dfa7..bcd2c64 100644 --- a/src/host/layer23/src/mobile/gsm48_mm.c +++ b/src/host/layer23/src/mobile/gsm48_mm.c @@ -2710,7 +2710,7 @@ gsm322_plmn_sendmsg(ms, nmsg); /* follow on proceed */ - if (TLVP_PRESENT(&tp, GSM48_IE_MOBILE_ID)) + if (TLVP_PRESENT(&tp, GSM48_IE_FOLLOW_ON_PROC)) LOGP(DMM, LOGL_NOTICE, "follow-on proceed not supported.\n"); /* start RR release timer */ -- To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/34704?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmocom-bb Gerrit-Branch: master Gerrit-Change-Id: I2b1aceb8b85bdd9faabe354501f9036f1fc6fe33 Gerrit-Change-Number: 34704 Gerrit-PatchSet: 1 Gerrit-Owner: fixeria Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: jolly Gerrit-Reviewer: osmith Gerrit-Reviewer: pespin Gerrit-MessageType: merged
[M] Change in osmo-pcu[master]: pcuif_proto: drop support for PCUIF v10
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-pcu/+/34706?usp=email ) Change subject: pcuif_proto: drop support for PCUIF v10 .. pcuif_proto: drop support for PCUIF v10 We now use PCUIF v11 in the TTCN3 tests exclusively and also osmo-bts and osmo-bsc only support PCUIF v11. There is no longer a need to maintain a backward compatibility to PCUIF v10 in osmo-pcu. Related: OS#5927 Change-Id: I68a3f59d5c960ae3a4fbd74f9d4a894295cb9ed8 --- M include/osmocom/pcu/pcuif_proto.h M src/bts.cpp M src/gprs_rlcmac.c M src/pcu_l1_if.cpp 4 files changed, 33 insertions(+), 111 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-pcu refs/changes/06/34706/1 diff --git a/include/osmocom/pcu/pcuif_proto.h b/include/osmocom/pcu/pcuif_proto.h index 9df85d9..cfa422b 100644 --- a/include/osmocom/pcu/pcuif_proto.h +++ b/include/osmocom/pcu/pcuif_proto.h @@ -13,7 +13,7 @@ /* msg_type */ #define PCU_IF_MSG_DATA_REQ0x00/* send data to given channel */ -#define PCU_IF_MSG_DATA_CNF0x01/* confirm (e.g. transmission on PCH) */ +#define PCU_IF_MSG_DATA_CNF0x01/* (deprecated) */ #define PCU_IF_MSG_DATA_IND0x02/* receive data from given channel */ #define PCU_IF_MSG_SUSP_REQ0x03/* BTS forwards GPRS SUSP REQ to PCU */ #define PCU_IF_MSG_APP_INFO_REQ0x04/* BTS asks PCU to transmit APP INFO via PACCH */ @@ -35,8 +35,8 @@ /* sapi */ #define PCU_IF_SAPI_RACH 0x01/* channel request on CCCH */ -#define PCU_IF_SAPI_AGCH 0x02/* assignment on AGCH */ -#define PCU_IF_SAPI_PCH0x03/* paging/assignment on PCH */ +#define PCU_IF_SAPI_AGCH 0x02/* (deprecated) */ +#define PCU_IF_SAPI_PCH0x03/* (deprecated) */ #define PCU_IF_SAPI_BCCH 0x04/* SI on BCCH */ #define PCU_IF_SAPI_PDTCH 0x05/* packet data/control/ccch block */ #define PCU_IF_SAPI_PRACH 0x06/* packet random access channel */ @@ -297,7 +297,6 @@ union { struct gsm_pcu_if_data data_req; - struct gsm_pcu_if_data data_cnf; struct gsm_pcu_if_data_cnf data_cnf2; struct gsm_pcu_if_data data_ind; struct gsm_pcu_if_susp_req susp_req; diff --git a/src/bts.cpp b/src/bts.cpp index 50c21a3..6dffa2d 100644 --- a/src/bts.cpp +++ b/src/bts.cpp @@ -1033,10 +1033,7 @@ rip->burst_type); bts_do_rate_ctr_inc(bts, CTR_IMMEDIATE_ASSIGN_UL_TBF); if (plen >= 0) { - if (the_pcu->pcu_if_version >= 0x0b) - pcu_l1if_tx_agch2(bts, bv, plen, false, GSM_RESERVED_TMSI); - else - pcu_l1if_tx_agch(bts, bv, plen); + pcu_l1if_tx_agch2(bts, bv, plen, false, GSM_RESERVED_TMSI); rc = 0; } else { rc = plen; @@ -1051,10 +1048,7 @@ (uint8_t)osmo_tdef_get(bts->T_defs_bts, 3142, OSMO_TDEF_S, -1)); bts_do_rate_ctr_inc(bts, CTR_IMMEDIATE_ASSIGN_REJ); if (plen >= 0) { - if (the_pcu->pcu_if_version >= 0x0b) - pcu_l1if_tx_agch2(bts, bv, plen, false, GSM_RESERVED_TMSI); - else - pcu_l1if_tx_agch(bts, bv, plen); + pcu_l1if_tx_agch2(bts, bv, plen, false, GSM_RESERVED_TMSI); } bitvec_free(bv); /* rc was already properly set before goto */ @@ -1136,24 +1130,20 @@ if (plen >= 0) { bts_do_rate_ctr_inc(bts, CTR_IMMEDIATE_ASSIGN_DL_TBF); - if (the_pcu->pcu_if_version >= 0x0b) { - if (ms_imsi_is_valid(tbf->ms())) { - pcu_l1if_tx_pch2(bts, immediate_assignment, plen, true, tbf->imsi(), tbf->tlli()); - } else { - /* During GMM ATTACH REQUEST, the IMSI is not yet known to the PCU or SGSN. (It is -* requested after the GMM ATTACH REQUEST with the GMM IDENTITY REQUEST.) When the PCU -* has to assign a DL TBF but the IMSI is not known, then the IMMEDIATE ASSIGNMENT is -* sent on the AGCH. The reason for this is that without an IMSI we can not calculate -+ the paging group, which would be necessary for transmission on PCH. Since the IMSI -* is usually only unknown during the GMM ATTACH REQUEST, we may assume that the MS -* is in non-DRX mode and hence it is listening on all CCCH blocks, including AGCH. -* -* See also: 3gpp TS 44.060, section 5.5.1.5 -* 3gpp TS 45.002, section 6.5.3, 6.5.6 */ - pcu
[S] Change in osmo-bts[master]: pcuif_proto: clean up last remains of old PCUIF v10
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/34707?usp=email ) Change subject: pcuif_proto: clean up last remains of old PCUIF v10 .. pcuif_proto: clean up last remains of old PCUIF v10 There are still some remains that are related to the old PCUIF v10 protocol version. Let's clean those up. Related: OS#5927 Depends: osmo-pcu.git I68a3f59d5c960ae3a4fbd74f9d4a894295cb9ed8 Change-Id: I04f7108c94c99c9920192177087748e8b89b3106 --- M include/osmo-bts/pcuif_proto.h M src/common/pcu_sock.c 2 files changed, 17 insertions(+), 6 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/07/34707/1 diff --git a/include/osmo-bts/pcuif_proto.h b/include/osmo-bts/pcuif_proto.h index a620993..7e14171 100644 --- a/include/osmo-bts/pcuif_proto.h +++ b/include/osmo-bts/pcuif_proto.h @@ -12,7 +12,7 @@ /* msg_type */ #define PCU_IF_MSG_DATA_REQ0x00/* send data to given channel */ -#define PCU_IF_MSG_DATA_CNF0x01/* confirm (e.g. transmission on PCH) */ +#define PCU_IF_MSG_DATA_CNF0x01/* (deprecated) */ #define PCU_IF_MSG_DATA_IND0x02/* receive data from given channel */ #define PCU_IF_MSG_SUSP_REQ0x03/* BTS forwards GPRS SUSP REQ to PCU */ #define PCU_IF_MSG_APP_INFO_REQ0x04/* BTS asks PCU to transmit APP INFO via PACCH */ @@ -29,8 +29,8 @@ /* sapi */ #define PCU_IF_SAPI_RACH 0x01/* channel request on CCCH */ -#define PCU_IF_SAPI_AGCH 0x02/* assignment on AGCH */ -#define PCU_IF_SAPI_PCH0x03/* paging/assignment on PCH */ +#define PCU_IF_SAPI_AGCH 0x02/* (deprecated) */ +#define PCU_IF_SAPI_PCH0x03/* (deprecated) */ #define PCU_IF_SAPI_BCCH 0x04/* SI on BCCH */ #define PCU_IF_SAPI_PDTCH 0x05/* packet data/control/ccch block */ #define PCU_IF_SAPI_PRACH 0x06/* packet random access channel */ @@ -256,7 +256,6 @@ union { struct gsm_pcu_if_data data_req; - struct gsm_pcu_if_data data_cnf; struct gsm_pcu_if_data_cnf data_cnf2; struct gsm_pcu_if_data data_ind; struct gsm_pcu_if_susp_req susp_req; diff --git a/src/common/pcu_sock.c b/src/common/pcu_sock.c index 79b39c4..6116c9e 100644 --- a/src/common/pcu_sock.c +++ b/src/common/pcu_sock.c @@ -53,8 +53,6 @@ static const char *sapi_string[] = { [PCU_IF_SAPI_RACH] ="RACH", - [PCU_IF_SAPI_AGCH] ="AGCH", - [PCU_IF_SAPI_PCH] = "PCH", [PCU_IF_SAPI_BCCH] ="BCCH", [PCU_IF_SAPI_PDTCH] = "PDTCH", [PCU_IF_SAPI_PRACH] = "PRACH", -- To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/34707?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: I04f7108c94c99c9920192177087748e8b89b3106 Gerrit-Change-Number: 34707 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-MessageType: newchange
[S] Change in osmo-bsc[master]: pcuif_proto: clean up last remains of old PCUIF v10
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/34708?usp=email ) Change subject: pcuif_proto: clean up last remains of old PCUIF v10 .. pcuif_proto: clean up last remains of old PCUIF v10 There are still some remains that are related to the old PCUIF v10 protocol version. Let's clean those up. Related: OS#5927 Depends: osmo-pcu.git I68a3f59d5c960ae3a4fbd74f9d4a894295cb9ed8 Change-Id: Iebb3a634fee680bdc3636a61f3ccaa1e97e54a64 --- M include/osmocom/bsc/pcuif_proto.h M src/osmo-bsc/pcu_sock.c 2 files changed, 17 insertions(+), 6 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/08/34708/1 diff --git a/include/osmocom/bsc/pcuif_proto.h b/include/osmocom/bsc/pcuif_proto.h index 9df85d9..cfa422b 100644 --- a/include/osmocom/bsc/pcuif_proto.h +++ b/include/osmocom/bsc/pcuif_proto.h @@ -13,7 +13,7 @@ /* msg_type */ #define PCU_IF_MSG_DATA_REQ0x00/* send data to given channel */ -#define PCU_IF_MSG_DATA_CNF0x01/* confirm (e.g. transmission on PCH) */ +#define PCU_IF_MSG_DATA_CNF0x01/* (deprecated) */ #define PCU_IF_MSG_DATA_IND0x02/* receive data from given channel */ #define PCU_IF_MSG_SUSP_REQ0x03/* BTS forwards GPRS SUSP REQ to PCU */ #define PCU_IF_MSG_APP_INFO_REQ0x04/* BTS asks PCU to transmit APP INFO via PACCH */ @@ -35,8 +35,8 @@ /* sapi */ #define PCU_IF_SAPI_RACH 0x01/* channel request on CCCH */ -#define PCU_IF_SAPI_AGCH 0x02/* assignment on AGCH */ -#define PCU_IF_SAPI_PCH0x03/* paging/assignment on PCH */ +#define PCU_IF_SAPI_AGCH 0x02/* (deprecated) */ +#define PCU_IF_SAPI_PCH0x03/* (deprecated) */ #define PCU_IF_SAPI_BCCH 0x04/* SI on BCCH */ #define PCU_IF_SAPI_PDTCH 0x05/* packet data/control/ccch block */ #define PCU_IF_SAPI_PRACH 0x06/* packet random access channel */ @@ -297,7 +297,6 @@ union { struct gsm_pcu_if_data data_req; - struct gsm_pcu_if_data data_cnf; struct gsm_pcu_if_data_cnf data_cnf2; struct gsm_pcu_if_data data_ind; struct gsm_pcu_if_susp_req susp_req; diff --git a/src/osmo-bsc/pcu_sock.c b/src/osmo-bsc/pcu_sock.c index d279093..24f3c1c 100644 --- a/src/osmo-bsc/pcu_sock.c +++ b/src/osmo-bsc/pcu_sock.c @@ -50,8 +50,6 @@ static const char *sapi_string[] = { [PCU_IF_SAPI_RACH] ="RACH", - [PCU_IF_SAPI_AGCH] ="AGCH", - [PCU_IF_SAPI_PCH] = "PCH", [PCU_IF_SAPI_BCCH] ="BCCH", [PCU_IF_SAPI_PDTCH] = "PDTCH", [PCU_IF_SAPI_PRACH] = "PRACH", -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/34708?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Iebb3a634fee680bdc3636a61f3ccaa1e97e54a64 Gerrit-Change-Number: 34708 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-MessageType: newchange
[M] Change in osmo-pcu[master]: pcuif_proto: drop support for PCUIF v10
Attention is currently required from: dexter, pespin. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/34706?usp=email ) Change subject: pcuif_proto: drop support for PCUIF v10 .. Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/34706?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-pcu Gerrit-Branch: master Gerrit-Change-Id: I68a3f59d5c960ae3a4fbd74f9d4a894295cb9ed8 Gerrit-Change-Number: 34706 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: fixeria Gerrit-Reviewer: pespin Gerrit-CC: Jenkins Builder Gerrit-Attention: pespin Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 13:53:11 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in osmo-bts[master]: pcuif_proto: clean up last remains of old PCUIF v10
Attention is currently required from: dexter, fixeria. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/34707?usp=email ) Change subject: pcuif_proto: clean up last remains of old PCUIF v10 .. Patch Set 1: Code-Review-1 (1 comment) File include/osmo-bts/pcuif_proto.h: https://gerrit.osmocom.org/c/osmo-bts/+/34707/comment/04b2a897_c1b38322 PS1, Line 32: #define PCU_IF_SAPI_AGCH 0x02/* (deprecated) */ They were deprecated with v11, but since v12 which you will introduce now they will be no-longer supported, hence they should actually be removed. AFAIU the protocol version is checked at startup, so there shouldn't be problems with different versions using the same value for different topics. -- To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/34707?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: I04f7108c94c99c9920192177087748e8b89b3106 Gerrit-Change-Number: 34707 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: pespin Gerrit-Attention: fixeria Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 14:32:24 + Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in osmo-bsc[master]: pcuif_proto: clean up last remains of old PCUIF v10
Attention is currently required from: dexter, fixeria. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/34708?usp=email ) Change subject: pcuif_proto: clean up last remains of old PCUIF v10 .. Patch Set 1: Code-Review-1 (1 comment) File include/osmocom/bsc/pcuif_proto.h: https://gerrit.osmocom.org/c/osmo-bsc/+/34708/comment/fba27e00_e2675da7 PS1, Line 38: #define PCU_IF_SAPI_AGCH 0x02/* (deprecated) */ https://gerrit.osmocom.org/c/osmo-bts/+/34707/1/include/osmo-bts/pcuif_proto.h -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/34708?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: Iebb3a634fee680bdc3636a61f3ccaa1e97e54a64 Gerrit-Change-Number: 34708 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: pespin Gerrit-Attention: fixeria Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 14:32:40 + Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[M] Change in osmo-pcu[master]: pcuif_proto: drop support for PCUIF v10
Attention is currently required from: dexter. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/34706?usp=email ) Change subject: pcuif_proto: drop support for PCUIF v10 .. Patch Set 1: Code-Review-1 (3 comments) File include/osmocom/pcu/pcuif_proto.h: https://gerrit.osmocom.org/c/osmo-pcu/+/34706/comment/c8997896_26149ac4 PS1, Line 16: #define PCU_IF_MSG_DATA_CNF 0x01/* (deprecated) */ this does no longer exist in v11 afaiu https://gerrit.osmocom.org/c/osmo-pcu/+/34706/comment/1f9dc75d_ffced86c PS1, Line 38: #define PCU_IF_SAPI_AGCH 0x02/* (deprecated) */ this does no longer exist in v11 afaiu File src/bts.cpp: https://gerrit.osmocom.org/c/osmo-pcu/+/34706/comment/a2b36e1f_4c1c6350 PS1, Line 1050: if (plen >= 0) { {} can be removed. -- To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/34706?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-pcu Gerrit-Branch: master Gerrit-Change-Id: I68a3f59d5c960ae3a4fbd74f9d4a894295cb9ed8 Gerrit-Change-Number: 34706 Gerrit-PatchSet: 1 Gerrit-Owner: dexter Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: pespin Gerrit-Attention: dexter Gerrit-Comment-Date: Tue, 10 Oct 2023 14:34:43 + Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in docker-playground[master]: WIP: Support debian boowkorm
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/34712?usp=email ) Change subject: WIP: Support debian boowkorm .. WIP: Support debian boowkorm Change-Id: Ib11a55294b525e3c3806246b133f8e479554a068 --- M open5gs-latest/Dockerfile 1 file changed, 36 insertions(+), 7 deletions(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/12/34712/1 diff --git a/open5gs-latest/Dockerfile b/open5gs-latest/Dockerfile index 7c385e2..c395d9c 100644 --- a/open5gs-latest/Dockerfile +++ b/open5gs-latest/Dockerfile @@ -1,8 +1,12 @@ ARGREGISTRY=docker.io -FROM ${REGISTRY}/debian:bullseye +ARGUPSTREAM_DISTRO=debian:bookworm +FROM ${REGISTRY}/${UPSTREAM_DISTRO} +# Arguments used after FROM must be specified again +ARGDISTRO + ARGOPEN5GS_REPO_HOST="https://download.opensuse.org"; ARGOPEN5GS_REPO_PATH="repositories/home:/acetcom:/open5gs:" -ARG OPEN5GS_REPO="${OPEN5GS_REPO_HOST}/${OPEN5GS_REPO_PATH}/latest/Debian_11" +ARG OPEN5GS_REPO="${OPEN5GS_REPO_HOST}/${OPEN5GS_REPO_PATH}/latest/Debian_12" ARGOPEN5GS_KEY=/usr/share/keyrings/open5gs-latest.asc ARGMONGODB_KEY=/usr/share/keyrings/mongodb-org.asc @@ -18,13 +22,29 @@ sudo \ wget +RUNwget "https://pgp.mongodb.com/server-5.0.asc"; -O "$MONGODB_KEY" +RUNcase "$DISTRO" in \ + debian-*) \ + DEBIAN_VERSION=$(echo "$DISTRO" | cut -d "-" -f2); \ + if [ "x${DEBIAN_VERSION}" = "xbookworm" ]; then \ + echo "Using bullseye since bookworm mongodb-org package is not available. Furthermore, manually install required libssl1.1." && \ + DEBIAN_VERSION="bullseye" && \ + wget "http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.1_1.1.1n-0+deb10u6_amd64.deb"; && \ + dpkg -i "libssl1.1_1.1.1n-0+deb10u6_amd64.deb" && \ + rm "libssl1.1_1.1.1n-0+deb10u6_amd64.deb"; \ + fi; \ + echo "deb [signed-by=$MONGODB_KEY] http://repo.mongodb.org/apt/debian ${DEBIAN_VERSION}/mongodb-org/5.0 main" \ + > /etc/apt/sources.list.d/mongodb-org.list \ + ;; \ + centos*) \ + echo "TODO: centos" && \ + exit 1 \ + ;; \ + esac + RUNecho "deb [signed-by=$OPEN5GS_KEY] $OPEN5GS_REPO/ ./" \ > /etc/apt/sources.list.d/open5gs.list -RUNecho "deb [signed-by=$MONGODB_KEY] http://repo.mongodb.org/apt/debian bullseye/mongodb-org/5.0 main" \ - > /etc/apt/sources.list.d/mongodb-org.list - -RUNwget "$OPEN5GS_REPO/Release.key" -O "$OPEN5GS_KEY" && \ - wget "https://pgp.mongodb.com/server-5.0.asc"; -O "$MONGODB_KEY" +RUNwget "$OPEN5GS_REPO/Release.key" -O "$OPEN5GS_KEY" RUNapt-get update && \ apt-get install -y \ -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34712?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Ib11a55294b525e3c3806246b133f8e479554a068 Gerrit-Change-Number: 34712 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-MessageType: newchange
[S] Change in docker-playground[master]: open5gs-master: Make mongodb available in the image
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email ) Change subject: open5gs-master: Make mongodb available in the image .. open5gs-master: Make mongodb available in the image The open5gs-latest image installs mongodb, but the master one doesn't. Having a mongodb image is required to run together with open5gs-hssd. Related: SYS#6588 Change-Id: Id6dde5f54b666279c102eb14fabb87194192c9e4 --- M open5gs-master/Dockerfile 1 file changed, 41 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/11/34711/1 diff --git a/open5gs-master/Dockerfile b/open5gs-master/Dockerfile index 827d661..e9b3cf4 100644 --- a/open5gs-master/Dockerfile +++ b/open5gs-master/Dockerfile @@ -2,6 +2,8 @@ ARGUSER ARGDISTRO FROM $USER/$DISTRO-build +# Arguments used after FROM must be specified again +ARGDISTRO RUNapt-get update && \ apt-get upgrade -y && \ @@ -13,9 +15,34 @@ iproute2 \ iputils-ping \ libcap2-bin \ - net-tools && \ + net-tools \ + wget && \ apt-get clean +ARGMONGODB_KEY=/usr/share/keyrings/mongodb-org.asc +RUNwget "https://pgp.mongodb.com/server-5.0.asc"; -O "$MONGODB_KEY" +RUNcase "$DISTRO" in \ + debian-*) \ + DEBIAN_VERSION=$(echo "$DISTRO" | cut -d "-" -f2); \ + if [ "x${DEBIAN_VERSION}" = "xbookworm" ]; then \ + echo "Using bullseye since bookworm mongodb-org package is not available. Furthermore, manually install required libssl1.1." && \ + DEBIAN_VERSION="bullseye" && \ + wget "http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.1_1.1.1n-0+deb10u6_amd64.deb"; && \ + dpkg -i "libssl1.1_1.1.1n-0+deb10u6_amd64.deb" && \ + rm "libssl1.1_1.1.1n-0+deb10u6_amd64.deb"; \ + fi; \ + echo "deb [signed-by=$MONGODB_KEY] http://repo.mongodb.org/apt/debian ${DEBIAN_VERSION}/mongodb-org/5.0 main" \ + > /etc/apt/sources.list.d/mongodb-org.list \ + ;; \ + centos*) \ + echo "TODO: centos" && \ + exit 1 \ + ;; \ + esac +RUNapt-get update && \ + apt-get install -y \ + mongodb-org + # create a user ARGusername=osmocom RUNuseradd -m ${username} && \ -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Id6dde5f54b666279c102eb14fabb87194192c9e4 Gerrit-Change-Number: 34711 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-MessageType: newchange
[M] Change in docker-playground[master]: open5gs-master: Fix indentation
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/34709?usp=email ) Change subject: open5gs-master: Fix indentation .. open5gs-master: Fix indentation Use tabs everywhere, as usual with other Dockerfiles (eg. open5gs-latest). Change-Id: Ie4e72f484797ada718915e837cd38be574136631 --- M open5gs-master/Dockerfile 1 file changed, 50 insertions(+), 38 deletions(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/09/34709/1 diff --git a/open5gs-master/Dockerfile b/open5gs-master/Dockerfile index fc88f9e..99def99 100644 --- a/open5gs-master/Dockerfile +++ b/open5gs-master/Dockerfile @@ -3,56 +3,56 @@ ARGDISTRO FROM $USER/$DISTRO-build -RUN apt-get update && \ -apt-get upgrade -y && \ -DEBIAN_FRONTEND=noninteractive \ -apt-get install -y --no-install-recommends \ -cmake \ -vim \ -sudo \ -iproute2 \ -iputils-ping \ -libcap2-bin \ -net-tools && \ -apt-get clean +RUNapt-get update && \ + apt-get upgrade -y && \ + DEBIAN_FRONTEND=noninteractive \ + apt-get install -y --no-install-recommends \ + cmake \ + vim \ + sudo \ + iproute2 \ + iputils-ping \ + libcap2-bin \ + net-tools && \ + apt-get clean # create a user -ARG username=osmocom -RUN useradd -m ${username} && \ -echo "${username} ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/${username} && \ -chmod 0440 /etc/sudoers.d/${username} +ARGusername=osmocom +RUNuseradd -m ${username} && \ + echo "${username} ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/${username} && \ + chmod 0440 /etc/sudoers.d/${username} -WORKDIR /home/${username} +WORKDIR/home/${username} # clone open5gs -ARG GITHUB_USER=open5gs -ARG GITHUB_REPO=open5gs -ARG OPEN5GS_BRANCH=main -RUN git clone https://github.com/$GITHUB_USER/$GITHUB_REPO +ARGGITHUB_USER=open5gs +ARGGITHUB_REPO=open5gs +ARGOPEN5GS_BRANCH=main +RUNgit clone https://github.com/$GITHUB_USER/$GITHUB_REPO # install dependencies specified in debian/control (cache them) -RUN cd $GITHUB_REPO && \ -git checkout $OPEN5GS_BRANCH && \ -apt-get build-dep -y . +RUNcd $GITHUB_REPO && \ + git checkout $OPEN5GS_BRANCH && \ + apt-get build-dep -y . -ADD https://api.github.com/repos/$GITHUB_USER/$GITHUB_REPO/git/refs/heads/$OPEN5GS_BRANCH /root/open5gs-ver.json +ADD https://api.github.com/repos/$GITHUB_USER/$GITHUB_REPO/git/refs/heads/$OPEN5GS_BRANCH /root/open5gs-ver.json # update the source code (if needed) -RUN cd $GITHUB_REPO && \ -git fetch && git checkout -f -B $OPEN5GS_BRANCH origin/$OPEN5GS_BRANCH +RUNcd $GITHUB_REPO && \ + git fetch && git checkout -f -B $OPEN5GS_BRANCH origin/$OPEN5GS_BRANCH # update installed dependencies, install missing (if any) -RUN cd $GITHUB_REPO && \ -apt-get build-dep -y . +RUNcd $GITHUB_REPO && \ + apt-get build-dep -y . # build + install open5gs -RUN cd $GITHUB_REPO && \ -meson build \ ---prefix=/usr \ ---sysconfdir=/etc \ ---localstatedir=/var \ ---libdir=lib/x86_64-linux-gnu \ ---libexecdir=lib/x86_64-linux-gnu && \ -meson configure build && \ -ninja -C build install +RUNcd $GITHUB_REPO && \ + meson build \ + --prefix=/usr \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --libdir=lib/x86_64-linux-gnu \ + --libexecdir=lib/x86_64-linux-gnu && \ + meson configure build && \ + ninja -C build install -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34709?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Ie4e72f484797ada718915e837cd38be574136631 Gerrit-Change-Number: 34709 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-MessageType: newchange
[S] Change in docker-playground[master]: open5gs-master: Install open5gs-dbctl to /usr/bin
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email ) Change subject: open5gs-master: Install open5gs-dbctl to /usr/bin .. open5gs-master: Install open5gs-dbctl to /usr/bin meson install doesn't install that file because it's aimed at developers. However, debian package does install it manually in debian/open5gs-common.install. Hence, the app is available in open5gs-latest docker image, but not in open5gs-master. Manually copy it to /usr/bin to have both behave the same in this aspect. Related: SYS#6588 Change-Id: I54a760d04e6522d843e6d65b94ef6067e502fbaa --- M open5gs-master/Dockerfile 1 file changed, 19 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/10/34710/1 diff --git a/open5gs-master/Dockerfile b/open5gs-master/Dockerfile index 99def99..827d661 100644 --- a/open5gs-master/Dockerfile +++ b/open5gs-master/Dockerfile @@ -55,4 +55,5 @@ --libdir=lib/x86_64-linux-gnu \ --libexecdir=lib/x86_64-linux-gnu && \ meson configure build && \ - ninja -C build install + ninja -C build install && \ + install -m 0755 build/misc/db/open5gs-dbctl /usr/bin/open5gs-dbctl -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I54a760d04e6522d843e6d65b94ef6067e502fbaa Gerrit-Change-Number: 34710 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-MessageType: newchange
[M] Change in docker-playground[master]: open5gs-master: Fix indentation
Attention is currently required from: fixeria, pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34709?usp=email ) Change subject: open5gs-master: Fix indentation .. Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34709?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Ie4e72f484797ada718915e837cd38be574136631 Gerrit-Change-Number: 34709 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: osmith Gerrit-Attention: pespin Gerrit-Attention: fixeria Gerrit-Comment-Date: Tue, 10 Oct 2023 15:34:05 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in docker-playground[master]: open5gs-master: Install open5gs-dbctl to /usr/bin
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email ) Change subject: open5gs-master: Install open5gs-dbctl to /usr/bin .. Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I54a760d04e6522d843e6d65b94ef6067e502fbaa Gerrit-Change-Number: 34710 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: osmith Gerrit-Attention: pespin Gerrit-Comment-Date: Tue, 10 Oct 2023 15:34:27 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in docker-playground[master]: open5gs-master: Make mongodb available in the image
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email ) Change subject: open5gs-master: Make mongodb available in the image .. Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Id6dde5f54b666279c102eb14fabb87194192c9e4 Gerrit-Change-Number: 34711 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: osmith Gerrit-Attention: pespin Gerrit-Comment-Date: Tue, 10 Oct 2023 15:36:07 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[M] Change in docker-playground[master]: open5gs-master: Fix indentation
pespin has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34709?usp=email ) Change subject: open5gs-master: Fix indentation .. open5gs-master: Fix indentation Use tabs everywhere, as usual with other Dockerfiles (eg. open5gs-latest). Change-Id: Ie4e72f484797ada718915e837cd38be574136631 --- M open5gs-master/Dockerfile 1 file changed, 50 insertions(+), 38 deletions(-) Approvals: osmith: Looks good to me, approved Jenkins Builder: Verified diff --git a/open5gs-master/Dockerfile b/open5gs-master/Dockerfile index fc88f9e..99def99 100644 --- a/open5gs-master/Dockerfile +++ b/open5gs-master/Dockerfile @@ -3,56 +3,56 @@ ARGDISTRO FROM $USER/$DISTRO-build -RUN apt-get update && \ -apt-get upgrade -y && \ -DEBIAN_FRONTEND=noninteractive \ -apt-get install -y --no-install-recommends \ -cmake \ -vim \ -sudo \ -iproute2 \ -iputils-ping \ -libcap2-bin \ -net-tools && \ -apt-get clean +RUNapt-get update && \ + apt-get upgrade -y && \ + DEBIAN_FRONTEND=noninteractive \ + apt-get install -y --no-install-recommends \ + cmake \ + vim \ + sudo \ + iproute2 \ + iputils-ping \ + libcap2-bin \ + net-tools && \ + apt-get clean # create a user -ARG username=osmocom -RUN useradd -m ${username} && \ -echo "${username} ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/${username} && \ -chmod 0440 /etc/sudoers.d/${username} +ARGusername=osmocom +RUNuseradd -m ${username} && \ + echo "${username} ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/${username} && \ + chmod 0440 /etc/sudoers.d/${username} -WORKDIR /home/${username} +WORKDIR/home/${username} # clone open5gs -ARG GITHUB_USER=open5gs -ARG GITHUB_REPO=open5gs -ARG OPEN5GS_BRANCH=main -RUN git clone https://github.com/$GITHUB_USER/$GITHUB_REPO +ARGGITHUB_USER=open5gs +ARGGITHUB_REPO=open5gs +ARGOPEN5GS_BRANCH=main +RUNgit clone https://github.com/$GITHUB_USER/$GITHUB_REPO # install dependencies specified in debian/control (cache them) -RUN cd $GITHUB_REPO && \ -git checkout $OPEN5GS_BRANCH && \ -apt-get build-dep -y . +RUNcd $GITHUB_REPO && \ + git checkout $OPEN5GS_BRANCH && \ + apt-get build-dep -y . -ADD https://api.github.com/repos/$GITHUB_USER/$GITHUB_REPO/git/refs/heads/$OPEN5GS_BRANCH /root/open5gs-ver.json +ADD https://api.github.com/repos/$GITHUB_USER/$GITHUB_REPO/git/refs/heads/$OPEN5GS_BRANCH /root/open5gs-ver.json # update the source code (if needed) -RUN cd $GITHUB_REPO && \ -git fetch && git checkout -f -B $OPEN5GS_BRANCH origin/$OPEN5GS_BRANCH +RUNcd $GITHUB_REPO && \ + git fetch && git checkout -f -B $OPEN5GS_BRANCH origin/$OPEN5GS_BRANCH # update installed dependencies, install missing (if any) -RUN cd $GITHUB_REPO && \ -apt-get build-dep -y . +RUNcd $GITHUB_REPO && \ + apt-get build-dep -y . # build + install open5gs -RUN cd $GITHUB_REPO && \ -meson build \ ---prefix=/usr \ ---sysconfdir=/etc \ ---localstatedir=/var \ ---libdir=lib/x86_64-linux-gnu \ ---libexecdir=lib/x86_64-linux-gnu && \ -meson configure build && \ -ninja -C build install +RUNcd $GITHUB_REPO && \ + meson build \ + --prefix=/usr \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --libdir=lib/x86_64-linux-gnu \ + --libexecdir=lib/x86_64-linux-gnu && \ + meson configure build && \ + ninja -C build install -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34709?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Ie4e72f484797ada718915e837cd38be574136631 Gerrit-Change-Number: 34709 Gerrit-PatchSet: 2 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: osmith Gerrit-Reviewer: pespin Gerrit-MessageType: merged
[S] Change in docker-playground[master]: open5gs-master: Install open5gs-dbctl to /usr/bin
Attention is currently required from: pespin. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email ) Change subject: open5gs-master: Install open5gs-dbctl to /usr/bin .. Patch Set 2: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I54a760d04e6522d843e6d65b94ef6067e502fbaa Gerrit-Change-Number: 34710 Gerrit-PatchSet: 2 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: osmith Gerrit-Attention: pespin Gerrit-Comment-Date: Tue, 10 Oct 2023 16:11:53 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in docker-playground[master]: open5gs-master: Install open5gs-dbctl to /usr/bin
pespin has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email ) Change subject: open5gs-master: Install open5gs-dbctl to /usr/bin .. open5gs-master: Install open5gs-dbctl to /usr/bin meson install doesn't install that file because it's aimed at developers. However, debian package does install it manually in debian/open5gs-common.install. Hence, the app is available in open5gs-latest docker image, but not in open5gs-master. Manually copy it to /usr/bin to have both behave the same in this aspect. Related: SYS#6588 Change-Id: I54a760d04e6522d843e6d65b94ef6067e502fbaa --- M open5gs-master/Dockerfile 1 file changed, 19 insertions(+), 1 deletion(-) Approvals: fixeria: Looks good to me, approved osmith: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/open5gs-master/Dockerfile b/open5gs-master/Dockerfile index 99def99..827d661 100644 --- a/open5gs-master/Dockerfile +++ b/open5gs-master/Dockerfile @@ -55,4 +55,5 @@ --libdir=lib/x86_64-linux-gnu \ --libexecdir=lib/x86_64-linux-gnu && \ meson configure build && \ - ninja -C build install + ninja -C build install && \ + install -m 0755 build/misc/db/open5gs-dbctl /usr/bin/open5gs-dbctl -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34710?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I54a760d04e6522d843e6d65b94ef6067e502fbaa Gerrit-Change-Number: 34710 Gerrit-PatchSet: 2 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: osmith Gerrit-Reviewer: pespin Gerrit-MessageType: merged
[S] Change in docker-playground[master]: open5gs-master: Make mongodb available in the image
Attention is currently required from: pespin. fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email ) Change subject: open5gs-master: Make mongodb available in the image .. Patch Set 2: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Id6dde5f54b666279c102eb14fabb87194192c9e4 Gerrit-Change-Number: 34711 Gerrit-PatchSet: 2 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: osmith Gerrit-Attention: pespin Gerrit-Comment-Date: Tue, 10 Oct 2023 16:16:27 + Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
[S] Change in docker-playground[master]: open5gs-master: Make mongodb available in the image
pespin has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email ) Change subject: open5gs-master: Make mongodb available in the image .. open5gs-master: Make mongodb available in the image The open5gs-latest image installs mongodb, but the master one doesn't. Having a mongodb image is required to run together with open5gs-hssd. Related: SYS#6588 Change-Id: Id6dde5f54b666279c102eb14fabb87194192c9e4 --- M open5gs-master/Dockerfile 1 file changed, 41 insertions(+), 1 deletion(-) Approvals: fixeria: Looks good to me, approved Jenkins Builder: Verified osmith: Looks good to me, but someone else must approve diff --git a/open5gs-master/Dockerfile b/open5gs-master/Dockerfile index 827d661..e9b3cf4 100644 --- a/open5gs-master/Dockerfile +++ b/open5gs-master/Dockerfile @@ -2,6 +2,8 @@ ARGUSER ARGDISTRO FROM $USER/$DISTRO-build +# Arguments used after FROM must be specified again +ARGDISTRO RUNapt-get update && \ apt-get upgrade -y && \ @@ -13,9 +15,34 @@ iproute2 \ iputils-ping \ libcap2-bin \ - net-tools && \ + net-tools \ + wget && \ apt-get clean +ARGMONGODB_KEY=/usr/share/keyrings/mongodb-org.asc +RUNwget "https://pgp.mongodb.com/server-5.0.asc"; -O "$MONGODB_KEY" +RUNcase "$DISTRO" in \ + debian-*) \ + DEBIAN_VERSION=$(echo "$DISTRO" | cut -d "-" -f2); \ + if [ "x${DEBIAN_VERSION}" = "xbookworm" ]; then \ + echo "Using bullseye since bookworm mongodb-org package is not available. Furthermore, manually install required libssl1.1." && \ + DEBIAN_VERSION="bullseye" && \ + wget "http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.1_1.1.1n-0+deb10u6_amd64.deb"; && \ + dpkg -i "libssl1.1_1.1.1n-0+deb10u6_amd64.deb" && \ + rm "libssl1.1_1.1.1n-0+deb10u6_amd64.deb"; \ + fi; \ + echo "deb [signed-by=$MONGODB_KEY] http://repo.mongodb.org/apt/debian ${DEBIAN_VERSION}/mongodb-org/5.0 main" \ + > /etc/apt/sources.list.d/mongodb-org.list \ + ;; \ + centos*) \ + echo "TODO: centos" && \ + exit 1 \ + ;; \ + esac +RUNapt-get update && \ + apt-get install -y \ + mongodb-org + # create a user ARGusername=osmocom RUNuseradd -m ${username} && \ -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/34711?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: Id6dde5f54b666279c102eb14fabb87194192c9e4 Gerrit-Change-Number: 34711 Gerrit-PatchSet: 2 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria Gerrit-Reviewer: osmith Gerrit-Reviewer: pespin Gerrit-MessageType: merged
[M] Change in osmo-ttcn3-hacks[master]: library/DIAMETER: Add several missing tr templates
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/34713?usp=email ) Change subject: library/DIAMETER: Add several missing tr templates .. library/DIAMETER: Add several missing tr templates Change-Id: I21da18a5e1f0d368176d653494e0e0cde0beb656 --- M library/DIAMETER_Templates.ttcn M library/Osmocom_Types.ttcn 2 files changed, 171 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/13/34713/1 diff --git a/library/DIAMETER_Templates.ttcn b/library/DIAMETER_Templates.ttcn index 8bb53e0..fde071b 100644 --- a/library/DIAMETER_Templates.ttcn +++ b/library/DIAMETER_Templates.ttcn @@ -852,6 +852,14 @@ /* TS 29.272 7.3.27 Context-Identifier */ +template (present) GenericAVP tr_AVP_3GPP_ContextId(template (present) uint32_t ctx := ?) := { + avp := { + avp_header := tr_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_Context_Identifier), + avp_data := { + avp_AAA_3GPP_Context_Identifier := int2oct_tmpl(ctx, 4) + } + } +} template (value) GenericAVP ts_AVP_3GPP_ContextId(uint32_t ctx) := { avp := { avp_header := ts_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_Context_Identifier), @@ -871,6 +879,15 @@ } } +template (present) GenericAVP tr_AVP_3GPP_SubscrRauTauTmr(template (present) uint32_t tmr := ?) := { + avp := { + avp_header := tr_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_Subscribed_Periodic_RAU_TAU_Timer), + avp_data := { + avp_AAA_3GPP_Subscribed_Periodic_RAU_TAU_Timer := int2oct_tmpl(tmr, 4) + } + } +} + template (value) GenericAVP ts_AVP_3GPP_SubscrRauTauTmr(uint32_t tmr) := { avp := { avp_header := ts_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_Subscribed_Periodic_RAU_TAU_Timer), @@ -881,6 +898,14 @@ } /* TS 29.272 7.3.33 All-APN-Configurations-Included-Indicator */ +template (present) GenericAVP tr_AVP_3GPP_AllApnConfigsIncl(template (present) AAA_3GPP_All_APN_Configurations_Included_Indicator ind := ?) := { + avp := { + avp_header := tr_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_All_APN_Configurations_Included_Indicator), + avp_data := { + avp_AAA_3GPP_All_APN_Configurations_Included_Indicator := ind + } + } +} template (value) GenericAVP ts_AVP_3GPP_AllApnConfigsIncl(template (value) AAA_3GPP_All_APN_Configurations_Included_Indicator ind := All_APN_CONFIGURATIONS_INCLUDED) := { avp := { avp_header := ts_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_All_APN_Configurations_Included_Indicator), @@ -891,6 +916,14 @@ } /* TS 29.272 7.3.34 APN-Configuration-Profile */ +template (present) GenericAVP tr_AVP_3GPP_ApnConfigProfile(template (present) AVP_list content := ?) := { + avp := { + avp_header := tr_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_APN_Configuration_Profile), + avp_data := { + avp_AAA_3GPP_APN_Configuration_Profile := content + } + } +} template (value) GenericAVP ts_AVP_3GPP_ApnConfigProfile(template (value) AVP_list content) := { avp := { avp_header := ts_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_APN_Configuration_Profile), @@ -901,6 +934,21 @@ } /* TS 29.272 7.3.35 APN-Configuration */ +template (present) GenericAVP tr_AVP_3GPP_ApnConfig(template (present) uint32_t ctx := ?, + template (present) AAA_3GPP_PDN_Type pdn_type := ?, + template (present) charstring apn := ?) := { + avp := { + avp_header := tr_DIA_Hdr_3GPP(c_AVP_Code_AAA_3GPP_APN_Configuration_Profile), + avp_data := { + avp_AAA_3GPP_APN_Configuration := { + tr_AVP_3GPP_ContextId(ctx), + tr_AVP_3GPP_PdnType(pdn_type), + tr_AVP_3GPP_EpsSubscrQosProfile(?, ?), + tr_AVP_ServiceSelection(apn) + } + } + } +} template (value) GenericAVP ts_AVP_3GPP_ApnConfig(uint32_t ctx, AAA_3GPP_PDN_Type pdn_type, charstring apn) := { avp := { @@ -917,6 +965,14 @@ } /* TS 29.272 7.3.36 Service-Selection (refers to RFC 5778) */ +template (present) GenericAVP tr_AVP_ServiceSelection(template (present) charstring apn := ?) := { + avp := { + avp_header := tr_DIA_Hdr(c_AVP_Code_MIPv6_NONE_Service_Selection), + avp_data := { + avp_MIPv6_NONE_Service_Selection := char2oct_tmpl(apn) + } + } +} template (value) GenericAVP ts_AVP_ServiceSelection(charstring apn) := { avp := {
[L] Change in osmo-ttcn3-hacks[master]: Introduce HSS_Tests testsuite
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/34714?usp=email ) Change subject: Introduce HSS_Tests testsuite .. Introduce HSS_Tests testsuite Change-Id: Ic2fccd9c54aea04f1a31649a0af47c974939fb2f Related: SYS#6588 --- M Makefile A hss/HSS_Tests.cfg A hss/HSS_Tests.default A hss/HSS_Tests.ttcn A hss/expected-results.xml A hss/gen_links.sh A hss/regen_makefile.sh 7 files changed, 352 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/14/34714/1 diff --git a/Makefile b/Makefile index 1d119d1..0ed632f 100644 --- a/Makefile +++ b/Makefile @@ -27,6 +27,7 @@ hlr \ hnbgw \ hnodeb \ + hss \ mgw \ mme \ msc \ diff --git a/hss/HSS_Tests.cfg b/hss/HSS_Tests.cfg new file mode 100644 index 000..24fe9c4 --- /dev/null +++ b/hss/HSS_Tests.cfg @@ -0,0 +1,18 @@ +[ORDERED_INCLUDE] +# Common configuration, shared between test suites +"../Common.cfg" +# testsuite specific configuration, not expected to change +"./HSS_Tests.default" + +# Local configuration below + +[LOGGING] + +[TESTPORT_PARAMETERS] + +[MODULE_PARAMETERS] + +[MAIN_CONTROLLER] + +[EXECUTE] +HSS_Tests.control diff --git a/hss/HSS_Tests.default b/hss/HSS_Tests.default new file mode 100644 index 000..4c0b502 --- /dev/null +++ b/hss/HSS_Tests.default @@ -0,0 +1,7 @@ +[LOGGING] + +[TESTPORT_PARAMETERS] + +[MODULE_PARAMETERS] + +[EXECUTE] diff --git a/hss/HSS_Tests.ttcn b/hss/HSS_Tests.ttcn new file mode 100644 index 000..bd18e9e --- /dev/null +++ b/hss/HSS_Tests.ttcn @@ -0,0 +1,263 @@ +module HSS_Tests { + +import from General_Types all; +import from Osmocom_Types all; +import from Native_Functions all; +import from Misc_Helpers all; + +import from DIAMETER_Types all; +import from DIAMETER_Templates all; +import from DIAMETER_Emulation all; + +type record of hexstring SubscriberConfigs; + +modulepar { + charstring mp_hss_hostname := "127.0.0.4"; + integer mp_hss_port := 3868; + charstring mp_diam_local_hostname := "127.0.0.1"; + integer mp_diam_local_port := 3868; + charstring mp_diam_orig_realm := "localdomain"; + charstring mp_diam_orig_host := "mme.localdomain"; + charstring mp_diam_dest_realm := "localdomain"; + charstring mp_diam_dest_host := "hss.localdomain"; + SubscriberConfigs subscribers := { + /* Existing subscriber, ULA returns SERVICE_GRANTED */ + '0010100'H + }; +} + +/* main component, we typically have one per testcase */ +type component MTC_CT { + + /* emulated MME/SGSN */ + var DIAMETER_Emulation_CT vc_S6a; + port DIAMETER_PT S6a_UNIT; + port DIAMETEREM_PROC_PT S6a_PROC; + /* global test case guard timer (actual timeout value is set in f_init()) */ + timer T_guard; +} + +/* global altstep for global guard timer; */ +altstep as_Tguard() runs on MTC_CT { + [] T_guard.timeout { + setverdict(fail, "Timeout of T_guard"); + mtc.stop; + } +} + +type component DIAMETER_ConnHdlr_CT extends DIAMETER_ConnHdlr { + port DIAMETER_Conn_PT DIAMETER_CLIENT; + port DIAMETEREM_PROC_PT DIAMETER_PROC_CLIENT; +} + +function f_diam_connhldr_ct_main(hexstring imsi) runs on DIAMETER_ConnHdlr_CT { + var DIAMETER_ConnHdlr vc_conn_unused; + var PDU_DIAMETER msg; + var UINT32 ete_id; + + f_diameter_expect_imsi(imsi); + + while (true) { + alt { + [] DIAMETER_CLIENT.receive(PDU_DIAMETER:?) -> value msg { + DIAMETER.send(msg); + } + [] DIAMETER.receive(PDU_DIAMETER:?) -> value msg { + DIAMETER_CLIENT.send(msg); + } + [] DIAMETER_PROC_CLIENT.getcall(DIAMETEREM_register_eteid:{?,?}) -> param(ete_id, vc_conn_unused) { + DIAMETER_PROC.call(DIAMETEREM_register_eteid:{ete_id, self}) { + [] DIAMETER_PROC.getreply(DIAMETEREM_register_eteid:{?,?}) {}; + } + DIAMETER_PROC_CLIENT.reply(DIAMETEREM_register_eteid:{ete_id, vc_conn_unused}); + } + } + } +} + +/* per-session component; we typically have 1..N per testcase */ +type component Cli_Session_CT { + var SessionPars g_pars; + + port DIAMETER_Conn_PT S6a; + port DIAMETEREM_PROC_PT S6a_PROC; +} +function f_diam_connhldr_expect_eteid(UINT32 ete_id) runs on Cli_Session_CT { + S6a_PROC.call(DIAMETEREM_register_eteid:{ete_id, null}) { + [] S6a_PROC.getreply(DIAMETEREM_register_eteid:{?,?}) {}; + } +} + +/* configuration data for a given Session */ +type record SessionPars { + hexstring imsi, + uint32_ts6a_next_hbh
[L] Change in docker-playground[master]: Introduce ttcn3-hss-test-ogs
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/34715?usp=email ) Change subject: Introduce ttcn3-hss-test-ogs .. Introduce ttcn3-hss-test-ogs Related: SYS#6588 Depends: osmo-ttcn3-hacks.git Ic2fccd9c54aea04f1a31649a0af47c974939fb2f Change-Id: Iebeefd9689ae2efa54678b99ff929ca255ec64d1 --- A ttcn3-hss-test-ogs/Dockerfile A ttcn3-hss-test-ogs/Makefile A ttcn3-hss-test-ogs/jenkins.sh A ttcn3-hss-test-ogs/ogs/HSS_Tests.cfg A ttcn3-hss-test-ogs/ogs/freediameter.conf A ttcn3-hss-test-ogs/ogs/mongod.conf A ttcn3-hss-test-ogs/ogs/open5gs-hss.yaml 7 files changed, 503 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/15/34715/1 diff --git a/ttcn3-hss-test-ogs/Dockerfile b/ttcn3-hss-test-ogs/Dockerfile new file mode 100644 index 000..f8ae830 --- /dev/null +++ b/ttcn3-hss-test-ogs/Dockerfile @@ -0,0 +1,21 @@ +ARGREGISTRY +ARGUSER +FROM $REGISTRY/$USER/debian-bookworm-titan + +RUNapt-get update && \ + apt-get upgrade -y && \ + DEBIAN_FRONTEND='noninteractive' apt-get install -y --no-install-recommends --no-install-suggests \ + libgnutls28-dev \ + && \ + apt-get clean + +ARGOSMO_TTCN3_BRANCH="master" + +ADD https://gerrit.osmocom.org/plugins/gitiles/osmo-ttcn3-hacks/+/$OSMO_TTCN3_BRANCH?format=TEXT /tmp/commit +RUNttcn3-docker-prepare "$OSMO_TTCN3_BRANCH" hss + +VOLUME /data + +COPY ogs/HSS_Tests.cfg /data/HSS_Tests.cfg + +CMDttcn3-docker-run hss HSS_Tests diff --git a/ttcn3-hss-test-ogs/Makefile b/ttcn3-hss-test-ogs/Makefile new file mode 100644 index 000..8d0e10b --- /dev/null +++ b/ttcn3-hss-test-ogs/Makefile @@ -0,0 +1 @@ +include ../make/Makefile diff --git a/ttcn3-hss-test-ogs/jenkins.sh b/ttcn3-hss-test-ogs/jenkins.sh new file mode 100755 index 000..5ca59a9 --- /dev/null +++ b/ttcn3-hss-test-ogs/jenkins.sh @@ -0,0 +1,72 @@ +#!/bin/sh + +. ../jenkins-common.sh + +IMAGE_SUFFIX="${IMAGE_SUFFIX:-master}" +docker_images_require \ + "open5gs-$IMAGE_SUFFIX" \ + "ttcn3-hss-test-ogs" + +set_clean_up_trap +set -e + +mkdir -p $VOL_BASE_DIR/mongo/db +cp ogs/mongod.conf $VOL_BASE_DIR/mongo/ + +mkdir $VOL_BASE_DIR/hss-tester +cp ogs/HSS_Tests.cfg $VOL_BASE_DIR/hss-tester/ +write_mp_osmo_repo "$VOL_BASE_DIR/hss-tester/HSS_Tests.cfg" + +mkdir $VOL_BASE_DIR/hss +cp ogs/open5gs-*.yaml $VOL_BASE_DIR/hss/ +cp ogs/freediameter.conf $VOL_BASE_DIR/hss/ + +network_create +network_replace_subnet_in_configs + +# start container with mongod in background +docker run --rm --user $(id -u) \ + $(docker_network_params $SUBNET 103) \ + --ulimit core=-1 \ + -v $VOL_BASE_DIR/mongo:/data \ + --name ${BUILD_TAG}-mongo -d \ + $DOCKER_ARGS \ + $REPO_USER/open5gs-$IMAGE_SUFFIX \ + /bin/sh -c "mongod -f /data/mongod.conf >/data/mongod.out 2>&1" + +# mongod needs some time to bootstrap... +while ! nc -z 172.18.$SUBNET.103 27017; do sleep 1; done + +# create a test subscriber with IMSI=0010100 +docker run --rm \ + $(docker_network_params $SUBNET 8) \ + $REPO_USER/open5gs-$IMAGE_SUFFIX \ + open5gs-dbctl --db_uri=mongodb://172.18.$SUBNET.103/open5gs \ + add 0010100 \ + 3c6e0b8a9c15224a8228b9a98ca1531d \ + 762a2206fe0b4151ace403c86a11e479 + +# start container with hss in background +docker run --sysctl net.ipv6.conf.all.disable_ipv6=0 \ + --rm \ + --ulimit core=-1 \ + -v $VOL_BASE_DIR/hss:/data \ + --name ${BUILD_TAG}-ogs-hss -d \ + $DOCKER_ARGS \ + $(docker_network_params $SUBNET 201) \ + $REPO_USER/open5gs-$IMAGE_SUFFIX \ + /bin/sh -c "open5gs-hssd -c /data/open5gs-hss.yaml >/data/open5gs-hssd.out 2>&1" + +# start docker container with testsuite in foreground +docker run --rm \ + --sysctl net.ipv6.conf.all.disable_ipv6=0 \ + $(docker_network_params $SUBNET 202) \ + --ulimit core=-1 \ + -v $VOL_BASE_DIR/hss-tester:/data \ + -e "TTCN3_PCAP_PATH=/data" \ + --name ${BUILD_TAG}-hss-test \ + $DOCKER_ARGS \ + $REPO_USER/ttcn3-hss-test-ogs + +# remove mongodb's database +rm -rf $VOL_BASE_DIR/mongo/db/ diff --git a/ttcn3-hss-test-ogs/ogs/HSS_Tests.cfg b/ttcn3-hss-test-ogs/ogs/HSS_Tests.cfg new file mode 100644 index 000..17fa1a5 --- /dev/null +++ b/ttcn3-hss-test-ogs/ogs/HSS_Tests.cfg @@ -0,0 +1,26 @@ +[ORDERED_INCLUDE] +# Common configuration, shared between test suites +"/osmo-ttcn3-hacks/Common.cfg" +# testsuite specific configuration, not expected to change +"/osmo-ttcn3-hacks/hss/HSS_Tests.default" + +# Loc
[S] Change in osmo-ci[master]: jobs/ttcn3-testsuites.yml: Add ttcn3-hss-test-ogs
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ci/+/34716?usp=email ) Change subject: jobs/ttcn3-testsuites.yml: Add ttcn3-hss-test-ogs .. jobs/ttcn3-testsuites.yml: Add ttcn3-hss-test-ogs Related: SYS#6588 Change-Id: Ic98a5a22b2c10b32052e613d0a46fbc7640c60d9 --- M jobs/ttcn3-testsuites.yml 1 file changed, 16 insertions(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ci refs/changes/16/34716/1 diff --git a/jobs/ttcn3-testsuites.yml b/jobs/ttcn3-testsuites.yml index 4c15f84..80625a5 100644 --- a/jobs/ttcn3-testsuites.yml +++ b/jobs/ttcn3-testsuites.yml @@ -125,7 +125,12 @@ - ttcn3-mme-test-ogs: timer: H 07 * * * description: | -Test open5gs-mme +Test open5gs-mmed + email: jenkins-notificati...@lists.osmocom.org acet...@gmail.com + - ttcn3-hss-test-ogs: + timer: H 07 * * * + description: | +Test open5gs-hssd email: jenkins-notificati...@lists.osmocom.org acet...@gmail.com - ttcn3-dia2gsup-test: timer: H 07 * * * -- To view, visit https://gerrit.osmocom.org/c/osmo-ci/+/34716?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ci Gerrit-Branch: master Gerrit-Change-Id: Ic98a5a22b2c10b32052e613d0a46fbc7640c60d9 Gerrit-Change-Number: 34716 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-MessageType: newchange
[S] Change in osmo-ci[master]: jobs/ttcn3-testsuites.yml: Add ttcn3-hss-test-ogs
Attention is currently required from: osmith. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-ci/+/34716?usp=email ) Change subject: jobs/ttcn3-testsuites.yml: Add ttcn3-hss-test-ogs .. Patch Set 1: (1 comment) Patchset: PS1: I already submitted the changed config, the test is created here: https://jenkins.osmocom.org/jenkins/view/TTCN3/job/ttcn3-hss-test-ogs/ I manually disabled it through jenkins UI meanwhile, until the related docker-playground and osmo-ttcn3 patches get mergd. -- To view, visit https://gerrit.osmocom.org/c/osmo-ci/+/34716?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ci Gerrit-Branch: master Gerrit-Change-Id: Ic98a5a22b2c10b32052e613d0a46fbc7640c60d9 Gerrit-Change-Number: 34716 Gerrit-PatchSet: 1 Gerrit-Owner: pespin Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: osmith Gerrit-Attention: osmith Gerrit-Comment-Date: Tue, 10 Oct 2023 17:31:27 + Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment