Change in libosmo-abis[master]: Include vty command 'pcap' in vty output

2020-11-11 Thread fixeria
fixeria has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmo-abis/+/21118 )

Change subject: Include vty command 'pcap' in vty output
..


Patch Set 1:

(1 comment)

https://gerrit.osmocom.org/c/libosmo-abis/+/21118/1/include/osmocom/abis/e1_input.h
File include/osmocom/abis/e1_input.h:

https://gerrit.osmocom.org/c/libosmo-abis/+/21118/1/include/osmocom/abis/e1_input.h@197
PS1, Line 197:  char *pcap_file;
> I put this here because I do not know how to handle a single "global" 
> variable […]
I think it makes more sense to have a global pointer in e1_input_vty.c, just 
make it 'static'.



--
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/21118
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: I316c3d6a839e84c2f52a148c6b8dd6f5933cf4bf
Gerrit-Change-Number: 21118
Gerrit-PatchSet: 1
Gerrit-Owner: keith 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: keith 
Gerrit-CC: fixeria 
Gerrit-Comment-Date: Thu, 12 Nov 2020 07:17:07 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: keith 
Gerrit-MessageType: comment


Change in libosmo-abis[master]: Include vty command 'pcap' in vty output

2020-11-11 Thread keith
keith has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmo-abis/+/21118 )

Change subject: Include vty command 'pcap' in vty output
..


Patch Set 1: Code-Review-1

(2 comments)

https://gerrit.osmocom.org/c/libosmo-abis/+/21118/1/include/osmocom/abis/e1_input.h
File include/osmocom/abis/e1_input.h:

https://gerrit.osmocom.org/c/libosmo-abis/+/21118/1/include/osmocom/abis/e1_input.h@197
PS1, Line 197:  char *pcap_file;
I put this here because I do not know how to handle a single "global" variable
with talloc, that is, outside of this e1inp_line struct. :-/ :-(
I did not find an example of such a thing in other vtys.

I see two ways to go forward, either implement the command as

pcap <0-255> .FILE

and actually have per line pcaps, or learn how to have a global talloc
var outside the struct.


https://gerrit.osmocom.org/c/libosmo-abis/+/21118/1/src/e1_input_vty.c
File src/e1_input_vty.c:

https://gerrit.osmocom.org/c/libosmo-abis/+/21118/1/src/e1_input_vty.c@255
PS1, Line 255:  int e1_nr = 0;
WIP, Storing the variable on the line struct, see my other comment.



--
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/21118
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: I316c3d6a839e84c2f52a148c6b8dd6f5933cf4bf
Gerrit-Change-Number: 21118
Gerrit-PatchSet: 1
Gerrit-Owner: keith 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: keith 
Gerrit-Comment-Date: Thu, 12 Nov 2020 06:07:11 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmo-abis[master]: Include vty command 'pcap' in vty output

2020-11-11 Thread keith
keith has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/libosmo-abis/+/21118 )


Change subject: Include vty command 'pcap' in vty output
..

Include vty command 'pcap' in vty output

Ensure that a configured pcap command appears in 'show running-config'
and is written to the config file on issuing 'write'

Change-Id: I316c3d6a839e84c2f52a148c6b8dd6f5933cf4bf
---
M include/osmocom/abis/e1_input.h
M src/e1_input_vty.c
2 files changed, 24 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmo-abis refs/changes/18/21118/1

diff --git a/include/osmocom/abis/e1_input.h b/include/osmocom/abis/e1_input.h
index 44708bb..795c83a 100644
--- a/include/osmocom/abis/e1_input.h
+++ b/include/osmocom/abis/e1_input.h
@@ -194,6 +194,7 @@
struct llist_head list;
int refcnt; /* unusued, kept for ABI compat, use_count is used instead 
*/

+   char *pcap_file;
unsigned int num;
const char *name;
unsigned int port_nr;
diff --git a/src/e1_input_vty.c b/src/e1_input_vty.c
index d915c19..cc4bc17 100644
--- a/src/e1_input_vty.c
+++ b/src/e1_input_vty.c
@@ -250,7 +250,15 @@
   "Setup a pcap recording of all E1 traffic\n"
   "Filename to save the packets to\n", CMD_ATTR_IMMEDIATE)
 {
+   struct e1inp_line *line;
int fd;
+   int e1_nr = 0;
+
+   line = e1inp_line_find(e1_nr);
+   if (!line) {
+   vty_out(vty, "%% Line %d doesn't exist%s", e1_nr, VTY_NEWLINE);
+   return CMD_WARNING;
+   }

fd = open(argv[0], O_WRONLY | O_CREAT | O_TRUNC, 0660);
if (fd < 0) {
@@ -259,6 +267,11 @@
}

e1_set_pcap_fd(fd);
+   if (line->pcap_file) {
+   talloc_free((void *)line->pcap_file);
+   line->pcap_file = NULL;
+   }
+   line->pcap_file = talloc_strdup(line, argv[0]);

return CMD_SUCCESS;
 }
@@ -268,7 +281,15 @@
   NO_STR "Disable pcap recording of all E1 traffic\n",
   CMD_ATTR_IMMEDIATE)
 {
+   struct e1inp_line *line;
+   int e1_nr = 0;
+   line = e1inp_line_find(e1_nr);
+
e1_set_pcap_fd(-1);
+   if (line->pcap_file) {
+   talloc_free((void *)line->pcap_file);
+   line->pcap_file = NULL;
+   }
return CMD_SUCCESS;
 }

@@ -329,6 +350,8 @@
vty_out(vty, " e1_line %u ipa-keepalive %d %d%s", 
line->num,
line->ipa_kap->interval, 
line->ipa_kap->wait_for_resp,
VTY_NEWLINE);
+   if (line->pcap_file)
+   vty_out(vty, " pcap %s%s", line->pcap_file, 
VTY_NEWLINE);
}

const char *ipa_bind = e1inp_ipa_get_bind_addr();

--
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/21118
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: I316c3d6a839e84c2f52a148c6b8dd6f5933cf4bf
Gerrit-Change-Number: 21118
Gerrit-PatchSet: 1
Gerrit-Owner: keith 
Gerrit-MessageType: newchange


Change in osmo-bts[master]: l1sap: add repeated downlink FACCH

2020-11-11 Thread fixeria
fixeria has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/21014 )

Change subject: l1sap: add repeated downlink FACCH
..


Patch Set 5:

(2 comments)

https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/l1sap.c
File src/common/l1sap.c:

https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/l1sap.c@932
PS5, Line 932: 2715648
> I'm sure we have some proper defines or macros related to that and we should 
> not resort to magic num […]
Indeed, I even mentioned them in my previous comments. This:

  (msg.fn + 8) % 2715648 <= fn

could be done with:

  GSM_TDMA_FN_SUM(msg.fn, 8) <= fn.

Or the whole condition can be rewritten (not sure, please re-check):

  GSM_TDMA_FN_SUB(fn, msg.fn) >= 8.

The last variant looks cleaner and closer to what the specs. require to me.


https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/vty.c
File src/common/vty.c:

https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/vty.c@805
PS5, Line 805: "facch-repetition",
> why would we ant to have a configuration item for that in the BTS?  Shouldn't 
> it be the policy of th […]
Ack



--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21014
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I72f0cf7eaaef9f80fc35e752c90ae0e2d24d0c75
Gerrit-Change-Number: 21014
Gerrit-PatchSet: 5
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: fixeria 
Gerrit-CC: laforge 
Gerrit-Comment-Date: Thu, 12 Nov 2020 02:52:19 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge 
Gerrit-MessageType: comment


Build failure of network:osmocom:nightly/simtrace2 in xUbuntu_20.10/x86_64

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/simtrace2/xUbuntu_20.10/x86_64

Package network:osmocom:nightly/simtrace2 failed to build in 
xUbuntu_20.10/x86_64

Check out the package for editing:
  osc checkout network:osmocom:nightly simtrace2

Last lines of build log:
[  327s] [COMPILING apps/dfu/main.c]
[  327s] [COMPILING ./atmel_softpack_libraries/usb/device/dfu/dfu.c]
[  327s] [COMPILING ./atmel_softpack_libraries/usb/device/dfu/dfu_desc.c]
[  328s] [COMPILING ./atmel_softpack_libraries/usb/device/dfu/dfu_driver.c]
[  328s] Memory region Used Size  Region Size  %age Used
[  328s]  rom:   16580 B16 KB101.20%
[  328s]  ram:   11672 B48 KB 
23.75/usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: warning: 
changing start of section .stack by 4 bytes
[  328s] /usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: 
warning: changing start of section .stack by 4 bytes
[  328s] /usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: 
bin/qmod-dfu-flash.elf section `.text' will not fit in region `rom'
[  328s] /usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: 
warning: changing start of section .stack by 4 bytes
[  328s] /usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: 
warning: changing start of section .stack by 4 bytes
[  328s] /usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: 
warning: changing start of section .stack by 4 bytes
[  328s] /usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: region 
`rom' overflowed by 196 bytes
[  328s] collect2: error: ld returned 1 exit status
[  328s] %
[  328s] make[2]: *** [Makefile:234: flash] Error 1
[  328s] make[2]: Leaving directory '/usr/src/packages/BUILD/firmware'
[  328s] make[1]: *** [Makefile:13: fw-qmod-dfu] Error 2
[  328s] make[1]: Leaving directory '/usr/src/packages/BUILD'
[  328s] dh_auto_build: error: make -j1 returned exit code 2
[  328s] make: *** [debian/rules:16: build] Error 25
[  328s] dpkg-buildpackage: error: debian/rules build subprocess returned exit 
status 2
[  328s] ### VM INTERACTION START ###
[  331s] [  314.470224] sysrq: Power Off
[  331s] [  314.509471] reboot: Power down
[  331s] ### VM INTERACTION END ###
[  331s] 
[  331s] lamb62 failed "build simtrace2_0.7.0.69.aadd.dsc" at Thu Nov 12 
02:08:49 UTC 2020.
[  331s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Build failure of network:osmocom:nightly/simtrace2 in xUbuntu_20.04/x86_64

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/simtrace2/xUbuntu_20.04/x86_64

Package network:osmocom:nightly/simtrace2 failed to build in 
xUbuntu_20.04/x86_64

Check out the package for editing:
  osc checkout network:osmocom:nightly simtrace2

Last lines of build log:
[  252s] [COMPILING libboard/qmod/source/wwan_perst.c]
[  252s] [COMPILING libboard/qmod/source/card_pres.c]
[  252s] [COMPILING libboard/qmod/source/wwan_led.c]
[  252s] [COMPILING libboard/qmod/source/i2c.c]
[  252s] [COMPILING libboard/qmod/source/board_qmod.c]
[  253s] [COMPILING apps/dfu/main.c]
[  253s] [COMPILING ./atmel_softpack_libraries/usb/device/dfu/dfu.c]
[  253s] [COMPILING ./atmel_softpack_libraries/usb/device/dfu/dfu_desc.c]
[  253s] [COMPILING ./atmel_softpack_libraries/usb/device/dfu/dfu_driver.c]
[  253s] Memory region Used Size  Region Size  %age Used
[  253s]  rom:   16588 B16 KB101.25%
[  253s]  ram:   11672 B48 KB 
23.75/usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: 
bin/qmod-dfu-flash.elf section `.text' will not fit in region `rom'
[  253s] /usr/lib/gcc/arm-none-eabi/9.2.1/../../../arm-none-eabi/bin/ld: region 
`rom' overflowed by 204 bytes
[  253s] collect2: error: ld returned 1 exit status
[  253s] %
[  253s] make[2]: *** [Makefile:234: flash] Error 1
[  253s] make[2]: Leaving directory '/usr/src/packages/BUILD/firmware'
[  253s] make[1]: *** [Makefile:13: fw-qmod-dfu] Error 2
[  253s] make[1]: Leaving directory '/usr/src/packages/BUILD'
[  253s] dh_auto_build: error: make -j1 returned exit code 2
[  253s] make: *** [debian/rules:16: build] Error 25
[  253s] dpkg-buildpackage: error: debian/rules build subprocess returned exit 
status 2
[  253s] ### VM INTERACTION START ###
[  257s] [  242.707801] sysrq: Power Off
[  257s] [  242.739204] reboot: Power down
[  257s] ### VM INTERACTION END ###
[  257s] 
[  257s] lamb53 failed "build simtrace2_0.7.0.69.aadd.dsc" at Thu Nov 12 
02:07:20 UTC 2020.
[  257s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Change in osmo-ccid-firmware[master]: sercom: make waiting for the uart safe...

2020-11-11 Thread Hoernchen
Hoernchen has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/21116 )


Change subject: sercom: make waiting for the uart safe...
..

sercom: make waiting for the uart safe...

In error cases the uart might already be disabled, so waiting for the
dre bit does not work.

Change-Id: I269cf8ece48df24c9f1fcb262ef4ddd06cbe3d62
---
M sysmoOCTSIM/cuart_driver_asf4_usart_async.c
1 file changed, 8 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ccid-firmware 
refs/changes/16/21116/1

diff --git a/sysmoOCTSIM/cuart_driver_asf4_usart_async.c 
b/sysmoOCTSIM/cuart_driver_asf4_usart_async.c
index e6d180c..64ec9f2 100644
--- a/sysmoOCTSIM/cuart_driver_asf4_usart_async.c
+++ b/sysmoOCTSIM/cuart_driver_asf4_usart_async.c
@@ -5,6 +5,7 @@
 #include 
 #include 

+#include 
 #include 
 #include 
 #include "driver_init.h"
@@ -228,8 +229,13 @@
cuart->u.asf4.extrawait_after_rx = 1./baudrate * 1000 * 1000;

printf("(%u) switching SERCOM clock to GCLK%u (freq = %lu kHz) and baud 
rate to %lu bps (baud = %u)\r\n", slotnr, (best + 1) * 2, 
(uint32_t)(round(sercom_glck_freqs[best] / 1000)), baudrate, bauds[best]);
-   while (!usart_async_is_tx_empty(slot)); // wait for transmission to 
complete (WARNING no timeout)
-   usart_async_disable(slot); // disable SERCOM peripheral
+
+   /* only wait if the uart is enabled */
+   if (hri_sercomusart_get_CTRLA_reg(slot->device.hw, 
SERCOM_USART_CTRLA_ENABLE)) {
+   while (!usart_async_is_tx_empty(slot)); // wait for 
transmission to complete (WARNING no timeout)
+   usart_async_disable(slot); // disable SERCOM peripheral
+   }
+
hri_gclk_clear_PCHCTRL_reg(GCLK, SIM_peripheral_GCLK_ID[slotnr], (1 << 
GCLK_PCHCTRL_CHEN_Pos)); // disable clock for this peripheral
while (hri_gclk_get_PCHCTRL_reg(GCLK, SIM_peripheral_GCLK_ID[slotnr], 
(1 << GCLK_PCHCTRL_CHEN_Pos))); // wait until clock is really disabled
// it does not seem we need to completely disable the peripheral using 
hri_mclk_clear_APBDMASK_SERCOMn_bit

--
To view, visit https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/21116
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-Change-Id: I269cf8ece48df24c9f1fcb262ef4ddd06cbe3d62
Gerrit-Change-Number: 21116
Gerrit-PatchSet: 1
Gerrit-Owner: Hoernchen 
Gerrit-MessageType: newchange


Change in osmo-ccid-firmware[master]: asf4 uart: properly handle uart errors

2020-11-11 Thread Hoernchen
Hoernchen has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/21117 )


Change subject: asf4 uart: properly handle uart errors
..

asf4 uart: properly handle uart errors

Uart will now lead to a (temporary) deactivation of the uart as well as
the deactivatin of the card + a a proper ccid response to notify the
host if the slot was busy.

Change-Id: Ia0efef03829b68d2b4f25899bb933b14fb9e0bd1
---
M ccid_common/ccid_slot_fsm.c
M ccid_common/cuart.h
M ccid_common/iso7816_fsm.c
M sysmoOCTSIM/cuart_driver_asf4_usart_async.c
4 files changed, 97 insertions(+), 21 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ccid-firmware 
refs/changes/17/21117/1

diff --git a/ccid_common/ccid_slot_fsm.c b/ccid_common/ccid_slot_fsm.c
index 4cf75bc..8dccfa5 100644
--- a/ccid_common/ccid_slot_fsm.c
+++ b/ccid_common/ccid_slot_fsm.c
@@ -147,12 +147,18 @@
msgb_free(msg);
/* continues in iso_fsm_clot_user_cb once ATR is received */
 }
+
 static void iso_fsm_clot_user_cb(struct osmo_fsm_inst *fi, int event, int 
cause, void *data)
 {
struct iso_fsm_slot *ss = iso7816_fsm_get_user_priv(fi);
struct ccid_slot *cs = ss->cs;

switch (event) {
+   /* special case: not handled as a normal callback below, in case slot 
was busy the fsm will
+* additionally emit a proper error event handled below to notify the 
host */
+   case ISO7816_E_HW_ERR_IND:
+   card_uart_ctrl(ss->cuart, CUART_CTL_NO_RXTX, true);
+   break;
case ISO7816_E_ATR_DONE_IND:
case ISO7816_E_ATR_ERR_IND:
case ISO7816_E_TPDU_DONE_IND:
@@ -219,10 +225,14 @@
break;
case ISO7816_E_ATR_ERR_IND:
tpdu = data;
-   LOGPCS(cs, LOGL_DEBUG, "%s(event=%d, data=%s)\n", __func__, 
event,
-   msgb_hexdump(tpdu));
-   resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_FAILED, 
CCID_ERR_ICC_MUTE,
-  msgb_data(tpdu), msgb_length(tpdu));
+   LOGPCS(cs, LOGL_DEBUG, "%s(event=%d, data=%s)\n", __func__, 
event, msgb_hexdump(tpdu));
+
+   /* perform deactivation */
+   card_uart_ctrl(ss->cuart, CUART_CTL_RST, true);
+   card_uart_ctrl(ss->cuart, CUART_CTL_POWER_5V0, false);
+   cs->icc_powered = false;
+
+   resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_FAILED, 
CCID_ERR_ICC_MUTE, msgb_data(tpdu), msgb_length(tpdu));
ccid_slot_send_unbusy(cs, resp);
cs->event = 0;
break;
@@ -237,8 +247,13 @@
break;
case ISO7816_E_TPDU_FAILED_IND:
tpdu = data;
-   LOGPCS(cs, LOGL_DEBUG, "%s(event=%d, data=%s)\n", __func__, 
event,
-   msgb_hexdump(tpdu));
+
+   /* perform deactivation */
+   card_uart_ctrl(ss->cuart, CUART_CTL_RST, true);
+   card_uart_ctrl(ss->cuart, CUART_CTL_POWER_5V0, false);
+   cs->icc_powered = false;
+
+   LOGPCS(cs, LOGL_DEBUG, "%s(event=%d, data=%s)\n", __func__, 
event, msgb_hexdump(tpdu));
/* FIXME: other error causes than card removal?*/
resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_FAILED, 
CCID_ERR_ICC_MUTE, msgb_l2(tpdu), 0);
ccid_slot_send_unbusy(cs, resp);
diff --git a/ccid_common/cuart.h b/ccid_common/cuart.h
index c0a3a52..c8573c5 100644
--- a/ccid_common/cuart.h
+++ b/ccid_common/cuart.h
@@ -36,6 +36,7 @@
CUART_E_RX_TIMEOUT,
/* an entire block of data was written, as instructed in prior 
card_uart_tx() call */
CUART_E_TX_COMPLETE,
+   CUART_E_HW_ERROR, /* might be uart parity or mystery error, might be 
something else */
 };

 extern const struct value_string card_uart_event_vals[];
diff --git a/ccid_common/iso7816_fsm.c b/ccid_common/iso7816_fsm.c
index 8e113b0..7207245 100644
--- a/ccid_common/iso7816_fsm.c
+++ b/ccid_common/iso7816_fsm.c
@@ -276,6 +276,9 @@
case CUART_E_TX_COMPLETE:
osmo_fsm_inst_dispatch(fi, ISO7816_E_TX_COMPL, data);
break;
+   case CUART_E_HW_ERROR:
+   osmo_fsm_inst_dispatch(fi, ISO7816_E_HW_ERR_IND, data);
+   break;
}
 }

@@ -361,7 +364,7 @@
struct iso7816_3_priv *ip = get_iso7816_3_priv(fi);
OSMO_ASSERT(fi->fsm == _3_fsm);
card_uart_ctrl(ip->uart, CUART_CTL_RX_TIMER_HINT, 0);
-   card_uart_ctrl(ip->uart, CUART_CTL_NO_RXTX, true);
+
/* reset the TPDU state machine */
osmo_fsm_inst_dispatch(ip->tpdu_fi, ISO7816_E_TPDU_CLEAR_REQ, NULL);
 }
@@ -424,6 +427,9 @@

switch (event) {
case ISO7816_E_HW_ERR_IND:
+   /* deactivates uart, then continues with the callbacks below 
for proper error reporting */
+   

Build failure of network:osmocom:nightly/libosmocore in Debian_9.0/armv7l

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/libosmocore/Debian_9.0/armv7l

Package network:osmocom:nightly/libosmocore failed to build in Debian_9.0/armv7l

Check out the package for editing:
  osc checkout network:osmocom:nightly libosmocore

Last lines of build log:
[  694s] | #  - CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH: --gcov-tool pathtogcov
[  694s] | #  - CODE_COVERAGE_LCOV_RMOPTS: Extra options to pass to the 
filtering lcov
[  694s] | #  - CODE_COVERAGE_LCOV_RMOPTS_DEFAULT: Extra options to pass to the 
filtering
[  694s] | #  - CODE_COVERAGE_LCOV_SHOPTS: Extra options to shared between both 
lcov
[  694s] | #  - CODE_COVERAGE_LCOV_SHOPTS_DEFAULT: Extra options shared between 
both lcov
[  694s] | #  - CODE_COVERAGE_OUTPUT_DIRECTORY: Directory for generated code 
coverage
[  694s] | #  - CODE_COVERAGE_OUTPUT_FILE: Filename and path for the .info file 
generated
[  694s] | # $(PACKAGE_VERSION). In order to add the current git hash to the 
title,
[  694s] | # Capture code coverage data
[  694s] | # Code coverage
[  694s] | # Hook rule executed before code-coverage-capture, overridable by 
the user
[  694s] | # Optional variables
[  694s] | # Optional:
[  694s] | # The generated report will be titled using the $(PACKAGE_NAME) and
[  694s] | # Use recursive makes in order to ignore errors during check
[  694s] | # sanitizes the test-name: replaces with underscores: dashes and dots
[  694s] | # use the git-version-gen script, available online.
[  694s] | $(if $(CODE_COVERAGE_BRANCH_COVERAGE),\
[  694s] | '
[  694s] | --rc genhtml_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE))
[  694s] | --rc lcov_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE))
[  694s] | .PHONY: check-code-coverage code-coverage-capture 
code-coverage-capture-hook code-coverage-clean
[  694s] | .PHONY: code-coverage-cobertura
[  696s] | ACLOCAL='${SHELL} /usr/src/packages/BU[  662.544499] sysrq: SysRq : 
Power Off
[  696s] [  662.546852] reboot: Power down
[  697s] ### VM INTERACTION END ###
[  697s] 
[  697s] armbuild01 failed "build libosmocore_1.4.0.186.c211.dsc" at Thu Nov 12 
01:46:36 UTC 2020.
[  697s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Build failure of network:osmocom:nightly/libosmocore in Debian_10/armv7l

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/libosmocore/Debian_10/armv7l

Package network:osmocom:nightly/libosmocore failed to build in Debian_10/armv7l

Check out the package for editing:
  osc checkout network:osmocom:nightly libosmocore

Last lines of build log:
[  666s] | configure:9703: checking for backtrace in -lexecinfo
[  666s] | configure:9728: gcc -o conftest -g -O2 
-fdebug-prefix-map=/usr/src/packages/BUILD=. -fstack-protector-strong -Wformat 
-Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -Wl,-z,relro -Wl,-z,now 
conftest.c -lexecinfo   >&5
[  666s] | /usr/bin/ld: cannot find -lexecinfo
[  666s] | collect2: error: ld returned 1 exit status
[  666s] | configure:9728: $? = 1
[  666s] | configure: failed program was:
[  666s] | | /* confdefs.h */
[  666s] | | #define PACKAGE_NAME "libosmocore"
[  666s] | | #define PACKAGE_TARNAME "libosmocore"
[  666s] | | #define PACKAGE_VERSION "1.4.0.186-c211"
[  666s] | | #define PACKAGE_STRING "libosmocore 1.4.0.186-c211"
[  666s] | | #define PACKAGE_BUGREPORT "open...@lists.osmocom.org"
[  666s] | | #define PACKAGE_URL ""
[  666s] | | #define PACKAGE "libosmocore"
[  666s] | | #define VERSION "1.4.0.186-c211"
[  666s] | | #define STDC_HEADERS 1
[  666s] | | #define HAVE_SYS_TYPES_H 1
[  666s] | | #define HAVE_SYS_STAT_H 1
[  666s] | | #define HAVE_STDLIB_H 1
[  666s] | | #define HAVE_STRING_H 1
[  666s] | | #define HAVE_MEMORY_H 1
[  666s] | | #define HAVE_STRINGS_H 1
[  666s] | | #define HAVE_INTTYPES_H 1
[  668s] | | #define HAVE_ST[  634.561366] sysrq: Power Off
[  668s] [  634.563008] reboot: Power down
[  669s] ### VM INTERACTION END ###
[  669s] 
[  669s] armbuild16 failed "build libosmocore_1.4.0.186.c211.dsc" at Thu Nov 12 
01:46:09 UTC 2020.
[  669s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Build failure of network:osmocom:nightly/libosmocore in Raspbian_10/armv7l

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/libosmocore/Raspbian_10/armv7l

Package network:osmocom:nightly/libosmocore failed to build in 
Raspbian_10/armv7l

Check out the package for editing:
  osc checkout network:osmocom:nightly libosmocore

Last lines of build log:
[  715s] | 
[  715s] | ## -- ##
[  715s] | ## Running config.status. ##
[  715s] | ## -- ##
[  715s] | 
[  715s] | This file was extended by libosmocore config.status 1.4.0.186-c211, 
which was
[  715s] | generated by GNU Autoconf 2.69.  Invocation command line was
[  715s] | 
[  715s] |   CONFIG_FILES= 
[  715s] |   CONFIG_HEADERS  = 
[  715s] |   CONFIG_LINKS= 
[  715s] |   CONFIG_COMMANDS = 
[  715s] |   $ ./config.status Doxyfile.core
[  715s] | 
[  715s] | on obs-arm-6
[  715s] | 
[  715s] | config.status:1347: creating Doxyfile.core
[  715s] 
[  715s] make[1]: *** [debian/rules:26: override_dh_auto_test] Error 1
[  715s] make[1]: Leaving directory '/usr/src/packages/BUILD'
[  715s] make: *** [debian/rules:15: build] Error 2
[  715s] dpkg-buildpackage: error: debian/rules build subprocess returned exit 
status 2
[  715s] ### VM INTERACTION START ###
[  717s] [  690.515600] sysrq: SysRq : Power Off
[  717s] [  690.522952] reboot: Power down
[  718s] ### VM INTERACTION END ###
[  718s] 
[  718s] obs-arm-6 failed "build libosmocore_1.4.0.186.c211.dsc" at Thu Nov 12 
01:43:16 UTC 2020.
[  718s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Build failure of network:osmocom:nightly/libosmocore in Debian_8.0/i586

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/libosmocore/Debian_8.0/i586

Package network:osmocom:nightly/libosmocore failed to build in Debian_8.0/i586

Check out the package for editing:
  osc checkout network:osmocom:nightly libosmocore

Last lines of build log:
[  395s] | ac_cv_env_LIBUSB_CFLAGS_set=
[  395s] | ac_cv_env_LIBUSB_CFLAGS_value=
[  395s] | ac_cv_env_LIBUSB_LIBS_set=
[  395s] | ac_cv_env_LIBUSB_LIBS_value=
[  395s] | ac_cv_env_PCSC_CFLAGS_set=
[  395s] | ac_cv_env_PCSC_CFLAGS_value=
[  395s] | ac_cv_env_PCSC_LIBS_set=
[  395s] | ac_cv_env_PCSC_LIBS_value=
[  395s] | ac_cv_env_PKG_CONFIG_LIBDIR_set=
[  395s] | ac_cv_env_PKG_CONFIG_LIBDIR_value=
[  395s] | ac_cv_env_PKG_CONFIG_PATH_set=
[  395s] | ac_cv_env_PKG_CONFIG_PATH_value=
[  395s] | ac_cv_env_PKG_CONFIG_set=
[  395s] | ac_cv_env_PKG_CONFIG_value=
[  395s] | ac_cv_env_PYTHON_set=
[  395s] | ac_cv_env_PYTHON_value=
[  395s] | ac_cv_env_SYSTEMD_CFLAGS_set=
[  395s] | ac_cv_env_SYSTEMD_CFLAGS_value=
[  395s] | ac_cv_env_SYSTEMD_LIBS_set=
[  395s] | ac_cv_env_SYSTEMD_LIBS_value=
[  395s] | ac_cv_env_TALLOC_CFLAGS_set=
[  395s] | ac_cv_env_TALLOC_CFLAGS_value=
[  395s] | ac_cv_env_TALLOC_LIBS_set=
[  395s] | ac_cv_ePowering off.
[  395s] [  386.068095] reboot: Power down
[  395s] ### VM INTERACTION END ###
[  395s] 
[  395s] lamb21 failed "build libosmocore_1.4.0.186.c211.dsc" at Thu Nov 12 
01:40:55 UTC 2020.
[  395s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Build failure of network:osmocom:nightly/libosmocore in Debian_9.0/i586

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/libosmocore/Debian_9.0/i586

Package network:osmocom:nightly/libosmocore failed to build in Debian_9.0/i586

Check out the package for editing:
  osc checkout network:osmocom:nightly libosmocore

Last lines of build log:
[  331s] | ## Running config.status. ##
[  331s] | ## -- ##
[  331s] | 
[  331s] | This file was extended by libosmocore config.status 1.4.0.186-c211, 
which was
[  331s] | generated by GNU Autoconf 2.69.  Invocation command line was
[  331s] | 
[  331s] |   CONFIG_FILES= 
[  331s] |   CONFIG_HEADERS  = 
[  331s] |   CONFIG_LINKS= 
[  331s] |   CONFIG_COMMANDS = 
[  331s] |   $ ./config.status Doxyfile.core
[  331s] | 
[  331s] | on lamb16
[  331s] | 
[  331s] | config.status:1355: creating Doxyfile.core
[  331s] 
[  331s] debian/rules:26: recipe for target 'override_dh_auto_test' failed
[  331s] make[1]: *** [override_dh_auto_test] Error 1
[  331s] make[1]: Leaving directory '/usr/src/packages/BUILD'
[  331s] debian/rules:15: recipe for target 'build' failed
[  331s] make: *** [build] Error 2
[  331s] dpkg-buildpackage: error: debian/rules build gave error exit status 2
[  331s] ### VM INTERACTION START ###
[  334s] [  324.030762] sysrq: Power Off
[  334s] [  324.036612] reboot: Power down
[  334s] ### VM INTERACTION END ###
[  334s] 
[  334s] lamb16 failed "build libosmocore_1.4.0.186.c211.dsc" at Thu Nov 12 
01:39:43 UTC 2020.
[  334s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Build failure of network:osmocom:nightly/libosmocore in Debian_10/i586

2020-11-11 Thread OBS Notification
Visit 
https://build.opensuse.org/package/live_build_log/network:osmocom:nightly/libosmocore/Debian_10/i586

Package network:osmocom:nightly/libosmocore failed to build in Debian_10/i586

Check out the package for editing:
  osc checkout network:osmocom:nightly libosmocore

Last lines of build log:
[  276s] 57. testsuite.at:363: testing tdef ...
[  276s] ./testsuite.at:366: $abs_top_builddir/tests/tdef/tdef_test
[  276s] stderr:
[  276s] DLGLOBAL tdef_test(test_tdef_state_timeout)[0x57f435a0]{Z}: transition 
to state B not permitted!
[  276s] DLGLOBAL tdef_test(test_tdef_state_timeout)[0x57f435a0]{Z}: transition 
to state C not permitted!
[  276s] DLGLOBAL tdef_test(test_tdef_state_timeout)[0x57f435a0]{Z}: transition 
to state D not permitted!
[  276s] --- expout 2020-11-12 01:38:56.101270971 +
[  276s] +++ /usr/src/packages/BUILD/tests/testsuite.dir/at-groups/57/stdout
2020-11-12 01:38:56.105270971 +
[  276s] @@ -17,7 +17,7 @@
[  276s]  osmo_tdef_get(3, ms)  = 600
[  276s]  osmo_tdef_get(3, m)   = 100
[  276s]  osmo_tdef_get(3, custom-unit) = 100
[  276s] -osmo_tdef_get(3, us)  = 60
[  276s] +osmo_tdef_get(3, us)  = 4294967295
[  276s]  T4=100custom-unit
[  276s]  osmo_tdef_get(4, s)   = 100
[  276s]  osmo_tdef_get(4, ms)  = 100
[  276s] 57. testsuite.at:363: 57. tdef (testsuite.at:363): FAILED 
(testsuite.at:366)
[  276s] make[1]: *** [debian/rules:26: override_dh_auto_test] Error 1
[  276s] make[1]: Leaving directory '/usr/src/packages/BUILD'
[  276s] make: *** [debian/rules:15: build] Error 2
[  276s] dpkg-buildpackage: error: debian/rules build subprocess returned exit 
status 2
[  276s] ### VM INTERACTION START ###
[  279s] [  268.274276] sysrq: Power Off
[  279s] [  268.276562] reboot: Power down
[  279s] ### VM INTERACTION END ###
[  279s] 
[  279s] hci-cnode2-m0 failed "build libosmocore_1.4.0.186.c211.dsc" at Thu Nov 
12 01:39:02 UTC 2020.
[  279s] 

-- 
Configure notifications at https://build.opensuse.org/my/subscriptions
openSUSE Build Service (https://build.opensuse.org/)


Change in docker-playground[master]: NS_Configuration: Adjust config regarding support for NS-VCG

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/docker-playground/+/2 )

Change subject: NS_Configuration: Adjust config regarding support for NS-VCG
..


Patch Set 1: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/2
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I6ac250555c3ac2aa8feb70bd3a052aafec5d4210
Gerrit-Change-Number: 2
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:46:54 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: FR/FRNET: Dynamically create number of BVC at runtime

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21110 )

Change subject: FR/FRNET: Dynamically create number of BVC at runtime
..


Patch Set 2: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21110
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I55b44481b5322deaf78619c1689462d716ddfcec
Gerrit-Change-Number: 21110
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:46:15 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: NS_Emulation: Introduce Load Sharing Function

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21109 )

Change subject: NS_Emulation: Introduce Load Sharing Function
..


Patch Set 2: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21109
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I8b960ec4d729f50cadca353bb52685311cd45eed
Gerrit-Change-Number: 21109
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: lynxis lazus 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:45:05 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: NS+BSSGP: Only send BVC-RESET when _first_ NSVC of NSVCG becomes unbl...

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21108 )

Change subject: NS+BSSGP: Only send BVC-RESET when _first_ NSVC of NSVCG 
becomes unblocked
..


Patch Set 2: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21108
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I69b2e9bd919fc981f189b6671b4234c3642e2449
Gerrit-Change-Number: 21108
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:39:29 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: BSSGP_Emulation: Match on proper NSEI from NS layer

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21107 )

Change subject: BSSGP_Emulation: Match on proper NSEI from NS layer
..


Patch Set 2: Code-Review+1

(1 comment)

https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21107/2/library/BSSGP_Emulation.ttcnpp
File library/BSSGP_Emulation.ttcnpp:

https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21107/2/library/BSSGP_Emulation.ttcnpp@362
PS2, Line 362:  [] BSCP.receive(NsStatusIndication:{g_cfg.nsei,?, complement 
(NSVC_S_ALIVE_UNBLOCKED), NSVC_S_ALIVE_UNBLOCKED}) -> value nsi {
missing space beween nsei and ?.
BTW, what's this complement thing?



--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21107
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I682574bc54b4432357adef2b4662b1f74495578c
Gerrit-Change-Number: 21107
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:28:53 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: NS_Emulation: Support multiple NS-VC within one NSE (NS-VCG)

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21087 )

Change subject: NS_Emulation: Support multiple NS-VC within one NSE (NS-VCG)
..


Patch Set 3: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21087
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: If1220852785853f8a5d8de183d5053ddd6ccb958
Gerrit-Change-Number: 21087
Gerrit-PatchSet: 3
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:25:34 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmocore[master]: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21115 )

Change subject: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"
..

Revert "gsm_04_08: add parser for Mobile Station Classmark 3"

This reverts commit a4939dc8461c0a2d8e67aa3bb95bfb73ad9225b7,
which caused massive build failures in C++ programs like osmo-pcu
- unsurprisingly, as it calls a struct member "class", which is a
reserved keyword in C++.

Change-Id: Ia43e56385e7b580f492c560aee8ff8b1e8a0e1d8
---
M include/osmocom/gsm/gsm48_ie.h
M include/osmocom/gsm/protocol/gsm_04_08.h
M src/gsm/gsm48_ie.c
M src/gsm/libosmogsm.map
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
6 files changed, 0 insertions(+), 960 deletions(-)

Approvals:
  pespin: Looks good to me, approved
  laforge: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/include/osmocom/gsm/gsm48_ie.h b/include/osmocom/gsm/gsm48_ie.h
index b79cbfc..339aa13 100644
--- a/include/osmocom/gsm/gsm48_ie.h
+++ b/include/osmocom/gsm/gsm48_ie.h
@@ -119,7 +119,3 @@
 /* decode "Cell Channel Description" (10.5.2.1b) and other frequency lists */
 int gsm48_decode_freq_list(struct gsm_sysinfo_freq *f, uint8_t *cd,
   uint8_t len, uint8_t mask, uint8_t frqt);
-
-/* decode "CSN.1 encoded Classmark 3" (10.5.1.7) */
-int gsm48_decode_classmark3(struct gsm48_classmark3 *classmark3_out,
-   const uint8_t *classmark3, size_t classmark3_len);
diff --git a/include/osmocom/gsm/protocol/gsm_04_08.h 
b/include/osmocom/gsm/protocol/gsm_04_08.h
index 2093bee..df13b15 100644
--- a/include/osmocom/gsm/protocol/gsm_04_08.h
+++ b/include/osmocom/gsm/protocol/gsm_04_08.h
@@ -58,175 +58,6 @@
 #endif
 } __attribute__ ((packed));

-/* Chapter 10.5.1.7 */
-struct gsm48_classmark3 {
-   uint8_t a5_bits;
-   uint8_t mult_band_supp;
-   uint8_t assoc_radio_cap_1;
-   uint8_t assoc_radio_cap_2;
-
-   struct {
-   bool present;
-   uint8_t r_gsm_assoc_radio_cap;
-   } r_support;
-
-   struct {
-   bool present;
-   uint8_t class;
-   } hscsd_mult_slot_cap;
-
-   bool ucs2_treatment;
-   bool extended_meas_cap;
-
-   struct {
-   bool present;
-   uint8_t sms_value;
-   uint8_t sm_value;
-   } ms_meas_cap;
-
-   struct {
-   bool present;
-   uint8_t method;
-   } ms_pos_method_cap;
-
-   struct {
-   bool present;
-   uint8_t class;
-   } ecsd_multislot_cap;
-
-   struct {
-   bool present;
-   bool mod_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } rf_pwr_cap_1;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } rf_pwr_cap_2;
-
-   } psk8_struct;
-
-   struct {
-   bool present;
-   uint8_t value;
-   uint8_t assoc_radio_cap;
-   } gsm_400_bands_supp;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } gsm_850_assoc_radio_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } gsm_1900_assoc_radio_cap;
-
-   bool umts_fdd_rat_cap;
-   bool umts_tdd_rat_cap;
-   bool cdma200_rat_cap;
-
-   struct {
-   bool present;
-   uint8_t class;
-   bool single_slot_dtm;
-   struct {
-   bool present;
-   uint8_t class;
-   } dtm_egprs_multislot_cap;
-   } dtm_gprs_multislot_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } single_band_supp;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } gsm_750_assoc_radio_cap;
-
-   bool umts_1_28_mcps_tdd_rat_cap;
-   bool geran_feature_package;
-
-   struct {
-   bool present;
-   uint8_t class;
-   struct {
-   bool present;
-   uint8_t class;
-   } extended_dtm_egprs_multislot_cap;
-   } extended_dtm_gprs_multislot_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } high_multislot_cap;
-
-   bool geran_feature_package_2;
-   uint8_t gmsk_multislot_power_prof;
-   uint8_t psk8_multislot_power_prof;
-
-   struct {
-   bool present;
-   uint8_t value;
-   uint8_t assoc_radio_cap;
-   } t_gsm_400_bands_supp;
-
-   uint8_t dl_advanced_rx_perf;
-   bool dtm_enhancements_cap;
-
-   struct {
-   bool present;
-   uint8_t class;
-   bool offset_required;
-   struct 

Change in libosmocore[master]: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21115 )

Change subject: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/21115
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ia43e56385e7b580f492c560aee8ff8b1e8a0e1d8
Gerrit-Change-Number: 21115
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: dexter 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-CC: Jenkins Builder
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:13:22 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmocore[master]: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21115 )

Change subject: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/21115
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ia43e56385e7b580f492c560aee8ff8b1e8a0e1d8
Gerrit-Change-Number: 21115
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: pespin 
Gerrit-CC: Jenkins Builder
Gerrit-Comment-Date: Wed, 11 Nov 2020 22:12:56 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmocore[master]: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21115 )


Change subject: Revert "gsm_04_08: add parser for Mobile Station Classmark 3"
..

Revert "gsm_04_08: add parser for Mobile Station Classmark 3"

This reverts commit a4939dc8461c0a2d8e67aa3bb95bfb73ad9225b7,
which caused massive build failures in C++ programs like osmo-pcu
- unsurprisingly, as it calls a struct member "class", which is a
reserved keyword in C++.

Change-Id: Ia43e56385e7b580f492c560aee8ff8b1e8a0e1d8
---
M include/osmocom/gsm/gsm48_ie.h
M include/osmocom/gsm/protocol/gsm_04_08.h
M src/gsm/gsm48_ie.c
M src/gsm/libosmogsm.map
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
6 files changed, 0 insertions(+), 960 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/15/21115/1

diff --git a/include/osmocom/gsm/gsm48_ie.h b/include/osmocom/gsm/gsm48_ie.h
index b79cbfc..339aa13 100644
--- a/include/osmocom/gsm/gsm48_ie.h
+++ b/include/osmocom/gsm/gsm48_ie.h
@@ -119,7 +119,3 @@
 /* decode "Cell Channel Description" (10.5.2.1b) and other frequency lists */
 int gsm48_decode_freq_list(struct gsm_sysinfo_freq *f, uint8_t *cd,
   uint8_t len, uint8_t mask, uint8_t frqt);
-
-/* decode "CSN.1 encoded Classmark 3" (10.5.1.7) */
-int gsm48_decode_classmark3(struct gsm48_classmark3 *classmark3_out,
-   const uint8_t *classmark3, size_t classmark3_len);
diff --git a/include/osmocom/gsm/protocol/gsm_04_08.h 
b/include/osmocom/gsm/protocol/gsm_04_08.h
index 2093bee..df13b15 100644
--- a/include/osmocom/gsm/protocol/gsm_04_08.h
+++ b/include/osmocom/gsm/protocol/gsm_04_08.h
@@ -58,175 +58,6 @@
 #endif
 } __attribute__ ((packed));

-/* Chapter 10.5.1.7 */
-struct gsm48_classmark3 {
-   uint8_t a5_bits;
-   uint8_t mult_band_supp;
-   uint8_t assoc_radio_cap_1;
-   uint8_t assoc_radio_cap_2;
-
-   struct {
-   bool present;
-   uint8_t r_gsm_assoc_radio_cap;
-   } r_support;
-
-   struct {
-   bool present;
-   uint8_t class;
-   } hscsd_mult_slot_cap;
-
-   bool ucs2_treatment;
-   bool extended_meas_cap;
-
-   struct {
-   bool present;
-   uint8_t sms_value;
-   uint8_t sm_value;
-   } ms_meas_cap;
-
-   struct {
-   bool present;
-   uint8_t method;
-   } ms_pos_method_cap;
-
-   struct {
-   bool present;
-   uint8_t class;
-   } ecsd_multislot_cap;
-
-   struct {
-   bool present;
-   bool mod_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } rf_pwr_cap_1;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } rf_pwr_cap_2;
-
-   } psk8_struct;
-
-   struct {
-   bool present;
-   uint8_t value;
-   uint8_t assoc_radio_cap;
-   } gsm_400_bands_supp;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } gsm_850_assoc_radio_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } gsm_1900_assoc_radio_cap;
-
-   bool umts_fdd_rat_cap;
-   bool umts_tdd_rat_cap;
-   bool cdma200_rat_cap;
-
-   struct {
-   bool present;
-   uint8_t class;
-   bool single_slot_dtm;
-   struct {
-   bool present;
-   uint8_t class;
-   } dtm_egprs_multislot_cap;
-   } dtm_gprs_multislot_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } single_band_supp;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } gsm_750_assoc_radio_cap;
-
-   bool umts_1_28_mcps_tdd_rat_cap;
-   bool geran_feature_package;
-
-   struct {
-   bool present;
-   uint8_t class;
-   struct {
-   bool present;
-   uint8_t class;
-   } extended_dtm_egprs_multislot_cap;
-   } extended_dtm_gprs_multislot_cap;
-
-   struct {
-   bool present;
-   uint8_t value;
-   } high_multislot_cap;
-
-   bool geran_feature_package_2;
-   uint8_t gmsk_multislot_power_prof;
-   uint8_t psk8_multislot_power_prof;
-
-   struct {
-   bool present;
-   uint8_t value;
-   uint8_t assoc_radio_cap;
-   } t_gsm_400_bands_supp;
-
-   uint8_t dl_advanced_rx_perf;
-   bool dtm_enhancements_cap;
-
-   struct {
-   bool present;
-   uint8_t class;
-   bool offset_required;
-   struct {
-   

Change in docker-playground[master]: ogt: Install dependency python3-watchdog

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/docker-playground/+/21091 )

Change subject: ogt: Install dependency python3-watchdog
..

ogt: Install dependency python3-watchdog

Change-Id: I9136cef6b5a7be085c840dd798bc21493f0a47a6
---
M osmo-gsm-tester/Dockerfile
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  pespin: Verified
  laforge: Looks good to me, approved



diff --git a/osmo-gsm-tester/Dockerfile b/osmo-gsm-tester/Dockerfile
index eaf6ff7..a19c385 100644
--- a/osmo-gsm-tester/Dockerfile
+++ b/osmo-gsm-tester/Dockerfile
@@ -22,6 +22,7 @@
python3-gi \
python3-numpy \
python3-wheel \
+   python3-watchdog \
ofono \
patchelf \
sudo \

--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/21091
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I9136cef6b5a7be085c840dd798bc21493f0a47a6
Gerrit-Change-Number: 21091
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-bsc[master]: sysmobts: expect feature IPV6_NSVC

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bsc/+/20477 )

Change subject: sysmobts: expect feature IPV6_NSVC
..


Patch Set 1:

> Patch Set 1:
>
> It creates a notice if the expected features doesn't match the features of 
> the bts.

but what good does this notice do us?  What is the "expected features"  Why do 
we have any expectation at all, given that the BTS can and will in instances 
run many years older software version.


--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/20477
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I711efca931012b8e66516f2721390e9dbdbb72a8
Gerrit-Change-Number: 20477
Gerrit-PatchSet: 1
Gerrit-Owner: lynxis lazus 
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:35:34 +
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment


Change in osmo-ccid-firmware[master]: ccid/7816 fsm: better pps error handling

2020-11-11 Thread Hoernchen
Hoernchen has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/21113 )


Change subject: ccid/7816 fsm: better pps error handling
..

ccid/7816 fsm: better pps error handling

Change-Id: Id138a600dbe2dd1b8d153b764f73d65e2fd444dd
---
M ccid_common/ccid_slot_fsm.c
M ccid_common/iso7816_fsm.c
M ccid_common/iso7816_fsm.h
3 files changed, 13 insertions(+), 36 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ccid-firmware 
refs/changes/13/21113/1

diff --git a/ccid_common/ccid_slot_fsm.c b/ccid_common/ccid_slot_fsm.c
index 5fc74e0..a8c4e54 100644
--- a/ccid_common/ccid_slot_fsm.c
+++ b/ccid_common/ccid_slot_fsm.c
@@ -265,19 +265,12 @@
cs->event = 0;
break;
case ISO7816_E_PPS_UNSUPPORTED_IND:
-   tpdu = data;
-
-   /* perform deactivation */
-   card_uart_ctrl(ss->cuart, CUART_CTL_RST, true);
-   card_uart_ctrl(ss->cuart, CUART_CTL_POWER_5V0, false);
-   cs->icc_powered = false;
-
-   /* failed comand */
-   resp = ccid_gen_parameters_t0(cs, ss->seq, 
CCID_CMD_STATUS_FAILED, 0);
-   ccid_slot_send_unbusy(cs, resp);
-
-   cs->event = 0;
-   break;
+   /* unsupported means no response, failed means request/response mismatch
+* yet both lead to a deactivation, and the host always gets a fi/di 
error
+* 10 "FI - DI pair invalid or not supported" since that part of the
+* ccid setparameters is handled by the pps exchange
+*/
+   /* fall-through */
case ISO7816_E_PPS_FAILED_IND:
tpdu = data;

@@ -389,7 +382,7 @@
LOGPCS(cs, LOGL_DEBUG, "scheduling PPS transfer, PPS1: %2x\n", PPS1);

/* pass PPS1 instead of msgb */
-   osmo_fsm_inst_dispatch(ss->fi, ISO7816_E_XCEIVE_PPS_CMD, PPS1);
+   osmo_fsm_inst_dispatch(ss->fi, ISO7816_E_XCEIVE_PPS_CMD, (void*)PPS1);
/* continues in iso_fsm_clot_user_cb once response/error/timeout is 
received */
return 0;
 }
diff --git a/ccid_common/iso7816_fsm.c b/ccid_common/iso7816_fsm.c
index 66250d5..e819e64 100644
--- a/ccid_common/iso7816_fsm.c
+++ b/ccid_common/iso7816_fsm.c
@@ -311,17 +311,6 @@
break;
case ISO7816_E_POWER_UP_IND:
break;
-   case ISO7816_E_PPS_UNSUPPORTED_IND:
-   case ISO7816_E_PPS_FAILED_IND:
-   msg = data;
-   /* notify user about PPS result */
-   ip->user_cb(fi, event, 0, msg);
-   break;
-   case ISO7816_E_TPDU_FAILED_IND:
-   msg = data;
-   /* hand finished TPDU to user */
-   ip->user_cb(fi, event, 0, msg);
-   break;
default:
OSMO_ASSERT(0);
}
@@ -441,7 +430,7 @@
ip->user_cb(fi, ISO7816_E_ATR_ERR_IND, 0, atp->atr);

if(fi->state == ISO7816_S_WAIT_PPS_RSP || fi->state == 
ISO7816_S_IN_PPS_RSP)
-   ip->user_cb(fi, ISO7816_E_PPS_FAILED_IND, 0, 
ppp->tx_cmd);
+   ip->user_cb(fi, ISO7816_E_PPS_UNSUPPORTED_IND, 0, 
ppp->tx_cmd);

if(fi->state == ISO7816_S_WAIT_TPDU || fi->state == 
ISO7816_S_IN_TPDU)
ip->user_cb(fi, ISO7816_E_TPDU_FAILED_IND, 0, 
tpdup->tpdu);
@@ -462,7 +451,7 @@
break;
}
if(fi->state == ISO7816_S_WAIT_PPS_RSP || fi->state == 
ISO7816_S_IN_PPS_RSP)
-   ip->user_cb(fi, ISO7816_E_PPS_FAILED_IND, 0, 
ppp->tx_cmd);
+   ip->user_cb(fi, ISO7816_E_PPS_UNSUPPORTED_IND, 0, 
ppp->tx_cmd);

if(fi->state == ISO7816_S_WAIT_TPDU || fi->state == 
ISO7816_S_IN_TPDU)
ip->user_cb(fi, ISO7816_E_TPDU_FAILED_IND, 0, 
tpdup->tpdu);
@@ -516,7 +505,6 @@
/* notify user about PPS result */
ip->user_cb(fi, event, 0, ppsrsp);
break;
-   case ISO7816_E_PPS_UNSUPPORTED_IND:
case ISO7816_E_PPS_FAILED_IND:
case ISO7816_E_RX_ERR_IND:
/* error cases lead to slot reset */
@@ -533,10 +521,7 @@
[ISO7816_S_RESET] = {
.name = "RESET",
.in_event_mask =S(ISO7816_E_RESET_REL_IND) |
-   
S(ISO7816_E_POWER_UP_IND) |
-   
S(ISO7816_E_PPS_FAILED_IND)|
-   
S(ISO7816_E_PPS_UNSUPPORTED_IND)|
-   
S(ISO7816_E_TPDU_FAILED_IND),
+   
S(ISO7816_E_POWER_UP_IND),
.out_state_mask =   S(ISO7816_S_WAIT_ATR) |
S(ISO7816_S_RESET),
.action 

Change in osmo-ccid-firmware[master]: 7816 fsm/cuart: support inverse condition cards

2020-11-11 Thread Hoernchen
Hoernchen has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/21114 )


Change subject: 7816 fsm/cuart: support inverse condition cards
..

7816 fsm/cuart: support inverse condition cards

This does not currently work with "pcsc-lite version 1.8.26." because
the inverse conditon cards I know do not support the PPS exchange, which
according to spec leads to card deactivation, so the slots needs to be
powered up again, which does not happen.

osmo-sim-test works after manually disabling the pps exchange code in
the firmware.

Change-Id: I892e1d883825111cc1e4ea09589c4fdd256da03c
---
M ccid_common/ccid_slot_fsm.c
M ccid_common/cuart.h
M ccid_common/iso7816_fsm.c
M sysmoOCTSIM/cuart_driver_asf4_usart_async.c
4 files changed, 52 insertions(+), 7 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ccid-firmware 
refs/changes/14/21114/1

diff --git a/ccid_common/ccid_slot_fsm.c b/ccid_common/ccid_slot_fsm.c
index a8c4e54..4cf75bc 100644
--- a/ccid_common/ccid_slot_fsm.c
+++ b/ccid_common/ccid_slot_fsm.c
@@ -204,10 +204,16 @@
break;
case ISO7816_E_ATR_DONE_IND:
tpdu = data;
-   LOGPCS(cs, LOGL_DEBUG, "%s(event=%d, data=%s)\n", __func__, 
event,
-   msgb_hexdump(tpdu));
-   resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_OK, 0,
-  msgb_data(tpdu), msgb_length(tpdu));
+
+   /* inverse condition, error interrupt is always disabled during 
atr and reenabled here after atr */
+   if(*msgb_data(tpdu) == 0x3f) {
+   card_uart_ctrl(ss->cuart, CUART_CTL_ERROR_AND_INV, 
true);
+   } else {
+   card_uart_ctrl(ss->cuart, CUART_CTL_ERROR_AND_INV, 
false);
+   }
+
+   LOGPCS(cs, LOGL_DEBUG, "%s(event=%d, data=%s)\n", __func__, 
event, msgb_hexdump(tpdu));
+   resp = ccid_gen_data_block(cs, ss->seq, CCID_CMD_STATUS_OK, 0, 
msgb_data(tpdu), msgb_length(tpdu));
ccid_slot_send_unbusy(cs, resp);
cs->event = 0;
break;
diff --git a/ccid_common/cuart.h b/ccid_common/cuart.h
index e5ec501..c0a3a52 100644
--- a/ccid_common/cuart.h
+++ b/ccid_common/cuart.h
@@ -54,6 +54,7 @@
CUART_CTL_SET_FD,
CUART_CTL_GET_BAUDRATE,
CUART_CTL_GET_CLOCK_FREQ,
+   CUART_CTL_ERROR_AND_INV, /* enable error interrupt and maybe inverse 
signalling according to arg */
 };

 struct card_uart;
diff --git a/ccid_common/iso7816_fsm.c b/ccid_common/iso7816_fsm.c
index e819e64..8e113b0 100644
--- a/ccid_common/iso7816_fsm.c
+++ b/ccid_common/iso7816_fsm.c
@@ -639,6 +639,15 @@
struct iso7816_3_priv *ip = get_iso7816_3_priv(fi);
uint8_t byte = *(uint8_t *)data;

+   return byte;
+}
+
+/* obtain the 'byte' (possbily inverted) parameter of an ISO7816_E_RX event */
+static uint8_t get_atr_rx_byte_evt(struct osmo_fsm_inst *fi, void *data)
+{
+   struct iso7816_3_priv *ip = get_iso7816_3_priv(fi);
+   uint8_t byte = *(uint8_t *)data;
+
/* apply inverse convention */
if (ip->convention_convert)
byte = convention_convert_lut[byte];
@@ -689,14 +698,14 @@
case ISO7816_E_RX_SINGLE:
OSMO_ASSERT(msgb_length(atp->atr) == 0);
 restart:
-   byte = get_rx_byte_evt(parent_fi, data);
+   byte = get_atr_rx_byte_evt(parent_fi, data);
LOGPFSML(fi, LOGL_DEBUG, "RX byte '%02x'\n", byte);
switch (byte) {
case 0x23:
/* direct convention used, but decoded using inverse
 * convention (a parity error should also have 
occurred) */
/* fall-through */
-   case 0x30:
+   case 0x03:
/* inverse convention used, but decoded using direct
 * convention (a parity error should also have 
occurred) */
ip->convention_convert = !ip->convention_convert;
@@ -732,7 +741,7 @@

switch (event) {
case ISO7816_E_RX_SINGLE:
-   byte = get_rx_byte_evt(fi->proc.parent, data);
+   byte = get_atr_rx_byte_evt(fi->proc.parent, data);
LOGPFSML(fi, LOGL_DEBUG, "RX byte '%02x'\n", byte);
atr_append_byte(fi, byte);
switch (fi->state) {
diff --git a/sysmoOCTSIM/cuart_driver_asf4_usart_async.c 
b/sysmoOCTSIM/cuart_driver_asf4_usart_async.c
index 89cd734..e6d180c 100644
--- a/sysmoOCTSIM/cuart_driver_asf4_usart_async.c
+++ b/sysmoOCTSIM/cuart_driver_asf4_usart_async.c
@@ -159,6 +159,19 @@
  */
 static const uint8_t SIM_peripheral_GCLK_ID[] = {SERCOM0_GCLK_ID_CORE, 
SERCOM1_GCLK_ID_CORE, SERCOM2_GCLK_ID_CORE, SERCOM3_GCLK_ID_CORE, 
SERCOM4_GCLK_ID_CORE, SERCOM5_GCLK_ID_CORE, SERCOM6_GCLK_ID_CORE, 

Change in osmo-bsc[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bsc/+/20752 )

Change subject: Use osmo_fd_*_{disable,enable}
..


Patch Set 2: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/20752
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I4e228399d21098cc9a99b9cc1aa42b24ec609159
Gerrit-Change-Number: 20752
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-CC: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:15:19 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-bsc[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-bsc/+/20752 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
Change-Id: I4e228399d21098cc9a99b9cc1aa42b24ec609159
---
M src/ipaccess/abisip-find.c
M src/ipaccess/ipaccess-proxy.c
M src/osmo-bsc/meas_feed.c
M src/osmo-bsc/pcu_sock.c
4 files changed, 13 insertions(+), 13 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/ipaccess/abisip-find.c b/src/ipaccess/abisip-find.c
index a414d16..4bba8a3 100644
--- a/src/ipaccess/abisip-find.c
+++ b/src/ipaccess/abisip-find.c
@@ -406,7 +406,7 @@
if (flags & OSMO_FD_READ)
return read_response(bfd->fd);
if (flags & OSMO_FD_WRITE) {
-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);
return bcast_find(bfd->fd);
}
return 0;
@@ -418,7 +418,7 @@
 {
struct osmo_fd *bfd = _data;

-   bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(bfd);

base_stations_bump(false);

diff --git a/src/ipaccess/ipaccess-proxy.c b/src/ipaccess/ipaccess-proxy.c
index 1ed215d..47465b4 100644
--- a/src/ipaccess/ipaccess-proxy.c
+++ b/src/ipaccess/ipaccess-proxy.c
@@ -283,7 +283,7 @@
if (other_conn) {
/* enqueue the message for TX on the respective FD */
msgb_enqueue(_conn->tx_queue, msg);
-   other_conn->fd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(_conn->fd);
} else
msgb_free(msg);

@@ -293,7 +293,7 @@
 static int handle_udp_write(struct osmo_fd *bfd)
 {
/* not implemented yet */
-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);

return -EIO;
 }
@@ -840,7 +840,7 @@
/* enqueue packet towards BSC */
msgb_enqueue(_conn->tx_queue, msg);
/* mark respective filedescriptor as 'we want to write' */
-   bsc_conn->fd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(_conn->fd);
} else {
logp_ipbc_uid(DLINP, LOGL_INFO, ipbc, bfd->priv_nr >> 8);
LOGPC(DLINP, LOGL_INFO, "Dropping packet from %s, "
@@ -869,7 +869,7 @@

/* get the next msg for this timeslot */
if (llist_empty(>tx_queue)) {
-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);
return 0;
}
lh = ipc->tx_queue.next;
diff --git a/src/osmo-bsc/meas_feed.c b/src/osmo-bsc/meas_feed.c
index 889f6ef..881f409 100644
--- a/src/osmo-bsc/meas_feed.c
+++ b/src/osmo-bsc/meas_feed.c
@@ -119,7 +119,7 @@
char buf[256];

rc = read(ofd->fd, buf, sizeof(buf));
-   ofd->fd &= ~OSMO_FD_READ;
+   osmo_fd_read_disable(ofd);

return rc;
 }
@@ -159,7 +159,7 @@
if (rc < 0)
return rc;

-   g_mfs.wqueue.bfd.when &= ~OSMO_FD_READ;
+   osmo_fd_read_disable(_mfs.wqueue.bfd);

if (g_mfs.dst_host)
talloc_free(g_mfs.dst_host);
diff --git a/src/osmo-bsc/pcu_sock.c b/src/osmo-bsc/pcu_sock.c
index d59df33..541fc84 100644
--- a/src/osmo-bsc/pcu_sock.c
+++ b/src/osmo-bsc/pcu_sock.c
@@ -495,7 +495,7 @@
return -EIO;
}
msgb_enqueue(>upqueue, msg);
-   conn_bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(conn_bfd);

return 0;
 }
@@ -518,7 +518,7 @@
osmo_fd_unregister(bfd);
 
/* re-enable the generation of ACCEPT for new connections */
-   state->listen_bfd.when |= OSMO_FD_READ;
+   osmo_fd_read_enable(>listen_bfd);

 #if 0
/* remove si13, ... */
@@ -597,7 +597,7 @@
msg = llist_entry(state->upqueue.next, struct msgb, list);
pcu_prim = (struct gsm_pcu_if *)msg->data;

-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);

/* bug hunter 8-): maybe someone forgot msgb_put(...) ? */
if (!msgb_length(msg)) {
@@ -612,7 +612,7 @@
goto close;
if (rc < 0) {
if (errno == EAGAIN) {
-   bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(bfd);
break;
}
goto close;
@@ -667,7 +667,7 @@
LOGP(DPCU, LOGL_NOTICE, "PCU connects but we already have "
"another active connection ?!?\n");
/* We already have one PCU connected, this is all we support */
-   state->listen_bfd.when &= ~OSMO_FD_READ;
+   osmo_fd_read_disable(>listen_bfd);
close(rc);
return 0;
}

--
To view, visit 

Change in osmo-trx[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-trx/+/20772 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Change-Id: Ic8c8c418e123fbdff625556a900b19650deefe0b
Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
---
M TODO-RELEASE
M Transceiver52M/Transceiver.cpp
M Transceiver52M/device/ipc/IPCDevice.cpp
M Transceiver52M/device/ipc/ipc_chan.c
M Transceiver52M/device/ipc/ipc_sock.c
5 files changed, 18 insertions(+), 17 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  pespin: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/TODO-RELEASE b/TODO-RELEASE
index 75fe7b8..84ecf22 100644
--- a/TODO-RELEASE
+++ b/TODO-RELEASE
@@ -1,2 +1,3 @@
 * update libosmocore dependency to > 1.3.x for osmo_sched_vty_init(), 
osmo_sched_vty_apply_localthread()
 * update osmo-gsm-manuals dependency to > 0.3.0 for vty_cpu_sched.adoc include.
+* update libosmocore dependency to > 1.4.x for 
osmo_fd_{read,write}_{enable,disable}()
diff --git a/Transceiver52M/Transceiver.cpp b/Transceiver52M/Transceiver.cpp
index 4980861..9c93e98 100644
--- a/Transceiver52M/Transceiver.cpp
+++ b/Transceiver52M/Transceiver.cpp
@@ -806,7 +806,7 @@
   struct osmo_fd *conn_bfd = _bfd;

   s.txmsgqueue.push_back(m);
-  conn_bfd->when |= OSMO_FD_WRITE;
+  osmo_fd_write_enable(conn_bfd);
 }

 int Transceiver::ctrl_sock_write(int chan)
@@ -821,7 +821,7 @@
   while (s.txmsgqueue.size()) {
 const ctrl_msg m = s.txmsgqueue.front();

-s.conn_bfd.when &= ~OSMO_FD_WRITE;
+osmo_fd_write_disable(_bfd);

 /* try to send it over the socket */
 rc = write(s.conn_bfd.fd, m.data, strlen(m.data) + 1);
@@ -829,7 +829,7 @@
   goto close;
 if (rc < 0) {
   if (errno == EAGAIN) {
-s.conn_bfd.when |= OSMO_FD_WRITE;
+osmo_fd_write_enable(_bfd);
 break;
   }
   goto close;
diff --git a/Transceiver52M/device/ipc/IPCDevice.cpp 
b/Transceiver52M/device/ipc/IPCDevice.cpp
index 102cb9b..a16f723 100644
--- a/Transceiver52M/device/ipc/IPCDevice.cpp
+++ b/Transceiver52M/device/ipc/IPCDevice.cpp
@@ -522,7 +522,7 @@
return -EIO;
}
msgb_enqueue(>upqueue, msg);
-   conn_bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(conn_bfd);

return 0;
 }
@@ -659,7 +659,7 @@
msg = llist_entry(master_sk_state.upqueue.next, struct msgb, 
list);
ipc_prim = (struct ipc_sk_if *)msg->data;

-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);

/* bug hunter 8-): maybe someone forgot msgb_put(...) ? */
if (!msgb_length(msg)) {
@@ -676,7 +676,7 @@
goto close;
if (rc < 0) {
if (errno == EAGAIN) {
-   bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(bfd);
break;
}
goto close;
@@ -706,7 +706,7 @@
/* peek at the beginning of the queue */
msg = llist_entry(sk_chan_state[bfd->priv_nr].upqueue.next, 
struct msgb, list);
ipc_prim = (struct ipc_sk_chan_if *)msg->data;
-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);
/* bug hunter 8-): maybe someone forgot msgb_put(...) ? */
if (!msgb_length(msg)) {
LOGP(DDEV, LOGL_ERROR,
@@ -722,7 +722,7 @@
goto close;
if (rc < 0) {
if (errno == EAGAIN) {
-   bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(bfd);
break;
}
goto close;
diff --git a/Transceiver52M/device/ipc/ipc_chan.c 
b/Transceiver52M/device/ipc/ipc_chan.c
index 50782b9..2a6f490 100644
--- a/Transceiver52M/device/ipc/ipc_chan.c
+++ b/Transceiver52M/device/ipc/ipc_chan.c
@@ -142,7 +142,7 @@
return -EIO;
}
msgb_enqueue(>upqueue, msg);
-   conn_bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(conn_bfd);

return 0;
 }
@@ -160,7 +160,7 @@
msg = llist_entry(state->upqueue.next, struct msgb, list);
ipc_prim = (struct ipc_sk_chan_if *)msg->data;

-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);

/* bug hunter 8-): maybe someone forgot msgb_put(...) ? */
if (!msgb_length(msg)) {
@@ -177,7 +177,7 @@
goto close;
if (rc < 0) {
if (errno == EAGAIN) {
-   bfd->when |= OSMO_FD_WRITE;
+   

Change in osmo-trx[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-trx/+/20772 )

Change subject: Use osmo_fd_*_{disable,enable}
..


Patch Set 2: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/20772
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-Change-Id: Ic8c8c418e123fbdff625556a900b19650deefe0b
Gerrit-Change-Number: 20772
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:15:55 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-sgsn[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-sgsn/+/20774 )

Change subject: Use osmo_fd_*_{disable,enable}
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-sgsn/+/20774
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-sgsn
Gerrit-Branch: master
Gerrit-Change-Id: Ia207cd2ee68d657ee88cb0152a5b1faa4161c967
Gerrit-Change-Number: 20774
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-CC: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:15:05 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-pcu[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-pcu/+/20781 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Change-Id: I16563a1033ad12a32104bfee974045ac4302bc74
Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
---
M TODO-RELEASE
M src/osmobts_sock.cpp
2 files changed, 4 insertions(+), 3 deletions(-)

Approvals:
  pespin: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/TODO-RELEASE b/TODO-RELEASE
index 17c6a34..40932ee 100644
--- a/TODO-RELEASE
+++ b/TODO-RELEASE
@@ -8,3 +8,4 @@
 # If any interfaces have been removed or changed since the last public 
release: c:r:0.
 #librarywhatdescription / commit summary line
 osmo-pcuupdate osmo-gsm-manuals dependency to > 0.3.0 for 
vty_cpu_sched.adoc include
+osmo-pcu   update libosmocore dependency > 1.4.x for 
osmo_fd_{read,write}_{enable,disable}
diff --git a/src/osmobts_sock.cpp b/src/osmobts_sock.cpp
index c9beff0..522581a 100644
--- a/src/osmobts_sock.cpp
+++ b/src/osmobts_sock.cpp
@@ -82,7 +82,7 @@
return -EIO;
}
msgb_enqueue(_sock_state.upqueue, msg);
-   conn_bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(conn_bfd);

return 0;
 }
@@ -153,7 +153,7 @@
msg = llist_entry(pcu_sock_state.upqueue.next, struct msgb, 
list);
pcu_prim = (struct gsm_pcu_if *)msg->data;

-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);

/* bug hunter 8-): maybe someone forgot msgb_put(...) ? */
if (!msgb_length(msg)) {
@@ -168,7 +168,7 @@
goto close;
if (rc < 0) {
if (errno == EAGAIN) {
-   bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(bfd);
break;
}
goto close;

--
To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/20781
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Change-Id: I16563a1033ad12a32104bfee974045ac4302bc74
Gerrit-Change-Number: 20781
Gerrit-PatchSet: 3
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-sgsn[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-sgsn/+/20774 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Change-Id: Ia207cd2ee68d657ee88cb0152a5b1faa4161c967
Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
---
M src/gprs/sgsn_ares.c
1 file changed, 4 insertions(+), 4 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/gprs/sgsn_ares.c b/src/gprs/sgsn_ares.c
index 38e31e1..87314f1 100644
--- a/src/gprs/sgsn_ares.c
+++ b/src/gprs/sgsn_ares.c
@@ -120,14 +120,14 @@

 update_fd:
if (read)
-   ufd->fd.when |= OSMO_FD_READ;
+   osmo_fd_read_enable(>fd);
else
-   ufd->fd.when &= ~OSMO_FD_READ;
+   osmo_fd_read_disable(>fd);

if (write)
-   ufd->fd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(>fd);
else
-   ufd->fd.when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(>fd);

osmo_ares_reschedule(sgsn);
 }

--
To view, visit https://gerrit.osmocom.org/c/osmo-sgsn/+/20774
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-sgsn
Gerrit-Branch: master
Gerrit-Change-Id: Ia207cd2ee68d657ee88cb0152a5b1faa4161c967
Gerrit-Change-Number: 20774
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-CC: pespin 
Gerrit-MessageType: merged


Change in osmo-msc[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-msc/+/20785 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Change-Id: I5208124e08d3b403492fe83acee235e61e423450
Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
---
M TODO-RELEASE
M src/libmsc/mncc_sock.c
2 files changed, 7 insertions(+), 6 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  pespin: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/TODO-RELEASE b/TODO-RELEASE
index fdddbc2..9c358ae 100644
--- a/TODO-RELEASE
+++ b/TODO-RELEASE
@@ -10,3 +10,4 @@
 manual needs common chapter cs7-config.adoc, 
vty_cpu_sched.adoc from osmo-gsm-manuals > 0.3.0
 osmo-msc   Mobile Identity Coding  OsmoMSC is stricter in rejecting 
invalid coding of Mobile Identity IEs
 libmosmo-mgcp-client   needs osmo-mgw.git > 1.7.0 
(8667d5169df8d06e10ee3f3104e4cd533d15ac57), ABI break due to struct size in 
mgcp_conn_peer and mgcp_response
+osmo-msc   update version dependency to version with 
osmo_fd_*_{disable,enable}
diff --git a/src/libmsc/mncc_sock.c b/src/libmsc/mncc_sock.c
index 4c1362d..b76855f 100644
--- a/src/libmsc/mncc_sock.c
+++ b/src/libmsc/mncc_sock.c
@@ -65,7 +65,7 @@

/* Actually enqueue the message and mark socket write need */
msgb_enqueue(>upqueue, msg);
-   net->mncc_state->conn_bfd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(>mncc_state->conn_bfd);
return 0;
 }

@@ -80,7 +80,7 @@
osmo_fd_unregister(bfd);

/* re-enable the generation of ACCEPT for new connections */
-   state->listen_bfd.when |= OSMO_FD_READ;
+   osmo_fd_read_enable(>listen_bfd);

/* release all existing calls */
gsm0408_clear_all_trans(state->net, TRANS_CC);
@@ -146,7 +146,7 @@
msg = llist_entry(net->upqueue.next, struct msgb, list);
mncc_prim = (struct gsm_mncc *)msg->data;

-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);

/* bug hunter 8-): maybe someone forgot msgb_put(...) ? */
if (!msgb_length(msg)) {
@@ -161,7 +161,7 @@
goto close;
if (rc < 0) {
if (errno == EAGAIN) {
-   bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(bfd);
break;
}
goto close;
@@ -222,7 +222,7 @@
hello->lchan_type_offset = offsetof(struct gsm_mncc, lchan_type);

msgb_enqueue(>net->upqueue, msg);
-   mncc->conn_bfd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(>conn_bfd);
 }

 /* accept a new connection */
@@ -245,7 +245,7 @@
LOGP(DMNCC, LOGL_NOTICE, "MNCC app connects but we already have 
"
"another active connection ?!?\n");
/* We already have one MNCC app connected, this is all we 
support */
-   state->listen_bfd.when &= ~OSMO_FD_READ;
+   osmo_fd_read_disable(>listen_bfd);
close(rc);
return 0;
}

--
To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/20785
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-Change-Id: I5208124e08d3b403492fe83acee235e61e423450
Gerrit-Change-Number: 20785
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmocom-bb[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmocom-bb/+/20767 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Change-Id: I65d37821873767e61a7eca029f9b30938a299683
Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
---
M src/host/osmocon/osmocon.c
1 file changed, 14 insertions(+), 14 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  pespin: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/src/host/osmocon/osmocon.c b/src/host/osmocon/osmocon.c
index 66b2ea0..d49c3fd 100644
--- a/src/host/osmocon/osmocon.c
+++ b/src/host/osmocon/osmocon.c
@@ -500,7 +500,7 @@
dnload.block_ptr = dnload.block;

dnload.block_number++;
-   dnload.serial_fd.when = OSMO_FD_READ | OSMO_FD_WRITE;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ | OSMO_FD_WRITE);
return 0;
 }

@@ -586,7 +586,7 @@
printf("Progress: %i%%\r", progress);
fflush(stdout);
dnload.write_ptr = dnload.data;
-   dnload.serial_fd.when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(_fd);
if (dnload.romload_state == SENDING_LAST_BLOCK) {
dnload.romload_state = LAST_BLOCK_SENT;
printf("Finished, sent %i blocks in total\n",
@@ -638,7 +638,7 @@
} else if (dnload.write_ptr >= dnload.data + dnload.data_len) {
printf("finished\n");
dnload.write_ptr = dnload.data;
-   dnload.serial_fd.when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(_fd);
return 1;
}

@@ -682,7 +682,7 @@
}

if (end)
-   dnload.serial_fd.when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(_fd);

return 0;
 }
@@ -751,7 +751,7 @@

sercomm_sendmsg(dlci, msg);

-   dnload.serial_fd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(_fd);
 }

 static void hdlc_console_cb(uint8_t dlci, struct msgb *msg)
@@ -842,12 +842,12 @@
}
} else if (!memcmp(buffer, phone_prompt2, sizeof(phone_prompt2))) {
printf("Received PROMPT2 from phone, starting download\n");
-   dnload.serial_fd.when = OSMO_FD_READ | OSMO_FD_WRITE;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ | 
OSMO_FD_WRITE);
dnload.state = DOWNLOADING;
} else if (!memcmp(buffer, phone_ack, sizeof(phone_ack))) {
printf("Received DOWNLOAD ACK from phone, your code is"
" running now!\n");
-   dnload.serial_fd.when = OSMO_FD_READ;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ);
dnload.state = WAITING_PROMPT1;
dnload.write_ptr = dnload.data;
dnload.expect_hdlc = 1;
@@ -868,18 +868,18 @@
} else if (!memcmp(buffer, phone_nack, sizeof(phone_nack))) {
printf("Received DOWNLOAD NACK from phone, something went"
" wrong :(\n");
-   dnload.serial_fd.when = OSMO_FD_READ;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ);
dnload.state = WAITING_PROMPT1;
dnload.write_ptr = dnload.data;
} else if (!memcmp(buffer, phone_nack_magic, sizeof(phone_nack_magic))) 
{
printf("Received MAGIC NACK from phone, you need to"
" have \"1003\" at 0x803ce0\n");
-   dnload.serial_fd.when = OSMO_FD_READ;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ);
dnload.state = WAITING_PROMPT1;
dnload.write_ptr = dnload.data;
} else if (!memcmp(buffer, ftmtool, sizeof(ftmtool))) {
printf("Received FTMTOOL from phone, ramloader has aborted\n");
-   dnload.serial_fd.when = OSMO_FD_READ;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ);
dnload.state = WAITING_PROMPT1;
dnload.write_ptr = dnload.data;
}
@@ -1000,7 +1000,7 @@
if (!memcmp(buffer, romload_branch_ack,
sizeof(romload_branch_ack))) {
printf("Received branch ack, your code is running 
now!\n");
-   dnload.serial_fd.when = OSMO_FD_READ;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ);
dnload.romload_state = FINISHED;
dnload.write_ptr = dnload.data;
dnload.expect_hdlc = 1;
@@ -1116,7 +1116,7 @@
printf("Received size ack\n");
dnload.expect_hdlc = 1;
dnload.mtk_state = MTK_SENDING_BLOCKS;
-   dnload.serial_fd.when = OSMO_FD_READ | OSMO_FD_WRITE;
+   osmo_fd_update_when(_fd, 0, OSMO_FD_READ | 
OSMO_FD_WRITE);
bufptr -= 

Change in osmocom-bb[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmocom-bb/+/20767 )

Change subject: Use osmo_fd_*_{disable,enable}
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/20767
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmocom-bb
Gerrit-Branch: master
Gerrit-Change-Id: I65d37821873767e61a7eca029f9b30938a299683
Gerrit-Change-Number: 20767
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:14:43 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmocom-bb[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmocom-bb/+/20770 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Change-Id: If4c7f946852d153bd472e5c704f8d517d26ca22e
Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
---
M src/host/layer23/src/mobile/mncc_sock.c
1 file changed, 6 insertions(+), 6 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  pespin: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/src/host/layer23/src/mobile/mncc_sock.c 
b/src/host/layer23/src/mobile/mncc_sock.c
index 14adf07..5ea6feb 100644
--- a/src/host/layer23/src/mobile/mncc_sock.c
+++ b/src/host/layer23/src/mobile/mncc_sock.c
@@ -72,13 +72,13 @@

/* Actually enqueue the message and mark socket write need */
msgb_enqueue(>upqueue, msg);
-   state->conn_bfd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(>conn_bfd);
return 0;
 }

 void mncc_sock_write_pending(struct mncc_sock_state *state)
 {
-   state->conn_bfd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(>conn_bfd);
 }

 static void mncc_sock_close(struct mncc_sock_state *state)
@@ -92,7 +92,7 @@
osmo_fd_unregister(bfd);

/* re-enable the generation of ACCEPT for new connections */
-   state->listen_bfd.when |= OSMO_FD_READ;
+   osmo_fd_read_enable(>listen_bfd);

/* FIXME: make sure we don't enqueue anymore */

@@ -156,7 +156,7 @@
msg = llist_entry(state->upqueue.next, struct msgb, list);
mncc_prim = (struct gsm_mncc *)msg->data;

-   bfd->when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(bfd);

/* bug hunter 8-): maybe someone forgot msgb_put(...) ? */
if (!msgb_length(msg)) {
@@ -171,7 +171,7 @@
goto close;
if (rc < 0) {
if (errno == EAGAIN) {
-   bfd->when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(bfd);
break;
}
goto close;
@@ -226,7 +226,7 @@
LOGP(DMNCC, LOGL_NOTICE, "MNCC app connects but we already have 
"
"another active connection ?!?\n");
/* We already have one MNCC app connected, this is all we 
support */
-   state->listen_bfd.when &= ~OSMO_FD_READ;
+   osmo_fd_read_disable(>listen_bfd);
close(rc);
return 0;
}

--
To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/20770
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmocom-bb
Gerrit-Branch: master
Gerrit-Change-Id: If4c7f946852d153bd472e5c704f8d517d26ca22e
Gerrit-Change-Number: 20770
Gerrit-PatchSet: 2
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmocom-bb[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmocom-bb/+/20770 )

Change subject: Use osmo_fd_*_{disable,enable}
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmocom-bb/+/20770
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmocom-bb
Gerrit-Branch: master
Gerrit-Change-Id: If4c7f946852d153bd472e5c704f8d517d26ca22e
Gerrit-Change-Number: 20770
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:14:55 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-msc[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-msc/+/20785 )

Change subject: Use osmo_fd_*_{disable,enable}
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/20785
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-Change-Id: I5208124e08d3b403492fe83acee235e61e423450
Gerrit-Change-Number: 20785
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:14:24 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-pcap[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-pcap/+/20783 )

Change subject: Use osmo_fd_*_{disable,enable}
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/20783
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: I97e100b34e9d26cf5acaa57be12879787d4d2d2b
Gerrit-Change-Number: 20783
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:13:56 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-pcap[master]: Use osmo_fd_*_{disable,enable}

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-pcap/+/20783 )

Change subject: Use osmo_fd_*_{disable,enable}
..

Use osmo_fd_*_{disable,enable}

Change-Id: I97e100b34e9d26cf5acaa57be12879787d4d2d2b
Depends: libosmocore.git Idb89ba7bc7c129a6304a76900d17f47daf54d17d
---
M src/osmo_tls.c
1 file changed, 4 insertions(+), 5 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, but someone else must approve
  laforge: Looks good to me, approved



diff --git a/src/osmo_tls.c b/src/osmo_tls.c
index f1671e9..f1f08ca 100644
--- a/src/osmo_tls.c
+++ b/src/osmo_tls.c
@@ -191,10 +191,9 @@
if (rc == 0) {
/* handshake is done. start writing if we are allowed to */
LOGP(DTLS, LOGL_NOTICE, "TLS handshake done.\n");
+   osmo_fd_read_enable(_session->wqueue->bfd);
if (!llist_empty(_session->wqueue->msg_queue))
-   tls_session->wqueue->bfd.when = OSMO_FD_WRITE | 
OSMO_FD_READ;
-   else
-   tls_session->wqueue->bfd.when = OSMO_FD_READ;
+   osmo_fd_write_enable(_session->wqueue->bfd);
tls_session->need_handshake = false;
release_keys(tls_session);
if (tls_session->handshake_done)
@@ -227,7 +226,7 @@
 static int tls_write(struct osmo_tls_session *sess)
 {
int rc;
-   sess->wqueue->bfd.when &= ~OSMO_FD_WRITE;
+   osmo_fd_write_disable(>wqueue->bfd);

if (llist_empty(>wqueue->msg_queue))
return 0;
@@ -252,7 +251,7 @@
}

if (sess->need_resend || !llist_empty(>wqueue->msg_queue))
-   sess->wqueue->bfd.when |= OSMO_FD_WRITE;
+   osmo_fd_write_enable(>wqueue->bfd);
return rc;
 }


--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/20783
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: I97e100b34e9d26cf5acaa57be12879787d4d2d2b
Gerrit-Change-Number: 20783
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-e1-recorder[master]: fix build against recent libosmo-abis (typo fixes)

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-e1-recorder/+/21053 )

Change subject: fix build against recent libosmo-abis (typo fixes)
..

fix build against recent libosmo-abis (typo fixes)

libosmo-abis Change-Id Ifb22b5544cf06012fa529828dfdf3f0d73b07e7d
fixed spelling from existant -> existent, which breaks some of the
tests here.

Making this change catches up, but will of course fail when older
libosmo-abis versions are used.  Given the niche nature of
osmo-e1-recorder, I think it's not worth investing time into that.

Change-Id: Ib7430bf940dea33df79abe01baae670f188ff82e
---
M tests/test_nodes.vty
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Jenkins Builder: Verified
  fixeria: Looks good to me, approved



diff --git a/tests/test_nodes.vty b/tests/test_nodes.vty
index ec52843..651079c 100644
--- a/tests/test_nodes.vty
+++ b/tests/test_nodes.vty
@@ -1,8 +1,8 @@
 osmo-e1-recorder> show e1_line
 E1 Line Number 0, Name , Driver dahdi
-DAHDI Span 1 non-existant
+DAHDI Span 1 non-existent
 E1 Line Number 1, Name , Driver dahdi
-DAHDI Span 2 non-existant
+DAHDI Span 2 non-existent
 osmo-e1-recorder> show e1_timeslot
 E1 Timeslot  1 of Line 0 is Type RAW
 E1 Timeslot  2 of Line 0 is Type RAW

--
To view, visit https://gerrit.osmocom.org/c/osmo-e1-recorder/+/21053
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-e1-recorder
Gerrit-Branch: master
Gerrit-Change-Id: Ib7430bf940dea33df79abe01baae670f188ff82e
Gerrit-Change-Number: 21053
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria 
Gerrit-Reviewer: laforge 
Gerrit-MessageType: merged


Change in osmo-sgsn[master]: osmo-gbproxy: Implement nsvc-state ctrl command

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-sgsn/+/21058 )

Change subject: osmo-gbproxy: Implement nsvc-state ctrl command
..

osmo-gbproxy: Implement nsvc-state ctrl command

Change-Id: I0beb572103803f3ee4ecb28d9bf2e3139e0f8aa4
---
M src/gbproxy/gb_proxy_ctrl.c
1 file changed, 15 insertions(+), 7 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  pespin: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/src/gbproxy/gb_proxy_ctrl.c b/src/gbproxy/gb_proxy_ctrl.c
index 3ebc7d1..9577383 100644
--- a/src/gbproxy/gb_proxy_ctrl.c
+++ b/src/gbproxy/gb_proxy_ctrl.c
@@ -33,12 +33,20 @@

 extern vector ctrl_node_vec;

-static int ctrl_nsvc_state_cb(struct gprs_ns2_vc *nsvc, void *ctx) {
-/* FIXME: Can't get NSVC state in ns2
-   struct ctrl_cmd *cmd = (struct ctrl_cmd *)ctx;
+struct nsvc_cb_data {
+   struct ctrl_cmd *cmd;
+   uint16_t nsei;
+   bool is_sgsn;
+};

-   cmd->reply = gprs_ns2_vc_state_append(cmd->reply, nsvc);
-*/
+static int ctrl_nsvc_state_cb(struct gprs_ns2_vc *nsvc, void *ctx) {
+   struct nsvc_cb_data *data = (struct nsvc_cb_data *)ctx;
+   struct ctrl_cmd *cmd = (struct ctrl_cmd *)data->cmd;
+
+   cmd->reply = talloc_asprintf_append(cmd->reply, "%u,%s,%s,%s\n",
+   data->nsei, gprs_ns2_ll_str(nsvc), 
gprs_ns2_nsvc_state_name(nsvc),
+   data->is_sgsn ? "SGSN" : "BSS" );
+
return 0;
 }

@@ -66,8 +74,8 @@
if (nse)
gprs_ns2_nse_foreach_nsvc(nse, _nsvc_state_cb, 
cmd);
}
-   cmd->reply = "Getting NSVC state not yet implemented for NS2";
-   return CTRL_CMD_ERROR;
+
+   return CTRL_CMD_REPLY;
 }

 CTRL_CMD_DEFINE_RO(nsvc_state, "nsvc-state");

--
To view, visit https://gerrit.osmocom.org/c/osmo-sgsn/+/21058
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-sgsn
Gerrit-Branch: master
Gerrit-Change-Id: I0beb572103803f3ee4ecb28d9bf2e3139e0f8aa4
Gerrit-Change-Number: 21058
Gerrit-PatchSet: 6
Gerrit-Owner: daniel 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: lynxis lazus 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-sgsn[master]: osmo-gbproxy: Implement nsvc-state ctrl command

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-sgsn/+/21058 )

Change subject: osmo-gbproxy: Implement nsvc-state ctrl command
..


Patch Set 5: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-sgsn/+/21058
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-sgsn
Gerrit-Branch: master
Gerrit-Change-Id: I0beb572103803f3ee4ecb28d9bf2e3139e0f8aa4
Gerrit-Change-Number: 21058
Gerrit-PatchSet: 5
Gerrit-Owner: daniel 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: lynxis lazus 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:11:35 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: pcu: Introduce test TC_mcs_initial_dl

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21102 )

Change subject: pcu: Introduce test TC_mcs_initial_dl
..


Patch Set 2: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21102
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ida01fb066f202033507f0c6a99212a1ff9d95423
Gerrit-Change-Number: 21102
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:10:37 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in docker-playground[master]: ogt: Install dependency python3-watchdog

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/docker-playground/+/21091 )

Change subject: ogt: Install dependency python3-watchdog
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/21091
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: I9136cef6b5a7be085c840dd798bc21493f0a47a6
Gerrit-Change-Number: 21091
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:10:56 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: pcu: Introduce test TC_mcs_max_ul

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21101 )

Change subject: pcu: Introduce test TC_mcs_max_ul
..


Patch Set 1: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21101
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I4cc77988832a2ae431ac3c5b85de940c2419bf09
Gerrit-Change-Number: 21101
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:10:27 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: pcu: Introduce test TC_mcs_initial_ul

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21095 )

Change subject: pcu: Introduce test TC_mcs_initial_ul
..


Patch Set 3: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21095
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I0ee2fce7045628caf8145468b29688a9f230e7cd
Gerrit-Change-Number: 21095
Gerrit-PatchSet: 3
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:10:11 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: pcu: Specify (M)CS to use when sending UL rlcmac data blocks

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21093 )

Change subject: pcu: Specify (M)CS to use when sending UL rlcmac data blocks
..


Patch Set 2: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21093
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I918acac81f550077daeda3374b3de9b426ff3572
Gerrit-Change-Number: 21093
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:09:47 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: RLCMAC_CSN1: Fix missing padding zero bits in UlAckNackEgprs

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21094 )

Change subject: RLCMAC_CSN1: Fix missing padding zero bits in UlAckNackEgprs
..

RLCMAC_CSN1: Fix missing padding zero bits in UlAckNackEgprs

Se 3GPP TS 44.060 Table 11.2.28.1

Change-Id: Iee04f39b43dc42efb9c2d96c46ff8e496664594a
---
M library/RLCMAC_CSN1_Templates.ttcn
M library/RLCMAC_CSN1_Types.ttcn
2 files changed, 2 insertions(+), 0 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/library/RLCMAC_CSN1_Templates.ttcn 
b/library/RLCMAC_CSN1_Templates.ttcn
index 21a7c46..727d4b8 100644
--- a/library/RLCMAC_CSN1_Templates.ttcn
+++ b/library/RLCMAC_CSN1_Templates.ttcn
@@ -196,6 +196,7 @@
};

template UlAckNackEgprs tr_UlAckNackEgprs(template GprsTlli tlli := *) 
:= {
+   msg_excape := '00'B,
ch_coding_cmd := ?,
resegment := ?,
preemptive_tx := ?,
diff --git a/library/RLCMAC_CSN1_Types.ttcn b/library/RLCMAC_CSN1_Types.ttcn
index 5ef7c44..1ffb85b 100644
--- a/library/RLCMAC_CSN1_Types.ttcn
+++ b/library/RLCMAC_CSN1_Types.ttcn
@@ -482,6 +482,7 @@
variant (cont_res_tlli) "BYTEORDER(first)"
};
type record UlAckNackEgprs {
+   BIT2msg_excape ('00'B),
EgprsChCodingCommandch_coding_cmd,
BIT1resegment,
BIT1preemptive_tx,

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21094
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Iee04f39b43dc42efb9c2d96c46ff8e496664594a
Gerrit-Change-Number: 21094
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-MessageType: merged


Change in osmo-ttcn3-hacks[master]: RLCMAC_CSN1: Fix missing padding zero bits in UlAckNackEgprs

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21094 )

Change subject: RLCMAC_CSN1: Fix missing padding zero bits in UlAckNackEgprs
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21094
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Iee04f39b43dc42efb9c2d96c46ff8e496664594a
Gerrit-Change-Number: 21094
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:09:00 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmocore[master]: tdef: Introduce OSMO_TDEF_US unit

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21047 )

Change subject: tdef: Introduce OSMO_TDEF_US unit
..

tdef: Introduce OSMO_TDEF_US unit

Some applications may need submillisecond timers, such as those
interacting with modbus serial lines (RS-485, RTU), which require
timers of values around 1.5 char-time (T1.5), where a data char is
composed of 11 bits sent on the line: 1 start bit, 8 data bits,
1 stop bit, and and parity bit (or 2nd stop bits if no parity).

For instance, for a baudrate of 9600:
1.5 * 11 / 9600 = 1.718 ms = 1718 us

So having a granularity of MS is not enough here.

Change-Id: I71848d7c1ee0649929ce07680ee7320bb2a42f0e
---
M include/osmocom/core/tdef.h
M src/tdef.c
M tests/tdef/tdef_test.c
M tests/tdef/tdef_test.ok
4 files changed, 49 insertions(+), 2 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  daniel: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/include/osmocom/core/tdef.h b/include/osmocom/core/tdef.h
index 54819d9..627ba3f 100644
--- a/include/osmocom/core/tdef.h
+++ b/include/osmocom/core/tdef.h
@@ -40,6 +40,7 @@
OSMO_TDEF_MS,   /*!< milliseconds */
OSMO_TDEF_M,/*!< minutes */
OSMO_TDEF_CUSTOM,   /*!< unspecified unit, explained in 
osmo_tdef.desc. */
+   OSMO_TDEF_US,   /*!< microseconds */
 };

 extern const struct value_string osmo_tdef_unit_names[];
diff --git a/src/tdef.c b/src/tdef.c
index 71a3315..897a92f 100644
--- a/src/tdef.c
+++ b/src/tdef.c
@@ -93,6 +93,17 @@
return 1;

switch (b) {
+   case OSMO_TDEF_US:
+   switch (a) {
+   case OSMO_TDEF_MS:
+   return 1000;
+   case OSMO_TDEF_S:
+   return 1000*1000;
+   case OSMO_TDEF_M:
+   return 60*1000*1000;
+   default:
+   return 0;
+   }
case OSMO_TDEF_MS:
switch (a) {
case OSMO_TDEF_S:
@@ -351,6 +362,7 @@
{ OSMO_TDEF_MS, "ms" },
{ OSMO_TDEF_M, "m" },
{ OSMO_TDEF_CUSTOM, "custom-unit" },
+   { OSMO_TDEF_US, "us" },
{}
 };

diff --git a/tests/tdef/tdef_test.c b/tests/tdef/tdef_test.c
index 9c0808e..d874231 100644
--- a/tests/tdef/tdef_test.c
+++ b/tests/tdef/tdef_test.c
@@ -54,6 +54,7 @@
{ .T=1006, .default_val=0, .unit=OSMO_TDEF_S, .desc="zero s" },
{ .T=1007, .default_val=0, .unit=OSMO_TDEF_M, .desc="zero m" },
{ .T=1008, .default_val=0, .unit=OSMO_TDEF_CUSTOM, .desc="zero" },
+   { .T=1009, .default_val=0, .unit=OSMO_TDEF_US, .desc="zero us" },

{ .T=0, .default_val=1, .unit=OSMO_TDEF_CUSTOM, .desc="zero" },

@@ -111,7 +112,7 @@
for (i = 0; i < ARRAY_SIZE(tdefs)-1; i++) {
unsigned int T = tdefs[i].T;
print_tdef_info(T);
-   for (as_unit = OSMO_TDEF_S; as_unit <= OSMO_TDEF_CUSTOM; 
as_unit++) {
+   for (as_unit = OSMO_TDEF_S; as_unit <= OSMO_TDEF_US; as_unit++) 
{
print_tdef_get_short(tdefs, T, as_unit);
}
}
@@ -122,7 +123,7 @@
for (i = 0; i < ARRAY_SIZE(tdefs_range)-1; i++) {
unsigned int T = tdefs_range[i].T;
print_tdef_info(T);
-   for (as_unit = OSMO_TDEF_S; as_unit <= OSMO_TDEF_CUSTOM; 
as_unit++) {
+   for (as_unit = OSMO_TDEF_S; as_unit <= OSMO_TDEF_US; as_unit++) 
{
print_tdef_get_short(tdefs_range, T, as_unit);
}
}
@@ -136,6 +137,7 @@
print_tdef_get(tdefs, 5, OSMO_TDEF_MS);
print_tdef_get(tdefs, 5, OSMO_TDEF_M);
print_tdef_get(tdefs, 5, OSMO_TDEF_CUSTOM);
+   print_tdef_get(tdefs, 5, OSMO_TDEF_US);
 }

 static void test_tdef_set_and_get()
@@ -152,6 +154,7 @@
print_tdef_get_short(tdefs, 7, OSMO_TDEF_S);
print_tdef_get_short(tdefs, 7, OSMO_TDEF_M);
print_tdef_get_short(tdefs, 7, OSMO_TDEF_CUSTOM);
+   print_tdef_get_short(tdefs, 7, OSMO_TDEF_US);

printf("setting 7 = 420\n");
OSMO_ASSERT(osmo_tdef_set(tdefs, 7, 420, OSMO_TDEF_S) == 0);
@@ -160,6 +163,7 @@
print_tdef_get_short(tdefs, 7, OSMO_TDEF_S);
print_tdef_get_short(tdefs, 7, OSMO_TDEF_M);
print_tdef_get_short(tdefs, 7, OSMO_TDEF_CUSTOM);
+   print_tdef_get_short(tdefs, 7, OSMO_TDEF_US);

printf("setting 7 = 10 (ERANGE)\n");
OSMO_ASSERT(!osmo_tdef_val_in_range(t, 10));
@@ -169,6 +173,7 @@
print_tdef_get_short(tdefs, 7, OSMO_TDEF_S);
print_tdef_get_short(tdefs, 7, OSMO_TDEF_M);
print_tdef_get_short(tdefs, 7, OSMO_TDEF_CUSTOM);
+   print_tdef_get_short(tdefs, 7, OSMO_TDEF_US);

printf("setting 7 = 900 (ERANGE)\n");
OSMO_ASSERT(!osmo_tdef_val_in_range(t, 900));
@@ -178,6 

Change in osmo-ttcn3-hacks[master]: RLCMAC: Fix stall_ind param not used

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21092 )

Change subject: RLCMAC: Fix stall_ind param not used
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21092
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ie1b6c66467028da8f93ccc42e5048daca3b68192
Gerrit-Change-Number: 21092
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:08:43 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in libosmocore[master]: tdef: Introduce OSMO_TDEF_US unit

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21047 )

Change subject: tdef: Introduce OSMO_TDEF_US unit
..


Patch Set 2: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/21047
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I71848d7c1ee0649929ce07680ee7320bb2a42f0e
Gerrit-Change-Number: 21047
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: neels 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:08:23 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: RLCMAC: Fix stall_ind param not used

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21092 )

Change subject: RLCMAC: Fix stall_ind param not used
..

RLCMAC: Fix stall_ind param not used

Change-Id: Ie1b6c66467028da8f93ccc42e5048daca3b68192
---
M library/RLCMAC_Templates.ttcn
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  laforge: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/library/RLCMAC_Templates.ttcn b/library/RLCMAC_Templates.ttcn
index b18c8db..9722f43 100644
--- a/library/RLCMAC_Templates.ttcn
+++ b/library/RLCMAC_Templates.ttcn
@@ -382,7 +382,7 @@
mac_hdr := {
payload_type := MAC_PT_RLC_DATA,
countdown := cv,
-   stall_ind := false,
+   stall_ind := stall,
retry := false,
spare := '0'B,
pfi_ind := false,
@@ -403,7 +403,7 @@
mac_hdr := {
payload_type := MAC_PT_RLC_DATA,
countdown := cv,
-   stall_ind := false,
+   stall_ind := stall,
retry := false,
spare := '0'B,
pfi_ind := false,

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21092
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ie1b6c66467028da8f93ccc42e5048daca3b68192
Gerrit-Change-Number: 21092
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-MessageType: merged


Change in libosmo-sccp[master]: update VTY / copyright message

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmo-sccp/+/21112 )

Change subject: update VTY / copyright message
..

update VTY / copyright message

* extend year to 2020
* Pau and Vadim have contributed significatnly
* fix typo (ot -> to)

Change-Id: I5c23e704dd958faf450b2427ff706ac65d4848f4
---
M stp/stp_main.c
1 file changed, 3 insertions(+), 3 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, approved



diff --git a/stp/stp_main.c b/stp/stp_main.c
index 33305b3..42f7108 100644
--- a/stp/stp_main.c
+++ b/stp/stp_main.c
@@ -60,10 +60,10 @@
 };

 static const char stp_copyright[] =
-   "Copyright (C) 2015-2017 by Harald Welte \r\n"
-   "Contributions by Holger Freyther, Neels Hofmeyr\r\n"
+   "Copyright (C) 2015-2020 by Harald Welte \r\n"
+   "Contributions by Holger Freyther, Neels Hofmeyr, Pau Espin, Vadim 
Yanitskiy\r\n"
"License GPLv2+: GNU GPL Version 2 or later 
\r\n"
-   "This is free software: you are free ot change and redistribute it.\r\n"
+   "This is free software: you are free to change and redistribute it.\r\n"
"There is NO WARRANTY, to the extent permitted by law.\r\n\r\n"
"Free Software lives by contribution.  If you use this, please 
contribute!\r\n";


--
To view, visit https://gerrit.osmocom.org/c/libosmo-sccp/+/21112
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-Change-Id: I5c23e704dd958faf450b2427ff706ac65d4848f4
Gerrit-Change-Number: 21112
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-MessageType: merged


Change in libosmo-sccp[master]: update VTY / copyright message

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmo-sccp/+/21112 )

Change subject: update VTY / copyright message
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/libosmo-sccp/+/21112
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-Change-Id: I5c23e704dd958faf450b2427ff706ac65d4848f4
Gerrit-Change-Number: 21112
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:07:10 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-bts[master]: l1sap: add repeated downlink FACCH

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/21014 )

Change subject: l1sap: add repeated downlink FACCH
..


Patch Set 5:

(1 comment)

https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/vty.c
File src/common/vty.c:

https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/vty.c@805
PS5, Line 805: "facch-repetition",
why would we ant to have a configuration item for that in the BTS?  Shouldn't 
it be the policy of the BSC to simply not include the proprietary IE if SACCH 
repetiton is forbidden for administrative reasons?

In general, everything that can be configured in the BSC should be configured 
in the BSC, if they can be communicated over Abis.  And as we're adding that 
new IE anyway, I don't understand why we need a config here.

Every new configuration parameter we add (particularly in the "low level" parts 
of the network like BTS or PCU) is one parameter more than people are likely to 
forget about or set wrong.



--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21014
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I72f0cf7eaaef9f80fc35e752c90ae0e2d24d0c75
Gerrit-Change-Number: 21014
Gerrit-PatchSet: 5
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: fixeria 
Gerrit-CC: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:06:39 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment


Change in osmo-bts[master]: l1sap: also include SRR bit in RSL l1 info field.

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/21088 )

Change subject: l1sap: also include SRR bit in RSL l1 info field.
..


Patch Set 3: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21088
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I987c61608b737521ba36756dabf2f6215b34c2d6
Gerrit-Change-Number: 21088
Gerrit-PatchSet: 3
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-CC: fixeria 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:01:59 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-bts[master]: l1sap: add repeated downlink FACCH

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/21014 )

Change subject: l1sap: add repeated downlink FACCH
..


Patch Set 5:

(1 comment)

https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/l1sap.c
File src/common/l1sap.c:

https://gerrit.osmocom.org/c/osmo-bts/+/21014/5/src/common/l1sap.c@932
PS5, Line 932: 2715648
I'm sure we have some proper defines or macros related to that and we should 
not resort to magic numbers.



--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21014
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I72f0cf7eaaef9f80fc35e752c90ae0e2d24d0c75
Gerrit-Change-Number: 21014
Gerrit-PatchSet: 5
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: fixeria 
Gerrit-CC: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 20:01:12 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment


Change in osmo-bts[master]: rsl.adoc: add info about RSL_IE_OSMO_REP_ACCH_CAP

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/21085 )

Change subject: rsl.adoc: add info about RSL_IE_OSMO_REP_ACCH_CAP
..


Patch Set 4: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21085
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I1d70846c2c184f7a189074c51137bc1f38fb3859
Gerrit-Change-Number: 21085
Gerrit-PatchSet: 4
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 19:59:30 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-bts[master]: rsl.adoc: add info about RSL_IE_OSMO_REP_ACCH_CAP

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/21085 )

Change subject: rsl.adoc: add info about RSL_IE_OSMO_REP_ACCH_CAP
..

rsl.adoc: add info about RSL_IE_OSMO_REP_ACCH_CAP

The RSL documentation should reflect some explanatory info about the
recently added RSL_IE_OSMO_REP_ACCH_CAP IE.

Depends: libosmocore I61ea6bf54ea90bd69b73ea0f0f3dc19a4214207b
Change-Id: I1d70846c2c184f7a189074c51137bc1f38fb3859
Related: OS#4796 SYS#5114
---
M doc/manuals/abis/rsl.adoc
1 file changed, 10 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, but someone else must approve
  laforge: Looks good to me, approved



diff --git a/doc/manuals/abis/rsl.adoc b/doc/manuals/abis/rsl.adoc
index 20ee836..8843a74 100644
--- a/doc/manuals/abis/rsl.adoc
+++ b/doc/manuals/abis/rsl.adoc
@@ -842,6 +842,7 @@
 |===
 | IEI  | Name | This document §
 | 0x01 | RSL_IE_CHAN_NR | <>
+| 0x60 | RSL_IE_OSMO_REP_ACCH_CAP | <>
 | 0xf0 | RSL_IE_IPAC_REMOTE_IP | <>
 | 0xf1 | RSL_IE_IPAC_REMOTE_PORT | <>
 | 0xf3 | RSL_IE_IPAC_LOCAL_PORT | <>
@@ -953,6 +954,15 @@
 used in the PT (Payload Type) field of the RTP header in subsequent
 transmissions of the RTP flow.

+[[RSL_IE_OSMO_REP_ACCH_CAP]]
+ RSL_IE_OSMO_REP_ACCH_CAP
+
+This is a one byte length TLV IE that is used to enable or disable repeated 
ACCH
+capabilities on the BTS side during Channel Activation and Mode Modify. If the
+IE is present and its value byte is set to 0x01, then the BTS will enable
+repeated ACCH capabilities, otherwise the channel is activated without repeated
+ACCH capabilities present.
+
 === A-bis RSL Initialization / BTS bring-up

 Upon receiving the 'IPA RSL CONNECT' OML message by the respective

--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21085
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I1d70846c2c184f7a189074c51137bc1f38fb3859
Gerrit-Change-Number: 21085
Gerrit-PatchSet: 4
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-bsc[master]: abis_rsl: parse cm3 and indicate ACCH repetition cap to BTS

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-bsc/+/21084 )

Change subject: abis_rsl: parse cm3 and indicate ACCH repetition cap to BTS
..


Patch Set 3:

(1 comment)

https://gerrit.osmocom.org/c/osmo-bsc/+/21084/1/include/osmocom/bsc/gsm_data.h
File include/osmocom/bsc/gsm_data.h:

https://gerrit.osmocom.org/c/osmo-bsc/+/21084/1/include/osmocom/bsc/gsm_data.h@328
PS1, Line 328:  bool repeated_acch_capability;
> what about storing here the whole MS cm3 in case we need more info later?
yes, I also think that is a very good idea, but it could be done in a 
subsequent patch.  The more advanced features we add, the more likely we need 
access to decoded CM3



--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/21084
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I39ae439d05562b35b2e47774dc92f8789fea1a57
Gerrit-Change-Number: 21084
Gerrit-PatchSet: 3
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge 
Gerrit-CC: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 19:58:43 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin 
Gerrit-MessageType: comment


Change in libosmocore[master]: gsm_04_08: add parser for Mobile Station Classmark 3

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21083 )

Change subject: gsm_04_08: add parser for Mobile Station Classmark 3
..

gsm_04_08: add parser for Mobile Station Classmark 3

3GPP TS 24.008 section 10.5.1.7 describes a Mobile Station Classmark 3
IE, which is encoded as CSN.1 struct. This means that it can not be
parsed by just casting a memory location to a struct pointer, so lets
add a parser to parse the CM3 IE.

Change-Id: Ic8b2bfd00330235f5bed00771e421588abfaac1f
Related: OS#4796 SYS#5114
---
M include/osmocom/gsm/gsm48_ie.h
M include/osmocom/gsm/protocol/gsm_04_08.h
M src/gsm/gsm48_ie.c
M src/gsm/libosmogsm.map
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
6 files changed, 960 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, approved



diff --git a/include/osmocom/gsm/gsm48_ie.h b/include/osmocom/gsm/gsm48_ie.h
index 339aa13..b79cbfc 100644
--- a/include/osmocom/gsm/gsm48_ie.h
+++ b/include/osmocom/gsm/gsm48_ie.h
@@ -119,3 +119,7 @@
 /* decode "Cell Channel Description" (10.5.2.1b) and other frequency lists */
 int gsm48_decode_freq_list(struct gsm_sysinfo_freq *f, uint8_t *cd,
   uint8_t len, uint8_t mask, uint8_t frqt);
+
+/* decode "CSN.1 encoded Classmark 3" (10.5.1.7) */
+int gsm48_decode_classmark3(struct gsm48_classmark3 *classmark3_out,
+   const uint8_t *classmark3, size_t classmark3_len);
diff --git a/include/osmocom/gsm/protocol/gsm_04_08.h 
b/include/osmocom/gsm/protocol/gsm_04_08.h
index df13b15..2093bee 100644
--- a/include/osmocom/gsm/protocol/gsm_04_08.h
+++ b/include/osmocom/gsm/protocol/gsm_04_08.h
@@ -58,6 +58,175 @@
 #endif
 } __attribute__ ((packed));

+/* Chapter 10.5.1.7 */
+struct gsm48_classmark3 {
+   uint8_t a5_bits;
+   uint8_t mult_band_supp;
+   uint8_t assoc_radio_cap_1;
+   uint8_t assoc_radio_cap_2;
+
+   struct {
+   bool present;
+   uint8_t r_gsm_assoc_radio_cap;
+   } r_support;
+
+   struct {
+   bool present;
+   uint8_t class;
+   } hscsd_mult_slot_cap;
+
+   bool ucs2_treatment;
+   bool extended_meas_cap;
+
+   struct {
+   bool present;
+   uint8_t sms_value;
+   uint8_t sm_value;
+   } ms_meas_cap;
+
+   struct {
+   bool present;
+   uint8_t method;
+   } ms_pos_method_cap;
+
+   struct {
+   bool present;
+   uint8_t class;
+   } ecsd_multislot_cap;
+
+   struct {
+   bool present;
+   bool mod_cap;
+
+   struct {
+   bool present;
+   uint8_t value;
+   } rf_pwr_cap_1;
+
+   struct {
+   bool present;
+   uint8_t value;
+   } rf_pwr_cap_2;
+
+   } psk8_struct;
+
+   struct {
+   bool present;
+   uint8_t value;
+   uint8_t assoc_radio_cap;
+   } gsm_400_bands_supp;
+
+   struct {
+   bool present;
+   uint8_t value;
+   } gsm_850_assoc_radio_cap;
+
+   struct {
+   bool present;
+   uint8_t value;
+   } gsm_1900_assoc_radio_cap;
+
+   bool umts_fdd_rat_cap;
+   bool umts_tdd_rat_cap;
+   bool cdma200_rat_cap;
+
+   struct {
+   bool present;
+   uint8_t class;
+   bool single_slot_dtm;
+   struct {
+   bool present;
+   uint8_t class;
+   } dtm_egprs_multislot_cap;
+   } dtm_gprs_multislot_cap;
+
+   struct {
+   bool present;
+   uint8_t value;
+   } single_band_supp;
+
+   struct {
+   bool present;
+   uint8_t value;
+   } gsm_750_assoc_radio_cap;
+
+   bool umts_1_28_mcps_tdd_rat_cap;
+   bool geran_feature_package;
+
+   struct {
+   bool present;
+   uint8_t class;
+   struct {
+   bool present;
+   uint8_t class;
+   } extended_dtm_egprs_multislot_cap;
+   } extended_dtm_gprs_multislot_cap;
+
+   struct {
+   bool present;
+   uint8_t value;
+   } high_multislot_cap;
+
+   bool geran_feature_package_2;
+   uint8_t gmsk_multislot_power_prof;
+   uint8_t psk8_multislot_power_prof;
+
+   struct {
+   bool present;
+   uint8_t value;
+   uint8_t assoc_radio_cap;
+   } t_gsm_400_bands_supp;
+
+   uint8_t dl_advanced_rx_perf;
+   bool dtm_enhancements_cap;
+
+   struct {
+   bool present;
+   uint8_t class;
+   bool offset_required;
+   struct {
+   

Change in libosmocore[master]: gsm_04_08: add parser for Mobile Station Classmark 3

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/21083 )

Change subject: gsm_04_08: add parser for Mobile Station Classmark 3
..


Patch Set 5: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/21083
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ic8b2bfd00330235f5bed00771e421588abfaac1f
Gerrit-Change-Number: 21083
Gerrit-PatchSet: 5
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: pespin 
Gerrit-CC: fixeria 
Gerrit-Comment-Date: Wed, 11 Nov 2020 19:56:37 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: FRNET: Add 'control' section

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21106 )

Change subject: FRNET: Add 'control' section
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21106
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: If08fa3572050fcd794be054afd4ebc44cd6580f6
Gerrit-Change-Number: 21106
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Comment-Date: Wed, 11 Nov 2020 19:54:24 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: FRNET: Add 'control' section

2020-11-11 Thread laforge
laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21106 )

Change subject: FRNET: Add 'control' section
..

FRNET: Add 'control' section

FR_Tests already had a control section, but FRNET_Tests didn't have one,
let's change that.

Change-Id: If08fa3572050fcd794be054afd4ebc44cd6580f6
---
M fr-net/FRNET_Tests.ttcn
1 file changed, 4 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, approved



diff --git a/fr-net/FRNET_Tests.ttcn b/fr-net/FRNET_Tests.ttcn
index c2994f6..010ca50 100644
--- a/fr-net/FRNET_Tests.ttcn
+++ b/fr-net/FRNET_Tests.ttcn
@@ -76,5 +76,9 @@
}
 }

+control {
+   execute( TC_foo() );
+}
+

 }

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21106
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: If08fa3572050fcd794be054afd4ebc44cd6580f6
Gerrit-Change-Number: 21106
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-MessageType: merged


Change in libosmo-sccp[master]: update VTY / copyright message

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/libosmo-sccp/+/21112 )


Change subject: update VTY / copyright message
..

update VTY / copyright message

* extend year to 2020
* Pau and Vadim have contributed significatnly
* fix typo (ot -> to)

Change-Id: I5c23e704dd958faf450b2427ff706ac65d4848f4
---
M stp/stp_main.c
1 file changed, 3 insertions(+), 3 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmo-sccp refs/changes/12/21112/1

diff --git a/stp/stp_main.c b/stp/stp_main.c
index 33305b3..42f7108 100644
--- a/stp/stp_main.c
+++ b/stp/stp_main.c
@@ -60,10 +60,10 @@
 };

 static const char stp_copyright[] =
-   "Copyright (C) 2015-2017 by Harald Welte \r\n"
-   "Contributions by Holger Freyther, Neels Hofmeyr\r\n"
+   "Copyright (C) 2015-2020 by Harald Welte \r\n"
+   "Contributions by Holger Freyther, Neels Hofmeyr, Pau Espin, Vadim 
Yanitskiy\r\n"
"License GPLv2+: GNU GPL Version 2 or later 
\r\n"
-   "This is free software: you are free ot change and redistribute it.\r\n"
+   "This is free software: you are free to change and redistribute it.\r\n"
"There is NO WARRANTY, to the extent permitted by law.\r\n\r\n"
"Free Software lives by contribution.  If you use this, please 
contribute!\r\n";


--
To view, visit https://gerrit.osmocom.org/c/libosmo-sccp/+/21112
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-Change-Id: I5c23e704dd958faf450b2427ff706ac65d4848f4
Gerrit-Change-Number: 21112
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-MessageType: newchange


Change in osmo-ttcn3-hacks[master]: NS_Emulation: Support multiple NS-VC within one NSE (NS-VCG)

2020-11-11 Thread laforge
laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21087 )

Change subject: NS_Emulation: Support multiple NS-VC within one NSE (NS-VCG)
..


Patch Set 3:

> Patch Set 1: Code-Review+1
>
> I see no related docker-playground patch updating the config files?

thanks, patch was still in the pipeline, I now pushed it 
(https://gerrit.osmocom.org/c/docker-playground/+/2).  I'll try to run all 
the tests with tat patch applied and report there.


--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21087
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: If1220852785853f8a5d8de183d5053ddd6ccb958
Gerrit-Change-Number: 21087
Gerrit-PatchSet: 3
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 19:39:15 +
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment


Change in docker-playground[master]: NS_Configuration: Adjust config regarding support for NS-VCG

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/docker-playground/+/2 )


Change subject: NS_Configuration: Adjust config regarding support for NS-VCG
..

NS_Configuration: Adjust config regarding support for NS-VCG

In osmo-ttcn3-hacks.git Change-Id If1220852785853f8a5d8de183d5053ddd6ccb958
we introduce support for multiple NS-VC inside a NS-VCG.  This modifies
the configuration structures, and we need to adjust all config files
accordingly.

Change-Id: I6ac250555c3ac2aa8feb70bd3a052aafec5d4210
---
M ttcn3-gbproxy-test/GBProxy_Tests.cfg
M ttcn3-pcu-test/PCU_Tests.cfg
M ttcn3-pcu-test/sns/PCU_Tests.cfg
M ttcn3-sgsn-test/SGSN_Tests.cfg
4 files changed, 100 insertions(+), 66 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/docker-playground 
refs/changes/11/2/1

diff --git a/ttcn3-gbproxy-test/GBProxy_Tests.cfg 
b/ttcn3-gbproxy-test/GBProxy_Tests.cfg
index 7f6c303..6b097a3 100644
--- a/ttcn3-gbproxy-test/GBProxy_Tests.cfg
+++ b/ttcn3-gbproxy-test/GBProxy_Tests.cfg
@@ -14,44 +14,58 @@
 [MODULE_PARAMETERS]
 GBProxy_Tests.mp_nsconfig_sgsn := {
{
-   provider := {
-   ip := {
-   address_family := AF_INET,
-   local_ip := "172.18.24.103",
-   local_udp_port := 23000,
-   remote_ip := "172.18.24.10"
+   nsvc := {
+   {
+   provider := {
+   ip := {
+   address_family := AF_INET,
+   local_ip := "172.18.24.103",
+   local_udp_port := 23000,
+   remote_ip := "172.18.24.10"
+   }
+   }
}
}
}
 }
 GBProxy_Tests.mp_nsconfig_pcu := {
-   {
-   provider := {
-   ip := {
-   address_family := AF_INET,
-   local_ip := "172.18.24.103",
-   remote_ip := "172.18.24.10"
-   }
-   }
-   },
-{
-   provider := {
-   ip := {
-   address_family := AF_INET,
-   local_ip := "172.18.24.103",
-   remote_ip := "172.18.24.10"
-   }
-   }
-   },
-{
-   provider := {
-   ip := {
-   address_family := AF_INET,
-   local_ip := "172.18.24.103",
-   remote_ip := "172.18.24.10"
+   {
+   nsvc := {
+   {
+   provider := {
+   ip := {
+   address_family := AF_INET,
+   local_ip := "172.18.24.103",
+   remote_ip := "172.18.24.10"
+   }
}
}
}
+   }, {
+   nsvc := {
+   {
+   provider := {
+   ip := {
+   address_family := AF_INET,
+   local_ip := "172.18.24.103",
+   remote_ip := "172.18.24.10"
+   }
+   }
+   }
+   }
+   }, {
+   nsvc := {
+   {
+   provider := {
+   ip := {
+   address_family := AF_INET,
+   local_ip := "172.18.24.103",
+   remote_ip := "172.18.24.10"
+   }
+   }
+   }
+   }
+   }
 }

 [MAIN_CONTROLLER]
diff --git a/ttcn3-pcu-test/PCU_Tests.cfg b/ttcn3-pcu-test/PCU_Tests.cfg
index 4bf2906..9e69f86 100644
--- a/ttcn3-pcu-test/PCU_Tests.cfg
+++ b/ttcn3-pcu-test/PCU_Tests.cfg
@@ -15,18 +15,22 @@
 PCU_Tests.mp_pcu_sock_path := "/data/unix/pcu_bts"
 PCU_Tests.mp_pcu_statsd_ip := "172.18.13.10"
 

Change in osmo-ttcn3-hacks[master]: NS_Emulation: Support multiple NS-VC within one NSE (NS-VCG)

2020-11-11 Thread laforge
Hello Jenkins Builder, pespin,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21087

to look at the new patch set (#3).

Change subject: NS_Emulation: Support multiple NS-VC within one NSE (NS-VCG)
..

NS_Emulation: Support multiple NS-VC within one NSE (NS-VCG)

This is something we need to simulate more complex scenarios,
particularly in the context of frame relay.

Change-Id: If1220852785853f8a5d8de183d5053ddd6ccb958
---
M fr-net/FRNET_Tests.ttcn
M fr/FR_Tests.ttcn
M gbproxy/GBProxy_Tests.cfg
M gbproxy/GBProxy_Tests.ttcn
M library/BSSGP_Emulation.ttcnpp
M library/NS_Emulation.ttcnpp
M library/NS_Provider_FR.ttcn
M library/NS_Provider_IPL4.ttcn
M library/RAW_NS.ttcn
M pcu/PCU_Tests.cfg
M pcu/PCU_Tests.ttcn
M pcu/PCU_Tests_NS.ttcn
M pcu/PCU_Tests_SNS.cfg
M pcu/PCU_Tests_SNS.ttcn
M pcu/PCU_Tests_SNSv6.cfg
M pcu/SGSN_Components.ttcn
M sgsn/SGSN_Tests.cfg
M sgsn/SGSN_Tests.ttcn
18 files changed, 598 insertions(+), 351 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/87/21087/3
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21087
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: If1220852785853f8a5d8de183d5053ddd6ccb958
Gerrit-Change-Number: 21087
Gerrit-PatchSet: 3
Gerrit-Owner: laforge 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-MessageType: newpatchset


Change in osmo-ttcn3-hacks[master]: NS_Emulation: Introduce Load Sharing Function

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21109 )


Change subject: NS_Emulation: Introduce Load Sharing Function
..

NS_Emulation: Introduce Load Sharing Function

The Load Sharing Function distributes traffic among all unblocked NS-VC
within a NS-VCG.  The sharing is done based on a LSP (Link Selector
Parameter) which is passed with the NS-UNITDATA.req primitive from BSSGP
to NS.  Details are implementation specific, but NS must ensure that all
traffic of one LSP is always sent through the same NS-VC, as long as
that NS-VC is alive/unblocked.

We use the LSP as follows:
* Signaling BVC always only uses lsp 0
* PTP BVC messages unrelated to user straffic use a per-BVC static LSP,
  which is the BVCI
* User traffic can set whatever LSP it wants
* NS keeps an array of NSVCs currently unblocked and uses the LSP modulo
  the array size as an index into it

Change-Id: I8b960ec4d729f50cadca353bb52685311cd45eed
Related: SYS#5084
---
M library/BSSGP_Emulation.ttcnpp
M library/NS_Emulation.ttcnpp
2 files changed, 68 insertions(+), 36 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/09/21109/1

diff --git a/library/BSSGP_Emulation.ttcnpp b/library/BSSGP_Emulation.ttcnpp
index 1370958..cb0c82c 100644
--- a/library/BSSGP_Emulation.ttcnpp
+++ b/library/BSSGP_Emulation.ttcnpp
@@ -274,14 +274,14 @@
/* Respond to RESET for signalling BVCI 0 */
[] BSCP.receive(f_BnsUdInd(tr_BVC_RESET(?, 0, omit), 0)) -> value udi {
log("Rx BVC-RESET for Signaling BVCI=0");
-   BSCP.send(f_BnsUdReq(ts_BVC_RESET_ACK(0, omit), 0));
+   BSCP.send(f_BnsUdReq(ts_BVC_RESET_ACK(0, omit), 0, 0));
f_sign_change_state(BVC_S_UNBLOCKED);
}

/* work-around for old, buggy libosmogb before Change-Id 
Ie87820537d6d616da4fd4bbf73eab06e28fda5e1 */
[mp_tolerate_bvc_reset_cellid] BSCP.receive(f_BnsUdInd(tr_BVC_RESET(?, 
0, g_cfg.bvc[0].cell_id), 0)) -> value udi {
log("Rx BVC-RESET for Signaling BVCI=0");
-   BSCP.send(f_BnsUdReq(ts_BVC_RESET_ACK(0, omit), 0));
+   BSCP.send(f_BnsUdReq(ts_BVC_RESET_ACK(0, omit), 0, 0));
f_sign_change_state(BVC_S_UNBLOCKED);
}
 }
@@ -301,7 +301,7 @@
BVC.send(udi) to bvc_comp_ref;
} else {
setverdict(fail, "Rx BSSGP for unknown PTP BVCI ", 
udi.bvci, ": ", udi.bssgp);
-   BSCP.send(f_BnsUdReq(ts_BSSGP_STATUS(udi.bvci, 
BSSGP_CAUSE_BVCI_UNKNOWN, udi.bssgp), udi.bvci));
+   BSCP.send(f_BnsUdReq(ts_BSSGP_STATUS(udi.bvci, 
BSSGP_CAUSE_BVCI_UNKNOWN, udi.bssgp), udi.bvci, 0));
}
}

@@ -324,7 +324,7 @@
BVC.send(udi) to bvc_comp_ref;
} else {
setverdict(fail, "Rx SIG BSSGP for unknown PTP 
BVCI ", ptp_bvci, ": ", udi.bssgp);
-   BSCP.send(f_BnsUdReq(ts_BSSGP_STATUS(udi.bvci, 
BSSGP_CAUSE_BVCI_UNKNOWN, udi.bssgp), 0));
+   BSCP.send(f_BnsUdReq(ts_BSSGP_STATUS(udi.bvci, 
BSSGP_CAUSE_BVCI_UNKNOWN, udi.bssgp), 0, 0));
 }
}
}
@@ -362,7 +362,7 @@
[] BSCP.receive(NsStatusIndication:{g_cfg.nsei,?, complement 
(NSVC_S_ALIVE_UNBLOCKED), NSVC_S_ALIVE_UNBLOCKED, true}) -> value nsi {
/* if we just became NS-unblocked, send a BCC-RESET */
if (g_cfg.sgsn_role == false) {
-   
BSCP.send(f_BnsUdReq(ts_BVC_RESET(BSSGP_CAUSE_OM_INTERVENTION, 0, omit), 0));
+   
BSCP.send(f_BnsUdReq(ts_BVC_RESET(BSSGP_CAUSE_OM_INTERVENTION, 0, omit), 0, 0));
g_T2.start;
/* The BVC_RESET_ACK is handled in the 
as_sig_allstate() below */
}
@@ -383,7 +383,7 @@
/* Respond to RESET for signalling BVCI 0 */
[] BSCP.receive(f_BnsUdInd(tr_BVC_RESET(?, 0, omit), 0)) -> value udi {
log("Rx BVC-RESET for Signaling BVCI=0");
-   BSCP.send(f_BnsUdReq(ts_BVC_RESET_ACK(0, omit), 0));
+   BSCP.send(f_BnsUdReq(ts_BVC_RESET_ACK(0, omit), 0, 0));
for (var integer i := 0; i < sizeof(BvcTable); i := i+1) {
if (isbound(BvcTable[i].comp_ref) and 
BvcTable[i].comp_ref != null) {
BVC.send(BssgpResetIndication:{0}) to 
BvcTable[i].comp_ref;
@@ -408,14 +408,14 @@
/* Respond to BLOCK for wrong BVCI */
[] BSCP.receive(f_BnsUdInd(t_BVC_BLOCK(?, ?), 0)) -> value udi {
setverdict(fail, "Rx BVC-BLOCK for unknown BVCI");
-   BSCP.send(f_BnsUdReq(ts_BSSGP_STATUS(0, 
BSSGP_CAUSE_BVCI_UNKNOWN, udi.bssgp), 0));
+   BSCP.send(f_BnsUdReq(ts_BSSGP_STATUS(0, 

Change in osmo-ttcn3-hacks[master]: FR/FRNET: Dynamically create number of BVC at runtime

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21110 )


Change subject: FR/FRNET: Dynamically create number of BVC at runtime
..

FR/FRNET: Dynamically create number of BVC at runtime

We don't want the number of NSE and the number of BVC to be a
compile-time choice, but rather something dynamic at rutime.  This
allows configuration files to define those details.

Change-Id: I55b44481b5322deaf78619c1689462d716ddfcec
---
M fr-net/FRNET_Tests.ttcn
M fr/FR_Tests.ttcn
2 files changed, 70 insertions(+), 49 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/10/21110/1

diff --git a/fr-net/FRNET_Tests.ttcn b/fr-net/FRNET_Tests.ttcn
index 593ca77..721dd32 100644
--- a/fr-net/FRNET_Tests.ttcn
+++ b/fr-net/FRNET_Tests.ttcn
@@ -8,6 +8,7 @@
 import from BSSGP_Emulation all;

 modulepar {
+   integer mp_num_bvc := 10;
NSConfigurations mp_nsconfig := {
{
nsei := 123,
@@ -34,11 +35,9 @@
BssgpConfig cfg
 };

-const integer NUM_GB := 1;
-type record length(NUM_GB) of GbInstance GbInstances;
-type record length(NUM_GB) of NSConfiguration NSConfigurations;
-type record length(NUM_GB) of BssgpCellId BssgpCellIds;
-
+type record of GbInstance GbInstances;
+type record of NSConfiguration NSConfigurations;
+type record of BssgpCellId BssgpCellIds;

 type component test_CT {
var GbInstances g_gb;
@@ -53,28 +52,39 @@
gb.vc_BSSGP.start(BssgpStart(gb.cfg, testcasename()));
 }

-testcase TC_foo() runs on test_CT {
-   g_gb[0].cfg := {
-   nsei := 123,
-   sgsn_role := true,
-   bvc := {
-   {
-   bvci := 1123,
-   cell_id := {
-   ra_id := {
-   lai := {
-   mcc_mnc := '262F42'H,
-   lac := 11123
-   },
-   rac := 1
-   },
-   cell_id := 31123
+function f_gen_bvc(integer base, integer idx) return BssgpBvcConfig {
+   var BssgpBvcConfig bvc := {
+   bvci := base + 100 + idx,
+   cell_id := {
+   ra_id := {
+   lai := {
+   mcc_mnc := '262F42'H,
+   lac := base + 300 + idx
},
-   depth := BSSGP_DECODE_DEPTH_LLC
-   }
-   }
+   rac := 1
+   },
+   cell_id := base + 600 + idx
+   },
+   depth := BSSGP_DECODE_DEPTH_LLC
};
-   f_init_gb(g_gb[0], "gb", 0);
+   return bvc;
+}
+
+testcase TC_foo() runs on test_CT {
+
+   for (var integer i := 0; i < lengthof(mp_nsconfig); i := i+1) {
+   g_gb[i].cfg := {
+   nsei := mp_nsconfig[i].nsei,
+   sgsn_role := true,
+   bvc := { }
+   };
+   /* create 'mp_num_bvc' number of BVCs */
+   for (var integer j := 0; j < mp_num_bvc; j := j+1) {
+   g_gb[i].cfg.bvc := g_gb[i].cfg.bvc & { f_gen_bvc(i * 
1000, j) };
+   }
+   f_init_gb(g_gb[i], "gb", i);
+   }
+
while (true) {
f_sleep(100.0);
}
diff --git a/fr/FR_Tests.ttcn b/fr/FR_Tests.ttcn
index d2d184f..b220bb9 100644
--- a/fr/FR_Tests.ttcn
+++ b/fr/FR_Tests.ttcn
@@ -8,6 +8,7 @@
 import from BSSGP_Emulation all;

 modulepar {
+   integer mp_num_bvc := 10;
NSConfigurations mp_nsconfig := {
{
nsei := 123,
@@ -34,10 +35,9 @@
BssgpConfig cfg
 };

-const integer NUM_GB := 1;
-type record length(NUM_GB) of GbInstance GbInstances;
-type record length(NUM_GB) of NSConfiguration NSConfigurations;
-type record length(NUM_GB) of BssgpCellId BssgpCellIds;
+type record of GbInstance GbInstances;
+type record of NSConfiguration NSConfigurations;
+type record of BssgpCellId BssgpCellIds;


 type component test_CT {
@@ -53,28 +53,39 @@
gb.vc_BSSGP.start(BssgpStart(gb.cfg, testcasename()));
 }

-testcase TC_foo() runs on test_CT {
-   g_gb[0].cfg := {
-   nsei := 123,
-   sgsn_role := false,
-   bvc := {
-   {
-   bvci := 1123,
-   cell_id := {
-   ra_id := {
-   lai := {
-

Change in osmo-ttcn3-hacks[master]: NS+BSSGP: Only send BVC-RESET when _first_ NSVC of NSVCG becomes unbl...

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21108 )


Change subject: NS+BSSGP: Only send BVC-RESET when _first_ NSVC of NSVCG 
becomes unblocked
..

NS+BSSGP: Only send BVC-RESET when _first_ NSVC of NSVCG becomes unblocked

In case of a NS-VCG with multiple NS-VC, we must BVC-RESET only when the
first NS-VC becomes unblocked, i.e. as soon as we have any connection
to the peer at all.  Whether we have further additional links doesn't
matter, at least not in the sense that all state should be reset.

Change-Id: I69b2e9bd919fc981f189b6671b4234c3642e2449
---
M library/BSSGP_Emulation.ttcnpp
M library/NS_Emulation.ttcnpp
2 files changed, 43 insertions(+), 9 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/08/21108/1

diff --git a/library/BSSGP_Emulation.ttcnpp b/library/BSSGP_Emulation.ttcnpp
index a4a939d..1370958 100644
--- a/library/BSSGP_Emulation.ttcnpp
+++ b/library/BSSGP_Emulation.ttcnpp
@@ -359,7 +359,7 @@
 /* We are in BVC_S_WAIT_NS_ALIVE_UNBLOCKED (only happens in BSS role) */
 altstep as_sig_wait_ns_alive_unblocked() runs on BSSGP_CT {
var NsStatusIndication nsi;
-   [] BSCP.receive(NsStatusIndication:{g_cfg.nsei,?, complement 
(NSVC_S_ALIVE_UNBLOCKED), NSVC_S_ALIVE_UNBLOCKED}) -> value nsi {
+   [] BSCP.receive(NsStatusIndication:{g_cfg.nsei,?, complement 
(NSVC_S_ALIVE_UNBLOCKED), NSVC_S_ALIVE_UNBLOCKED, true}) -> value nsi {
/* if we just became NS-unblocked, send a BCC-RESET */
if (g_cfg.sgsn_role == false) {

BSCP.send(f_BnsUdReq(ts_BVC_RESET(BSSGP_CAUSE_OM_INTERVENTION, 0, omit), 0));
@@ -450,9 +450,9 @@
}
}
/* Keep NS Status Indicaitons to us; no need to inform per-BVC 
components [for now?] */
-   [] BSCP.receive(NsStatusIndication:{g_cfg.nsei, ?, ?, ?}) -> value nsi 
{ }
+   [] BSCP.receive(tr_NsStsInd(g_cfg.nsei)) -> value nsi { }
/* We should never see any different NSEI: There's one BSSGP_CT per NSE 
*/
-   [] BSCP.receive(NsStatusIndication:{?, ?, ?, ?}) -> value nsi {
+   [] BSCP.receive(tr_NsStsInd(?)) -> value nsi {
setverdict(fail, "Rx NsStatusInd for wrong NSEI ", nsi);
}

diff --git a/library/NS_Emulation.ttcnpp b/library/NS_Emulation.ttcnpp
index e286945..7958938 100644
--- a/library/NS_Emulation.ttcnpp
+++ b/library/NS_Emulation.ttcnpp
@@ -73,25 +73,30 @@
Nseinsei,
Nsvci   nsvci,
NsvcState   old_state,
-   NsvcState   new_state
+   NsvcState   new_state,
+   boolean first_or_last
}

template (present) NsStatusIndication tr_NsStsInd(template (present) 
Nsei nsei := ?,
  template (present) 
Nsvci nsvci := ?,
  template (present) 
NsvcState old_state := ?,
- template (present) 
NsvcState state := ?) := {
+ template (present) 
NsvcState state := ?,
+ template (present) 
boolean first_or_last := ?) := {
nsei := nsei,
nsvci := nsvci,
old_state := old_state,
-   new_state := state
+   new_state := state,
+   first_or_last := first_or_last
}


-   template (value) NsStatusIndication ts_NsStsInd(Nsei nsei, Nsvci nsvci, 
NsvcState old_state, NsvcState state) := {
+   template (value) NsStatusIndication ts_NsStsInd(Nsei nsei, Nsvci nsvci, 
NsvcState old_state, NsvcState state,
+   boolean first_or_last 
:= false) := {
nsei := nsei,
nsvci := nsvci,
old_state := old_state,
-   new_state := state
+   new_state := state,
+   first_or_last := first_or_last
}

type enumerated NsvcState {
@@ -247,12 +252,41 @@
}
}

+   function f_count_nsvcs_in_state(template NsvcState state := ?) runs on 
NS_CT return integer {
+   var integer i;
+   var integer res := 0;
+   for (i := 0; i < lengthof(g_nsvcs); i := i+1) {
+   if (match(g_nsvcs[i].state, state)) {
+   res := res + 1;
+   }
+   }
+   return res;
+   }
+
private altstep as_ns_common() runs on NS_CT {
var NsStatusIndication rx_nssi;
var NsUnitdataIndication rx_nsudi;
var NsUnitdataRequest rx_nsudr;
/* pass from NS-VCs up to user */
-   [] 

Change in osmo-ttcn3-hacks[master]: BSSGP_Emulation: Match on proper NSEI from NS layer

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21107 )


Change subject: BSSGP_Emulation: Match on proper NSEI from NS layer
..

BSSGP_Emulation: Match on proper NSEI from NS layer

Change-Id: I682574bc54b4432357adef2b4662b1f74495578c
---
M library/BSSGP_Emulation.ttcnpp
1 file changed, 6 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/07/21107/1

diff --git a/library/BSSGP_Emulation.ttcnpp b/library/BSSGP_Emulation.ttcnpp
index 87b35ac..a4a939d 100644
--- a/library/BSSGP_Emulation.ttcnpp
+++ b/library/BSSGP_Emulation.ttcnpp
@@ -359,7 +359,7 @@
 /* We are in BVC_S_WAIT_NS_ALIVE_UNBLOCKED (only happens in BSS role) */
 altstep as_sig_wait_ns_alive_unblocked() runs on BSSGP_CT {
var NsStatusIndication nsi;
-   [] BSCP.receive(NsStatusIndication:{?,?, complement 
(NSVC_S_ALIVE_UNBLOCKED), NSVC_S_ALIVE_UNBLOCKED}) -> value nsi {
+   [] BSCP.receive(NsStatusIndication:{g_cfg.nsei,?, complement 
(NSVC_S_ALIVE_UNBLOCKED), NSVC_S_ALIVE_UNBLOCKED}) -> value nsi {
/* if we just became NS-unblocked, send a BCC-RESET */
if (g_cfg.sgsn_role == false) {

BSCP.send(f_BnsUdReq(ts_BVC_RESET(BSSGP_CAUSE_OM_INTERVENTION, 0, omit), 0));
@@ -450,7 +450,11 @@
}
}
/* Keep NS Status Indicaitons to us; no need to inform per-BVC 
components [for now?] */
-   [] BSCP.receive(NsStatusIndication:?) -> value nsi { }
+   [] BSCP.receive(NsStatusIndication:{g_cfg.nsei, ?, ?, ?}) -> value nsi 
{ }
+   /* We should never see any different NSEI: There's one BSSGP_CT per NSE 
*/
+   [] BSCP.receive(NsStatusIndication:{?, ?, ?, ?}) -> value nsi {
+   setverdict(fail, "Rx NsStatusInd for wrong NSEI ", nsi);
+   }

/* Procedure port request to resolve the per-BVC component for a given 
ptp BVCI */
[] PROC.getcall(BSSGP_get_bvci_ct:{?}) -> param(bvci) sender vc_conn {

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21107
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I682574bc54b4432357adef2b4662b1f74495578c
Gerrit-Change-Number: 21107
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-MessageType: newchange


Change in osmo-ttcn3-hacks[master]: FRNET: Add 'control' section

2020-11-11 Thread laforge
laforge has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21106 )


Change subject: FRNET: Add 'control' section
..

FRNET: Add 'control' section

FR_Tests already had a control section, but FRNET_Tests didn't have one,
let's change that.

Change-Id: If08fa3572050fcd794be054afd4ebc44cd6580f6
---
M fr-net/FRNET_Tests.ttcn
1 file changed, 4 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/06/21106/1

diff --git a/fr-net/FRNET_Tests.ttcn b/fr-net/FRNET_Tests.ttcn
index c2994f6..010ca50 100644
--- a/fr-net/FRNET_Tests.ttcn
+++ b/fr-net/FRNET_Tests.ttcn
@@ -76,5 +76,9 @@
}
 }

+control {
+   execute( TC_foo() );
+}
+

 }

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21106
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: If08fa3572050fcd794be054afd4ebc44cd6580f6
Gerrit-Change-Number: 21106
Gerrit-PatchSet: 1
Gerrit-Owner: laforge 
Gerrit-MessageType: newchange


Change in osmo-gsm-tester[master]: schema: allow empty lists in resource schema

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21104 )

Change subject: schema: allow empty lists in resource schema
..

schema: allow empty lists in resource schema

Change-Id: I9249e29deef00d4dd68f89c704ef1d3093c799fd
---
M src/osmo_gsm_tester/core/schema.py
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  pespin: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/osmo_gsm_tester/core/schema.py 
b/src/osmo_gsm_tester/core/schema.py
index 816f439..9d26b0f 100644
--- a/src/osmo_gsm_tester/core/schema.py
+++ b/src/osmo_gsm_tester/core/schema.py
@@ -307,7 +307,7 @@
 if util.is_dict(value):
 nest(path, value, schema)
 return
-if util.is_list(value) and value:
+if util.is_list(value):
 for list_v in value:
 validate_item(path, list_v, schema)
 return

--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21104
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I9249e29deef00d4dd68f89c704ef1d3093c799fd
Gerrit-Change-Number: 21104
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-gsm-tester[master]: enb-cells_2ca: add missing cell params

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21103 )

Change subject: enb-cells_2ca: add missing cell params
..

enb-cells_2ca: add missing cell params

the default params are set for a single cell in defaults.conf
but this 2 cell config requires them to be set explicitly.

Change-Id: I8b3c486eb3e42aeb04b6a7548d3f0de2aa40ee0c
---
M sysmocom/scenarios/mod-enb-cells-2ca.conf
1 file changed, 4 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, approved



diff --git a/sysmocom/scenarios/mod-enb-cells-2ca.conf 
b/sysmocom/scenarios/mod-enb-cells-2ca.conf
index 4727340..c9468c6 100644
--- a/sysmocom/scenarios/mod-enb-cells-2ca.conf
+++ b/sysmocom/scenarios/mod-enb-cells-2ca.conf
@@ -6,6 +6,8 @@
 - cell_id: 0x00
   pci: 0x01
   dl_earfcn: 2850
+  tac: 0x0007
+  root_seq_idx: 204
   rf_port: 0
   scell_list: [0x01]
   ncell_list:
@@ -16,6 +18,8 @@
 - cell_id: 0x01
   pci: 0x02
   dl_earfcn: 3050
+  tac: 0x0007
+  root_seq_idx: 205
   rf_port: 1
   scell_list: [0x00]
   ncell_list:

--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21103
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I8b3c486eb3e42aeb04b6a7548d3f0de2aa40ee0c
Gerrit-Change-Number: 21103
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-bts[master]: l1sap: also include SRR bit in RSL l1 info field.

2020-11-11 Thread dexter
Hello Jenkins Builder, laforge,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/osmo-bts/+/21088

to look at the new patch set (#3).

Change subject: l1sap: also include SRR bit in RSL l1 info field.
..

l1sap: also include SRR bit in RSL l1 info field.

The SRR bit, which got specified in 3gpp release 6 to support repeated
ACCH capability is not yet included in the L1 Information IE on RSL
level. Also lets update the spec reference to more modern 3gpp spec ref
numbers.

Change-Id: I987c61608b737521ba36756dabf2f6215b34c2d6
Related: OS#4796 SYS#5114
---
M src/common/l1sap.c
1 file changed, 4 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/88/21088/3
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21088
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I987c61608b737521ba36756dabf2f6215b34c2d6
Gerrit-Change-Number: 21088
Gerrit-PatchSet: 3
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-CC: fixeria 
Gerrit-MessageType: newpatchset


Change in osmo-bts[master]: l1sap: add repeated downlink FACCH

2020-11-11 Thread dexter
Hello Jenkins Builder,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/osmo-bts/+/21014

to look at the new patch set (#5).

Change subject: l1sap: add repeated downlink FACCH
..

l1sap: add repeated downlink FACCH

3GPP TS 44.006, section 10 describes a method how the downlink
FACCH transmission can be repeated to increase transmission
reliability.

Change-Id: I72f0cf7eaaef9f80fc35e752c90ae0e2d24d0c75
Depends: libosmocore I61ea6bf54ea90bd69b73ea0f0f3dc19a4214207b
Related: OS#4796 SYS#5114
---
M include/osmo-bts/bts.h
M include/osmo-bts/gsm_data.h
M src/common/bts.c
M src/common/l1sap.c
M src/common/rsl.c
M src/common/vty.c
6 files changed, 133 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/14/21014/5
--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/21014
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I72f0cf7eaaef9f80fc35e752c90ae0e2d24d0c75
Gerrit-Change-Number: 21014
Gerrit-PatchSet: 5
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: fixeria 
Gerrit-CC: laforge 
Gerrit-MessageType: newpatchset


Change in osmo-bts[master]: l1sap: add repeated downlink SACCH

2020-11-11 Thread dexter
dexter has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/21105 )


Change subject: l1sap: add repeated downlink SACCH
..

l1sap: add repeated downlink SACCH

3GPP TS 44.006, section 11 describes a method how the downlink
SACCH transmission can be repeated to increase transmission
reliability.

Depends: libosmocore I61ea6bf54ea90bd69b73ea0f0f3dc19a4214207b
Change-Id: I00806f936b15fbaf6a4e7bbd61f3bec262cdbb28
Related: OS#4794, SYS#5114
---
M include/osmo-bts/bts.h
M include/osmo-bts/gsm_data.h
M src/common/l1sap.c
M src/common/rsl.c
M src/common/vty.c
5 files changed, 77 insertions(+), 3 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/05/21105/1

diff --git a/include/osmo-bts/bts.h b/include/osmo-bts/bts.h
index fdcc67b..950551c 100644
--- a/include/osmo-bts/bts.h
+++ b/include/osmo-bts/bts.h
@@ -341,6 +341,9 @@
/* 3GPP TS 44.006, section 10, Repeated Downlink FACCH */
bool facch_repetition_enabled;

+   /* 3GPP TS 44.006, section 11.2, Procedure for Repeated SACCH on the 
downlink */
+   bool dl_sacch_repetition_enabled;
+
void *model_priv; /* Allocated by bts_model, contains model specific 
data pointer */
 };

diff --git a/include/osmo-bts/gsm_data.h b/include/osmo-bts/gsm_data.h
index 59fd809..2441286 100644
--- a/include/osmo-bts/gsm_data.h
+++ b/include/osmo-bts/gsm_data.h
@@ -264,6 +264,7 @@

/* SLOT #0 and #1 to store FACCH for repetition */
struct gsm_rep_facch rep_facch[2];
+   struct msgb *rep_sacch;

} tch;

diff --git a/src/common/l1sap.c b/src/common/l1sap.c
index 6001b9f..30f226a 100644
--- a/src/common/l1sap.c
+++ b/src/common/l1sap.c
@@ -964,6 +964,44 @@
return msg;
 }

+/* Special dequeueing function with SACCH repetition (3GPP TS 44.006, section 
11) */
+static inline struct msgb *lapdm_phsap_dequeue_msg_sacch(struct gsm_lchan 
*lchan, struct lapdm_entity *le)
+{
+   struct osmo_phsap_prim pp;
+   struct msgb *msg;
+   uint8_t sapi;
+
+   /* SACCH repetition disabled by the MS */
+   if (((lchan->meas.l1_info[0] >> 1) & 1) == 0) {
+   /* Toss pending repetition candidate */
+   if (lchan->tch.rep_sacch)
+   msgb_free(lchan->tch.rep_sacch);
+   lchan->tch.rep_sacch = NULL;
+
+   /* Fetch new FACCH from queue normally */
+   return lapdm_phsap_dequeue_msg(le);
+   }
+
+   /* Repeat pending candidate */
+   if (lchan->tch.rep_sacch) {
+   msg = lchan->tch.rep_sacch;
+   lchan->tch.rep_sacch = NULL;
+   return msg;
+   }
+
+   /* Fetch new SACCH from queue ... */
+   if (lapdm_phsap_dequeue_prim(le, ) < 0)
+   return NULL;
+   msg = pp.oph.msg;
+
+   /* Only SAPI 0 SACCH frames are repetition candidates, see also 3GPP TS 
44.006, section 11.2 */
+   sapi = (msg->data[0] >> 2) & 0x07;
+   if (sapi == 0)
+   lchan->tch.rep_sacch = msg;
+
+   return msg;
+}
+
 /* PH-RTS-IND prim received from bts model */
 static int l1sap_ph_rts_ind(struct gsm_bts_trx *trx,
struct osmo_phsap_prim *l1sap, struct ph_data_param *rts_ind)
@@ -1044,7 +1082,10 @@
p[0] = lchan->ms_power_ctrl.current;
p[1] = lchan->rqd_ta;
le = >lapdm_ch.lapdm_acch;
-   pp_msg = lapdm_phsap_dequeue_msg(le);
+   if (lchan->ts->trx->bts->dl_sacch_repetition_enabled)
+   pp_msg = lapdm_phsap_dequeue_msg_sacch(lchan, 
le);
+   else
+   pp_msg = lapdm_phsap_dequeue_msg(le);
} else {
if (lchan->ts->trx->bts->dtxd)
dtxd_facch = true;
diff --git a/src/common/rsl.c b/src/common/rsl.c
index 16109b2..26560b9 100644
--- a/src/common/rsl.c
+++ b/src/common/rsl.c
@@ -823,13 +823,16 @@
 */
lapdm_channel_exit(>lapdm_ch);

-   /* Also ensure that there are no leftovers from repeated FACCH
-* that might cause memory leakage. */
+   /* Also ensure that there are no leftovers from repeated FACCH or
+* repeated SACCH that might cause memory leakage. */
if (lchan->tch.rep_facch[0].msg)
msgb_free(lchan->tch.rep_facch[0].msg);
if (lchan->tch.rep_facch[1].msg)
msgb_free(lchan->tch.rep_facch[1].msg);
memset(lchan->tch.rep_facch, 0, sizeof(lchan->tch.rep_facch));
+   if(lchan->tch.rep_sacch)
+   msgb_free(lchan->tch.rep_sacch);
+   lchan->tch.rep_sacch = NULL;

return tx_rf_rel_ack(lchan, chan_nr);
 }
diff --git a/src/common/vty.c b/src/common/vty.c
index 59a6dee..f8033df 100644
--- a/src/common/vty.c
+++ b/src/common/vty.c
@@ -307,6 +307,8 @@

Change in osmo-gsm-tester[master]: iperf3_{dl, ul}: adapt pass/fail threshold

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21057 )

Change subject: iperf3_{dl,ul}: adapt pass/fail threshold
..

iperf3_{dl,ul}: adapt pass/fail threshold

change pass threshold to 80% of the max rate for
half of the testduration (rolling average).

the overall average might be lowered because of a slower
TCP start or a late UE attach.

Change-Id: I8a545b8175784e9d6b49d6bf80f637ef7aa731f7
---
M sysmocom/suites/4g/iperf3_dl.py
M sysmocom/suites/4g/iperf3_ul.py
2 files changed, 6 insertions(+), 2 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, approved



diff --git a/sysmocom/suites/4g/iperf3_dl.py b/sysmocom/suites/4g/iperf3_dl.py
index 6f79076..bf5b1f0 100755
--- a/sysmocom/suites/4g/iperf3_dl.py
+++ b/sysmocom/suites/4g/iperf3_dl.py
@@ -36,6 +36,8 @@
 iperf3cli.print_results()
 iperf3srv.print_results(iperf3cli.proto() == iperf3cli.PROTO_UDP)

-res_str = ue.verify_metric(max_rate * 0.8, operation='avg', metric='dl_brate', 
criterion='gt')
+# 80% of the maximum rate for half of the test duration
+half_duration = int(round(iperf3cli.time_sec() / 2))
+res_str = ue.verify_metric(max_rate * 0.8, operation='max_rolling_avg', 
metric='dl_brate', criterion='gt', window=half_duration)
 print(res_str)
 test.set_report_stdout(res_str)
diff --git a/sysmocom/suites/4g/iperf3_ul.py b/sysmocom/suites/4g/iperf3_ul.py
index 4ae0118..6c0d25d 100755
--- a/sysmocom/suites/4g/iperf3_ul.py
+++ b/sysmocom/suites/4g/iperf3_ul.py
@@ -36,6 +36,8 @@
 iperf3cli.print_results()
 iperf3srv.print_results(iperf3cli.proto() == iperf3cli.PROTO_UDP)

-res_str = ue.verify_metric(max_rate * 0.8, operation='avg', metric='ul_brate', 
criterion='gt')
+# 80% of the maximum rate for half of the test duration
+half_duration = int(round(iperf3cli.time_sec() / 2))
+res_str = ue.verify_metric(max_rate * 0.8, operation='max_rolling_avg', 
metric='ul_brate', criterion='gt', window=half_duration)
 print(res_str)
 test.set_report_stdout(res_str)

--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21057
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I8a545b8175784e9d6b49d6bf80f637ef7aa731f7
Gerrit-Change-Number: 21057
Gerrit-PatchSet: 3
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-gsm-tester[master]: {enb, ms}_srs: Add DL QAM-256 support

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21097 )

Change subject: {enb,ms}_srs: Add DL QAM-256 support
..

{enb,ms}_srs: Add DL QAM-256 support

Due to the integration of DL-QAM256 another table for DL max rates is needed.
Therefore, I added the parameter 'qam256' to the feature list in the 
resource.cfg.

The patch also enables the correct UE settings in the config file.

Change-Id: I2d34395449cdcfb31db66ea887d9adbee551e757
---
M src/osmo_gsm_tester/core/schema.py
M src/osmo_gsm_tester/obj/enb_srs.py
M src/osmo_gsm_tester/obj/ms_srs.py
M src/osmo_gsm_tester/templates/srsue.conf.tmpl
4 files changed, 26 insertions(+), 8 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, approved



diff --git a/src/osmo_gsm_tester/core/schema.py 
b/src/osmo_gsm_tester/core/schema.py
index 72c2738..816f439 100644
--- a/src/osmo_gsm_tester/core/schema.py
+++ b/src/osmo_gsm_tester/core/schema.py
@@ -111,7 +111,7 @@
 raise ValueError('Unknown Cipher value: %r' % val)

 def modem_feature(val):
-if val in ('sms', 'gprs', 'voice', 'ussd', 'sim', '2g', '3g', '4g'):
+if val in ('sms', 'gprs', 'voice', 'ussd', 'sim', '2g', '3g', '4g', 
'dl_qam256'):
 return True
 raise ValueError('Unknown Modem Feature: %r' % val)

diff --git a/src/osmo_gsm_tester/obj/enb_srs.py 
b/src/osmo_gsm_tester/obj/enb_srs.py
index 93168bf..8319ba4 100644
--- a/src/osmo_gsm_tester/obj/enb_srs.py
+++ b/src/osmo_gsm_tester/obj/enb_srs.py
@@ -269,19 +269,30 @@
 return rfemu_obj

 def ue_max_rate(self, downlink=True, num_carriers=1):
-# The max rate for a single UE per PRB configuration in TM1 with MCS 
28 QAM64
-max_phy_rate_tm1_dl = { 6 : 3.5e6,
-   15 : 11e6,
-   25 : 18e6,
-   50 : 36e6,
-   75 : 55e6,
-   100 : 75e6 }
+
+
+# The max rate for a single UE per PRB configuration in TM1 with MCS 28
+if 'dl_qam256' in self.ue.features():
+max_phy_rate_tm1_dl = {6: 5.9e6,
+   15: 14.6e6,
+   25: 24.5e6,
+   50: 48.9e6,
+   75: 75.3e6,
+   100: 97.8e6}
+else:
+max_phy_rate_tm1_dl = {6: 3.5e6,
+   15: 11e6,
+   25: 18e6,
+   50: 36e6,
+   75: 55e6,
+   100: 75e6}
 max_phy_rate_tm1_ul = { 6 : 1.7e6,
15 : 4.7e6,
25 : 10e6,
50 : 23e6,
75 : 34e6,
100 : 51e6 }
+
 if downlink:
 max_rate = max_phy_rate_tm1_dl[self.num_prb()]
 else:
diff --git a/src/osmo_gsm_tester/obj/ms_srs.py 
b/src/osmo_gsm_tester/obj/ms_srs.py
index a3505c8..610d3e6 100644
--- a/src/osmo_gsm_tester/obj/ms_srs.py
+++ b/src/osmo_gsm_tester/obj/ms_srs.py
@@ -128,6 +128,9 @@
 # Collect KPIs for each TC
 self.testenv.test().set_kpis(self.get_kpis())

+def features(self):
+return self._conf.get('features', [])
+
 def scp_back_metrics(self, raiseException=True):
 ''' Copy back metrics only if they have not been copied back yet '''
 if not self.have_metrics_file:
diff --git a/src/osmo_gsm_tester/templates/srsue.conf.tmpl 
b/src/osmo_gsm_tester/templates/srsue.conf.tmpl
index 284922b..31642cd 100644
--- a/src/osmo_gsm_tester/templates/srsue.conf.tmpl
+++ b/src/osmo_gsm_tester/templates/srsue.conf.tmpl
@@ -150,6 +150,10 @@
 % if int(ue.num_carriers) > 1:
 ue_category   = 7
 release   = 10
+% elif "dl_qam256" in ue.features:
+ue_category   = 7
+release   = 13
+ue_category_dl= 14
 % else:
 #ue_category   = 4
 #release   = 8

--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21097
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I2d34395449cdcfb31db66ea887d9adbee551e757
Gerrit-Change-Number: 21097
Gerrit-PatchSet: 2
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-gsm-tester[master]: schema: allow empty lists in resource schema

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21104 )

Change subject: schema: allow empty lists in resource schema
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21104
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I9249e29deef00d4dd68f89c704ef1d3093c799fd
Gerrit-Change-Number: 21104
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 16:28:55 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-gsm-tester[master]: epc_srs.py: Fixed reference in local execution

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21098 )

Change subject: epc_srs.py: Fixed reference in local execution
..

epc_srs.py: Fixed reference in local execution

fixes local execution of srsEPC

Change-Id: I36db8f2f65be6c92ccea050f550e21b67bb9e50e
---
M src/osmo_gsm_tester/obj/epc_srs.py
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, approved



diff --git a/src/osmo_gsm_tester/obj/epc_srs.py 
b/src/osmo_gsm_tester/obj/epc_srs.py
index b5ae0bd..6a7a20e 100644
--- a/src/osmo_gsm_tester/obj/epc_srs.py
+++ b/src/osmo_gsm_tester/obj/epc_srs.py
@@ -102,8 +102,8 @@
 self.process.launch()

 def start_locally(self):
-binary = inst.child('bin', BINFILE)
-lib = inst.child('lib')
+binary = self.inst.child('bin', srsEPC.BINFILE)
+lib = self.inst.child('lib')
 env = {}

 # setting capabilities will later disable use of LD_LIBRARY_PATH from 
ELF loader -> modify RPATH instead.

--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21098
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I36db8f2f65be6c92ccea050f550e21b67bb9e50e
Gerrit-Change-Number: 21098
Gerrit-PatchSet: 2
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


Change in osmo-gsm-tester[master]: enb-cells_2ca: add missing cell params

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21103 )

Change subject: enb-cells_2ca: add missing cell params
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21103
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I8b3c486eb3e42aeb04b6a7548d3f0de2aa40ee0c
Gerrit-Change-Number: 21103
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 16:28:46 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-gsm-tester[master]: schema: allow empty lists in resource schema

2020-11-11 Thread srs_andre
srs_andre has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21104 )


Change subject: schema: allow empty lists in resource schema
..

schema: allow empty lists in resource schema

Change-Id: I9249e29deef00d4dd68f89c704ef1d3093c799fd
---
M src/osmo_gsm_tester/core/schema.py
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-gsm-tester 
refs/changes/04/21104/1

diff --git a/src/osmo_gsm_tester/core/schema.py 
b/src/osmo_gsm_tester/core/schema.py
index 816f439..9d26b0f 100644
--- a/src/osmo_gsm_tester/core/schema.py
+++ b/src/osmo_gsm_tester/core/schema.py
@@ -307,7 +307,7 @@
 if util.is_dict(value):
 nest(path, value, schema)
 return
-if util.is_list(value) and value:
+if util.is_list(value):
 for list_v in value:
 validate_item(path, list_v, schema)
 return

--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21104
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I9249e29deef00d4dd68f89c704ef1d3093c799fd
Gerrit-Change-Number: 21104
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-MessageType: newchange


Change in osmo-gsm-tester[master]: enb-cells_2ca: add missing cell params

2020-11-11 Thread srs_andre
srs_andre has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21103 )


Change subject: enb-cells_2ca: add missing cell params
..

enb-cells_2ca: add missing cell params

the default params are set for a single cell in defaults.conf
but this 2 cell config requires them to be set explicitly.

Change-Id: I8b3c486eb3e42aeb04b6a7548d3f0de2aa40ee0c
---
M sysmocom/scenarios/mod-enb-cells-2ca.conf
1 file changed, 4 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-gsm-tester 
refs/changes/03/21103/1

diff --git a/sysmocom/scenarios/mod-enb-cells-2ca.conf 
b/sysmocom/scenarios/mod-enb-cells-2ca.conf
index 4727340..c9468c6 100644
--- a/sysmocom/scenarios/mod-enb-cells-2ca.conf
+++ b/sysmocom/scenarios/mod-enb-cells-2ca.conf
@@ -6,6 +6,8 @@
 - cell_id: 0x00
   pci: 0x01
   dl_earfcn: 2850
+  tac: 0x0007
+  root_seq_idx: 204
   rf_port: 0
   scell_list: [0x01]
   ncell_list:
@@ -16,6 +18,8 @@
 - cell_id: 0x01
   pci: 0x02
   dl_earfcn: 3050
+  tac: 0x0007
+  root_seq_idx: 205
   rf_port: 1
   scell_list: [0x00]
   ncell_list:

--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21103
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I8b3c486eb3e42aeb04b6a7548d3f0de2aa40ee0c
Gerrit-Change-Number: 21103
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-MessageType: newchange


Change in osmo-ttcn3-hacks[master]: pcu: Introduce test TC_mcs_initial_dl

2020-11-11 Thread pespin
Hello Jenkins Builder,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21102

to look at the new patch set (#2).

Change subject: pcu: Introduce test TC_mcs_initial_dl
..

pcu: Introduce test TC_mcs_initial_dl

Change-Id: Ida01fb066f202033507f0c6a99212a1ff9d95423
---
M pcu/PCU_Tests.ttcn
1 file changed, 55 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/02/21102/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21102
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ida01fb066f202033507f0c6a99212a1ff9d95423
Gerrit-Change-Number: 21102
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-MessageType: newpatchset


Change in osmo-ttcn3-hacks[master]: pcu: Introduce test TC_mcs_initial_dl

2020-11-11 Thread pespin
pespin has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21102 )


Change subject: pcu: Introduce test TC_mcs_initial_dl
..

pcu: Introduce test TC_mcs_initial_dl

Change-Id: Ida01fb066f202033507f0c6a99212a1ff9d95423
---
M pcu/PCU_Tests.ttcn
1 file changed, 56 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/02/21102/1

diff --git a/pcu/PCU_Tests.ttcn b/pcu/PCU_Tests.ttcn
index f530b42..89fa7d9 100644
--- a/pcu/PCU_Tests.ttcn
+++ b/pcu/PCU_Tests.ttcn
@@ -1096,6 +1096,61 @@
f_shutdown(__BFILE__, __LINE__, final := true);
 }

+/* Test the initial DL CS set by VTY works fine */
+testcase TC_mcs_initial_dl() runs on RAW_PCU_Test_CT {
+   var octetstring data := f_rnd_octstring(10);
+   var CodingScheme exp_dl_cs_mcs;
+   var RlcmacDlBlock dl_block;
+   var uint32_t poll_fn;
+   var GprsMS ms;
+   /* SGSN sends some DL data, PCU will assign DL TBF through PACCH */
+   var MultislotCap_GPRS_BSSGP mscap_gprs := {
+   gprsmultislotclass := '00011'B,
+   gprsextendeddynalloccap := '0'B
+   };
+   var MultislotCap_EGPRS_BSSGP mscap_egprs := {
+   egprsmultislotclass := '00011'B,
+   egprsextendeddynalloccap := '0'B
+   };
+   var MSRadioAccessCapabilityV_BSSGP ms_racap := { 
valueof(ts_RaCapRec_BSSGP('0001'B /* E-GSM */, mscap_gprs, mscap_egprs)) };
+
+   /* Initialize NS/BSSGP side */
+   f_init_bssgp();
+   /* Initialize GPRS MS side */
+   f_init_gprs_ms();
+   ms := g_ms[0]; /* We only use first MS in this test */
+
+   /* Initialize the PCU interface abstraction */
+   f_init_raw(testcasename());
+
+   /* Set initial allowed DL MCS to 3 */
+   g_mcs_initial_dl := 3;
+   exp_dl_cs_mcs := MCS_3;
+   /* Set maximum allowed DL MCS to 4 */
+   g_mcs_max_dl := 4;
+   f_pcuvty_set_allowed_cs_mcs();
+   f_pcuvty_set_link_quality_ranges();
+
+   /* Establish BSSGP connection to the PCU */
+   f_bssgp_establish();
+   f_bssgp_client_llgmm_assign(TLLI_UNUSED, ms.tlli);
+
+   /* SGSN sends some DL data, PCU will page on CCCH (PCH) */
+   BSSGP[0].send(ts_BSSGP_DL_UD(ms.tlli, data, ms_racap));
+   f_ms_exp_dl_tbf_ass_ccch(ms, PCU_IF_SAPI_PCH);
+
+   /* Wait timer X2002 and DL block is available after CCCH IMM ASS: */
+   f_sleep(X2002);
+   f_rx_rlcmac_dl_block_exp_data(dl_block, poll_fn, data, 0, 
exp_dl_cs_mcs);
+
+   /* ACK the DL block */
+   f_acknackdesc_ack_block(ms.dl_tbf.acknack_desc, dl_block, '1'B);
+   f_ms_tx_ul_block(ms, ts_RLCMAC_DL_ACK_NACK(ms.dl_tbf.tfi, 
ms.dl_tbf.acknack_desc),
+f_dl_block_ack_fn(dl_block, poll_fn));
+
+   f_shutdown(__BFILE__, __LINE__, final := true);
+}
+
 /* Verify PCU drops TBF after some time of inactivity. */
 testcase TC_t3169() runs on RAW_PCU_Test_CT {
var PCUIF_info_ind info_ind;
@@ -3167,6 +3222,7 @@
execute( TC_dl_cs1_to_cs4() );
execute( TC_mcs_initial_ul() );
execute( TC_mcs_max_ul() );
+   execute( TC_mcs_initial_dl() );
execute( TC_t3169() );
execute( TC_t3193() );
execute( TC_countdown_procedure() );

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21102
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ida01fb066f202033507f0c6a99212a1ff9d95423
Gerrit-Change-Number: 21102
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-MessageType: newchange


Change in osmo-ttcn3-hacks[master]: pcu: Introduce test TC_mcs_max_ul

2020-11-11 Thread pespin
pespin has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21101 )


Change subject: pcu: Introduce test TC_mcs_max_ul
..

pcu: Introduce test TC_mcs_max_ul

Change-Id: I4cc77988832a2ae431ac3c5b85de940c2419bf09
---
M pcu/PCU_Tests.ttcn
1 file changed, 50 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/01/21101/1

diff --git a/pcu/PCU_Tests.ttcn b/pcu/PCU_Tests.ttcn
index 63b9e61..f530b42 100644
--- a/pcu/PCU_Tests.ttcn
+++ b/pcu/PCU_Tests.ttcn
@@ -1047,6 +1047,55 @@
f_shutdown(__BFILE__, __LINE__, final := true);
 }

+/* Test the maximum UL MCS set by VTY works fine */
+testcase TC_mcs_max_ul() runs on RAW_PCU_Test_CT {
+   var RlcmacDlBlock dl_block;
+   var EgprsChCodingCommand last_ch_coding;
+   var PollFnCtx pollctx;
+   var uint32_t unused_fn, sched_fn;
+   var GprsMS ms;
+   var MultislotCap_GPRS mscap_gprs := {
+   gprsmultislotclass := '00011'B,
+   gprsextendeddynalloccap := '0'B
+   };
+   var MultislotCap_EGPRS mscap_egprs := {
+   egprsmultislotclass := '00011'B,
+   egprsextendeddynalloccap := '0'B
+   };
+   var MSRadioAccessCapabilityV ms_racap := { valueof(ts_RaCapRec('0001'B 
/* E-GSM */, mscap_gprs, mscap_egprs)) };
+
+
+   /* Initialize GPRS MS side */
+   f_init_gprs_ms();
+   ms := g_ms[0]; /* We only use first MS in this test */
+
+   /* Initialize the PCU interface abstraction */
+   f_init_raw(testcasename());
+
+   /* Set maximum allowed UL MCS to 5 */
+   g_mcs_max_ul := 5;
+   f_pcuvty_set_allowed_cs_mcs();
+   f_pcuvty_set_link_quality_ranges();
+
+   /* Send PACKET RESOURCE REQUEST to upgrade to EGPRS */
+   pollctx := f_ms_establish_ul_tbf_2phase_access(ms, 
ts_RlcMacUlCtrl_PKT_RES_REQ(ms.tlli, ms_racap));
+   /* Pkt Uplink Assignment above sets poll+rrbp requesting PACKET CONTROL 
ACK */
+   f_ms_tx_ul_block(ms, ts_RLCMAC_CTRL_ACK(ms.tlli), pollctx.fn, nr := 
pollctx.tstrxbts);
+
+   ms.lqual_cb :=  40*10; /* 40 dB */
+   f_ms_tx_ul_data_block_multi(ms, 16);
+
+   f_rx_rlcmac_dl_block_exp_ack_nack(dl_block, unused_fn);
+   last_ch_coding := 
dl_block.ctrl.payload.u.ul_ack_nack.egprs.ch_coding_cmd;
+
+   if (last_ch_coding != CH_CODING_MCS5) {
+   setverdict(fail, "Channel Coding does not match our 
expectations (MCS-5): ", last_ch_coding);
+   f_shutdown(__BFILE__, __LINE__);
+   }
+
+   f_shutdown(__BFILE__, __LINE__, final := true);
+}
+
 /* Verify PCU drops TBF after some time of inactivity. */
 testcase TC_t3169() runs on RAW_PCU_Test_CT {
var PCUIF_info_ind info_ind;
@@ -3117,6 +3166,7 @@
execute( TC_cs_max_dl() );
execute( TC_dl_cs1_to_cs4() );
execute( TC_mcs_initial_ul() );
+   execute( TC_mcs_max_ul() );
execute( TC_t3169() );
execute( TC_t3193() );
execute( TC_countdown_procedure() );

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21101
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I4cc77988832a2ae431ac3c5b85de940c2419bf09
Gerrit-Change-Number: 21101
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-MessageType: newchange


Change in osmo-gsm-tester[master]: {enb, ms}_srs: Add DL QAM-256 support

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21097 )

Change subject: {enb,ms}_srs: Add DL QAM-256 support
..


Patch Set 1: Code-Review+2

Thanks, makes sense then.


--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21097
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I2d34395449cdcfb31db66ea887d9adbee551e757
Gerrit-Change-Number: 21097
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 11:42:59 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-gsm-tester[master]: {enb, ms}_srs: Add DL QAM-256 support

2020-11-11 Thread srs_andre
srs_andre has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21097 )

Change subject: {enb,ms}_srs: Add DL QAM-256 support
..


Patch Set 1:

> Patch Set 1:
>
> Why is this added as a feature? Are some implementations not supporting it 
> right now? Amarisoft ones? Old versions of srsUE you want to test?

Yes, the default UE config does not announce QAM256 capabilities. Also a normal 
2 year old low or mid-range LTE phone doesn't support it. So the default will 
be to not have QAM256.


--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21097
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I2d34395449cdcfb31db66ea887d9adbee551e757
Gerrit-Change-Number: 21097
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre 
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 11:41:41 +
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment


Change in osmo-ttcn3-hacks[master]: pcu: Introduce test TC_mcs_initial_ul

2020-11-11 Thread pespin
Hello Jenkins Builder,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21095

to look at the new patch set (#3).

Change subject: pcu: Introduce test TC_mcs_initial_ul
..

pcu: Introduce test TC_mcs_initial_ul

Change-Id: I0ee2fce7045628caf8145468b29688a9f230e7cd
---
M pcu/PCU_Tests.ttcn
1 file changed, 86 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/95/21095/3
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/21095
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I0ee2fce7045628caf8145468b29688a9f230e7cd
Gerrit-Change-Number: 21095
Gerrit-PatchSet: 3
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-MessageType: newpatchset


Change in osmo-gsm-tester[master]: resource: Support waiting for reserved resources until available

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21089 )

Change subject: resource: Support waiting for reserved resources until available
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21089
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I938602ee890712fda82fd3f812d8edb1bcd05e08
Gerrit-Change-Number: 21089
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 11:38:28 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


Change in osmo-gsm-tester[master]: resource: Support waiting for reserved resources until available

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21089 )

Change subject: resource: Support waiting for reserved resources until available
..

resource: Support waiting for reserved resources until available

Before this patch, almost everything was in place to support concurrent
osmo-gsm-tester instances sharing a common state dir. However, during
resource reservation, if the reservation couldn't be done due to too
many resources being in use, osmo-gsm-tester would fail and skip the
test suite.
With this patch, OGT will wait until some reserved resources are
released and then try requesting the reservation again.

Change-Id: I938602ee890712fda82fd3f812d8edb1bcd05e08
---
M doc/manuals/chapters/install.adoc
M selftest/resource_test/resource_test.ok
M selftest/resource_test/resource_test.py
M selftest/suite_test/suite_test.ok
M src/osmo_gsm_tester/core/resource.py
M src/osmo_gsm_tester/core/util.py
6 files changed, 470 insertions(+), 11 deletions(-)

Approvals:
  pespin: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/doc/manuals/chapters/install.adoc 
b/doc/manuals/chapters/install.adoc
index 0e48e9d..c94c596 100644
--- a/doc/manuals/chapters/install.adoc
+++ b/doc/manuals/chapters/install.adoc
@@ -340,6 +340,7 @@
 python3-yaml \
 python3-mako \
 python3-gi \
+python3-watchdog \
 locales
 

diff --git a/selftest/resource_test/resource_test.ok 
b/selftest/resource_test/resource_test.ok
index 91acaaf..5f7d5f6 100644
--- a/selftest/resource_test/resource_test.ok
+++ b/selftest/resource_test/resource_test.ok
@@ -116,6 +116,59 @@
 *** end: all resources

 - request some resources
+--- testowner: Verifying 2 x arfcn (candidates: 10)
+--- testowner: DBG: Picked - _hash: e620569450f8259b3f0212ec19c285dd07df063c
+  arfcn: '512'
+  band: GSM-1800
+- _hash: 022621e513c5a5bf33b77430a1e9c886be676fa1
+  arfcn: '514'
+  band: GSM-1800
+--- testowner: Verifying 2 x bts (candidates: 3)
+--- testowner: DBG: Picked - _hash: d2aa7c1124943de352351b650ca0c751784da6b6
+  addr: 10.42.42.114
+  band: GSM-1800
+  ciphers:
+  - a5_0
+  - a5_1
+  direct_pcu: 'True'
+  ipa_unit_id: '1'
+  label: sysmoBTS 1002
+  type: osmo-bts-sysmo
+- _hash: 2158317d5e0055070e7174c2498dedf53a2957e9
+  addr: 10.42.42.50
+  band: GSM-1800
+  ciphers:
+  - a5_0
+  - a5_1
+  ipa_unit_id: '6'
+  label: Ettus B200
+  osmo_trx:
+clock_reference: external
+launch_trx: 'True'
+  type: osmo-bts-trx
+--- testowner: Verifying 1 x ip_address (candidates: 5)
+--- testowner: DBG: Picked - _hash: fd103b22c7cf2480d609150e06f4bbd92ac78d8c
+  addr: 10.42.42.2
+--- testowner: Verifying 2 x modem (candidates: 4)
+--- testowner: DBG: Picked - _hash: 0b538cb6ad799fbd7c2953fd3b4463a76c7cc9c0
+  auth_algo: comp128v1
+  ciphers:
+  - a5_0
+  - a5_1
+  imsi: '90170009031'
+  ki: 80A37E6FDEA931EAC92FFA5F671EFEAD
+  label: sierra_1
+  path: /sierra_1
+- _hash: 3a6e7747dfe7dfdf817bd3351031bd08051605c3
+  auth_algo: comp128v1
+  ciphers:
+  - a5_0
+  - a5_1
+  imsi: '90170009029'
+  ki: 00969E283349D354A8239E877F2E0866
+  label: sierra_2
+  path: /sierra_2
+--- testowner: DBG: FileWatch: scheduling watch for directory 
[PATH]/selftest/resource_test/conf/test_work/state_dir
 --- testowner: Reserving 2 x arfcn (candidates: 10)
 --- testowner: DBG: Picked - _hash: e620569450f8259b3f0212ec19c285dd07df063c
   arfcn: '512'
@@ -168,6 +221,7 @@
   ki: 00969E283349D354A8239E877F2E0866
   label: sierra_2
   path: /sierra_2
+--- testowner: DBG: FileWatch: unscheduling watch 
 ~~~ currently reserved:
 arfcn:
 - _hash: e620569450f8259b3f0212ec19c285dd07df063c
@@ -290,3 +344,27 @@
 3rd subset should not match, pass
 3rd subset should not match, pass
 4th subset should not match, pass
+*** concurrent allocation:
+--- testowner1: Verifying 2 x arfcn (candidates: 10)
+--- testowner1: Verifying 2 x bts (candidates: 3)
+--- testowner1: Verifying 1 x ip_address (candidates: 5)
+--- testowner1: Verifying 2 x modem (candidates: 4)
+--- testowner1: Reserving 2 x arfcn (candidates: 10)
+--- testowner1: Reserving 2 x bts (candidates: 3)
+--- testowner1: Reserving 1 x ip_address (candidates: 5)
+--- testowner1: Reserving 2 x modem (candidates: 4)
+- 2nd instance reserve() start
+--- testowner2: Verifying 2 x arfcn (candidates: 10)
+--- testowner2: Verifying 2 x bts (candidates: 3)
+--- testowner2: Verifying 1 x ip_address (candidates: 5)
+--- testowner2: Verifying 2 x modem (candidates: 4)
+--- testowner2: Reserving 2 x arfcn (candidates: 8)
+--- testowner2: Reserving 2 x bts (candidates: 1)
+--- testowner2: Unable to reserve resources, too many currently reserved. 
Waiting until some are available again
+- 1st instance free()
+--- testowner2: Reserving 2 x arfcn (candidates: 10)
+--- testowner2: Reserving 2 x bts (candidates: 3)
+--- testowner2: Reserving 1 x ip_address (candidates: 5)
+--- testowner2: Reserving 2 x modem 

Change in osmo-gsm-tester[master]: enb: Support cells from different ENBs in ncell_list

2020-11-11 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21099 )

Change subject: enb: Support cells from different ENBs in ncell_list
..

enb: Support cells from different ENBs in ncell_list

Change-Id: I1242c56ff42caea06e7f96317def82064fd11325
---
M src/osmo_gsm_tester/obj/enb.py
M src/osmo_gsm_tester/templates/amarisoft_enb.cfg.tmpl
M src/osmo_gsm_tester/templates/srsenb_rr.conf.tmpl
M sysmocom/defaults.conf
M sysmocom/scenarios/mod-enb-cells-2ca.conf
M sysmocom/scenarios/mod-enb-cells-intra-freq-ho-sameport.conf
M sysmocom/scenarios/mod-enb-cells-intra-freq-ho.conf
7 files changed, 45 insertions(+), 22 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, approved



diff --git a/src/osmo_gsm_tester/obj/enb.py b/src/osmo_gsm_tester/obj/enb.py
index f258b52..cdf9505 100644
--- a/src/osmo_gsm_tester/obj/enb.py
+++ b/src/osmo_gsm_tester/obj/enb.py
@@ -60,7 +60,10 @@
 'cell_list[].cell_id': schema.UINT,
 'cell_list[].rf_port': schema.UINT,
 'cell_list[].pci': schema.UINT,
-'cell_list[].ncell_list[]': schema.UINT,
+'cell_list[].ncell_list[].enb_id': schema.UINT,
+'cell_list[].ncell_list[].cell_id': schema.UINT,
+'cell_list[].ncell_list[].pci': schema.UINT,
+'cell_list[].ncell_list[].dl_earfcn': schema.UINT,
 'cell_list[].scell_list[]': schema.UINT,
 'cell_list[].dl_earfcn': schema.UINT,
 'cell_list[].root_seq_idx': schema.UINT,
diff --git a/src/osmo_gsm_tester/templates/amarisoft_enb.cfg.tmpl 
b/src/osmo_gsm_tester/templates/amarisoft_enb.cfg.tmpl
index a0f22ff..4c7aa33 100644
--- a/src/osmo_gsm_tester/templates/amarisoft_enb.cfg.tmpl
+++ b/src/osmo_gsm_tester/templates/amarisoft_enb.cfg.tmpl
@@ -77,10 +77,8 @@
 root_sequence_index: ${loop.index * 10 + 204}, /* PRACH root sequence 
index */

 ncell_list: [
-%for ncell in enb.cell_list:
-%if ncell.cell_id in cell.ncell_list:
-  { n_id_cell: ${ncell.pci}, dl_earfcn: ${ncell.dl_earfcn}, cell_id: 
${ncell.cell_id}, tac: 1 },
-%endif
+%for ncell in cell.ncell_list:
+  { n_id_cell: ${ncell.pci}, dl_earfcn: ${ncell.dl_earfcn}, cell_id: 
${ncell.cell_id}, tac: 7 },
 %endfor
 ],

diff --git a/src/osmo_gsm_tester/templates/srsenb_rr.conf.tmpl 
b/src/osmo_gsm_tester/templates/srsenb_rr.conf.tmpl
index ff51bfd..a906df7 100644
--- a/src/osmo_gsm_tester/templates/srsenb_rr.conf.tmpl
+++ b/src/osmo_gsm_tester/templates/srsenb_rr.conf.tmpl
@@ -82,17 +82,13 @@
 // Cells available for handover
 meas_cell_list =
 (
-%for ncell in enb.cell_list:
-<% loop.my_num_items = 0 if loop.index == 0 else loop.my_num_items %>
-%if ncell.cell_id in cell.ncell_list:
-${',' if loop.my_num_items != 0 else ''}
-<% loop.my_num_items += 1 %>
+%for ncell in cell.ncell_list:
+${',' if loop.index != 0 else ''}
 {
-  eci = ${hex((int(enb.id)<<8) + int(ncell.cell_id))};
+  eci = ${hex((int(ncell.enb_id)<<8) + int(ncell.cell_id))};
   dl_earfcn = ${ncell.dl_earfcn};
   pci = ${ncell.pci};
 }
-%endif
 %endfor
 );

diff --git a/sysmocom/defaults.conf b/sysmocom/defaults.conf
index 98852aa..a9015f7 100644
--- a/sysmocom/defaults.conf
+++ b/sysmocom/defaults.conf
@@ -137,7 +137,7 @@
  tac: 0x0007
  root_seq_idx: 204
  scell_list: []
- ncell_list: [0x02]
+ ncell_list: []
- cell_id: 0x02
  pci: 0x02
  dl_earfcn: 2850
@@ -145,7 +145,7 @@
  tac: 0x0007
  root_seq_idx: 205
  scell_list: []
- ncell_list: [0x01]
+ ncell_list: []

 srsenb:
   num_prb: 100
diff --git a/sysmocom/scenarios/mod-enb-cells-2ca.conf 
b/sysmocom/scenarios/mod-enb-cells-2ca.conf
index 1dbea73..4727340 100644
--- a/sysmocom/scenarios/mod-enb-cells-2ca.conf
+++ b/sysmocom/scenarios/mod-enb-cells-2ca.conf
@@ -1,16 +1,25 @@
 # CA and HO config, two cells different EARFCN, cell IDs match CC index of eNB
 modifiers:
   enb:
-  - cell_list:
+  - id: 0x19B
+cell_list:
 - cell_id: 0x00
   pci: 0x01
   dl_earfcn: 2850
   rf_port: 0
   scell_list: [0x01]
-  ncell_list: [0x01]
+  ncell_list:
+  - enb_id: 0x19B
+cell_id: 0x01
+pci: 0x02
+dl_earfcn: 3050
 - cell_id: 0x01
   pci: 0x02
   dl_earfcn: 3050
   rf_port: 1
   scell_list: [0x00]
-  ncell_list: [0x00]
+  ncell_list:
+  - enb_id: 0x19B
+cell_id: 0x00
+pci: 0x01
+dl_earfcn: 2850
diff --git a/sysmocom/scenarios/mod-enb-cells-intra-freq-ho-sameport.conf 
b/sysmocom/scenarios/mod-enb-cells-intra-freq-ho-sameport.conf
index 4a0a6b4..899ec4b 100644
--- a/sysmocom/scenarios/mod-enb-cells-intra-freq-ho-sameport.conf
+++ b/sysmocom/scenarios/mod-enb-cells-intra-freq-ho-sameport.conf
@@ -1,16 +1,25 @@
 # HO config for intra-frequency HO between two cells (same EARFCN) on the same 
RF port (Amarisoft eNB)
 modifiers:
   

Change in osmo-gsm-tester[master]: sysmocom: Introduce suite 4g2enb

2020-11-11 Thread pespin
pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21100 )

Change subject: sysmocom: Introduce suite 4g2enb
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/21100
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: I73b1a5e07f81fa1e3d3db1db243a3d0b137bda8e
Gerrit-Change-Number: 21100
Gerrit-PatchSet: 1
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin 
Gerrit-Comment-Date: Wed, 11 Nov 2020 11:28:26 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


  1   2   >