Build failed in Jenkins: master-osmo-ggsn » --disable-gtp-linux,1,a3=default,a4=default,osmocom-master-debian9 #1196

2018-12-05 Thread jenkins
See 


--
[...truncated 26.63 KB...]
make[3]: Leaving directory 
'
make[2]: Leaving directory 
'
Making install in src
make[2]: Entering directory 
'
  GEN  crc8gen.c
  GEN  crc16gen.c
  GEN  crc32gen.c
  GEN  crc64gen.c
make  install-am
make[3]: Entering directory 
'
  CC   timer.lo
  CC   timer_gettimeofday.lo
  CC   timer_clockgettime.lo
  CC   select.lo
  CC   signal.lo
  CC   msgb.lo
  CC   bitvec.lo
  CC   bits.lo
  CC   bitcomp.lo
  CC   counter.lo
  CC   fsm.lo
  CC   write_queue.lo
  CC   utils.lo
  CC   socket.lo
  CC   logging.lo
  CC   logging_syslog.lo
  CC   logging_gsmtap.lo
  CC   rate_ctr.lo
  CC   gsmtap_util.lo
  CC   crc16.lo
  CC   panic.lo
  CC   backtrace.lo
  CC   conv.lo
  CC   application.lo
  CC   rbtree.lo
  CC   strrb.lo
  CC   loggingrb.lo
  CC   crc8gen.lo
  CC   crc16gen.lo
  CC   crc32gen.lo
  CC   crc64gen.lo
  CC   macaddr.lo
  CC   stat_item.lo
  CC   stats.lo
  CC   stats_statsd.lo
  CC   prim.lo
  CC   conv_acc.lo
  CC   conv_acc_generic.lo
  CC   sercomm.lo
  CC   prbs.lo
  CC   isdnhdlc.lo
  CC   conv_acc_sse.lo
  CC   conv_acc_sse_avx.lo
  CC   plugin.lo
  CC   msgfile.lo
  CC   serial.lo
  CCLD libosmocore.la
make[4]: Entering directory 
'
make[4]: Nothing to be done for 'install-data-am'.
 /bin/mkdir -p 
'
 /bin/bash ../libtool   --mode=install /usr/bin/install -c   libosmocore.la 
'
libtool: install: /usr/bin/install -c .libs/libosmocore.so.11.0.0 

libtool: install: (cd 

 && { ln -s -f libosmocore.so.11.0.0 libosmocore.so.11 || { rm -f 
libosmocore.so.11 && ln -s libosmocore.so.11.0.0 libosmocore.so.11; }; })
libtool: install: (cd 

 && { ln -s -f libosmocore.so.11.0.0 libosmocore.so || { rm -f libosmocore.so 
&& ln -s libosmocore.so.11.0.0 libosmocore.so; }; })
libtool: install: /usr/bin/install -c .libs/libosmocore.lai 

libtool: finish: 
PATH="/usr/local/bin:/usr/bin:/bin:/usr/games:/home/osmocom-build/bin:/sbin" 
ldconfig -n 

--
Libraries have been installed in:
   


If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or 

Build failed in Jenkins: master-osmo-ggsn » --enable-gtp-linux,0,a3=default,a4=default,osmocom-master-debian9 #1196

2018-12-05 Thread jenkins
See 


--
[...truncated 44.59 KB...]
  CC   sercomm.lo
  CC   prbs.lo
  CC   isdnhdlc.lo
  CC   conv_acc_sse.lo
  CC   conv_acc_sse_avx.lo
  CC   plugin.lo
  CC   msgfile.lo
  CC   serial.lo
  CCLD libosmocore.la
make[4]: Entering directory 
'
make[4]: Nothing to be done for 'install-data-am'.
 /bin/mkdir -p 
'
 /bin/bash ../libtool   --mode=install /usr/bin/install -c   libosmocore.la 
'
libtool: install: /usr/bin/install -c .libs/libosmocore.so.11.0.0 

libtool: install: (cd 

 && { ln -s -f libosmocore.so.11.0.0 libosmocore.so.11 || { rm -f 
libosmocore.so.11 && ln -s libosmocore.so.11.0.0 libosmocore.so.11; }; })
libtool: install: (cd 

 && { ln -s -f libosmocore.so.11.0.0 libosmocore.so || { rm -f libosmocore.so 
&& ln -s libosmocore.so.11.0.0 libosmocore.so; }; })
libtool: install: /usr/bin/install -c .libs/libosmocore.lai 

libtool: finish: 
PATH="/usr/local/bin:/usr/bin:/bin:/usr/games:/home/osmocom-build/bin:/sbin" 
ldconfig -n 

--
Libraries have been installed in:
   


If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the '-LLIBDIR'
flag during linking and do at least one of the following:
   - add LIBDIR to the 'LD_LIBRARY_PATH' environment variable
 during execution
   - add LIBDIR to the 'LD_RUN_PATH' environment variable
 during linking
   - use the '-Wl,-rpath -Wl,LIBDIR' linker flag
   - have your system administrator add LIBDIR to '/etc/ld.so.conf'

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
--
make[4]: Leaving directory 
'
make[3]: Leaving directory 
'
make[2]: Leaving directory 
'
Making install in src/vty
make[2]: Entering directory 
'
  CC   buffer.lo
  CC   command.lo
  CC   vty.lo
  CC   utils.lo
  CC   telnet_interface.lo
  CC   logging_vty.lo
  CC   vector.lo
  CC   stats_vty.lo
  CC   fsm_vty.lo
  CC   talloc_ctx_vty.lo
  CCLD libosmovty.la
make[3]: Entering directory 

Build failed in Jenkins: master-simtrace2 » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #211

2018-12-05 Thread jenkins
See 


--
[...truncated 161.75 KB...]
  8   0   0   8   8 obj/owhw/dfu_boardver_adc.o
 30  16   0  46  2e obj/owhw/dfu_manifest.o
239   0   0 239  ef obj/owhw/dfu_owhw.o
   1472   1   01473 5c1 obj/owhw/dfu_main.o
244   0   0 244  f4 obj/owhw/dfu_dfu.o
645   4   6 655 28f obj/owhw/dfu_dfu_runtime.o
   3490   0 2083698 e72 obj/owhw/dfu_card_emu.o
  0   0   0   0   0 obj/owhw/dfu_cciddriver.o
   2629  12   42645 a55 obj/owhw/dfu_iso7816_4.o
 96   0   0  96  60 obj/owhw/dfu_iso7816_fidi.o
  0   0   0   0   0 obj/owhw/dfu_mitm.o
   23081152   03460 d84 obj/owhw/dfu_mode_cardemu.o
  0   0   0   0   0 obj/owhw/dfu_mode_ccid.o
352   0 520 872 368 obj/owhw/dfu_simtrace_iso7816.o
  0   0   0   0   0 obj/owhw/dfu_sniffer.o
488  40   0 528 210 obj/owhw/dfu_tc_etu.o
597  48   0 645 285 obj/owhw/dfu_usb.o
  26024   0   17988   44012abec bin/owhw-cardem-dfu.elf
=== owhw / cardem RES:0 ==

=== FIRMWARE TESTS ===
cc -g -Wall `pkg-config --cflags libosmocore` -I../src_simtrace 
-I../atmel_softpack_libraries/libchip_sam3s 
-I../atmel_softpack_libraries/libchip_sam3s/cmsis 
-I../atmel_softpack_libraries/libchip_sam3s/include 
-I../atmel_softpack_libraries/usb/include -I../libcommon/include 
-I../libboard/common/include -I../libboard/simtrace/include -I. -o 
card_emu_tests.hobj -c card_emu_tests.c
In file included from ../libboard/common/include/board_common.h:24:0,
 from ../libboard/simtrace/include/board.h:21,
 from 
../atmel_softpack_libraries/libchip_sam3s/include/trace.h:70,
 from ../libcommon/include/assert.h:60,
 from card_emu_tests.c:4:
../atmel_softpack_libraries/libchip_sam3s/chip.h:11:6: warning: #warning 
Library does not support the specified chip, specifying sam3s4. [-Wcpp]
 #warning Library does not support the specified chip, specifying sam3s4.
  ^~~
card_emu_tests.c: In function ‘get_and_verify_rctx’:
card_emu_tests.c:171:34: warning: unused variable ‘td’ [-Wunused-variable]
  struct cardemu_usb_msg_tx_data *td;
  ^~
cc -g -Wall `pkg-config --cflags libosmocore` -I../src_simtrace 
-I../atmel_softpack_libraries/libchip_sam3s 
-I../atmel_softpack_libraries/libchip_sam3s/cmsis 
-I../atmel_softpack_libraries/libchip_sam3s/include 
-I../atmel_softpack_libraries/usb/include -I../libcommon/include 
-I../libboard/common/include -I../libboard/simtrace/include -I. -o 
card_emu.hobj -c ../libcommon/source/card_emu.c
In file included from ../libboard/common/include/board_common.h:24:0,
 from ../libboard/simtrace/include/board.h:21,
 from 
../atmel_softpack_libraries/libchip_sam3s/include/trace.h:70,
 from ../libcommon/include/assert.h:60,
 from ../libcommon/source/card_emu.c:21:
../atmel_softpack_libraries/libchip_sam3s/chip.h:11:6: warning: #warning 
Library does not support the specified chip, specifying sam3s4. [-Wcpp]
 #warning Library does not support the specified chip, specifying sam3s4.
  ^~~
In file included from ../libcommon/source/card_emu.c:27:0:
../libcommon/include/utils.h:31:2: warning: #warning 
"local_irq_{save,restore}() not implemented" [-Wcpp]
 #warning "local_irq_{save,restore}() not implemented"
  ^~~
../libcommon/source/card_emu.c: In function ‘flush_rx_buffer’:
../libcommon/source/card_emu.c:279:11: warning: unused variable ‘data_len’ 
[-Wunused-variable]
  uint32_t data_len;
   ^~~~
cc -g -Wall `pkg-config --cflags libosmocore` -I../src_simtrace 
-I../atmel_softpack_libraries/libchip_sam3s 
-I../atmel_softpack_libraries/libchip_sam3s/cmsis 
-I../atmel_softpack_libraries/libchip_sam3s/include 
-I../atmel_softpack_libraries/usb/include -I../libcommon/include 
-I../libboard/common/include -I../libboard/simtrace/include -I. -o usb_buf.hobj 
-c ../libcommon/source/usb_buf.c
In file included from ../libboard/common/include/board_common.h:24:0,
 from ../libboard/simtrace/include/board.h:21,
 from ../libcommon/source/usb_buf.c:17:
../atmel_softpack_libraries/libchip_sam3s/chip.h:11:6: warning: #warning 
Library does not support the specified chip, specifying sam3s4. [-Wcpp]
 #warning Library does not support the specified chip, specifying sam3s4.
  ^~~
cc -g -Wall `pkg-config --cflags libosmocore` -I../src_simtrace 
-I../atmel_softpack_libraries/libchip_sam3s 

Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4390

2018-12-05 Thread jenkins
See 


--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4389

2018-12-05 Thread jenkins
See 


--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Change in osmo-msc[master]: libmsc/gsm_04_80.c: HACK: reimplement GSM 04.08 RELEASE COMPLETE

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/11991 )

Change subject: libmsc/gsm_04_80.c: HACK: reimplement GSM 04.08 RELEASE COMPLETE
..


Patch Set 4:

(1 comment)

https://gerrit.osmocom.org/#/c/11991/4/src/libmsc/gsm_04_80.c
File src/libmsc/gsm_04_80.c:

https://gerrit.osmocom.org/#/c/11991/4/src/libmsc/gsm_04_80.c@a83
PS4, Line 83:
feel free to implement a gsm0480_create_ussd_release_complete2() in libosmocore



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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I89727354385b40e18732e8fd1d6c93f4463ade37
Gerrit-Change-Number: 11991
Gerrit-PatchSet: 4
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-CC: Neels Hofmeyr 
Gerrit-Comment-Date: Thu, 06 Dec 2018 01:49:34 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in osmo-hlr[master]: gsupclient: add osmo_gsup_msg_enc_send() helper

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/11989 )

Change subject: gsupclient: add osmo_gsup_msg_enc_send() helper
..


Patch Set 2: Code-Review-1

(6 comments)

https://gerrit.osmocom.org/#/c/11989/2//COMMIT_MSG
Commit Message:

https://gerrit.osmocom.org/#/c/11989/2//COMMIT_MSG@7
PS2, Line 7: gsupclient: add osmo_gsup_msg_enc_send() helper
("helper" triggers a rant from me: it is a word like "framework" or "thing". 
All functions except main() are helpers.)


https://gerrit.osmocom.org/#/c/11989/2//COMMIT_MSG@10
PS2, Line 10: messages using a given abstract 'osmo_gsup_message' structure.
what the function does should be documented at the new function. the commit log 
is more about understanding why and how the change came to be.

And that is exactly what is missing here. All that I can tell is that you are 
adding dead code??


https://gerrit.osmocom.org/#/c/11989/2/src/gsupclient/gsup_client.c
File src/gsupclient/gsup_client.c:

https://gerrit.osmocom.org/#/c/11989/2/src/gsupclient/gsup_client.c@342
PS2, Line 342: /* Helper for encoding and sending GSUP messages */
/* Encode and send a GSUP message. */

Though, that part is rather obvious from the function name, while e.g. the 
return value is not explained.


https://gerrit.osmocom.org/#/c/11989/2/src/gsupclient/gsup_client.c@349
PS2, Line 349:  /* Allocate GSUP message buffer */
omit comments that merely restate the code


https://gerrit.osmocom.org/#/c/11989/2/src/gsupclient/gsup_client.c@356
PS2, Line 356:  /* Encode GSUP message */
ditto


https://gerrit.osmocom.org/#/c/11989/2/src/gsupclient/gsup_client.c@363
PS2, Line 363:  /* Finally send */
Do you know these API docs that go like:

  set_value(): Helper to set value.
  osmo_gsup_encode():  Encode an OsmoGSUP.
  osmo_gsup_client_send(): Send an OsmoGSUP client.

;)



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

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I0589ff27933e9bca2bcf93b8259004935778db8f
Gerrit-Change-Number: 11989
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Comment-Date: Thu, 06 Dec 2018 01:47:41 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes


Change in osmo-ci[master]: master-builds: set PUBLISH=0 temporarily

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/12137 )

Change subject: master-builds: set PUBLISH=0 temporarily
..


Patch Set 1: Code-Review+2

yes, let's fix those, but just in case that stuff is breaking and we get failed 
builds even though the code is fine because of this, I will allow a temporary 
merge of this.

If no jobs break sporadically, then assume I voted like Pau.


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

Gerrit-Project: osmo-ci
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I946f2e17229d3c602bbe79a72cc37104745ea552
Gerrit-Change-Number: 12137
Gerrit-PatchSet: 1
Gerrit-Owner: osmith 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Thu, 06 Dec 2018 01:32:02 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ci[master]: jobs/ttcn3-testsuites.yml: add build-discarder

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/12141 )

Change subject: jobs/ttcn3-testsuites.yml: add build-discarder
..


Patch Set 1: Code-Review+1

ok for me, maybe someone wants to keep more builds for the builds summary in 
jenkins? so waiting for someone else's +2


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

Gerrit-Project: osmo-ci
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ib7f01751ca5f6fb3e29a436982e2891d9cab0488
Gerrit-Change-Number: 12141
Gerrit-PatchSet: 1
Gerrit-Owner: osmith 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Comment-Date: Thu, 06 Dec 2018 01:30:31 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmocore[master]: Add osmo_init_logging_std*()

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/12094 )

Change subject: Add osmo_init_logging_std*()
..


Patch Set 2: Code-Review-2

What Pau said.

We already have various tests that verify stderr output. Each test also can 
individually configure logging categories (show only a set of categories) and 
achieve a reproducable format (hide timestamps, ...).

If needed, the next best thing would be 2>&1 in the testsuite.at.

For anything that is not a test, logging targets are configured by .cfg file.


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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I0fe8dc4a41aba4e4509540266e229700e8ec083c
Gerrit-Change-Number: 12094
Gerrit-PatchSet: 2
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Pau Espin Pedrol 
Gerrit-Comment-Date: Thu, 06 Dec 2018 01:21:16 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmocore[master]: gsm48_mi_to_string(): style tweak: break on error first

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12158


Change subject: gsm48_mi_to_string(): style tweak: break on error first
..

gsm48_mi_to_string(): style tweak: break on error first

In the TMSI case, use early-exit paradigm. It's debatable which way would be
early exit, since the success case is also a 'return', but early-exit in the
sense of: handle error paths in sub-clauses, with the success path below.

Change-Id: Ic76bc5e84ad1278fa3b2db5f5e28cadf1d90a343
---
M src/gsm/gsm48.c
1 file changed, 6 insertions(+), 5 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/58/12158/1

diff --git a/src/gsm/gsm48.c b/src/gsm/gsm48.c
index 2d4b840..6568523 100644
--- a/src/gsm/gsm48.c
+++ b/src/gsm/gsm48.c
@@ -659,11 +659,12 @@
switch (mi_type) {
case GSM_MI_TYPE_TMSI:
/* Table 10.5.4.3, reverse generate_mid_from_tmsi */
-   if (mi_len == GSM48_TMSI_LEN && mi[0] == (0xf0 | 
GSM_MI_TYPE_TMSI)) {
-   tmsi = osmo_load32be([1]);
-   return snprintf(string, str_len, "%"PRIu32, tmsi);
-   }
-   break;
+   if (mi_len != GSM48_TMSI_LEN
+   || mi[0] != (0xf0 | GSM_MI_TYPE_TMSI))
+   break;
+   tmsi = osmo_load32be([1]);
+   return snprintf(string, str_len, "%"PRIu32, tmsi);
+
case GSM_MI_TYPE_IMSI:
case GSM_MI_TYPE_IMEI:
case GSM_MI_TYPE_IMEISV:

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic76bc5e84ad1278fa3b2db5f5e28cadf1d90a343
Gerrit-Change-Number: 12158
Gerrit-PatchSet: 1
Gerrit-Owner: Neels Hofmeyr 


Change in libosmocore[master]: gsm48_mi_to_string(): do not read from zero length input buffer

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12157

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

Change subject: gsm48_mi_to_string(): do not read from zero length input buffer
..

gsm48_mi_to_string(): do not read from zero length input buffer

Change-Id: I12cada7c2c5187146ca5a33d1ebfefb4cad65632
---
M src/gsm/gsm48.c
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/57/12157/3
--
To view, visit https://gerrit.osmocom.org/12157
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I12cada7c2c5187146ca5a33d1ebfefb4cad65632
Gerrit-Change-Number: 12157
Gerrit-PatchSet: 3
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Change in libosmocore[master]: gsm48_mi_to_string(): guard against zero length output buffer

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12156

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

Change subject: gsm48_mi_to_string(): guard against zero length output buffer
..

gsm48_mi_to_string(): guard against zero length output buffer

All successful cases already return from the switch(), so simply handle all
errors below it by returning an empty string (if there is enough string
buffer).

Change-Id: I709ac3b9efb7b4258d8660715b10312e11b9b571
---
M src/gsm/gsm48.c
M tests/gsm0408/gsm0408_test.ok
2 files changed, 13 insertions(+), 13 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/56/12156/3
--
To view, visit https://gerrit.osmocom.org/12156
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I709ac3b9efb7b4258d8660715b10312e11b9b571
Gerrit-Change-Number: 12156
Gerrit-PatchSet: 3
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Change in libosmocore[master]: gsm48_generate_mid(): mask out ODD flag from mi_type

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12155

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

Change subject: gsm48_generate_mid(): mask out ODD flag from mi_type
..

gsm48_generate_mid(): mask out ODD flag from mi_type

Change-Id: Id6e695ebf9f86b295eaa7e2c6228989256f37e68
---
M src/gsm/gsm48.c
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
3 files changed, 6 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/55/12155/2
--
To view, visit https://gerrit.osmocom.org/12155
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Id6e695ebf9f86b295eaa7e2c6228989256f37e68
Gerrit-Change-Number: 12155
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Change in libosmocore[master]: add osmo_bsc2str()

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12153

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

Change subject: add osmo_bsc2str()
..

add osmo_bsc2str()

Add a standalone bcd-to-string conversion function with generic parameters.
Add a regression test in utils_test.c.

So far there is no single universal implementation that converts a BCD to a
string. I could only find gsm48_mi_to_string(), which also interprets
surrounding bytes, MI type and TMSI as non-BCD value.

The idea is to use this function from gsm48_mi_to_string() and similar
implementations in subsequent commits.

Root cause: in osmo-msc, I want to have an alternative MI-to-string function
for composing an FSM name, which needs the BCD part of gsm48_mi_to_string() but
not the TMSI part.

Change-Id: I86b09d37ceef1c1a56046a5443127d6c6be0
---
M include/osmocom/core/utils.h
M src/utils.c
M tests/utils/utils_test.c
M tests/utils/utils_test.ok
4 files changed, 131 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/53/12153/2
--
To view, visit https://gerrit.osmocom.org/12153
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I86b09d37ceef1c1a56046a5443127d6c6be0
Gerrit-Change-Number: 12153
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Change in libosmocore[master]: gsm0408_test: test encoding and decoding Mobile Identity

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12151

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

Change subject: gsm0408_test: test encoding and decoding Mobile Identity
..

gsm0408_test: test encoding and decoding Mobile Identity

One would think by now we would solidly encode and decode Mobile Identities.
Well, guess again.

- rc is sometimes the amount of bytes written, sometimes actual strlen().

- on string truncation, rc is sometimes strlen() (assuming nul terminated), and
  sometimes snprintf()-style would-be strlen().

- returned string, when truncated by not enough buffer size, is sometimes nul
  terminated, sometimes not.

- gsm48_mi_to_string() happily reads a byte from zero-length input buffer.

- gsm48_mi_to_string() happily writes to zero length output buffer.

- gsm48_mi_to_string() returns nonempty string for empty input.

- encoding a MI type that still has the GSM_MI_ODD flag set results in encoding
  an even-length MI as odd-length (hence appending a stray 'F').

I am going to tweak the implementation of gsm48 mobile identity encoding /
decoding, so first pinpoint the current behavior in a unit test, and show how
perforated even such a seemingly trivial API can be.

Change-Id: Iaae3af87f82f1a8f2e6273984c011b2813038cf7
---
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
2 files changed, 358 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/51/12151/2
--
To view, visit https://gerrit.osmocom.org/12151
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Iaae3af87f82f1a8f2e6273984c011b2813038cf7
Gerrit-Change-Number: 12151
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Change in libosmocore[master]: api doc: gsm48_mi_to_string(): warn of return value implementation

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12152

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

Change subject: api doc: gsm48_mi_to_string(): warn of return value 
implementation
..

api doc: gsm48_mi_to_string(): warn of return value implementation

Change-Id: If5e7abd15dddf39cdfad8071f4cd5ca8244eabe0
---
M src/gsm/gsm48.c
1 file changed, 4 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/52/12152/2
--
To view, visit https://gerrit.osmocom.org/12152
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: If5e7abd15dddf39cdfad8071f4cd5ca8244eabe0
Gerrit-Change-Number: 12152
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Change in libosmocore[master]: gsm48_mi_to_string: use osmo_bcd2str(), fix some corner cases

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12154

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

Change subject: gsm48_mi_to_string: use osmo_bcd2str(), fix some corner cases
..

gsm48_mi_to_string: use osmo_bcd2str(), fix some corner cases

By using osmo_bcd2str(), ensure that the resulting string is always nul
terminated, and always return strlen()+1 whether truncated or not.

Still keep up the previous return value style, even if that isn't consistent at
all.

The difference between IMSI/IMEI and TMSI return values remains and is not part
of this patch.

Change-Id: I1b51b72a721e1cc9d69796b804ebda741ff0f36b
---
M src/gsm/gsm48.c
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
3 files changed, 22 insertions(+), 28 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/54/12154/2
--
To view, visit https://gerrit.osmocom.org/12154
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I1b51b72a721e1cc9d69796b804ebda741ff0f36b
Gerrit-Change-Number: 12154
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4387

2018-12-05 Thread jenkins
See 


--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4388

2018-12-05 Thread jenkins
See 


--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Change in libosmocore[master]: gsm48_mi_to_string(): guard against zero length output buffer

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12156

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

Change subject: gsm48_mi_to_string(): guard against zero length output buffer
..

gsm48_mi_to_string(): guard against zero length output buffer

All successful cases already return from the switch(), so simply handle all
errors below it by returning an empty string (if there is enough string
buffer).

Change-Id: I709ac3b9efb7b4258d8660715b10312e11b9b571
---
M src/gsm/gsm48.c
M tests/gsm0408/gsm0408_test.ok
2 files changed, 13 insertions(+), 13 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/56/12156/2
--
To view, visit https://gerrit.osmocom.org/12156
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I709ac3b9efb7b4258d8660715b10312e11b9b571
Gerrit-Change-Number: 12156
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)


Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4386

2018-12-05 Thread jenkins
See 


--
[...truncated 1.13 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4385

2018-12-05 Thread jenkins
See 


--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Change in libosmocore[master]: gsm48_mi_to_string(): guard against zero length output buffer

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12156


Change subject: gsm48_mi_to_string(): guard against zero length output buffer
..

gsm48_mi_to_string(): guard against zero length output buffer

All successful cases already return from the switch(), so simply handle all
errors below it by returning an empty string (if there is enough string
buffer).

Change-Id: I709ac3b9efb7b4258d8660715b10312e11b9b571
---
M src/gsm/gsm48.c
M tests/gsm0408/gsm0408_test.ok
2 files changed, 13 insertions(+), 12 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/56/12156/1

diff --git a/src/gsm/gsm48.c b/src/gsm/gsm48.c
index 3487ef7..7517c09 100644
--- a/src/gsm/gsm48.c
+++ b/src/gsm/gsm48.c
@@ -658,8 +658,6 @@
mi_type = mi[0] & GSM_MI_TYPE_MASK;

switch (mi_type) {
-   case GSM_MI_TYPE_NONE:
-   break;
case GSM_MI_TYPE_TMSI:
/* Table 10.5.4.3, reverse generate_mid_from_tmsi */
if (mi_len == GSM48_TMSI_LEN && mi[0] == (0xf0 | 
GSM_MI_TYPE_TMSI)) {
@@ -679,12 +677,15 @@
return 0;
else
return strlen(string) + 1;
+
default:
break;
}
-   *str_cur++ = '\0';

-   return str_cur - string;
+   if (str_len < 1)
+   return 0;
+   *string = '\0';
+   return 1;
 }

 /*! Parse TS 04.08 Routing Area Identifier
diff --git a/tests/gsm0408/gsm0408_test.ok b/tests/gsm0408/gsm0408_test.ok
index 6e99f5b..d6579e5 100644
--- a/tests/gsm0408/gsm0408_test.ok
+++ b/tests/gsm0408/gsm0408_test.ok
@@ -72,8 +72,8 @@
 returned empty string
 - MI type: TMSI
   - writing to zero-length string:
-rc=1
-ERROR: Wrote to invalid memory!
+rc=0
+nothing written
   - writing to 1-byte-length string:
 rc=1
 returned empty string
@@ -82,8 +82,8 @@
 returned empty string
 - MI type: NONE
   - writing to zero-length string:
-rc=1
-ERROR: Wrote to invalid memory!
+rc=0
+nothing written
   - writing to 1-byte-length string:
 rc=1
 returned empty string
@@ -102,8 +102,8 @@
 returned empty string
 - MI type: TMSI | GSM_MI_ODD
   - writing to zero-length string:
-rc=1
-ERROR: Wrote to invalid memory!
+rc=0
+nothing written
   - writing to 1-byte-length string:
 rc=1
 returned empty string
@@ -112,8 +112,8 @@
 returned empty string
 - MI type: NONE | GSM_MI_ODD
   - writing to zero-length string:
-rc=1
-ERROR: Wrote to invalid memory!
+rc=0
+nothing written
   - writing to 1-byte-length string:
 rc=1
 returned empty string

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I709ac3b9efb7b4258d8660715b10312e11b9b571
Gerrit-Change-Number: 12156
Gerrit-PatchSet: 1
Gerrit-Owner: Neels Hofmeyr 


Change in libosmocore[master]: gsm48_mi_to_string(): do not read from zero length input buffer

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12157


Change subject: gsm48_mi_to_string(): do not read from zero length input buffer
..

gsm48_mi_to_string(): do not read from zero length input buffer

Change-Id: I12cada7c2c5187146ca5a33d1ebfefb4cad65632
---
M src/gsm/gsm48.c
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/57/12157/1

diff --git a/src/gsm/gsm48.c b/src/gsm/gsm48.c
index 7517c09..68cb567 100644
--- a/src/gsm/gsm48.c
+++ b/src/gsm/gsm48.c
@@ -655,7 +655,7 @@
char *str_cur = string;
uint32_t tmsi;

-   mi_type = mi[0] & GSM_MI_TYPE_MASK;
+   mi_type = (mi && mi_len) ? (mi[0] & GSM_MI_TYPE_MASK) : 
GSM_MI_TYPE_NONE;

switch (mi_type) {
case GSM_MI_TYPE_TMSI:

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I12cada7c2c5187146ca5a33d1ebfefb4cad65632
Gerrit-Change-Number: 12157
Gerrit-PatchSet: 1
Gerrit-Owner: Neels Hofmeyr 


Change in libosmocore[master]: api doc: gsm48_mi_to_string(): warn of return value implementation

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12152


Change subject: api doc: gsm48_mi_to_string(): warn of return value 
implementation
..

api doc: gsm48_mi_to_string(): warn of return value implementation

Change-Id: If5e7abd15dddf39cdfad8071f4cd5ca8244eabe0
---
M src/gsm/gsm48.c
1 file changed, 4 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/52/12152/1

diff --git a/src/gsm/gsm48.c b/src/gsm/gsm48.c
index ae9a1cf..e684a3c 100644
--- a/src/gsm/gsm48.c
+++ b/src/gsm/gsm48.c
@@ -643,7 +643,10 @@
  *  \param[in] str_len Length of \a string in bytes
  *  \param[in] mi Mobile Identity to be stringified
  *  \param[in] mi_len Length of \a mi in bytes
- *  \returns length of string written to \a string */
+ *  \returns WARNING: the return value of this function is not well 
implemented.
+ *   Depending on the MI type and amount of output buffer, this may 
return
+ *   the nr of written bytes, or the written strlen(), or the 
snprintf()
+ *   style strlen()-if-the-buffer-were-large-enough. */
 int gsm48_mi_to_string(char *string, const int str_len, const uint8_t *mi,
   const int mi_len)
 {

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: If5e7abd15dddf39cdfad8071f4cd5ca8244eabe0
Gerrit-Change-Number: 12152
Gerrit-PatchSet: 1
Gerrit-Owner: Neels Hofmeyr 


Change in libosmocore[master]: gsm0408_test: test encoding and decoding Mobile Identity

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12151


Change subject: gsm0408_test: test encoding and decoding Mobile Identity
..

gsm0408_test: test encoding and decoding Mobile Identity

One would think by now we would solidly encode and decode Mobile Identities.
Well, guess again.

- rc is sometimes the amount of bytes written, sometimes actual strlen().

- on string truncation, rc is sometimes strlen() (assuming truncation), and
  sometimes snprintf()-style would-be strlen().

- returned string, when truncated by not enough buffer size, is sometimes nul
  terminated, sometimes not.

- gsm48_mi_to_string() happily reads a byte from zero-length input buffer.

- gsm48_mi_to_string() happily writes to zero length output buffer.

- gsm48_mi_to_string() returns nonempty string for empty input.

- encoding a MI type that still has the GSM_MI_ODD flag set results in encoding
  an even-length MI as odd-length (hence appending a stray 'F').

I am going to tweak the implementation of gsm48 mobile identity encoding /
decoding, so first pinpoint the current behavior in a unit test, and show how
perforated even such a seemingly trivial API can be.

Change-Id: Iaae3af87f82f1a8f2e6273984c011b2813038cf7
---
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
2 files changed, 358 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/51/12151/1

diff --git a/tests/gsm0408/gsm0408_test.c b/tests/gsm0408/gsm0408_test.c
index 2a0e661..d38969b 100644
--- a/tests/gsm0408/gsm0408_test.c
+++ b/tests/gsm0408/gsm0408_test.c
@@ -352,11 +352,246 @@
printf("passed: [%u] %s\n", len, osmo_hexdump(buf, len));
 }

+struct test_mid_encode_decode_test {
+   uint8_t mi_type;
+   const char *mi_str;
+   size_t str_size;
+   const char *expect_mi_tlv_hex;
+   const char *expect_str;
+   int expect_rc;
+};
+
+static const struct test_mid_encode_decode_test test_mid_encode_decode_tests[] 
= {
+   {
+   .mi_type = GSM_MI_TYPE_IMSI,
+   .mi_str = "123456789012345",
+   .expect_mi_tlv_hex = "17081932547698103254",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMSI,
+   .mi_str = "12345678901234",
+   .expect_mi_tlv_hex = "170811325476981032f4",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMSI,
+   .mi_str = "423423",
+   .expect_mi_tlv_hex = "1704413224f3",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMSI | GSM_MI_ODD,
+   .mi_str = "423423",
+   .expect_mi_tlv_hex = "1704493224f3", /* encodes "odd" for even 
number of digits! */
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMSI,
+   .mi_str = "4234235",
+   .expect_mi_tlv_hex = "170449322453",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMSI,
+   .mi_str = "4234235",
+   .expect_mi_tlv_hex = "170449322453",
+   .str_size = 4,
+   .expect_str = "423",
+   .expect_rc = 3, /* exception: on truncation, 
gsm48_mi_to_string() returns strlen(), not bytes! */
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMEI,
+   .mi_str = "123456789012345",
+   .expect_mi_tlv_hex = "17081a32547698103254",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMEI,
+   .mi_str = "98765432109876",
+   .expect_mi_tlv_hex = "170892785634129078f6",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMEI,
+   .mi_str = "987654321098765",
+   .expect_mi_tlv_hex = "17089a78563412907856",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMEISV,
+   .mi_str = "987654321098765432",
+   .expect_mi_tlv_hex = "170a937856341290785634f2",
+   },
+   {
+   .mi_type = GSM_MI_TYPE_IMEISV,
+   .mi_str = "987654321098765432",
+   .expect_mi_tlv_hex = "170a937856341290785634f2",
+   .str_size = 16,
+   .expect_str = "987654321098765",
+   .expect_rc = 15, /* exception: on truncation, 
gsm48_mi_to_string() returns strlen(), not bytes! */
+   },
+   {
+   /* gsm48 treats TMSI as decimal string */
+   .mi_type = GSM_MI_TYPE_TMSI,
+   .mi_str = "305419896", /* 0x12345678 as decimal */
+   .expect_mi_tlv_hex = "1705f412345678",
+   .expect_rc = 9, /* exception: gsm48_mi_to_string() for TMSI 
returns strlen(), not bytes! */
+   },
+   {
+   .mi_type = GSM_MI_TYPE_TMSI,
+   .mi_str = "12648430", /* 0xc0ffee as decimal */
+   .expect_mi_tlv_hex = "1705f400c0ffee",
+   .expect_rc = 8, /* exception: gsm48_mi_to_string() for TMSI 
returns strlen(), not bytes! 

Change in libosmocore[master]: gsm48_generate_mid(): mask out ODD flag from mi_type

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12155


Change subject: gsm48_generate_mid(): mask out ODD flag from mi_type
..

gsm48_generate_mid(): mask out ODD flag from mi_type

Change-Id: Id6e695ebf9f86b295eaa7e2c6228989256f37e68
---
M src/gsm/gsm48.c
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
3 files changed, 6 insertions(+), 8 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/55/12155/1

diff --git a/src/gsm/gsm48.c b/src/gsm/gsm48.c
index df4b4c1..3487ef7 100644
--- a/src/gsm/gsm48.c
+++ b/src/gsm/gsm48.c
@@ -611,7 +611,7 @@
uint8_t length = strnlen(id, 255), i, off = 0, odd = (length & 1) == 1;

buf[0] = GSM48_IE_MOBILE_ID;
-   buf[2] = osmo_char2bcd(id[0]) << 4 | mi_type | (odd << 3);
+   buf[2] = osmo_char2bcd(id[0]) << 4 | (mi_type & GSM_MI_TYPE_MASK) | 
(odd << 3);

/* if the length is even we will fill half of the last octet */
buf[1] = (length + (odd ? 1 : 2)) >> 1;
diff --git a/tests/gsm0408/gsm0408_test.c b/tests/gsm0408/gsm0408_test.c
index 7dbb97d..c85d1fd 100644
--- a/tests/gsm0408/gsm0408_test.c
+++ b/tests/gsm0408/gsm0408_test.c
@@ -380,7 +380,7 @@
{
.mi_type = GSM_MI_TYPE_IMSI | GSM_MI_ODD,
.mi_str = "423423",
-   .expect_mi_tlv_hex = "1704493224f3", /* encodes "odd" for even 
number of digits! */
+   .expect_mi_tlv_hex = "1704413224f3",
},
{
.mi_type = GSM_MI_TYPE_IMSI,
@@ -464,7 +464,7 @@
{
.mi_type = GSM_MI_ODD,
.mi_str = "1234",
-   .expect_mi_tlv_hex = "17031832f4", /* encoding nonsense and 
encodes "odd" for an even number of digits! */
+   .expect_mi_tlv_hex = "17031032f4", /* encoding nonsense! */
.expect_str = "",
},
 };
diff --git a/tests/gsm0408/gsm0408_test.ok b/tests/gsm0408/gsm0408_test.ok
index 2db58de..6e99f5b 100644
--- a/tests/gsm0408/gsm0408_test.ok
+++ b/tests/gsm0408/gsm0408_test.ok
@@ -14,10 +14,8 @@
   -> MI-TLV-hex='1704413224f3'
   -> MI-str="423423" rc=7
 - unknown 0x9 423423
-  -> MI-TLV-hex='1704493224f3'
-  -> MI-str="423423F" rc=8
- ERROR: expected MI-str="423423"
- ERROR: expected rc=7
+  -> MI-TLV-hex='1704413224f3'
+  -> MI-str="423423" rc=7
 - IMSI 4234235
   -> MI-TLV-hex='170449322453'
   -> MI-str="4234235" rc=8
@@ -58,7 +56,7 @@
   -> MI-TLV-hex='17031032f4'
   -> MI-str="" rc=1
 - unknown 0x8 1234
-  -> MI-TLV-hex='17031832f4'
+  -> MI-TLV-hex='17031032f4'
   -> MI-str="" rc=1

 Decoding zero length Mobile Identities

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Id6e695ebf9f86b295eaa7e2c6228989256f37e68
Gerrit-Change-Number: 12155
Gerrit-PatchSet: 1
Gerrit-Owner: Neels Hofmeyr 


Change in libosmocore[master]: add osmo_bsc2str()

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12153


Change subject: add osmo_bsc2str()
..

add osmo_bsc2str()

Add a standalone bcd-to-string conversion function with generic parameters.
Add a regression test in utils_test.c.

So far there is no single universal implementation that converts a BCD to a
string. I could only find gsm48_mi_to_string(), which also interprets
surrounding bytes, MI type and TMSI as non-BCD value.

The idea is to use this function from gsm48_mi_to_string() and similar
implementations in subsequent commits.

Root cause: in osmo-msc, I want to have an alternative MI-to-string function
for composing an FSM name, which needs the BCD part of gsm48_mi_to_string() but
not the TMSI part.

Change-Id: I86b09d37ceef1c1a56046a5443127d6c6be0
---
M include/osmocom/core/utils.h
M src/utils.c
M tests/utils/utils_test.c
M tests/utils/utils_test.ok
4 files changed, 131 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/53/12153/1

diff --git a/include/osmocom/core/utils.h b/include/osmocom/core/utils.h
index 0b54c88..34e6a4a 100644
--- a/include/osmocom/core/utils.h
+++ b/include/osmocom/core/utils.h
@@ -49,6 +49,8 @@
 /* only works for numbers in ascci */
 uint8_t osmo_char2bcd(char c);

+int osmo_bcd2str(char *dst, size_t dst_size, const uint8_t bcd[], int 
start_nibble, int end_nibble);
+
 int osmo_hexparse(const char *str, uint8_t *b, int max_len);
 
 char *osmo_ubit_dump(const uint8_t *bits, unsigned int len);
diff --git a/src/utils.c b/src/utils.c
index e6adcf8..a86b0fb 100644
--- a/src/utils.c
+++ b/src/utils.c
@@ -129,6 +129,38 @@
return 0;
 }

+/*! Convert BCD to string.
+ * The given nibble offsets are interpreted in BCD order, i.e. nibble 0 is 
bcd[0] & 0xf, nibble 1 is bcd[0] >> 4, nibble
+ * 3 is bcd[1] & 0xf, etc..
+ *  \param[out] dst  Output string buffer, is always nul terminated when 
dst_size > 0.
+ *  \param[in] dst_size  sizeof() the output string buffer.
+ *  \param[in] bcd  Binary coded data buffer.
+ *  \param[in] start_nibble  Offset to start from, in nibbles, typically 1 to 
skip the first nibble.
+ *  \param[in] end_nibble  Offset to stop before, in nibbles, e.g. sizeof(bcd) 
- (bcd[0] & GSM_MI_ODD? 0:1).
+ *  \returns The strlen that would be written if the output buffer is large 
enough, excluding nul byte (like
+ *   snprintf()).
+ */
+int osmo_bcd2str(char *dst, size_t dst_size, const uint8_t bcd[], int 
start_nibble, int end_nibble)
+{
+   char *dst_end = dst + dst_size - 1;
+   int nibble_i;
+
+   for (nibble_i = start_nibble; nibble_i < end_nibble && dst < dst_end; 
nibble_i++, dst++) {
+   uint8_t nibble = bcd[nibble_i >> 1];
+   if ((nibble_i & 1))
+   nibble >>= 4;
+   nibble &= 0xf;
+
+   *dst = osmo_bcd2char(nibble);
+   }
+
+   /* Always terminate, but guard against zero dst_size */
+   if (dst <= dst_end)
+   *dst = '\0';
+
+   return OSMO_MAX(0, end_nibble - start_nibble);
+}
+
 /*! Parse a string containing hexadecimal digits
  *  \param[in] str string containing ASCII encoded hexadecimal digits
  *  \param[out] b output buffer
diff --git a/tests/utils/utils_test.c b/tests/utils/utils_test.c
index 2bb1f9c..f8ff105 100644
--- a/tests/utils/utils_test.c
+++ b/tests/utils/utils_test.c
@@ -383,6 +383,85 @@
}
 }

+struct bcd2str_test {
+   const char *bcd_hex;
+   int start_nibble;
+   int end_nibble;
+   size_t str_size;
+   const char *expect_str;
+   int expect_rc;
+};
+
+static const struct bcd2str_test bcd2str_tests[] = {
+   {
+   .bcd_hex = "1a 32 54 76 98 f0",
+   .start_nibble = 1,
+   .end_nibble = 11,
+   .expect_str = "1234567890",
+   .expect_rc = 10,
+   },
+   {
+   .bcd_hex = "1a 32 54 76 98 f0",
+   .start_nibble = 1,
+   .end_nibble = 12,
+   .expect_str = "1234567890F",
+   .expect_rc = 11,
+   },
+   {
+   .bcd_hex = "1a 32 54 76 98 f0",
+   .start_nibble = 0,
+   .end_nibble = 12,
+   .expect_str = "A1234567890F",
+   .expect_rc = 12,
+   },
+   {
+   .bcd_hex = "1a 32 54 76 98 f0",
+   .start_nibble = 1,
+   .end_nibble = 12,
+   .str_size = 5,
+   .expect_str = "1234",
+   .expect_rc = 11,
+   },
+   {
+   .bcd_hex = "",
+   .start_nibble = 1,
+   .end_nibble = 1,
+   .expect_str = "",
+   .expect_rc = 0,
+   },
+};
+
+static void bcd2str_test(void)
+{
+   int i;
+
+   printf("\nTesting bcd to string conversion\n");
+
+   for (i = 0; i < ARRAY_SIZE(bcd2str_tests); 

Change in libosmocore[master]: gsm48_mi_to_string: use osmo_bcd2str(), fix some corner cases

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has uploaded this change for review. ( 
https://gerrit.osmocom.org/12154


Change subject: gsm48_mi_to_string: use osmo_bcd2str(), fix some corner cases
..

gsm48_mi_to_string: use osmo_bcd2str(), fix some corner cases

By using osmo_bcd2str(), ensure that the resulting string is always nul
terminated, and always return strlen()+1 whether truncated or not.

Still keep up the previous return value style, even if that isn't consistent at
all.

The difference between IMSI/IMEI and TMSI return values remains and is not part
of this patch.

Change-Id: I1b51b72a721e1cc9d69796b804ebda741ff0f36b
---
M src/gsm/gsm48.c
M tests/gsm0408/gsm0408_test.c
M tests/gsm0408/gsm0408_test.ok
3 files changed, 22 insertions(+), 28 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/54/12154/1

diff --git a/src/gsm/gsm48.c b/src/gsm/gsm48.c
index e684a3c..df4b4c1 100644
--- a/src/gsm/gsm48.c
+++ b/src/gsm/gsm48.c
@@ -650,7 +650,7 @@
 int gsm48_mi_to_string(char *string, const int str_len, const uint8_t *mi,
   const int mi_len)
 {
-   int i;
+   int rc;
uint8_t mi_type;
char *str_cur = string;
uint32_t tmsi;
@@ -670,17 +670,15 @@
case GSM_MI_TYPE_IMSI:
case GSM_MI_TYPE_IMEI:
case GSM_MI_TYPE_IMEISV:
-   *str_cur++ = osmo_bcd2char(mi[0] >> 4);
-
-for (i = 1; i < mi_len; i++) {
-   if (str_cur + 2 >= string + str_len)
-   return str_cur - string;
-   *str_cur++ = osmo_bcd2char(mi[i] & 0xf);
-   /* skip last nibble in last input byte when GSM_EVEN */
-   if( (i != mi_len-1) || (mi[0] & GSM_MI_ODD))
-   *str_cur++ = osmo_bcd2char(mi[i] >> 4);
-   }
-   break;
+   rc = osmo_bcd2str(string, str_len, mi,
+ 1, mi_len * 2 - ((mi[0] & GSM_MI_ODD) ? 0 : 
1));
+   /* osmo_bcd2str() returns snprintf style strlen(), this returns 
bytes written. */
+   if (rc < str_len)
+   return rc + 1;
+   else if (!str_len)
+   return 0;
+   else
+   return strlen(string) + 1;
default:
break;
}
diff --git a/tests/gsm0408/gsm0408_test.c b/tests/gsm0408/gsm0408_test.c
index d38969b..7dbb97d 100644
--- a/tests/gsm0408/gsm0408_test.c
+++ b/tests/gsm0408/gsm0408_test.c
@@ -393,7 +393,6 @@
.expect_mi_tlv_hex = "170449322453",
.str_size = 4,
.expect_str = "423",
-   .expect_rc = 3, /* exception: on truncation, 
gsm48_mi_to_string() returns strlen(), not bytes! */
},
{
.mi_type = GSM_MI_TYPE_IMEI,
@@ -421,7 +420,6 @@
.expect_mi_tlv_hex = "170a937856341290785634f2",
.str_size = 16,
.expect_str = "987654321098765",
-   .expect_rc = 15, /* exception: on truncation, 
gsm48_mi_to_string() returns strlen(), not bytes! */
},
{
/* gsm48 treats TMSI as decimal string */
diff --git a/tests/gsm0408/gsm0408_test.ok b/tests/gsm0408/gsm0408_test.ok
index 1dc4249..2db58de 100644
--- a/tests/gsm0408/gsm0408_test.ok
+++ b/tests/gsm0408/gsm0408_test.ok
@@ -23,8 +23,7 @@
   -> MI-str="4234235" rc=8
 - IMSI 4234235
   -> MI-TLV-hex='170449322453'
-  -> MI-str="423" rc=3
- ERROR: resulting string is not explicitly nul terminated
+  -> MI-str="423" rc=4
 - IMEI 123456789012345
   -> MI-TLV-hex='17081a32547698103254'
   -> MI-str="123456789012345" rc=16
@@ -39,8 +38,7 @@
   -> MI-str="987654321098765432" rc=19
 - IMEI-SV 987654321098765432
   -> MI-TLV-hex='170a937856341290785634f2'
-  -> MI-str="987654321098765" rc=15
- ERROR: resulting string is not explicitly nul terminated
+  -> MI-str="987654321098765" rc=16
 - TMSI 305419896
   -> MI-TLV-hex='1705f412345678'
   -> MI-str="305419896" rc=9
@@ -66,14 +64,14 @@
 Decoding zero length Mobile Identities
 - MI type: IMSI
   - writing to zero-length string:
-rc=1
-ERROR: Wrote to invalid memory!
+rc=0
+nothing written
   - writing to 1-byte-length string:
 rc=1
-ERROR: Wrote unexpected string "1"
+returned empty string
   - decode zero-length mi:
-rc=2
-ERROR: expected empty string, got output string: "1"
+rc=1
+returned empty string
 - MI type: TMSI
   - writing to zero-length string:
 rc=1
@@ -96,14 +94,14 @@
 returned empty string
 - MI type: IMSI | GSM_MI_ODD
   - writing to zero-length string:
-rc=1
-ERROR: Wrote to invalid memory!
+rc=0
+nothing written
   - writing to 1-byte-length string:
 rc=1
-ERROR: Wrote unexpected string "1"
+returned empty string
   - decode zero-length mi:
-rc=2
-ERROR: 

Change in osmo-ttcn3-hacks[master]: MSC_Tests.ttcn: correct VTY command in TC_lu_and_ss_session_timeout

2018-12-05 Thread Vadim Yanitskiy
Vadim Yanitskiy has posted comments on this change. ( 
https://gerrit.osmocom.org/12057 )

Change subject: MSC_Tests.ttcn: correct VTY command in 
TC_lu_and_ss_session_timeout
..


Set Ready For Review


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

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Icd1133ca9f46bc2a9302deebb1e401862cf672cb
Gerrit-Change-Number: 12057
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Comment-Date: Wed, 05 Dec 2018 21:25:58 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in osmo-msc[master]: libmsc/gsm_09_11.c: implement guard timer for NCSS sessions

2018-12-05 Thread Vadim Yanitskiy
Hello Neels Hofmeyr, Harald Welte, Jenkins Builder,

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

https://gerrit.osmocom.org/11992

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

Change subject: libmsc/gsm_09_11.c: implement guard timer for NCSS sessions
..

libmsc/gsm_09_11.c: implement guard timer for NCSS sessions

It may happen that either the MS or an ESME would become
unresponsive during a call independent SS session, e.g.
due to a bug, or a dropped message. In such cases, the
corresponding transaction would remain unfreed forever.

This change introduces a guard timer, that prevents keeping
'stalled' NCSS sessions forever. As soon as it expires, both
sides (i.e. MS and ESME) are getting notified, and the
transaction is being released.

By default, the timer expires after 30 seconds. As soon as
either the MS, or an ESME initiates any activity, the timer
is being rescheduled.

The timeout value can be configured from the VTY:

  msc
   ...
   ! Use 0 to disable this timer
   ncss guard-timeout 30

Change-Id: Icf4d87c45e90324764073e8230e0fb9cb96dd9cb
Depends Change-Id: (OsmoHLR) I0589ff27933e9bca2bcf93b8259004935778db8f
Related Change-Id: (TTCN) I3e1791773d56617172ae27a46889a1ae4d400e2f
Related: OS#3655
---
M include/osmocom/msc/gsm_data.h
M include/osmocom/msc/transaction.h
M src/libmsc/gsm_09_11.c
M src/libmsc/msc_vty.c
M src/libmsc/osmo_msc.c
M tests/test_nodes.vty
6 files changed, 86 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/92/11992/7
--
To view, visit https://gerrit.osmocom.org/11992
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Icf4d87c45e90324764073e8230e0fb9cb96dd9cb
Gerrit-Change-Number: 11992
Gerrit-PatchSet: 7
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Vadim Yanitskiy 


Change in osmo-ttcn3-hacks[master]: MSC_Test: Test what happens when Paging for SMS is unanswered

2018-12-05 Thread Vadim Yanitskiy
Vadim Yanitskiy has posted comments on this change. ( 
https://gerrit.osmocom.org/11897 )

Change subject: MSC_Test: Test what happens when Paging for SMS is unanswered
..


Patch Set 6:

(1 comment)

Please also update 'expected-results.xml'.

https://gerrit.osmocom.org/#/c/11897/6/msc/MSC_Tests.ttcn
File msc/MSC_Tests.ttcn:

https://gerrit.osmocom.org/#/c/11897/6/msc/MSC_Tests.ttcn@2000
PS6, Line 2000: timer T := 20.0;
I think it's too much, ~5.0 seconds would be enough as there
is no delay between Paging attempts in OsmoMSC.



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

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Id645729551672026c6a96bb849ecd04f20cd0c56
Gerrit-Change-Number: 11897
Gerrit-PatchSet: 6
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Comment-Date: Wed, 05 Dec 2018 20:11:23 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4383

2018-12-05 Thread jenkins
See 


--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4384

2018-12-05 Thread jenkins
See 


--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Jenkins build is back to normal : master-libosmo-sccp » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #1889

2018-12-05 Thread jenkins
See 




Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4382

2018-12-05 Thread jenkins
See 


Changes:

[laforge] paging: Add VTY options to calculate T3113 timeout dynamically

--
[...truncated 1.16 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.269-1b963/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.269-1b963/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS 

Change in osmo-hlr[master]: introduce osmo_gsup_client_create2()

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12098 )

Change subject: introduce osmo_gsup_client_create2()
..


Patch Set 4: Code-Review+2


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

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ief09677e07d6e977247185b72c605f109aa091f5
Gerrit-Change-Number: 12098
Gerrit-PatchSet: 4
Gerrit-Owner: Stefan Sperling 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:47:42 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-hlr[master]: SS/USSD: make NCSS session timeout configurable

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12048 )

Change subject: SS/USSD: make NCSS session timeout configurable
..

SS/USSD: make NCSS session timeout configurable

It may happen that either the MS or an ESME would become
unresponsive, e.g. due to a bug, or a dropped message.
This is why we have SS session timeout, that prevents
keeping 'stalled' sessions forever.

Let's introduce a VTY option, which can be used to configure
this timer (by default it's set to 30 seconds):

hlr
  ...
  ! Use 0 to disable this timer
  ncss-guard-timeout 30

Change-Id: I971fc2cee6fd46d4d5d6dac6c634e0b22fff183d
Related: OS#3717
---
M src/hlr.c
M src/hlr.h
M src/hlr_ussd.c
M src/hlr_ussd.h
M src/hlr_vty.c
M tests/test_nodes.vty
6 files changed, 29 insertions(+), 4 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/hlr.c b/src/hlr.c
index 14945b6..4873a66 100644
--- a/src/hlr.c
+++ b/src/hlr.c
@@ -611,6 +611,9 @@
INIT_LLIST_HEAD(_hlr->ss_sessions);
INIT_LLIST_HEAD(_hlr->ussd_routes);

+   /* Init default (call independent) SS session guard timeout value */
+   g_hlr->ncss_guard_timeout = NCSS_GUARD_TIMEOUT_DEFAULT;
+
rc = osmo_init_logging2(hlr_ctx, _log_info);
if (rc < 0) {
fprintf(stderr, "Error initializing logging\n");
diff --git a/src/hlr.h b/src/hlr.h
index 315c3dd..e9cc747 100644
--- a/src/hlr.h
+++ b/src/hlr.h
@@ -45,6 +45,9 @@
struct hlr_euse *euse_default;
struct llist_head iuse_list;

+   /* NCSS (call independent) session guard timeout value */
+   int ncss_guard_timeout;
+
struct llist_head ussd_routes;

struct llist_head ss_sessions;
diff --git a/src/hlr_ussd.c b/src/hlr_ussd.c
index b7aaba4..16a197c 100644
--- a/src/hlr_ussd.c
+++ b/src/hlr_ussd.c
@@ -209,10 +209,11 @@
OSMO_STRLCPY_ARRAY(ss->imsi, imsi);
ss->session_id = session_id;
osmo_timer_setup(>timeout, ss_session_timeout, ss);
-   /* NOTE: The timeout is currently global and not refreshed with 
subsequent messages
-* within the SS/USSD session.  So 30s after the initial SS message, 
the session will
-* timeout! */
-   osmo_timer_schedule(>timeout, 30, 0);
+   /* NOTE: The timeout is currently not refreshed with subsequent messages
+* within the SS/USSD session. So X seconds after the initial SS 
message,
+* the session will timeout! */
+   if (g_hlr->ncss_guard_timeout > 0)
+   osmo_timer_schedule(>timeout, g_hlr->ncss_guard_timeout, 0);

llist_add_tail(>list, >ss_sessions);
return ss;
diff --git a/src/hlr_ussd.h b/src/hlr_ussd.h
index 0414924..393ca6c 100644
--- a/src/hlr_ussd.h
+++ b/src/hlr_ussd.h
@@ -7,6 +7,8 @@

 #include "gsup_server.h"

+#define NCSS_GUARD_TIMEOUT_DEFAULT 30
+
 struct hlr_ussd_route {
/* g_hlr.routes */
struct llist_head list;
diff --git a/src/hlr_vty.c b/src/hlr_vty.c
index 2d9b929..6706aa4 100644
--- a/src/hlr_vty.c
+++ b/src/hlr_vty.c
@@ -35,6 +35,7 @@
 #include "hlr.h"
 #include "hlr_vty.h"
 #include "hlr_vty_subscr.h"
+#include "hlr_ussd.h"
 #include "gsup_server.h"

 struct cmd_node hlr_node = {
@@ -288,9 +289,22 @@
if (g_hlr->euse_default)
vty_out(vty, " ussd default-route external %s%s", 
g_hlr->euse_default->name, VTY_NEWLINE);

+   if (g_hlr->ncss_guard_timeout != NCSS_GUARD_TIMEOUT_DEFAULT)
+   vty_out(vty, " ncss-guard-timeout %i%s",
+   g_hlr->ncss_guard_timeout, VTY_NEWLINE);
+
return 0;
 }

+DEFUN(cfg_ncss_guard_timeout, cfg_ncss_guard_timeout_cmd,
+   "ncss-guard-timeout <0-255>",
+   "Set guard timer for NCSS (call independent SS) session activity\n"
+   "Guard timer value (sec.), or 0 to disable")
+{
+   g_hlr->ncss_guard_timeout = atoi(argv[0]);
+   return CMD_SUCCESS;
+}
+
 /***
  * Common Code
  ***/
@@ -353,6 +367,7 @@
install_element(HLR_NODE, _ussd_no_route_pfx_cmd);
install_element(HLR_NODE, _ussd_defaultroute_cmd);
install_element(HLR_NODE, _ussd_no_defaultroute_cmd);
+   install_element(HLR_NODE, _ncss_guard_timeout_cmd);

hlr_vty_subscriber_init();
 }
diff --git a/tests/test_nodes.vty b/tests/test_nodes.vty
index e1f57a9..63d3da0 100644
--- a/tests/test_nodes.vty
+++ b/tests/test_nodes.vty
@@ -78,6 +78,7 @@
   no ussd route prefix PREFIX
   ussd default-route external EUSE
   no ussd default-route
+  ncss-guard-timeout <0-255>

 OsmoHLR(config-hlr)# gsup
 OsmoHLR(config-hlr-gsup)# list

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

Gerrit-Project: osmo-hlr

Change in osmo-hlr[master]: SS/USSD: fix: properly (re)schedule NCSS session timeout

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12049 )

Change subject: SS/USSD: fix: properly (re)schedule NCSS session timeout
..

SS/USSD: fix: properly (re)schedule NCSS session timeout

It may happen that either the MS or an ESME would become
unresponsive, e.g. due to a bug, or a dropped message. This
is why we have SS session timeout, that prevents keeping
'stalled' sessions forever.

For some reason, it wasn't properly resceduled in case of
subsequent SS/USSD activity, so the lifetime of a session
was limited. Let's properly (re)schedule it.

Change-Id: I11aeacf012b06d3d0b5cc6e64baecf857b645fda
Related: OS#3717
---
M src/hlr_ussd.c
1 file changed, 7 insertions(+), 3 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/hlr_ussd.c b/src/hlr_ussd.c
index 16a197c..cc6aa8a 100644
--- a/src/hlr_ussd.c
+++ b/src/hlr_ussd.c
@@ -208,10 +208,9 @@

OSMO_STRLCPY_ARRAY(ss->imsi, imsi);
ss->session_id = session_id;
+
+   /* Schedule self-destruction timer */
osmo_timer_setup(>timeout, ss_session_timeout, ss);
-   /* NOTE: The timeout is currently not refreshed with subsequent messages
-* within the SS/USSD session. So X seconds after the initial SS 
message,
-* the session will timeout! */
if (g_hlr->ncss_guard_timeout > 0)
osmo_timer_schedule(>timeout, g_hlr->ncss_guard_timeout, 0);

@@ -538,6 +537,11 @@
gsup->imsi, gsup->session_id);
goto out_err;
}
+
+   /* Reschedule self-destruction timer */
+   if (g_hlr->ncss_guard_timeout > 0)
+   osmo_timer_schedule(>timeout, 
g_hlr->ncss_guard_timeout, 0);
+
if (ss_op_is_ussd(req.opcode)) {
/* dispatch unstructured SS to routing */
handle_ussd(conn, ss, gsup, );

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

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I11aeacf012b06d3d0b5cc6e64baecf857b645fda
Gerrit-Change-Number: 12049
Gerrit-PatchSet: 4
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 


Change in osmo-hlr[master]: SS/USSD: release IUSE sessions immediately after response

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12023 )

Change subject: SS/USSD: release IUSE sessions immediately after response
..

SS/USSD: release IUSE sessions immediately after response

At the moment, all available IUSE handlers do assume a single
request-response operation, e.g. MS requests its MSISDN - IUSE
responds. No further nor intermediate communications is required.

Let's immediately terminate such SS sessions in order to avoid
waiting for the session inactivity watchdog (i.e. timeout).

Change-Id: Iaefe37512da79e10fbe92378236bfff0eae0f8b9
---
M src/hlr_ussd.c
1 file changed, 2 insertions(+), 0 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/hlr_ussd.c b/src/hlr_ussd.c
index ba373f3..b7aaba4 100644
--- a/src/hlr_ussd.c
+++ b/src/hlr_ussd.c
@@ -455,6 +455,8 @@
} else {
/* Handle internally */
ss->u.iuse->handle_ussd(conn, ss, gsup, req);
+   /* Release session immediately */
+   ss_session_free(ss);
}
}


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

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Iaefe37512da79e10fbe92378236bfff0eae0f8b9
Gerrit-Change-Number: 12023
Gerrit-PatchSet: 6
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 


Change in osmo-hlr[master]: SS/USSD: fix: properly (re)schedule NCSS session timeout

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12049 )

Change subject: SS/USSD: fix: properly (re)schedule NCSS session timeout
..


Patch Set 3: Code-Review+2


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

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I11aeacf012b06d3d0b5cc6e64baecf857b645fda
Gerrit-Change-Number: 12049
Gerrit-PatchSet: 3
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:45:31 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-hlr[master]: SS/USSD: make NCSS session timeout configurable

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12048 )

Change subject: SS/USSD: make NCSS session timeout configurable
..


Patch Set 3: Code-Review+2


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

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I971fc2cee6fd46d4d5d6dac6c634e0b22fff183d
Gerrit-Change-Number: 12048
Gerrit-PatchSet: 3
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:45:12 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-trx[master]: lms: Allow setting Tx/RxFreq for lchan!=0

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12097 )

Change subject: lms: Allow setting Tx/RxFreq for lchan!=0
..


Patch Set 2: Code-Review+2


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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I9dd0bb41d1863111d28947fc0d7c7e7ecfaf5fa8
Gerrit-Change-Number: 12097
Gerrit-PatchSet: 2
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-CC: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:43:35 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-trx[master]: lms: Allow setting Tx/RxGain for chan!=0

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12096 )

Change subject: lms: Allow setting Tx/RxGain for chan!=0
..

lms: Allow setting Tx/RxGain for chan!=0

Related: OS#3346
Change-Id: I5fae92a7ed5e2d92be12b9dfd33fc56195030c0b
---
M Transceiver52M/device/lms/LMSDevice.cpp
1 file changed, 0 insertions(+), 10 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/Transceiver52M/device/lms/LMSDevice.cpp 
b/Transceiver52M/device/lms/LMSDevice.cpp
index 712652a..21bcece 100644
--- a/Transceiver52M/device/lms/LMSDevice.cpp
+++ b/Transceiver52M/device/lms/LMSDevice.cpp
@@ -322,11 +322,6 @@

 double LMSDevice::setTxGain(double dB, size_t chan)
 {
-   if (chan) {
-   LOGC(DDEV, ALERT) << "Invalid channel " << chan;
-   return 0.0;
-   }
-
if (dB > maxTxGain())
dB = maxTxGain();
if (dB < minTxGain())
@@ -342,11 +337,6 @@

 double LMSDevice::setRxGain(double dB, size_t chan)
 {
-   if (chan) {
-   LOGC(DDEV, ALERT) << "Invalid channel " << chan;
-   return 0.0;
-   }
-
if (dB > maxRxGain())
dB = maxRxGain();
if (dB < minRxGain())

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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I5fae92a7ed5e2d92be12b9dfd33fc56195030c0b
Gerrit-Change-Number: 12096
Gerrit-PatchSet: 3
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-trx[master]: lms: Improve Set{Rx, Tx}{Gain, Freq} logging

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12099 )

Change subject: lms: Improve Set{Rx,Tx}{Gain,Freq} logging
..

lms: Improve Set{Rx,Tx}{Gain,Freq} logging

Change-Id: I6713a27c5f74beb7fcfdd712fcf695afccbc3d76
---
M Transceiver52M/device/lms/LMSDevice.cpp
1 file changed, 10 insertions(+), 6 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/Transceiver52M/device/lms/LMSDevice.cpp 
b/Transceiver52M/device/lms/LMSDevice.cpp
index 8f3d8e1..9804bbd 100644
--- a/Transceiver52M/device/lms/LMSDevice.cpp
+++ b/Transceiver52M/device/lms/LMSDevice.cpp
@@ -327,10 +327,10 @@
if (dB < minTxGain())
dB = minTxGain();

-   LOGC(DDEV, NOTICE) << "Setting TX gain to " << dB << " dB.";
+   LOGC(DDEV, NOTICE) << "chan " << chan <<": Setting TX gain to " << dB 
<< " dB";

if (LMS_SetGaindB(m_lms_dev, LMS_CH_TX, chan, dB) < 0)
-   LOGC(DDEV, ERR) << "Error setting TX gain";
+   LOGC(DDEV, ERR) << "chan " << chan <<": Error setting TX gain 
to " << dB << " dB";

return dB;
 }
@@ -342,10 +342,10 @@
if (dB < minRxGain())
dB = minRxGain();

-   LOGC(DDEV, NOTICE) << "Setting RX gain to " << dB << " dB.";
+   LOGC(DDEV, NOTICE) << "chan "<< chan << ": Setting RX gain to " << dB 
<< " dB";

if (LMS_SetGaindB(m_lms_dev, LMS_CH_RX, chan, dB) < 0)
-   LOGC(DDEV, ERR) << "Error setting RX gain";
+   LOGC(DDEV, ERR) << "chan "<< chan << ": Error setting RX gain 
to " << dB << " dB";

return dB;
 }
@@ -601,8 +601,10 @@

 bool LMSDevice::setTxFreq(double wFreq, size_t chan)
 {
+   LOGC(DDEV, NOTICE) << "chan "<< chan << ": Setting Tx Freq to " << 
wFreq << " Hz";
+
if (LMS_SetLOFrequency(m_lms_dev, LMS_CH_TX, chan, wFreq) < 0) {
-   LOGC(DDEV, ALERT) << "set Tx: " << wFreq << " failed!";
+   LOGC(DDEV, ERROR) << "chan "<< chan << ": Error setting Tx Freq 
to " << wFreq << " Hz";
return false;
}

@@ -611,8 +613,10 @@

 bool LMSDevice::setRxFreq(double wFreq, size_t chan)
 {
+   LOGC(DDEV, NOTICE) << "chan "<< chan << ": Setting Rx Freq to " << 
wFreq << " Hz";
+
if (LMS_SetLOFrequency(m_lms_dev, LMS_CH_RX, chan, wFreq) < 0) {
-   LOGC(DDEV, ALERT) << "set Rx: " << wFreq << " failed!";
+   LOGC(DDEV, ERROR) << "chan "<< chan << ": Error setting Rx Freq 
to " << wFreq << " Hz";
return false;
}


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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I6713a27c5f74beb7fcfdd712fcf695afccbc3d76
Gerrit-Change-Number: 12099
Gerrit-PatchSet: 3
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-trx[master]: lms: Allow setting Tx/RxFreq for lchan!=0

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12097 )

Change subject: lms: Allow setting Tx/RxFreq for lchan!=0
..

lms: Allow setting Tx/RxFreq for lchan!=0

Related: OS#3346
Change-Id: I9dd0bb41d1863111d28947fc0d7c7e7ecfaf5fa8
---
M Transceiver52M/device/lms/LMSDevice.cpp
1 file changed, 0 insertions(+), 11 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/Transceiver52M/device/lms/LMSDevice.cpp 
b/Transceiver52M/device/lms/LMSDevice.cpp
index 21bcece..8f3d8e1 100644
--- a/Transceiver52M/device/lms/LMSDevice.cpp
+++ b/Transceiver52M/device/lms/LMSDevice.cpp
@@ -601,12 +601,6 @@

 bool LMSDevice::setTxFreq(double wFreq, size_t chan)
 {
-
-   if (chan) {
-   LOGC(DDEV, ALERT) << "Invalid channel " << chan;
-   return false;
-   }
-
if (LMS_SetLOFrequency(m_lms_dev, LMS_CH_TX, chan, wFreq) < 0) {
LOGC(DDEV, ALERT) << "set Tx: " << wFreq << " failed!";
return false;
@@ -617,11 +611,6 @@

 bool LMSDevice::setRxFreq(double wFreq, size_t chan)
 {
-   if (chan) {
-   LOGC(DDEV, ALERT) << "Invalid channel " << chan;
-   return false;
-   }
-
if (LMS_SetLOFrequency(m_lms_dev, LMS_CH_RX, chan, wFreq) < 0) {
LOGC(DDEV, ALERT) << "set Rx: " << wFreq << " failed!";
return false;

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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I9dd0bb41d1863111d28947fc0d7c7e7ecfaf5fa8
Gerrit-Change-Number: 12097
Gerrit-PatchSet: 3
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-CC: Stefan Sperling 


Change in osmo-trx[master]: transceiver: log chan on CTRL command received

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12100 )

Change subject: transceiver: log chan on CTRL command received
..

transceiver: log chan on CTRL command received

Change-Id: Ia3b2a35e03a8aaddd6efebc8db2ccca872f51f20
---
M Transceiver52M/Transceiver.cpp
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/Transceiver52M/Transceiver.cpp b/Transceiver52M/Transceiver.cpp
index d6ddce8..8702fb6 100644
--- a/Transceiver52M/Transceiver.cpp
+++ b/Transceiver52M/Transceiver.cpp
@@ -721,7 +721,7 @@

   /* Set command pointer */
   command = buffer + 4;
-  LOG(INFO) << "command is " << command;
+  LOG(INFO) << "chan " << chan << ": command is " << command;

   if (match_cmd(command, "POWEROFF", NULL)) {
 stop();

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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ia3b2a35e03a8aaddd6efebc8db2ccca872f51f20
Gerrit-Change-Number: 12100
Gerrit-PatchSet: 3
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-trx[master]: lms: Allow setting Tx/RxGain for chan!=0

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12096 )

Change subject: lms: Allow setting Tx/RxGain for chan!=0
..


Patch Set 2: Code-Review+2


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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I5fae92a7ed5e2d92be12b9dfd33fc56195030c0b
Gerrit-Change-Number: 12096
Gerrit-PatchSet: 2
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:43:31 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-trx[master]: Add CTRL log category

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12120 )

Change subject: Add CTRL log category
..


Patch Set 2: Code-Review-1

> > Actually I would argue to log to DLCTRL in this case.  Either you
 > > want to see logging of all CTRL related messages at a certain
 > lvel,
 > > or not...
 >
 > I don't really understand this comment. libosmocore IPA CTRL
 > interface has nothing to do with CTRL socket of the TRX, so for
 > sure I don't want them to be the same category.

Don't call it CTRL if it's not CTRL.  Please call it TRXCTRL or something else 
unambiguous.


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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I98ec5e416272783ad3fbadf70478a4e48ae64983
Gerrit-Change-Number: 12120
Gerrit-PatchSet: 2
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-CC: Max 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:43:11 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-gsm-tester[master]: test: cs_paging_gprs_active: Make sure gprs data (TBF) is ongoing

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12143 )

Change subject: test: cs_paging_gprs_active: Make sure gprs data (TBF) is 
ongoing
..


Patch Set 1: Code-Review+1


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

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Id29391d75101d94e2cd58f444b383f4c5217ab6a
Gerrit-Change-Number: 12143
Gerrit-PatchSet: 1
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:42:07 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-trx[master]: SigProcLib: Improve Vector buffer allocation mess

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12085 )

Change subject: SigProcLib: Improve Vector buffer allocation mess
..


Patch Set 2: Code-Review+2


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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie484a4762a7f77fe1b105188ea03a6f025730b82
Gerrit-Change-Number: 12085
Gerrit-PatchSet: 2
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-CC: Vadim Yanitskiy 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:41:31 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-trx[master]: SigProcLib: Improve Vector buffer allocation mess

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12085 )

Change subject: SigProcLib: Improve Vector buffer allocation mess
..

SigProcLib: Improve Vector buffer allocation mess

Original issue: In order to use SSE instructions, 16-byte aligned memory
chunks are needed, and C++ version < C++11 doesn't provide for a native
new/delete store. For that reason, memalign() must be used in the
implementation of convolve_h_alloc() for some buffers.
On the other side, The C++ code relies on C++ "new T[]" operator to
allocate a chunk of memory containing an array of class instances. As
classes are complex types, they cannot be allocated through C structures
(calling malloc). Experimentally can be seen too that it's unreliable
and the process will crash during startup if malloc() is used and then a
Complex<> deferred from it.

Previous implementation allowed for use of convolve_h_alloc or new[]
based on how the (signal)Vector is called, because then the buffer is
not going to be managed internally. But that's unreliable since resize()
calling resize() on it could use "delete" operator on a malloc'ed
buffer, and end up having a new new[] allocated buffer. It was also
found that some of the callers were actually leaking memory through ASan 
(because the
buffer is not managed by the Vector instance).

IMHO best option would be to rewrite all this code using C structures
and malloc/free exclusively, since it would make all this cod eeasier to
maintain.

But for now, let's extend the Vector class to allow specifying an
external alloc/free function and let the Vector instance take care of
the ownership of the buffer in all scenarios.

Change-Id: Ie484a4762a7f77fe1b105188ea03a6f025730b82
---
M CommonLibs/Vector.h
M Transceiver52M/arch/common/convolve.h
M Transceiver52M/arch/common/convolve_base.c
M Transceiver52M/sigProcLib.cpp
M Transceiver52M/signalVector.cpp
M Transceiver52M/signalVector.h
6 files changed, 52 insertions(+), 47 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/CommonLibs/Vector.h b/CommonLibs/Vector.h
index 9119683..4c96b78 100644
--- a/CommonLibs/Vector.h
+++ b/CommonLibs/Vector.h
@@ -32,11 +32,14 @@
 #include 
 #include 
 #include 
+#include 
+
 // We cant use Logger.h in this file...
 extern int gVectorDebug;
 #define BVDEBUG(msg) if (gVectorDebug) {std::cout << msg;}

-
+typedef void (*vector_free_func)(void* wData);
+typedef void *(*vector_alloc_func)(size_t newSize);

 /**
A simplified Vector template with aliases.
@@ -60,6 +63,8 @@
T* mData;   ///< allocated data block, if any
T* mStart;  ///< start of useful data
T* mEnd;///< end of useful data + 1
+   vector_alloc_func mAllocFunc; ///< function used to alloc new mData 
during resize.
+   vector_free_func mFreeFunc; ///< function used to free mData.

public:

@@ -85,9 +90,19 @@
/** Change the size of the Vector, discarding content. */
void resize(size_t newSize)
{
-   if (mData!=NULL) delete[] mData;
+   if (mData!=NULL) {
+   if (mFreeFunc)
+   mFreeFunc(mData);
+   else
+   delete[] mData;
+   }
if (newSize==0) mData=NULL;
-   else mData = new T[newSize];
+   else {
+   if (mAllocFunc)
+   mData = (T*) mAllocFunc(newSize);
+   else
+   mData = new T[newSize];
+   }
mStart = mData;
mEnd = mStart + newSize;
}
@@ -116,29 +131,31 @@
//@{

/** Build an empty Vector of a given size. */
-   Vector(size_t wSize=0):mData(NULL) { resize(wSize); }
+   Vector(size_t wSize=0, vector_alloc_func wAllocFunc=NULL, 
vector_free_func wFreeFunc=NULL)
+   :mData(NULL), mAllocFunc(wAllocFunc), mFreeFunc(wFreeFunc)
+   { resize(wSize); }

/** Build a Vector by moving another. */
Vector(Vector&& other)
-   :mData(other.mData),mStart(other.mStart),mEnd(other.mEnd)
+   :mData(other.mData),mStart(other.mStart),mEnd(other.mEnd), 
mAllocFunc(other.mAllocFunc),  mFreeFunc(other.mFreeFunc)
{ other.mData=NULL; }

/** Build a Vector by copying another. */
-   Vector(const Vector& other):mData(NULL) { clone(other); }
+   Vector(const Vector& other):mData(NULL), 
mAllocFunc(other.mAllocFunc), mFreeFunc(other.mFreeFunc) { clone(other); }

/** Build a Vector with explicit values. */
-   Vector(T* wData, T* wStart, T* wEnd)
-   :mData(wData),mStart(wStart),mEnd(wEnd)
+   Vector(T* wData, T* wStart, T* wEnd, vector_alloc_func wAllocFunc=NULL, 
vector_free_func 

Change in osmo-bsc[master]: paging: Add VTY options to calculate T3113 timeout dynamically

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/11654 )

Change subject: paging: Add VTY options to calculate T3113 timeout dynamically
..

paging: Add VTY options to calculate T3113 timeout dynamically

The idea is to have a base static value which is set like before "timer
t3113 [seconds]", but now have a part of this timeout calculated
dynamically based on BTS channel configuration and channel load.

This patch only implements initial support to calculate based on channel
configuration, but doesn't include code to calculate based on channel
load. To implement the later part, we probably need to keep track of BTS
paging queues per paging group, which we don't do nowadays.

Dynamic calculation is enabled by default, and default static base value
is decreased accordingly. This way, in a typical setup were the default
10 seconds were used, now the calculated final value is 11 seconds.
That's intended because it was observed experimentally in osmo-gsm-tester with
a similar channel setup that sometimes paging response can arrive slightly
later than 10 seconds.

Related: OS#3680
Change-Id: I4fb2969b690151415038631fb6ad059aa6835c7f
---
M include/osmocom/bsc/gsm_data.h
M include/osmocom/bsc/gsm_timers.h
M src/osmo-bsc/bsc_vty.c
M src/osmo-bsc/gsm_data.c
M src/osmo-bsc/gsm_timers_vty.c
M src/osmo-bsc/net_init.c
M src/osmo-bsc/paging.c
7 files changed, 86 insertions(+), 4 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Neels Hofmeyr: Looks good to me, but someone else must approve
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/include/osmocom/bsc/gsm_data.h b/include/osmocom/bsc/gsm_data.h
index 0b472a4..e57da55 100644
--- a/include/osmocom/bsc/gsm_data.h
+++ b/include/osmocom/bsc/gsm_data.h
@@ -1147,6 +1147,7 @@

/* BTS-specific overrides for timer values from struct gsm_network. */
uint8_t T3122;  /* ASSIGMENT REJECT wait indication */
+   bool T3113_dynamic; /* Calculate T3113 timeout dynamically based on BTS 
channel config and load */

/* Periodic channel load measurements are used to maintain T3122. */
struct load_counter chan_load_samples[7];
diff --git a/include/osmocom/bsc/gsm_timers.h b/include/osmocom/bsc/gsm_timers.h
index 78f04ed..699c461 100644
--- a/include/osmocom/bsc/gsm_timers.h
+++ b/include/osmocom/bsc/gsm_timers.h
@@ -37,7 +37,7 @@

 void T_defs_vty_init(struct T_def *T_defs, int cfg_parent_node);
 void T_defs_vty_write(struct vty *vty, const char *indent);
-
+struct T_def *parse_T_arg(struct vty *vty, const char *T_str);

 struct state_timeout {
int T;
diff --git a/src/osmo-bsc/bsc_vty.c b/src/osmo-bsc/bsc_vty.c
index 983dcb9..8c7d8e1 100644
--- a/src/osmo-bsc/bsc_vty.c
+++ b/src/osmo-bsc/bsc_vty.c
@@ -3951,6 +3951,56 @@
return check_amr_config(vty);
 }

+#define TNUM_STR "T-number, optionally preceded by 't' or 'T'\n"
+DEFUN(cfg_bts_t3113_dynamic, cfg_bts_t3113_dynamic_cmd,
+   "timer-dynamic T",
+   "Calculate T3113 dynamically based on channel config and load\n"
+   TNUM_STR)
+{
+   struct T_def *d;
+   struct gsm_bts *bts = vty->index;
+
+   d = parse_T_arg(vty, argv[0]);
+   if (!d)
+   return CMD_WARNING;
+
+   switch (d->T) {
+   case 3113:
+   bts->T3113_dynamic = true;
+   break;
+   default:
+   vty_out(vty, "T%d cannot be set to dynamic%s", d->T, 
VTY_NEWLINE);
+   return CMD_WARNING;
+   }
+
+   return CMD_SUCCESS;
+}
+
+DEFUN(cfg_bts_no_t3113_dynamic, cfg_bts_no_t3113_dynamic_cmd,
+   "no timer-dynamic T",
+   NO_STR
+   "Set given timer to non-dynamic and use the default or user provided 
fixed value\n"
+   TNUM_STR)
+{
+   struct T_def *d;
+   struct gsm_bts *bts = vty->index;
+
+   d = parse_T_arg(vty, argv[0]);
+   if (!d)
+   return CMD_WARNING;
+
+   switch (d->T) {
+   case 3113:
+   bts->T3113_dynamic = false;
+   break;
+   default:
+   vty_out(vty, "T%d already is non-dynamic%s", d->T, VTY_NEWLINE);
+   return CMD_WARNING;
+   }
+
+   return CMD_SUCCESS;
+}
+
 #define TRX_TEXT "Radio Transceiver\n"

 /* per TRX configuration */
@@ -5129,6 +5179,8 @@
install_element(BTS_NODE, _bts_no_acc_ramping_cmd);
install_element(BTS_NODE, _bts_acc_ramping_step_interval_cmd);
install_element(BTS_NODE, _bts_acc_ramping_step_size_cmd);
+   install_element(BTS_NODE, _bts_t3113_dynamic_cmd);
+   install_element(BTS_NODE, _bts_no_t3113_dynamic_cmd);
neighbor_ident_vty_init(network, network->neighbor_bss_cells);
/* See also handover commands added on bts level from handover_vty.c */

diff --git a/src/osmo-bsc/gsm_data.c b/src/osmo-bsc/gsm_data.c
index 6d39642..0f76a27 100644

Change in osmo-bsc[master]: paging: Add VTY options to calculate T3113 timeout dynamically

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/11654 )

Change subject: paging: Add VTY options to calculate T3113 timeout dynamically
..


Patch Set 6: Code-Review+2


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

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4fb2969b690151415038631fb6ad059aa6835c7f
Gerrit-Change-Number: 11654
Gerrit-PatchSet: 6
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Assignee: Harald Welte 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:39:32 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmocore[master]: gsm_29_118: add missing extern for struct value_string decl.

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12144 )

Change subject: gsm_29_118: add missing extern for struct value_string decl.
..


Patch Set 1: Code-Review+2


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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ib6c4cbea649f790fa4db1ed2fe2b7e76a60291b4
Gerrit-Change-Number: 12144
Gerrit-PatchSet: 1
Gerrit-Owner: dexter 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:35:44 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: python tests: use py shebang instead of $(PYTHON)

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12138 )

Change subject: python tests: use py shebang instead of $(PYTHON)
..

python tests: use py shebang instead of $(PYTHON)

I'm going to make the external tests manually launchable. For that I first had
an error message if $(PYTHON) was empty. But Pau says I should just use shebang
instead and ignore the autoconf python stuff, since that often fails anyway.

Change-Id: Ie35dd78c42577109a6a3143221a9769e47d361a5
---
M tests/Makefile.am
M tests/ctrl_test_runner.py
M tests/smpp_test_runner.py
M tests/vty_test_runner.py
4 files changed, 6 insertions(+), 6 deletions(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, approved
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/tests/Makefile.am b/tests/Makefile.am
index c225afa..f6b33fc 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -46,10 +46,10 @@
 python-tests: $(BUILT_SOURCES)
osmotestvty.py -p $(abs_top_srcdir) -w $(abs_top_builddir) -v
osmotestconfig.py -p $(abs_top_srcdir) -w $(abs_top_builddir) -v
-   $(PYTHON) $(srcdir)/vty_test_runner.py -w $(abs_top_builddir) -v
-   $(PYTHON) $(srcdir)/ctrl_test_runner.py -w $(abs_top_builddir) -v
+   $(srcdir)/vty_test_runner.py -w $(abs_top_builddir) -v
+   $(srcdir)/ctrl_test_runner.py -w $(abs_top_builddir) -v
 if BUILD_SMPP
-   $(PYTHON) $(srcdir)/smpp_test_runner.py -w $(abs_top_builddir) -v
+   $(srcdir)/smpp_test_runner.py -w $(abs_top_builddir) -v
 endif
rm -f $(top_builddir)/sms.db
 else
diff --git a/tests/ctrl_test_runner.py b/tests/ctrl_test_runner.py
old mode 100644
new mode 100755
index 05d3e30..f652a67
--- a/tests/ctrl_test_runner.py
+++ b/tests/ctrl_test_runner.py
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python2

 # (C) 2013 by Jacob Erlbeck 
 # (C) 2014 by Holger Hans Peter Freyther
diff --git a/tests/smpp_test_runner.py b/tests/smpp_test_runner.py
old mode 100644
new mode 100755
index 7a3a342..f6567d9
--- a/tests/smpp_test_runner.py
+++ b/tests/smpp_test_runner.py
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python2

 # (C) 2014 by Holger Hans Peter Freyther
 # based on vty_test_runner.py:
diff --git a/tests/vty_test_runner.py b/tests/vty_test_runner.py
old mode 100644
new mode 100755
index 6d8ca6f..471ecf6
--- a/tests/vty_test_runner.py
+++ b/tests/vty_test_runner.py
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python2

 # (C) 2013 by Katerina Barone-Adesi 
 # (C) 2013 by Holger Hans Peter Freyther

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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ie35dd78c42577109a6a3143221a9769e47d361a5
Gerrit-Change-Number: 12138
Gerrit-PatchSet: 3
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-msc[master]: msc_main: mncc: move mncc socket decision to after read_cfg

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12129 )

Change subject: msc_main: mncc: move mncc socket decision to after read_cfg
..

msc_main: mncc: move mncc socket decision to after read_cfg

First step towards allowing to configure the MNCC socket path by config file.

Rationale: see I2ec59d5eba407f83295528b51b93678d446b9cee

Change-Id: Ifc87c1cacaa809d04fc23e8ccd761bee4509c805
---
M src/osmo-msc/msc_main.c
1 file changed, 4 insertions(+), 5 deletions(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, approved
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/src/osmo-msc/msc_main.c b/src/osmo-msc/msc_main.c
index 07e4c8b..157d5ae 100644
--- a/src/osmo-msc/msc_main.c
+++ b/src/osmo-msc/msc_main.c
@@ -545,11 +545,9 @@
/* Parse options */
handle_options(argc, argv);

-   /* Allocate global gsm_network struct; choose socket/internal MNCC */
-   msc_network = msc_network_alloc(tall_msc_ctx,
-   msc_cmdline_config.mncc_sock_path?
-   mncc_sock_from_cc
-   : int_mncc_recv);
+   /* Allocate global gsm_network struct.
+* At first set the internal MNCC as default, may be changed below 
according to cfg or cmdline option. */
+   msc_network = msc_network_alloc(tall_msc_ctx, int_mncc_recv);
if (!msc_network)
return -ENOMEM;

@@ -577,6 +575,7 @@

/* Initialize MNCC socket if appropriate */
if (msc_cmdline_config.mncc_sock_path) {
+   msc_network->mncc_recv = mncc_sock_from_cc;
rc = mncc_sock_init(msc_network,
msc_cmdline_config.mncc_sock_path);
if (rc) {

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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ifc87c1cacaa809d04fc23e8ccd761bee4509c805
Gerrit-Change-Number: 12129
Gerrit-PatchSet: 7
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-msc[master]: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12130 )

Change subject: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'
..

vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'

I want to add 'mncc internal' and 'mncc external' commands, and IMHO makes most
sense to have a common 'mncc' keyword to start MNCC config commands with. To
put it in terms of VTY online help:

  OsmoMSC(config-msc)# mncc ?
internal   Use internal MNCC handler
external   Use internal MNCC handler
guard-timeout  Set global guard timeout

So far only the 'guard-timeout' exists, I want to add 'internal' and 'external'
in a subsequent commit.

Keep the old command 'mncc-guard-timeout' as deprecated alias. That means it
still works from old config files, but online documentation will omit it.

On 'write', write back the new format instead.

Rationale: see I2ec59d5eba407f83295528b51b93678d446b9cee

Change-Id: I52d69af48e1ddc87b3fb54bf66a01b1b8cbf5abe
---
M src/libmsc/msc_vty.c
M tests/test_nodes.vty
2 files changed, 16 insertions(+), 6 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Vadim Yanitskiy: Looks good to me, but someone else must approve
  Pau Espin Pedrol: Looks good to me, but someone else must approve
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/src/libmsc/msc_vty.c b/src/libmsc/msc_vty.c
index aaefb0b..d9e57a7 100644
--- a/src/libmsc/msc_vty.c
+++ b/src/libmsc/msc_vty.c
@@ -335,16 +335,25 @@
return CMD_SUCCESS;
 }

+#define MNCC_STR "Configure Mobile Network Call Control\n"
+#define MNCC_GUARD_TIMEOUT_STR "Set global guard timer for mncc interface 
activity\n"
+#define MNCC_GUARD_TIMEOUT_VALUE_STR "guard timer value (sec.)\n"
+
 DEFUN(cfg_msc_mncc_guard_timeout,
   cfg_msc_mncc_guard_timeout_cmd,
-  "mncc-guard-timeout <0-255>",
-  "Set global guard timer for mncc interface activity\n"
-  "guard timer value (sec.)")
+  "mncc guard-timeout <0-255>",
+  MNCC_STR
+  MNCC_GUARD_TIMEOUT_STR MNCC_GUARD_TIMEOUT_VALUE_STR)
 {
gsmnet->mncc_guard_timeout = atoi(argv[0]);
return CMD_SUCCESS;
 }

+ALIAS_DEPRECATED(cfg_msc_mncc_guard_timeout,
+cfg_msc_deprecated_mncc_guard_timeout_cmd,
+"mncc-guard-timeout <0-255>",
+MNCC_GUARD_TIMEOUT_STR MNCC_GUARD_TIMEOUT_VALUE_STR);
+
 DEFUN(cfg_msc_assign_tmsi, cfg_msc_assign_tmsi_cmd,
   "assign-tmsi",
   "Assign TMSI during Location Updating.\n")
@@ -433,7 +442,7 @@
 static int config_write_msc(struct vty *vty)
 {
vty_out(vty, "msc%s", VTY_NEWLINE);
-   vty_out(vty, " mncc-guard-timeout %i%s",
+   vty_out(vty, " mncc guard-timeout %i%s",
gsmnet->mncc_guard_timeout, VTY_NEWLINE);
vty_out(vty, " %sassign-tmsi%s",
gsmnet->vlr->cfg.assign_tmsi? "" : "no ", VTY_NEWLINE);
@@ -1443,6 +1452,7 @@
install_node(_node, config_write_msc);
install_element(MSC_NODE, _msc_assign_tmsi_cmd);
install_element(MSC_NODE, _msc_mncc_guard_timeout_cmd);
+   install_element(MSC_NODE, _msc_deprecated_mncc_guard_timeout_cmd);
install_element(MSC_NODE, _msc_no_assign_tmsi_cmd);
install_element(MSC_NODE, _msc_auth_tuple_max_reuse_count_cmd);
install_element(MSC_NODE, _msc_auth_tuple_reuse_on_error_cmd);
diff --git a/tests/test_nodes.vty b/tests/test_nodes.vty
index e03ed00..9fa9d2a 100644
--- a/tests/test_nodes.vty
+++ b/tests/test_nodes.vty
@@ -30,7 +30,7 @@
 OsmoMSC(config-msc)# list
 ...
   assign-tmsi
-  mncc-guard-timeout <0-255>
+  mncc guard-timeout <0-255>
   no assign-tmsi
   auth-tuple-max-reuse-count <-1-2147483647>
   auth-tuple-reuse-on-error (0|1)
@@ -82,7 +82,7 @@
  mm info 1
  periodic location update 30
 msc
- mncc-guard-timeout 180
+ mncc guard-timeout 180
  assign-tmsi
  cs7-instance-a 0
 ...

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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I52d69af48e1ddc87b3fb54bf66a01b1b8cbf5abe
Gerrit-Change-Number: 12130
Gerrit-PatchSet: 7
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: osmith 


Change in libosmocore[master]: gsm_29_118: add missing extern for struct value_string decl.

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12144 )

Change subject: gsm_29_118: add missing extern for struct value_string decl.
..

gsm_29_118: add missing extern for struct value_string decl.

The value string arrays in the header file (gsm_29_118.h) are not
declared as extern. Lets add it now.

Change-Id: Ib6c4cbea649f790fa4db1ed2fe2b7e76a60291b4
Related: OS#3615
---
M include/osmocom/gsm/protocol/gsm_29_118.h
1 file changed, 8 insertions(+), 8 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/include/osmocom/gsm/protocol/gsm_29_118.h 
b/include/osmocom/gsm/protocol/gsm_29_118.h
index bf210ad..97a9c43 100644
--- a/include/osmocom/gsm/protocol/gsm_29_118.h
+++ b/include/osmocom/gsm/protocol/gsm_29_118.h
@@ -35,7 +35,7 @@
/* unassigned */
SGSAP_MSGT_UE_UNREACHABLE   = 0x1f,
 };
-const struct value_string sgsap_msg_type_names[];
+extern const struct value_string sgsap_msg_type_names[];
 static inline const char *sgsap_msg_type_name(enum sgsap_msg_type msgt) {
return get_value_string(sgsap_msg_type_names, msgt);
 }
@@ -74,7 +74,7 @@
SGSAP_IE_ADDL_PAGING_INDICATORS = 0x26,
SGSAP_IE_TMSI_BASED_NRI_CONT= 0x27,
 };
-const struct value_string sgsap_iei_names[];
+extern const struct value_string sgsap_iei_names[];
 static inline const char *sgsap_iei_name(enum sgsap_iei iei) {
return get_value_string(sgsap_iei_names, iei);
 }
@@ -84,7 +84,7 @@
SGSAP_EPS_LUT_IMSI_ATTACH   = 0x01,
SGSAP_EPS_LUT_NORMAL= 0x02,
 };
-const struct value_string sgsap_eps_lu_type_names[];
+extern const struct value_string sgsap_eps_lu_type_names[];
 static inline const char *sgsap_eps_lu_type_name(enum sgsap_eps_lu_type lut) {
return get_value_string(sgsap_eps_lu_type_names, lut);
 }
@@ -95,7 +95,7 @@
SGSAP_ID_EPS_T_UE_INITIATED = 0x02,
SGSAP_ID_EPS_T_EPS_NOT_ALLOWED  = 0x03,
 };
-const struct value_string sgsap_ismi_det_eps_type_names[];
+extern const struct value_string sgsap_ismi_det_eps_type_names[];
 static inline const char *sgsap_imsi_det_eps_type_name(enum 
sgsap_imsi_det_eps_type idt) {
return get_value_string(sgsap_ismi_det_eps_type_names, idt);
 }
@@ -106,7 +106,7 @@
SGSAP_ID_NONEPS_T_COMBINED_UE_EPS_NONEPS= 0x02,
SGSAP_ID_NONEPS_T_IMPLICIT_UE_EPS_NONEPS= 0x03,
 };
-const struct value_string sgsap_ismi_det_noneps_type_names[];
+extern const struct value_string sgsap_ismi_det_noneps_type_names[];
 static inline const char *sgsap_imsi_det_noneps_type_name(enum 
sgsap_imsi_det_noneps_type idt) {
return get_value_string(sgsap_ismi_det_noneps_type_names, idt);
 }
@@ -116,7 +116,7 @@
SGSAP_SERV_IND_CS_CALL  = 0x01,
SGSAP_SERV_IND_SMS  = 0x02,
 };
-const struct value_string sgsap_service_ind_names[];
+extern const struct value_string sgsap_service_ind_names[];
 static inline const char *sgsap_service_ind_name(enum sgsap_service_ind si) {
return get_value_string(sgsap_service_ind_names, si);
 }
@@ -138,7 +138,7 @@
SGSAP_SGS_CAUSE_MT_CSFB_REJ_USER= 0x0d,
SGSAP_SGS_CAUSE_UE_TEMP_UNREACHABLE = 0x0e,
 };
-const struct value_string sgsap_sgs_cause_names[];
+extern const struct value_string sgsap_sgs_cause_names[];
 static inline const char *sgsap_sgs_cause_name(enum sgsap_sgs_cause cause) {
return get_value_string(sgsap_sgs_cause_names, cause);
 }
@@ -148,7 +148,7 @@
SGSAP_UE_EMM_MODE_IDLE  = 0x00,
SGSAP_UE_EMM_MODE_CONNECTED = 0x01,
 };
-const struct value_string sgsap_ue_emm_mode_names[];
+extern const struct value_string sgsap_ue_emm_mode_names[];
 static inline const char *sgsap_ue_emm_mode_name(enum sgsap_ue_emm_mode mode) {
return get_value_string(sgsap_ue_emm_mode_names, mode);
 }

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib6c4cbea649f790fa4db1ed2fe2b7e76a60291b4
Gerrit-Change-Number: 12144
Gerrit-PatchSet: 2
Gerrit-Owner: dexter 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-msc[master]: cosmetic: msc_main.c: default args definition style

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12128 )

Change subject: cosmetic: msc_main.c: default args definition style
..

cosmetic: msc_main.c: default args definition style

Explicitly name each arg with its default value, omit zero values, end last
item in comma.

Change-Id: I0e0f1e2c8722768b6c61fd6544911b20fe1af212
---
M src/osmo-msc/msc_main.c
1 file changed, 3 insertions(+), 5 deletions(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, approved
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/src/osmo-msc/msc_main.c b/src/osmo-msc/msc_main.c
index afab417..07e4c8b 100644
--- a/src/osmo-msc/msc_main.c
+++ b/src/osmo-msc/msc_main.c
@@ -96,11 +96,9 @@
const char *mncc_sock_path;
int use_db_counter;
 } msc_cmdline_config = {
-   "sms.db",
-   "osmo-msc.cfg",
-   0,
-   0,
-   1
+   .database_name = "sms.db",
+   .config_file = "osmo-msc.cfg",
+   .use_db_counter = 1,
 };

 /* timer to store statistics */

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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I0e0f1e2c8722768b6c61fd6544911b20fe1af212
Gerrit-Change-Number: 12128
Gerrit-PatchSet: 6
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-msc[master]: add VTY commands: mncc internal / external (== -M)

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12131 )

Change subject: add VTY commands: mncc internal / external (== -M)
..

add VTY commands: mncc internal / external (== -M)

So far the only way to use external MNCC is to pass the -M cmdline arg:

  osmo-msc -M /path/to/socket

However, the osmo-msc.service file for systemd is installed by 'make install',
and hence it is quite impractical to depend on such a config item to be
required in the service file:

- It defies any scheme an operator may have in place to compose the
  osmo-msc.cfg file -- this option doesn't go in the .cfg file but needs
  separate action to add to the installed service file.

- After a make install or package upgrades / re-installations, this option will
  be plain overwritten silently, or lead to the need for resolving file
  conflicts.

The initial spark for this came from configuring the 35c3 GSM from cfg
templates.

Change-Id: I2ec59d5eba407f83295528b51b93678d446b9cee
---
M include/osmocom/msc/gsm_data.h
M include/osmocom/msc/msc_common.h
M src/libmsc/msc_vty.c
M src/libmsc/osmo_msc.c
M src/osmo-msc/msc_main.c
M tests/test_nodes.vty
6 files changed, 68 insertions(+), 2 deletions(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/include/osmocom/msc/gsm_data.h b/include/osmocom/msc/gsm_data.h
index d3cb7d8..63af3e7 100644
--- a/include/osmocom/msc/gsm_data.h
+++ b/include/osmocom/msc/gsm_data.h
@@ -140,6 +140,7 @@
struct osmo_counter *active_nc_ss;

/* layer 4 */
+   char *mncc_sock_path;
struct mncc_sock_state *mncc_state;
mncc_recv_cb_t mncc_recv;
struct llist_head upqueue;
diff --git a/include/osmocom/msc/msc_common.h b/include/osmocom/msc/msc_common.h
index ffe8902..3ca3469 100644
--- a/include/osmocom/msc/msc_common.h
+++ b/include/osmocom/msc/msc_common.h
@@ -15,6 +15,7 @@
 typedef int (*mncc_recv_cb_t)(struct gsm_network *, struct msgb *);

 struct gsm_network *gsm_network_init(void *ctx, mncc_recv_cb_t mncc_recv);
+void gsm_network_set_mncc_sock_path(struct gsm_network *net, const char 
*mncc_sock_path);

 int msc_vlr_alloc(struct gsm_network *net);
 int msc_vlr_start(struct gsm_network *net);
diff --git a/src/libmsc/msc_vty.c b/src/libmsc/msc_vty.c
index d9e57a7..e1d1b40 100644
--- a/src/libmsc/msc_vty.c
+++ b/src/libmsc/msc_vty.c
@@ -339,6 +339,25 @@
 #define MNCC_GUARD_TIMEOUT_STR "Set global guard timer for mncc interface 
activity\n"
 #define MNCC_GUARD_TIMEOUT_VALUE_STR "guard timer value (sec.)\n"

+DEFUN(cfg_msc_mncc_internal,
+  cfg_msc_mncc_internal_cmd,
+  "mncc internal",
+  MNCC_STR "Use internal MNCC handler (default; changes need a program 
restart)\n")
+{
+   gsm_network_set_mncc_sock_path(gsmnet, NULL);
+   return CMD_SUCCESS;
+}
+
+DEFUN(cfg_msc_mncc_external,
+  cfg_msc_mncc_external_cmd,
+  "mncc external MNCC_SOCKET_PATH",
+  MNCC_STR "Use external MNCC handler (changes need a program restart)\n"
+  "File system path to create the MNCC unix domain socket at\n")
+{
+   gsm_network_set_mncc_sock_path(gsmnet, argv[0]);
+   return CMD_SUCCESS;
+}
+
 DEFUN(cfg_msc_mncc_guard_timeout,
   cfg_msc_mncc_guard_timeout_cmd,
   "mncc guard-timeout <0-255>",
@@ -442,6 +461,8 @@
 static int config_write_msc(struct vty *vty)
 {
vty_out(vty, "msc%s", VTY_NEWLINE);
+   if (gsmnet->mncc_sock_path)
+   vty_out(vty, " mncc external %s%s", gsmnet->mncc_sock_path, 
VTY_NEWLINE);
vty_out(vty, " mncc guard-timeout %i%s",
gsmnet->mncc_guard_timeout, VTY_NEWLINE);
vty_out(vty, " %sassign-tmsi%s",
@@ -1451,6 +1472,8 @@
install_element(CONFIG_NODE, _msc_cmd);
install_node(_node, config_write_msc);
install_element(MSC_NODE, _msc_assign_tmsi_cmd);
+   install_element(MSC_NODE, _msc_mncc_internal_cmd);
+   install_element(MSC_NODE, _msc_mncc_external_cmd);
install_element(MSC_NODE, _msc_mncc_guard_timeout_cmd);
install_element(MSC_NODE, _msc_deprecated_mncc_guard_timeout_cmd);
install_element(MSC_NODE, _msc_no_assign_tmsi_cmd);
diff --git a/src/libmsc/osmo_msc.c b/src/libmsc/osmo_msc.c
index 52277b7..37c1d15 100644
--- a/src/libmsc/osmo_msc.c
+++ b/src/libmsc/osmo_msc.c
@@ -76,6 +76,13 @@
return net;
 }

+void gsm_network_set_mncc_sock_path(struct gsm_network *net, const char 
*mncc_sock_path)
+{
+   if (net->mncc_sock_path)
+   talloc_free(net->mncc_sock_path);
+   net->mncc_sock_path = mncc_sock_path ? talloc_strdup(net, 
mncc_sock_path) : NULL;
+}
+
 /* Receive a SAPI-N-REJECT from BSC */
 void ran_conn_sapi_n_reject(struct ran_conn *conn, int dlci)
 {
diff --git a/src/osmo-msc/msc_main.c b/src/osmo-msc/msc_main.c
index 157d5ae..8500b97 100644
--- a/src/osmo-msc/msc_main.c
+++ b/src/osmo-msc/msc_main.c
@@ -573,11 +573,20 @@
   

Change in osmo-msc[master]: add test_nodes.vty transcript test

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12127 )

Change subject: add test_nodes.vty transcript test
..

add test_nodes.vty transcript test

It needs to work whether SMPP,Iu are enable or disabled, hence a bit more
wildcarding than one might expect.

Change-Id: I3a8c50d8d555b6b948d97d6412e17594ee439de0
---
M tests/Makefile.am
A tests/test_nodes.vty
2 files changed, 107 insertions(+), 1 deletion(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, approved
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/tests/Makefile.am b/tests/Makefile.am
index a6a4011..dc5194c 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -34,6 +34,7 @@
vty_test_runner.py \
ctrl_test_runner.py \
smpp_test_runner.py \
+   test_nodes.vty \
$(NULL)

 TESTSUITE = $(srcdir)/testsuite
@@ -66,7 +67,11 @@
 # pass -u to vty_script_runner.py by doing:
 #   make vty-transcript-test U=-u
 vty-transcript-test:
-   echo "No vty-transcript-test exists yet"
+   osmo_verify_transcript_vty.py -v \
+   -n OsmoMSC -p 4254 \
+   -r "$(top_builddir)/src/osmo-msc/osmo-msc -c 
$(top_srcdir)/doc/examples/osmo-msc/osmo-msc.cfg" \
+   $(U) $(srcdir)/*.vty
+   rm -f $(builddir)/sms.db

 # don't run multiple tests concurrently so that the ports don't conflict
 vty-test:
diff --git a/tests/test_nodes.vty b/tests/test_nodes.vty
new file mode 100644
index 000..e03ed00
--- /dev/null
+++ b/tests/test_nodes.vty
@@ -0,0 +1,101 @@
+OsmoMSC> enable
+OsmoMSC# configure terminal
+OsmoMSC(config)# list
+...
+  network
+  msc
+  mncc-int
+  hlr
+...
+
+OsmoMSC(config)# network
+OsmoMSC(config-net)# list
+...
+  network country code <1-999>
+  mobile network code <0-999>
+  short name NAME
+  long name NAME
+  encryption a5 <0-3> [<0-3>] [<0-3>] [<0-3>]
+  authentication (optional|required)
+  rrlp mode (none|ms-based|ms-preferred|ass-preferred)
+  mm info (0|1)
+  timezone <-19-19> (0|15|30|45)
+  timezone <-19-19> (0|15|30|45) <0-2>
+  no timezone
+  periodic location update <6-1530>
+  no periodic location update
+
+OsmoMSC(config-net)# exit
+OsmoMSC(config)# msc
+OsmoMSC(config-msc)# list
+...
+  assign-tmsi
+  mncc-guard-timeout <0-255>
+  no assign-tmsi
+  auth-tuple-max-reuse-count <-1-2147483647>
+  auth-tuple-reuse-on-error (0|1)
+  cs7-instance-a <0-15>
+  cs7-instance-iu <0-15>
+  paging response-timer (default|<1-65535>)
+  emergency-call route-to-msisdn MSISDN
+  mgw local-ip A.B.C.D
+  mgw local-port <0-65535>
+  mgw remote-ip A.B.C.D
+  mgw remote-port <0-65535>
+  mgw endpoint-range <1-65534> <1-65534>
+  mgw bts-base <0-65534>
+...
+
+OsmoMSC(config-msc)# exit
+OsmoMSC(config)# mncc-int
+OsmoMSC(config-mncc-int)# list
+...
+  default-codec tch-f (fr|efr|amr)
+  default-codec tch-h (hr|amr)
+
+OsmoMSC(config-mncc-int)# exit
+OsmoMSC(config)# hlr
+OsmoMSC(config-hlr)# list
+...
+  remote-ip A.B.C.D
+  remote-port <1-65535>
+
+OsmoMSC(config-hlr)# exit
+OsmoMSC(config)# exit
+OsmoMSC# configure terminal
+OsmoMSC(config)# network
+OsmoMSC(config-net)# end
+OsmoMSC# disable
+OsmoMSC> enable
+
+OsmoMSC# ! Punching some '...' holes because of optional SMPP, Iu
+OsmoMSC# show running-config
+...
+network
+ network country code 001
+ mobile network code 01
+ short name OsmoMSC
+ long name OsmoMSC
+ encryption a5 0
+ authentication optional
+ rrlp mode none
+ mm info 1
+ periodic location update 30
+msc
+ mncc-guard-timeout 180
+ assign-tmsi
+ cs7-instance-a 0
+...
+ auth-tuple-max-reuse-count 3
+ auth-tuple-reuse-on-error 1
+ mgw local-port 2728
+ mgw remote-ip 10.23.24.1
+ mgw remote-port 2427
+mncc-int
+ default-codec tch-f fr
+ default-codec tch-h hr
+...
+hlr
+ remote-ip 127.0.0.1
+ remote-port 4222
+end

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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I3a8c50d8d555b6b948d97d6412e17594ee439de0
Gerrit-Change-Number: 12127
Gerrit-PatchSet: 6
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-msc[master]: make: prepare for adding transcript tests

2018-12-05 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12126 )

Change subject: make: prepare for adding transcript tests
..

make: prepare for adding transcript tests

Separate 'make python-test' into separate make targets, to sensibly add VTY
transcript tests in an upcoming commit.

Feature: even though ./configure was called without --enable-external-tests,
each of the {ctrl,vty}x{python,transcript} tests can be invoked individually by
e.g. 'make vty-python-test'.

Both 'vty-transcript-test' and 'ctrl-transcript-test' are still empty, a
subsequent patch adds a vty-transcript-test.

All of this in preparation of tweaking the 'mncc' vty configuration, to be able
to track it in a vty transcript test.

Change-Id: I688657e56ae469c07b9f25ba37275d38dbd457e2
---
M tests/Makefile.am
1 file changed, 41 insertions(+), 6 deletions(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, approved
  Stefan Sperling: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/tests/Makefile.am b/tests/Makefile.am
index f6b33fc..a6a4011 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -43,20 +43,55 @@
$(NULL)

 if ENABLE_EXT_TESTS
+# don't run multiple tests concurrently so that the ports don't conflict
 python-tests: $(BUILT_SOURCES)
-   osmotestvty.py -p $(abs_top_srcdir) -w $(abs_top_builddir) -v
-   osmotestconfig.py -p $(abs_top_srcdir) -w $(abs_top_builddir) -v
-   $(srcdir)/vty_test_runner.py -w $(abs_top_builddir) -v
-   $(srcdir)/ctrl_test_runner.py -w $(abs_top_builddir) -v
+   $(MAKE) vty-test
+   $(MAKE) ctrl-test
 if BUILD_SMPP
-   $(srcdir)/smpp_test_runner.py -w $(abs_top_builddir) -v
+   $(MAKE) smpp-test
 endif
-   rm -f $(top_builddir)/sms.db
+
 else
 python-tests: $(BUILT_SOURCES)
echo "Not running python-based tests (determined at configure-time)"
 endif

+vty-python-test: $(BUILT_SOURCES)
+   osmotestvty.py -p $(abs_top_srcdir) -w $(abs_top_builddir) -v
+   osmotestconfig.py -p $(abs_top_srcdir) -w $(abs_top_builddir) -v
+   $(srcdir)/vty_test_runner.py -w $(abs_top_builddir) -v
+   rm -f $(top_builddir)/sms.db
+
+# To update the VTY script from current application behavior,
+# pass -u to vty_script_runner.py by doing:
+#   make vty-transcript-test U=-u
+vty-transcript-test:
+   echo "No vty-transcript-test exists yet"
+
+# don't run multiple tests concurrently so that the ports don't conflict
+vty-test:
+   $(MAKE) vty-python-test
+   $(MAKE) vty-transcript-test
+
+ctrl-python-test: $(BUILT_SOURCES)
+   $(srcdir)/ctrl_test_runner.py -w $(abs_top_builddir) -v
+   rm -f $(top_builddir)/sms.db
+
+# To update the CTRL script from current application behavior,
+# pass -u to ctrl_script_runner.py by doing:
+#   make ctrl-transcript-test U=-u
+ctrl-transcript-test:
+   echo "No ctrl-transcript-test exists yet"
+
+# don't run multiple tests concurrently so that the ports don't conflict
+ctrl-test:
+   $(MAKE) ctrl-python-test
+   $(MAKE) ctrl-transcript-test
+
+smpp-test:
+   $(srcdir)/smpp_test_runner.py -w $(abs_top_builddir) -v
+   rm -f $(top_builddir)/sms.db
+
 check-local: atconfig $(TESTSUITE)
$(SHELL) '$(TESTSUITE)' $(TESTSUITEFLAGS)
$(MAKE) $(AM_MAKEFLAGS) python-tests

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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I688657e56ae469c07b9f25ba37275d38dbd457e2
Gerrit-Change-Number: 12126
Gerrit-PatchSet: 5
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-msc[master]: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'

2018-12-05 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12130 )

Change subject: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'
..


Patch Set 6: Code-Review+2


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I52d69af48e1ddc87b3fb54bf66a01b1b8cbf5abe
Gerrit-Change-Number: 12130
Gerrit-PatchSet: 6
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: osmith 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:34:33 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'

2018-12-05 Thread Vadim Yanitskiy
Vadim Yanitskiy has posted comments on this change. ( 
https://gerrit.osmocom.org/12130 )

Change subject: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'
..


Patch Set 6: Code-Review+1

+3 finally ;)


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I52d69af48e1ddc87b3fb54bf66a01b1b8cbf5abe
Gerrit-Change-Number: 12130
Gerrit-PatchSet: 6
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: osmith 
Gerrit-Comment-Date: Wed, 05 Dec 2018 19:31:17 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmocore[master]: LCLS, TS 48.008: add GCR IE encoding/decoding

2018-12-05 Thread Pau Espin Pedrol
Pau Espin Pedrol has posted comments on this change. ( 
https://gerrit.osmocom.org/12020 )

Change subject: LCLS, TS 48.008: add GCR IE encoding/decoding
..


Patch Set 13:

(1 comment)

https://gerrit.osmocom.org/#/c/12020/13/tests/gsm0808/gsm0808_test.c
File tests/gsm0808/gsm0808_test.c:

https://gerrit.osmocom.org/#/c/12020/13/tests/gsm0808/gsm0808_test.c@615
PS13, Line 615: if (p.net_len != g.net_len)
> In case where errors won't make sense we already abort() - see above. […]
If decoding failed (gsm0808_dec_gcr returned <0), it makes no sense using p and 
printing related p stuff.



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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I82ce0207dc8de50689a8806c6471ad7fbae6219d
Gerrit-Change-Number: 12020
Gerrit-PatchSet: 13
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Wed, 05 Dec 2018 18:33:12 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in libosmocore[master]: LCLS, TS 48.008: add GCR IE encoding/decoding

2018-12-05 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12020 )

Change subject: LCLS, TS 48.008: add GCR IE encoding/decoding
..


Patch Set 13:

(1 comment)

I thought I've already answered it but can't find it now.

https://gerrit.osmocom.org/#/c/12020/13/tests/gsm0808/gsm0808_test.c
File tests/gsm0808/gsm0808_test.c:

https://gerrit.osmocom.org/#/c/12020/13/tests/gsm0808/gsm0808_test.c@615
PS13, Line 615: if (p.net_len != g.net_len)
> I asked it already I think: if anything fails during test, abort or at least 
> return in order to avoi […]
In case where errors won't make sense we already abort() - see above. Here it's 
better to print all possible errors at once so we don't have to waste time 
checking them one by one.



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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I82ce0207dc8de50689a8806c6471ad7fbae6219d
Gerrit-Change-Number: 12020
Gerrit-PatchSet: 13
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Wed, 05 Dec 2018 18:25:55 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in python/osmo-python-tests[master]: ctrl2cgi: make http request timeout configurable

2018-12-05 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12148


Change subject: ctrl2cgi: make http request timeout configurable
..

ctrl2cgi: make http request timeout configurable

Change-Id: I7839121da831aeab0be7e599049bf79471f845fd
Related: SYS#4399
---
M scripts/ctrl2cgi.py
1 file changed, 6 insertions(+), 5 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/python/osmo-python-tests 
refs/changes/48/12148/1

diff --git a/scripts/ctrl2cgi.py b/scripts/ctrl2cgi.py
index e11e6e6..81674d8 100755
--- a/scripts/ctrl2cgi.py
+++ b/scripts/ctrl2cgi.py
@@ -22,7 +22,7 @@
  */
 """

-__version__ = "0.0.7" # bump this on every non-trivial change
+__version__ = "0.0.8" # bump this on every non-trivial change

 import argparse, os, logging, logging.handlers, datetime
 import hashlib
@@ -61,10 +61,10 @@
 #print('HASH: \nparams="%r"\ninput="%s" \nres="%s"' %(params, input, res))
 return res

-def make_async_req(ts, dst, par, f_write, f_log):
-d = post(dst, par)
+def make_async_req(ts, dst, par, f_write, f_log, tout):
+d = post(dst, par, timeout=tout)
 d.addCallback(collect, partial(handle_reply, ts, par['bsc_id'], f_write, 
f_log)) # treq's collect helper is handy to get all reply content at once
-d.addErrback(lambda e: f_log.critical("HTTP POST error %s while trying to 
register BSC %s on %s" % (e, par['bsc_id'], dst))) # handle HTTP errors
+d.addErrback(lambda e: f_log.critical("HTTP POST error %s while trying to 
register BSC %s on %s (timeout %d)" % (e, par['bsc_id'], dst, tout))) # handle 
HTTP errors
 return d

 class Trap(CTRL):
@@ -110,7 +110,7 @@
 t = datetime.datetime.now()
 self.factory.log.debug('Preparing request for BSC %s @ %s...' % 
(params['bsc_id'], t))
 # Ensure that we run only limited number of requests in parallel:
-self.factory.semaphore.run(make_async_req, t, self.factory.location, 
params, self.transport.write, self.factory.log)
+self.factory.semaphore.run(make_async_req, t, self.factory.location, 
params, self.transport.write, self.factory.log, self.factory.timeout)

 def handle_notificationrejectionv1(self, net, bsc, bts, trx, data):
 """
@@ -148,6 +148,7 @@

 T.addr_ctrl = config['main'].get('addr_ctrl', 'localhost')
 T.port_ctrl = config['main'].getint('port_ctrl', 4250)
+T.timeout = config['main'].getint('timeout', 30)
 T.semaphore = 
defer.DeferredSemaphore(config['main'].getint('num_max_conn', 5))
 T.location = config['main'].get('location')
 T.secret_key = config['main'].get('secret_key')

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

Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I7839121da831aeab0be7e599049bf79471f845fd
Gerrit-Change-Number: 12148
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in python/osmo-python-tests[master]: Trap handlers: log request/reply as info level

2018-12-05 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12146


Change subject: Trap handlers: log request/reply as info level
..

Trap handlers: log request/reply as info level

Log the basic location-state trap triggering request and command reply
as info level - that way we can receive useful information without
turning on full debug output.

Change-Id: If8eae9f36292930571954becf6613fada43d301c
---
M osmopy/trap_helper.py
M scripts/ctrl2cgi.py
M scripts/soap.py
3 files changed, 3 insertions(+), 3 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/python/osmo-python-tests 
refs/changes/46/12146/1

diff --git a/osmopy/trap_helper.py b/osmopy/trap_helper.py
index b7202ac..3e80c6d 100644
--- a/osmopy/trap_helper.py
+++ b/osmopy/trap_helper.py
@@ -60,7 +60,7 @@
 Command processor: takes function f to run for each command
 """
 bsc_id = comm[0].split()[0].split('.')[3] # we expect 1st command to have 
net.0.bsc.666.bts.2.trx.1 location prefix format
-log.debug("BSC %s commands: %r" % (bid, comm))
+log.info("BSC %s commands: %r" % (bid, comm))
 for t in comm:
 (_, m) = Ctrl().cmd(*t.split())
 f(m)
diff --git a/scripts/ctrl2cgi.py b/scripts/ctrl2cgi.py
index addca2f..5c675bc 100755
--- a/scripts/ctrl2cgi.py
+++ b/scripts/ctrl2cgi.py
@@ -104,7 +104,7 @@
 Handle location-state TRAP: parse trap content, build CGI Request and 
use treq's routines to post it while setting up async handlers
 """
 params = make_params(bsc, data)
-self.factory.log.debug('location-state@%s.%s.%s.%s (%s) => %s' % (net, 
bsc, bts, trx, params['time_stamp'], data))
+self.factory.log.info('location-state@%s.%s.%s.%s (%s) => %s' % (net, 
bsc, bts, trx, params['time_stamp'], data))
 params['h'] = gen_hash(params, self.factory.secret_key)
 # Ensure that we run only limited number of requests in parallel:
 self.factory.semaphore.run(make_async_req, self.factory.location, 
params, self.transport.write, self.factory.log)
diff --git a/scripts/soap.py b/scripts/soap.py
index f771530..5817988 100755
--- a/scripts/soap.py
+++ b/scripts/soap.py
@@ -86,7 +86,7 @@
 Handle location-state TRAP: parse trap content, build SOAP context and 
use treq's routines to post it while setting up async handlers
 """
 params = make_params(bsc, data)
-self.factory.log.debug('location-state@%s.%s.%s.%s (%s) => %s' % (net, 
bsc, bts, trx, params['time_stamp'], data))
+self.factory.log.info('location-state@%s.%s.%s.%s (%s) => %s' % (net, 
bsc, bts, trx, params['time_stamp'], data))
 ctx = self.factory.client.registerSiteLocation(bsc, 
float(params['lon']), float(params['lat']), params['position_validity'], 
params['time_stamp'], params['oper_status'], params['admin_status'], 
params['policy_status'])
 d = post(self.factory.location, ctx.envelope)
 d.addCallback(collect, partial(handle_reply, ctx.process_reply, 
params['bsc_id'], self.transport.write, self.factory.log)) # treq's collect 
helper is handy to get all reply content at once using closure on ctx

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

Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: If8eae9f36292930571954becf6613fada43d301c
Gerrit-Change-Number: 12146
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in python/osmo-python-tests[master]: Trap handlers: propagate expected BSC id to command processor

2018-12-05 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12145


Change subject: Trap handlers: propagate expected BSC id to command processor
..

Trap handlers: propagate expected BSC id to command processor

When receiving commands for particular BSC, log BSC id known at the time
when request was made, not the one which is part of the reply.

Change-Id: I6acdfddb9a1132f978f2b55c769559b0c29eb3e8
---
M osmopy/trap_helper.py
M scripts/ctrl2cgi.py
M scripts/soap.py
3 files changed, 8 insertions(+), 8 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/python/osmo-python-tests 
refs/changes/45/12145/1

diff --git a/osmopy/trap_helper.py b/osmopy/trap_helper.py
index 45dc527..b7202ac 100644
--- a/osmopy/trap_helper.py
+++ b/osmopy/trap_helper.py
@@ -55,12 +55,12 @@
 loc = split_type(v)
 return loc[-1]

-def comm_proc(comm, f, log):
+def comm_proc(comm, bid, f, log):
 """
 Command processor: takes function f to run for each command
 """
 bsc_id = comm[0].split()[0].split('.')[3] # we expect 1st command to have 
net.0.bsc.666.bts.2.trx.1 location prefix format
-log.debug("BSC %s commands: %r" % (bsc_id, comm))
+log.debug("BSC %s commands: %r" % (bid, comm))
 for t in comm:
 (_, m) = Ctrl().cmd(*t.split())
 f(m)
diff --git a/scripts/ctrl2cgi.py b/scripts/ctrl2cgi.py
index cd59209..addca2f 100755
--- a/scripts/ctrl2cgi.py
+++ b/scripts/ctrl2cgi.py
@@ -40,12 +40,12 @@
 assert V(twisted_ipa_version) > V('0.4')


-def handle_reply(f, log, resp):
+def handle_reply(bid, f, log, resp):
 """
 Reply handler: process raw CGI server response, function f to run for each 
command
 """
 decoded = json.loads(resp.decode('utf-8'))
-comm_proc(decoded.get('commands'), f, log)
+comm_proc(decoded.get('commands'), bid, f, log)

 def gen_hash(params, skey):
 inp = ''
@@ -62,7 +62,7 @@

 def make_async_req(dst, par, f_write, f_log):
 d = post(dst, par)
-d.addCallback(collect, partial(handle_reply, f_write, f_log)) # treq's 
collect helper is handy to get all reply content at once
+d.addCallback(collect, partial(handle_reply, par['bsc_id'], f_write, 
f_log)) # treq's collect helper is handy to get all reply content at once
 d.addErrback(lambda e: f_log.critical("HTTP POST error %s while trying to 
register BSC %s on %s" % (e, par['bsc_id'], dst))) # handle HTTP errors
 return d

diff --git a/scripts/soap.py b/scripts/soap.py
index 0534000..f771530 100755
--- a/scripts/soap.py
+++ b/scripts/soap.py
@@ -38,12 +38,12 @@
 assert V(twisted_ipa_version) > V('0.4')


-def handle_reply(p, f, log, r):
+def handle_reply(p, bid, f, log, r):
 """
 Reply handler: takes function p to process raw SOAP server reply r, 
function f to run for each command
 """
 repl = p(r) # result is expected to have both commands[] array and error 
string (could be None)
-bsc_id = comm_proc(repl.commands, f, log)
+bsc_id = comm_proc(repl.commands, bid, f, log)
 log.info("Received SOAP response for BSC %s with %d commands, error 
status: %s" % (bsc_id, len(repl.commands), repl.error))


@@ -89,7 +89,7 @@
 self.factory.log.debug('location-state@%s.%s.%s.%s (%s) => %s' % (net, 
bsc, bts, trx, params['time_stamp'], data))
 ctx = self.factory.client.registerSiteLocation(bsc, 
float(params['lon']), float(params['lat']), params['position_validity'], 
params['time_stamp'], params['oper_status'], params['admin_status'], 
params['policy_status'])
 d = post(self.factory.location, ctx.envelope)
-d.addCallback(collect, partial(handle_reply, ctx.process_reply, 
self.transport.write, self.factory.log)) # treq's collect helper is handy to 
get all reply content at once using closure on ctx
+d.addCallback(collect, partial(handle_reply, ctx.process_reply, 
params['bsc_id'], self.transport.write, self.factory.log)) # treq's collect 
helper is handy to get all reply content at once using closure on ctx
 d.addErrback(lambda e, bsc: self.factory.log.critical("HTTP POST error 
%s while trying to register BSC %s on %s" % (e, bsc, self.factory.location)), 
bsc) # handle HTTP errors
 # Ensure that we run only limited number of requests in parallel:
 yield self.factory.semaphore.acquire()

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

Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I6acdfddb9a1132f978f2b55c769559b0c29eb3e8
Gerrit-Change-Number: 12145
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in python/osmo-python-tests[master]: Trap handlers: adjust http error log

2018-12-05 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12149


Change subject: Trap handlers: adjust http error log
..

Trap handlers: adjust http error log

Log repr() of error because it's more conscience which makes it easier to
read the logs.

Change-Id: I39870b83cacee9a589636974d04e356ef0d32345
---
M scripts/ctrl2cgi.py
M scripts/soap.py
2 files changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/python/osmo-python-tests 
refs/changes/49/12149/1

diff --git a/scripts/ctrl2cgi.py b/scripts/ctrl2cgi.py
index 81674d8..28a7c3b 100755
--- a/scripts/ctrl2cgi.py
+++ b/scripts/ctrl2cgi.py
@@ -64,7 +64,7 @@
 def make_async_req(ts, dst, par, f_write, f_log, tout):
 d = post(dst, par, timeout=tout)
 d.addCallback(collect, partial(handle_reply, ts, par['bsc_id'], f_write, 
f_log)) # treq's collect helper is handy to get all reply content at once
-d.addErrback(lambda e: f_log.critical("HTTP POST error %s while trying to 
register BSC %s on %s (timeout %d)" % (e, par['bsc_id'], dst, tout))) # handle 
HTTP errors
+d.addErrback(lambda e: f_log.critical("HTTP POST error %s while trying to 
register BSC %s on %s (timeout %d)" % (repr(e), par['bsc_id'], dst, tout))) # 
handle HTTP errors
 return d

 class Trap(CTRL):
diff --git a/scripts/soap.py b/scripts/soap.py
index 5817988..0cb2184 100755
--- a/scripts/soap.py
+++ b/scripts/soap.py
@@ -90,7 +90,7 @@
 ctx = self.factory.client.registerSiteLocation(bsc, 
float(params['lon']), float(params['lat']), params['position_validity'], 
params['time_stamp'], params['oper_status'], params['admin_status'], 
params['policy_status'])
 d = post(self.factory.location, ctx.envelope)
 d.addCallback(collect, partial(handle_reply, ctx.process_reply, 
params['bsc_id'], self.transport.write, self.factory.log)) # treq's collect 
helper is handy to get all reply content at once using closure on ctx
-d.addErrback(lambda e, bsc: self.factory.log.critical("HTTP POST error 
%s while trying to register BSC %s on %s" % (e, bsc, self.factory.location)), 
bsc) # handle HTTP errors
+d.addErrback(lambda e, bsc: self.factory.log.critical("HTTP POST error 
%s while trying to register BSC %s on %s" % (repr(e), bsc, 
self.factory.location)), bsc) # handle HTTP errors
 # Ensure that we run only limited number of requests in parallel:
 yield self.factory.semaphore.acquire()
 yield d # we end up here only if semaphore is available which means 
it's ok to fire the request without exceeding the limit

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

Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I39870b83cacee9a589636974d04e356ef0d32345
Gerrit-Change-Number: 12149
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in python/osmo-python-tests[master]: twisted: disable low-level logging in dispatchers

2018-12-05 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12150


Change subject: twisted: disable low-level logging in dispatchers
..

twisted: disable low-level logging in dispatchers

The same messages are better handled in derived classes using
message-specific functions instead of generic dispatchers.

Change-Id: I4a054eec9ef7ab39e15ac0cd64834a251d4fb2d7
---
M osmopy/twisted_ipa.py
1 file changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/python/osmo-python-tests 
refs/changes/50/12150/1

diff --git a/osmopy/twisted_ipa.py b/osmopy/twisted_ipa.py
index 70c1ef0..5b60d28 100755
--- a/osmopy/twisted_ipa.py
+++ b/osmopy/twisted_ipa.py
@@ -146,7 +146,7 @@
 """
 (_, proto, extension, content) = IPA().del_header(data)
 if content is not None:
-self.dbg('IPA received %s::%s [%d/%d] %s' % (IPA().proto(proto), 
IPA().ext_name(proto, extension), len(data), len(content), content))
+#self.dbg('IPA received %s::%s [%d/%d] %s' % (IPA().proto(proto), 
IPA().ext_name(proto, extension), len(data), len(content), content))
 method = getattr(self, 'handle_' + IPA().proto(proto), lambda: 
"protocol dispatch failure")
 method(content, proto, extension)

@@ -249,7 +249,7 @@
 OSMO CTRL message dispatcher, lambda default should never happen
 For basic tests only, appropriate handling routines should be 
replaced: see CtrlServer for example
 """
-self.dbg('OSMO CTRL received %s::%s' % Ctrl().parse_kv(data))
+#self.dbg('OSMO CTRL received %s::%s' % Ctrl().parse_kv(data))
 (cmd, op_id, v) = data.decode('utf-8').split(' ', 2)
 method = getattr(self, 'ctrl_' + cmd, lambda: "CTRL unknown command")
 method(data, op_id, v)

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

Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I4a054eec9ef7ab39e15ac0cd64834a251d4fb2d7
Gerrit-Change-Number: 12150
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in python/osmo-python-tests[master]: ctrl2cgi: log request time

2018-12-05 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12147


Change subject: ctrl2cgi: log request time
..

ctrl2cgi: log request time

Log http request timestamp and duration on debug loglevel. This is
especially helpful while troubleshooting issues with multiple concurrent
requests under significant load while network issues are present.

Change-Id: I11c8ac67a2730a9c6912694e5b83bbdf08fe357d
Related: SYS#4399
---
M scripts/ctrl2cgi.py
1 file changed, 9 insertions(+), 6 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/python/osmo-python-tests 
refs/changes/47/12147/1

diff --git a/scripts/ctrl2cgi.py b/scripts/ctrl2cgi.py
index 5c675bc..e11e6e6 100755
--- a/scripts/ctrl2cgi.py
+++ b/scripts/ctrl2cgi.py
@@ -22,9 +22,9 @@
  */
 """

-__version__ = "0.0.6" # bump this on every non-trivial change
+__version__ = "0.0.7" # bump this on every non-trivial change

-import argparse, os, logging, logging.handlers
+import argparse, os, logging, logging.handlers, datetime
 import hashlib
 import json
 import configparser
@@ -40,11 +40,12 @@
 assert V(twisted_ipa_version) > V('0.4')


-def handle_reply(bid, f, log, resp):
+def handle_reply(ts, bid, f, log, resp):
 """
 Reply handler: process raw CGI server response, function f to run for each 
command
 """
 decoded = json.loads(resp.decode('utf-8'))
+log.debug('request for BSC %s took %d seconds' % (bid, 
(datetime.datetime.now() - ts).total_seconds()))
 comm_proc(decoded.get('commands'), bid, f, log)

 def gen_hash(params, skey):
@@ -60,9 +61,9 @@
 #print('HASH: \nparams="%r"\ninput="%s" \nres="%s"' %(params, input, res))
 return res

-def make_async_req(dst, par, f_write, f_log):
+def make_async_req(ts, dst, par, f_write, f_log):
 d = post(dst, par)
-d.addCallback(collect, partial(handle_reply, par['bsc_id'], f_write, 
f_log)) # treq's collect helper is handy to get all reply content at once
+d.addCallback(collect, partial(handle_reply, ts, par['bsc_id'], f_write, 
f_log)) # treq's collect helper is handy to get all reply content at once
 d.addErrback(lambda e: f_log.critical("HTTP POST error %s while trying to 
register BSC %s on %s" % (e, par['bsc_id'], dst))) # handle HTTP errors
 return d

@@ -106,8 +107,10 @@
 params = make_params(bsc, data)
 self.factory.log.info('location-state@%s.%s.%s.%s (%s) => %s' % (net, 
bsc, bts, trx, params['time_stamp'], data))
 params['h'] = gen_hash(params, self.factory.secret_key)
+t = datetime.datetime.now()
+self.factory.log.debug('Preparing request for BSC %s @ %s...' % 
(params['bsc_id'], t))
 # Ensure that we run only limited number of requests in parallel:
-self.factory.semaphore.run(make_async_req, self.factory.location, 
params, self.transport.write, self.factory.log)
+self.factory.semaphore.run(make_async_req, t, self.factory.location, 
params, self.transport.write, self.factory.log)

 def handle_notificationrejectionv1(self, net, bsc, bts, trx, data):
 """

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

Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I11c8ac67a2730a9c6912694e5b83bbdf08fe357d
Gerrit-Change-Number: 12147
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in osmo-msc[master]: make: prepare for adding transcript tests

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/12126 )

Change subject: make: prepare for adding transcript tests
..


Patch Set 4: Code-Review+1


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I688657e56ae469c07b9f25ba37275d38dbd457e2
Gerrit-Change-Number: 12126
Gerrit-PatchSet: 4
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:58:46 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: msc_main: mncc: move mncc socket decision to after read_cfg

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/12129 )

Change subject: msc_main: mncc: move mncc socket decision to after read_cfg
..


Patch Set 6: Code-Review+1


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifc87c1cacaa809d04fc23e8ccd761bee4509c805
Gerrit-Change-Number: 12129
Gerrit-PatchSet: 6
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:55:18 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: python tests: use py shebang instead of $(PYTHON)

2018-12-05 Thread Pau Espin Pedrol
Pau Espin Pedrol has posted comments on this change. ( 
https://gerrit.osmocom.org/12138 )

Change subject: python tests: use py shebang instead of $(PYTHON)
..


Patch Set 2: Code-Review+2


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie35dd78c42577109a6a3143221a9769e47d361a5
Gerrit-Change-Number: 12138
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:54:00 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: python tests: use py shebang instead of $(PYTHON)

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/12138 )

Change subject: python tests: use py shebang instead of $(PYTHON)
..


Patch Set 2: Code-Review+1

Fine with me.


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie35dd78c42577109a6a3143221a9769e47d361a5
Gerrit-Change-Number: 12138
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:53:08 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: add test_nodes.vty transcript test

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/12127 )

Change subject: add test_nodes.vty transcript test
..


Patch Set 5: Code-Review+1


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I3a8c50d8d555b6b948d97d6412e17594ee439de0
Gerrit-Change-Number: 12127
Gerrit-PatchSet: 5
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:51:46 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmocore[master]: gsm_29_118: add missing extern for struct value_string decl.

2018-12-05 Thread dexter
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/12144


Change subject: gsm_29_118: add missing extern for struct value_string decl.
..

gsm_29_118: add missing extern for struct value_string decl.

The value string arrays in the header file (gsm_29_118.h) are not
declared as extern. Lets add it now.

Change-Id: Ib6c4cbea649f790fa4db1ed2fe2b7e76a60291b4
Related: OS#3615
---
M include/osmocom/gsm/protocol/gsm_29_118.h
1 file changed, 8 insertions(+), 8 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/44/12144/1

diff --git a/include/osmocom/gsm/protocol/gsm_29_118.h 
b/include/osmocom/gsm/protocol/gsm_29_118.h
index bf210ad..97a9c43 100644
--- a/include/osmocom/gsm/protocol/gsm_29_118.h
+++ b/include/osmocom/gsm/protocol/gsm_29_118.h
@@ -35,7 +35,7 @@
/* unassigned */
SGSAP_MSGT_UE_UNREACHABLE   = 0x1f,
 };
-const struct value_string sgsap_msg_type_names[];
+extern const struct value_string sgsap_msg_type_names[];
 static inline const char *sgsap_msg_type_name(enum sgsap_msg_type msgt) {
return get_value_string(sgsap_msg_type_names, msgt);
 }
@@ -74,7 +74,7 @@
SGSAP_IE_ADDL_PAGING_INDICATORS = 0x26,
SGSAP_IE_TMSI_BASED_NRI_CONT= 0x27,
 };
-const struct value_string sgsap_iei_names[];
+extern const struct value_string sgsap_iei_names[];
 static inline const char *sgsap_iei_name(enum sgsap_iei iei) {
return get_value_string(sgsap_iei_names, iei);
 }
@@ -84,7 +84,7 @@
SGSAP_EPS_LUT_IMSI_ATTACH   = 0x01,
SGSAP_EPS_LUT_NORMAL= 0x02,
 };
-const struct value_string sgsap_eps_lu_type_names[];
+extern const struct value_string sgsap_eps_lu_type_names[];
 static inline const char *sgsap_eps_lu_type_name(enum sgsap_eps_lu_type lut) {
return get_value_string(sgsap_eps_lu_type_names, lut);
 }
@@ -95,7 +95,7 @@
SGSAP_ID_EPS_T_UE_INITIATED = 0x02,
SGSAP_ID_EPS_T_EPS_NOT_ALLOWED  = 0x03,
 };
-const struct value_string sgsap_ismi_det_eps_type_names[];
+extern const struct value_string sgsap_ismi_det_eps_type_names[];
 static inline const char *sgsap_imsi_det_eps_type_name(enum 
sgsap_imsi_det_eps_type idt) {
return get_value_string(sgsap_ismi_det_eps_type_names, idt);
 }
@@ -106,7 +106,7 @@
SGSAP_ID_NONEPS_T_COMBINED_UE_EPS_NONEPS= 0x02,
SGSAP_ID_NONEPS_T_IMPLICIT_UE_EPS_NONEPS= 0x03,
 };
-const struct value_string sgsap_ismi_det_noneps_type_names[];
+extern const struct value_string sgsap_ismi_det_noneps_type_names[];
 static inline const char *sgsap_imsi_det_noneps_type_name(enum 
sgsap_imsi_det_noneps_type idt) {
return get_value_string(sgsap_ismi_det_noneps_type_names, idt);
 }
@@ -116,7 +116,7 @@
SGSAP_SERV_IND_CS_CALL  = 0x01,
SGSAP_SERV_IND_SMS  = 0x02,
 };
-const struct value_string sgsap_service_ind_names[];
+extern const struct value_string sgsap_service_ind_names[];
 static inline const char *sgsap_service_ind_name(enum sgsap_service_ind si) {
return get_value_string(sgsap_service_ind_names, si);
 }
@@ -138,7 +138,7 @@
SGSAP_SGS_CAUSE_MT_CSFB_REJ_USER= 0x0d,
SGSAP_SGS_CAUSE_UE_TEMP_UNREACHABLE = 0x0e,
 };
-const struct value_string sgsap_sgs_cause_names[];
+extern const struct value_string sgsap_sgs_cause_names[];
 static inline const char *sgsap_sgs_cause_name(enum sgsap_sgs_cause cause) {
return get_value_string(sgsap_sgs_cause_names, cause);
 }
@@ -148,7 +148,7 @@
SGSAP_UE_EMM_MODE_IDLE  = 0x00,
SGSAP_UE_EMM_MODE_CONNECTED = 0x01,
 };
-const struct value_string sgsap_ue_emm_mode_names[];
+extern const struct value_string sgsap_ue_emm_mode_names[];
 static inline const char *sgsap_ue_emm_mode_name(enum sgsap_ue_emm_mode mode) {
return get_value_string(sgsap_ue_emm_mode_names, mode);
 }

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib6c4cbea649f790fa4db1ed2fe2b7e76a60291b4
Gerrit-Change-Number: 12144
Gerrit-PatchSet: 1
Gerrit-Owner: dexter 


Change in osmo-msc[master]: cosmetic: msc_main.c: default args definition style

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/12128 )

Change subject: cosmetic: msc_main.c: default args definition style
..


Patch Set 5: Code-Review+1


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I0e0f1e2c8722768b6c61fd6544911b20fe1af212
Gerrit-Change-Number: 12128
Gerrit-PatchSet: 5
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:39:04 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ttcn3-hacks[master]: MSC_Test: Test what happens when Paging for SMS is unanswered

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/11897 )

Change subject: MSC_Test: Test what happens when Paging for SMS is unanswered
..


Patch Set 6: Code-Review+1


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

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Id645729551672026c6a96bb849ecd04f20cd0c56
Gerrit-Change-Number: 11897
Gerrit-PatchSet: 6
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:36:13 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-bsc[master]: paging: Add VTY options to calculate T3113 timeout dynamically

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/11654 )

Change subject: paging: Add VTY options to calculate T3113 timeout dynamically
..


Patch Set 6: Code-Review+1


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

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4fb2969b690151415038631fb6ad059aa6835c7f
Gerrit-Change-Number: 11654
Gerrit-PatchSet: 6
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Assignee: Harald Welte 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:34:12 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/12130 )

Change subject: vty: mncc cfg: separate the 'mncc' from 'mncc-guard-timeout'
..


Patch Set 6: Code-Review+1


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I52d69af48e1ddc87b3fb54bf66a01b1b8cbf5abe
Gerrit-Change-Number: 12130
Gerrit-PatchSet: 6
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: osmith 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:30:07 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-hlr[master]: introduce osmo_gsup_client_create2()

2018-12-05 Thread Stefan Sperling
Stefan Sperling has posted comments on this change. ( 
https://gerrit.osmocom.org/12098 )

Change subject: introduce osmo_gsup_client_create2()
..


Patch Set 2:

Thanks for the review. Should be all good in next patch set.


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

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ief09677e07d6e977247185b72c605f109aa091f5
Gerrit-Change-Number: 12098
Gerrit-PatchSet: 2
Gerrit-Owner: Stefan Sperling 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 17:21:16 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in osmo-hlr[master]: introduce osmo_gsup_client_create2()

2018-12-05 Thread Stefan Sperling
Hello Neels Hofmeyr, Jenkins Builder,

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

https://gerrit.osmocom.org/12098

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

Change subject: introduce osmo_gsup_client_create2()
..

introduce osmo_gsup_client_create2()

Add a new API which allows creating a GSUP client connection with
more identification information than just a unit name. Instead of
being selective about which idenfifiers callers may use, allow
callers to pass a full-blown struct ipaccess_unit. This allows
applications to use entirely custom identifiers on GSUP client
connections.

This change is a prerequisite for inter-MSC handover because MSCs
will need to use unique identifiers towards the HLR, which isn't
very easy to do with the old osmo_gsup_client_create() API. While
it's always been possible to pass a unique unit_name, this is not
as flexible as we would like.

The old API remains for backwards compatibility.
struct osmo_gsup_client grows in size but is allocated internally
by the library; old calling code won't notice the difference.

Change-Id: Ief09677e07d6e977247185b72c605f109aa091f5
Related: OS#3355
---
M include/osmocom/gsupclient/gsup_client.h
M src/gsupclient/gsup_client.c
2 files changed, 49 insertions(+), 19 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-hlr refs/changes/98/12098/3
--
To view, visit https://gerrit.osmocom.org/12098
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-hlr
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ief09677e07d6e977247185b72c605f109aa091f5
Gerrit-Change-Number: 12098
Gerrit-PatchSet: 3
Gerrit-Owner: Stefan Sperling 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Stefan Sperling 


Change in osmo-gsm-tester[master]: test: cs_paging_gprs_active: Make sure gprs data (TBF) is ongoing

2018-12-05 Thread Pau Espin Pedrol
Pau Espin Pedrol has uploaded this change for review. ( 
https://gerrit.osmocom.org/12143


Change subject: test: cs_paging_gprs_active: Make sure gprs data (TBF) is 
ongoing
..

test: cs_paging_gprs_active: Make sure gprs data (TBF) is ongoing

PACCH is used for paging only if the MS is actively using a PDCH, and
the only way to be sure that's happening is to place some data through
the GPRS path so MS has TBF in use when the call is placed.

Change-Id: Id29391d75101d94e2cd58f444b383f4c5217ab6a
---
M suites/gprs/cs_paging_gprs_active.py
M suites/gprs/lib/testlib.py
2 files changed, 30 insertions(+), 73 deletions(-)



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

diff --git a/suites/gprs/cs_paging_gprs_active.py 
b/suites/gprs/cs_paging_gprs_active.py
index fc0e160..b7dead2 100755
--- a/suites/gprs/cs_paging_gprs_active.py
+++ b/suites/gprs/cs_paging_gprs_active.py
@@ -5,79 +5,34 @@

 from osmo_gsm_tester.testenv import *

-hlr = suite.hlr()
-bts = suite.bts()
-pcu = bts.pcu()
-mgw_msc = suite.mgw()
-mgw_bsc = suite.mgw()
-stp = suite.stp()
-ggsn = suite.ggsn()
-sgsn = suite.sgsn(hlr, ggsn)
-msc = suite.msc(hlr, mgw_msc, stp)
-bsc = suite.bsc(msc, mgw_bsc, stp)
-ms_mo = suite.modem()
-ms_mt = suite.modem()
+import testlib
+suite.test_import_modules_register_for_cleanup(testlib)
+from testlib import setup_run_iperf3_test_parallel

-bsc.bts_add(bts)
-sgsn.bts_add(bts)
+def ready_cb_place_voicecall(ms_li):
+print('waiting a few secs to make sure iperf3 test is running')
+sleep(2)
+# At this point in time, TBF should be enabled on both MS since they are 
sending/receiving data.
+print('iperf3 running, let\'s place a call')
+ms_mo = ms_li[0]
+ms_mt = ms_li[1]
+assert len(ms_mo.call_id_list()) == 0 and len(ms_mt.call_id_list()) == 0
+mo_cid = ms_mo.call_dial(ms_mt)
+mt_cid = ms_mt.call_wait_incoming(ms_mo)
+print('dial success')

-print('start network...')
-hlr.start()
-stp.start()
-ggsn.start()
-sgsn.start()
-msc.start()
-mgw_msc.start()
-mgw_bsc.start()
-bsc.start()
+assert not ms_mo.call_is_active(mo_cid) and not 
ms_mt.call_is_active(mt_cid)
+ms_mt.call_answer(mt_cid)
+wait(ms_mo.call_is_active, mo_cid)
+wait(ms_mt.call_is_active, mt_cid)
+print('answer success, call established and ongoing')

-bts.start()
-wait(bsc.bts_is_connected, bts)
-print('Waiting for bts to be ready...')
-wait(bts.ready_for_pcu)
-pcu.start()
+sleep(5) # maintain the call active for 5 seconds

-hlr.subscriber_add(ms_mo)
-hlr.subscriber_add(ms_mt)
+assert ms_mo.call_is_active(mo_cid) and ms_mt.call_is_active(mt_cid)
+ms_mt.call_hangup(mt_cid)
+wait(lambda: len(ms_mo.call_id_list()) == 0 and len(ms_mt.call_id_list()) 
== 0)
+print('hangup success')

-ms_mo.connect(msc.mcc_mnc())
-ms_mt.connect(msc.mcc_mnc())
-ms_mo.attach()
-ms_mt.attach()

-ms_mo.log_info()
-ms_mt.log_info()
-
-print('waiting for modems to attach...')
-wait(ms_mo.is_connected, msc.mcc_mnc())
-wait(ms_mt.is_connected, msc.mcc_mnc())
-wait(msc.subscriber_attached, ms_mo, ms_mt)
-
-print('waiting for modems to attach to data services...')
-wait(ms_mo.is_attached)
-wait(ms_mt.is_attached)
-
-# We need to use inet46 since ofono qmi only uses ipv4v6 eua (OS#2713)
-ctx_id_v4_mo = ms_mo.activate_context(apn='inet46', 
protocol=ms_mo.CTX_PROT_IPv4)
-ctx_id_v4_mt = ms_mt.activate_context(apn='inet46', 
protocol=ms_mt.CTX_PROT_IPv4)
-
-assert len(ms_mo.call_id_list()) == 0 and len(ms_mt.call_id_list()) == 0
-mo_cid = ms_mo.call_dial(ms_mt)
-mt_cid = ms_mt.call_wait_incoming(ms_mo)
-print('dial success')
-
-assert not ms_mo.call_is_active(mo_cid) and not ms_mt.call_is_active(mt_cid)
-ms_mt.call_answer(mt_cid)
-wait(ms_mo.call_is_active, mo_cid)
-wait(ms_mt.call_is_active, mt_cid)
-print('answer success, call established and ongoing')
-
-sleep(5) # maintain the call active for 5 seconds
-
-assert ms_mo.call_is_active(mo_cid) and ms_mt.call_is_active(mt_cid)
-ms_mt.call_hangup(mt_cid)
-wait(lambda: len(ms_mo.call_id_list()) == 0 and len(ms_mt.call_id_list()) == 0)
-print('hangup success')
-
-ms_mo.deactivate_context(ctx_id_v4_mo)
-ms_mt.deactivate_context(ctx_id_v4_mt)
+setup_run_iperf3_test_parallel(2, ready_cb=ready_cb_place_voicecall)
diff --git a/suites/gprs/lib/testlib.py b/suites/gprs/lib/testlib.py
index 13a6671..ac3a847 100644
--- a/suites/gprs/lib/testlib.py
+++ b/suites/gprs/lib/testlib.py
@@ -11,7 +11,7 @@
 print("\tSEND: %d KB, %d kbps, %d seconds" % (cli_sent['bytes']/1000, 
cli_sent['bits_per_second']/1000, cli_sent['seconds']))
 print("\tRECV: %d KB, %d kbps, %d seconds" % (cli_recv['bytes']/1000, 
cli_recv['bits_per_second']/1000, cli_recv['seconds']))

-def run_iperf3_cli_parallel(iperf3clients, ms_li):
+def run_iperf3_cli_parallel(iperf3clients, ms_li, ready_cb):
 assert len(iperf3clients) == len(ms_li)
 procs = []
 for i in range(len(iperf3clients)):
@@ -20,6 

Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4381

2018-12-05 Thread jenkins
See 


--
[...truncated 1.13 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Build failed in Jenkins: master-libosmo-sccp » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #1888

2018-12-05 Thread jenkins
See 


--
[...truncated 36.68 KB...]
--
make[3]: Leaving directory 
'
make[2]: Leaving directory 
'
Making install in src/codec
make[2]: Entering directory 
'
  CC   gsm610.lo
  CC   gsm620.lo
  CC   gsm690.lo
  CC   gsm660.lo
  CC   ecu_fr.lo
  CCLD libosmocodec.la
make[3]: Entering directory 
'
make[3]: Nothing to be done for 'install-data-am'.
 /bin/mkdir -p 
'
 /bin/bash ../../libtool   --mode=install /usr/bin/install -c   libosmocodec.la 
'
libtool: warning: relinking 'libosmocodec.la'
libtool: install: (cd 

 /bin/bash 
"
  --silent --tag CC --mode=relink gcc -Wall -g -O2 -DBUILDING_LIBOSMOCORE -Wall 
-version-info 1:1:1 -no-undefined -o libosmocodec.la -rpath 

 gsm610.lo gsm620.lo gsm660.lo gsm690.lo ecu_fr.lo ../../src/libosmocore.la )
libtool: install: /usr/bin/install -c .libs/libosmocodec.so.0.1.1T 

libtool: install: (cd 

 && { ln -s -f libosmocodec.so.0.1.1 libosmocodec.so.0 || { rm -f 
libosmocodec.so.0 && ln -s libosmocodec.so.0.1.1 libosmocodec.so.0; }; })
libtool: install: (cd 

 && { ln -s -f libosmocodec.so.0.1.1 libosmocodec.so || { rm -f libosmocodec.so 
&& ln -s libosmocodec.so.0.1.1 libosmocodec.so; }; })
libtool: install: /usr/bin/install -c .libs/libosmocodec.lai 

libtool: finish: 
PATH=":/usr/local/bin:/usr/bin:/bin:/usr/games:/home/osmocom-build/bin:/sbin"
 ldconfig -n 

--
Libraries have been installed in:
   


If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the '-LLIBDIR'
flag during linking and do at least one of the following:
   - add LIBDIR to the 'LD_LIBRARY_PATH' environment variable
 during execution
   - add LIBDIR to the 'LD_RUN_PATH' environment variable
 during linking
   - use the '-Wl,-rpath -Wl,LIBDIR' linker flag
   - have your system administrator add LIBDIR to '/etc/ld.so.conf'

See any operating system 

Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4380

2018-12-05 Thread jenkins
See 


Changes:

[Pau Espin Pedrol] bsc: Add define for ts_as_pchan_for_each_lchan with 
ts->pchan_on_init

[Pau Espin Pedrol] bsc: Fix lchan iteration for dyn TS during PDCH Deact

[Pau Espin Pedrol] bsc: timelost_fsm: Remove unneeded set of out variable on 
failure

[Pau Espin Pedrol] bsc: timeslot_fsm: Fix ts_is_lchan_waiting_for_pchan

[Pau Espin Pedrol] bsc: ts_is_pchan_switching: Return correct IPA dyn TS 
target_pchan

[Pau Espin Pedrol] bsc: timeslot_fsm: Fix possible skip of some lchans in

[Pau Espin Pedrol] bsc: timeslot_fsm: Fix count in ts_lchans_waiting

[Pau Espin Pedrol] bsc: lchan_rtp_fsm: Avoid duplicate LCHAN_EV_RTP_RELEASED 
event

[Pau Espin Pedrol] bsc: lchan_fsm: Add missing transition

[Pau Espin Pedrol] bsc: timeslot_fsm: Handle and ignore tear down of lchan 
during PDCH

[Pau Espin Pedrol] bsc: lchan_fsm: Fix invalid duplicated transition

--
[...truncated 1.13 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.268-4af2d/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.268-4af2d/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Change in osmo-msc[master]: gsm_subscriber: make function msc_paging_request() static

2018-12-05 Thread dexter
dexter has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12142 )

Change subject: gsm_subscriber: make function msc_paging_request() static
..

gsm_subscriber: make function msc_paging_request() static

The function msc_paging_request() is only called from within
gsm_subscriber.c but never from outside. Lets make it static.

Change-Id: I2efc8eac01a4dd8733118067eecf566c13062106
---
M src/libmsc/gsm_subscriber.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Pau Espin Pedrol: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/libmsc/gsm_subscriber.c b/src/libmsc/gsm_subscriber.c
index c3b8a95..188807e 100644
--- a/src/libmsc/gsm_subscriber.c
+++ b/src/libmsc/gsm_subscriber.c
@@ -109,7 +109,7 @@
return 0;
 }

-int msc_paging_request(struct vlr_subscr *vsub)
+static int msc_paging_request(struct vlr_subscr *vsub)
 {
/* The subscriber was last seen in subscr->lac. Find out which
 * BSCs/RNCs are responsible and send them a paging request via open

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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I2efc8eac01a4dd8733118067eecf566c13062106
Gerrit-Change-Number: 12142
Gerrit-PatchSet: 2
Gerrit-Owner: dexter 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: dexter 


Jenkins build is back to normal : master-osmo-iuh » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #2596

2018-12-05 Thread jenkins
See 




Change in osmo-msc[master]: python tests: use py shebang instead of $(PYTHON)

2018-12-05 Thread Neels Hofmeyr
Hello Pau Espin Pedrol, Jenkins Builder,

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

https://gerrit.osmocom.org/12138

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

Change subject: python tests: use py shebang instead of $(PYTHON)
..

python tests: use py shebang instead of $(PYTHON)

I'm going to make the external tests manually launchable. For that I first had
an error message if $(PYTHON) was empty. But Pau says I should just use shebang
instead and ignore the autoconf python stuff, since that often fails anyway.

Change-Id: Ie35dd78c42577109a6a3143221a9769e47d361a5
---
M tests/Makefile.am
M tests/ctrl_test_runner.py
M tests/smpp_test_runner.py
M tests/vty_test_runner.py
4 files changed, 6 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/38/12138/2
-- 
To view, visit https://gerrit.osmocom.org/12138
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ie35dd78c42577109a6a3143221a9769e47d361a5
Gerrit-Change-Number: 12138
Gerrit-PatchSet: 2
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Pau Espin Pedrol 


Change in osmo-bsc[master]: paging: Add VTY options to calculate T3113 timeout dynamically

2018-12-05 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/11654 )

Change subject: paging: Add VTY options to calculate T3113 timeout dynamically
..


Patch Set 6:

would suffice if someone else agrees that the new way should be the new default


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

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4fb2969b690151415038631fb6ad059aa6835c7f
Gerrit-Change-Number: 11654
Gerrit-PatchSet: 6
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Assignee: Harald Welte 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Stefan Sperling 
Gerrit-Comment-Date: Wed, 05 Dec 2018 16:14:03 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in osmo-msc[master]: make: prepare for adding transcript tests

2018-12-05 Thread Pau Espin Pedrol
Pau Espin Pedrol has posted comments on this change. ( 
https://gerrit.osmocom.org/12126 )

Change subject: make: prepare for adding transcript tests
..


Patch Set 3: Code-Review+2


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I688657e56ae469c07b9f25ba37275d38dbd457e2
Gerrit-Change-Number: 12126
Gerrit-PatchSet: 3
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Wed, 05 Dec 2018 16:09:09 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: add test_nodes.vty transcript test

2018-12-05 Thread Neels Hofmeyr
Hello Jenkins Builder,

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

https://gerrit.osmocom.org/12127

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

Change subject: add test_nodes.vty transcript test
..

add test_nodes.vty transcript test

It needs to work whether SMPP,Iu are enable or disabled, hence a bit more
wildcarding than one might expect.

Change-Id: I3a8c50d8d555b6b948d97d6412e17594ee439de0
---
M tests/Makefile.am
A tests/test_nodes.vty
2 files changed, 107 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/27/12127/4
--
To view, visit https://gerrit.osmocom.org/12127
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I3a8c50d8d555b6b948d97d6412e17594ee439de0
Gerrit-Change-Number: 12127
Gerrit-PatchSet: 4
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-CC: Pau Espin Pedrol 


Change in osmo-msc[master]: make: prepare for adding transcript tests

2018-12-05 Thread Neels Hofmeyr
Hello Pau Espin Pedrol, Jenkins Builder,

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

https://gerrit.osmocom.org/12126

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

Change subject: make: prepare for adding transcript tests
..

make: prepare for adding transcript tests

Separate 'make python-test' into separate make targets, to sensibly add VTY
transcript tests in an upcoming commit.

Feature: even though ./configure was called without --enable-external-tests,
each of the {ctrl,vty}x{python,transcript} tests can be invoked individually by
e.g. 'make vty-python-test'.

Both 'vty-transcript-test' and 'ctrl-transcript-test' are still empty, a
subsequent patch adds a vty-transcript-test.

All of this in preparation of tweaking the 'mncc' vty configuration, to be able
to track it in a vty transcript test.

Change-Id: I688657e56ae469c07b9f25ba37275d38dbd457e2
---
M tests/Makefile.am
1 file changed, 41 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/26/12126/3
--
To view, visit https://gerrit.osmocom.org/12126
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I688657e56ae469c07b9f25ba37275d38dbd457e2
Gerrit-Change-Number: 12126
Gerrit-PatchSet: 3
Gerrit-Owner: Neels Hofmeyr 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 


Build failed in Jenkins: master-osmo-bsc » a1=default,a2=default,a3=default,a4=default,osmocom-master-debian9 #4379

2018-12-05 Thread jenkins
See 


--
[...truncated 1.13 MB...]
Making distclean in bsc
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/include/osmocom/bsc'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../../include/osmocom/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f Makefile
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/include/osmocom/bsc'
make[4]: Entering directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/include/osmocom'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../../include/osmocom" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[4]: Leaving directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/include/osmocom'
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/include/osmocom'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/include'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../include" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/include'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/include'
Making distclean in src
make[2]: Entering directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src'
Making distclean in libfilter
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/libfilter'
rm -rf .libs _libs
test -z "libfilter.a " || rm -f libfilter.a 
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/libfilter" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/libfilter'
Making distclean in osmo-bsc
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/osmo-bsc'
 rm -f osmo-bsc
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/osmo-bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/osmo-bsc'
Making distclean in utils
make[3]: Entering directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/utils'
 rm -f bs11_config isdnsync meas_json osmo-meas-udp2db osmo-meas-pcap2db
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/utils" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/utils'
Making distclean in ipaccess
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/ipaccess'
 rm -f abisip-find ipaccess-config ipaccess-proxy
rm -rf .libs _libs
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../src/ipaccess" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src/ipaccess'
make[3]: Entering directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f 
test . = "../../src" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src'
rm -f Makefile
make[2]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/src'
Making distclean in tests
make[2]: Entering directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/tests'
Making distclean in bsc
make[3]: Entering directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/tests/bsc'
rm -rf .libs _libs
 rm -f bsc_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/bsc" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory '/build/osmo-bsc-1.3.0.257-ab9a2/_build/tests/bsc'
Making distclean in codec_pref
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/tests/codec_pref'
rm -rf .libs _libs
 rm -f codec_pref_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/codec_pref" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/tests/codec_pref'
Making distclean in gsm0408
make[3]: Entering directory 
'/build/osmo-bsc-1.3.0.257-ab9a2/_build/tests/gsm0408'
rm -rf .libs _libs
 rm -f gsm0408_test
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f 
test . = "../../../tests/gsm0408" || test -z "" || rm -f 
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[3]: Leaving directory 

Change in osmo-bsc[master]: bsc: Fix lchan iteration for dyn TS during PDCH Deact

2018-12-05 Thread Pau Espin Pedrol
Pau Espin Pedrol has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/11957 )

Change subject: bsc: Fix lchan iteration for dyn TS during PDCH Deact
..

bsc: Fix lchan iteration for dyn TS during PDCH Deact

In general PDCH channels are not handled as lchans in BSC (lchan_fsm.c),
and so when a TS is in ts->pchan_is=GSM_PCHAN_PDCH, no lchan slot is
being used.

However, during Dynamic TS PDCH Deactivation being in progress (state
WAIT_PDCH_DEACT in timeslot_fsm.c), ts->pchan_is =GSM_PCHAN_PDCH, but
an lchan slot of that TS is actually already being used by a TCH lchan:
it's the one who initiated the deactivate in order to be able to use the TS.

While being in WAIT_PDCH_DEACT state and receiving a PDCH DEACT NACK,
ts_fsm_error() was called in order to kill the TS and it was expected
that it would kill any lchan using it (or willing to start using it). In
order to do that, it calls ts_lchans_dispatch() which in turns iterates
over all lchans attached to the TS using ts_for_each_lchan().

However, when the NACK arrived we still had ts->pchan_is=GSM_PCHAN_PDCH,
ts_for_each_lchan ends up calling
ts_as_pchan_for_each_lchan(GSM_PCHAN_PDCH), which in turns calls
pchan_subslots(GSM_PCHAN_PDCH) which returns 0, because we don't manage
lchans in that mode as explained in first paragraph. This means in this
case ts_for_each_lchan() is actually an empty loop while still any of
the TCH channels may be in use, and won't be advertised about the TS
entering in a broken state.

As a result, the lchan won't be released for a while, only after T23001
expires.

Related: OS#3708
Change-Id: I9cedb77d6578597f1febab36c54b2ee427c7a4a2
---
M src/osmo-bsc/timeslot_fsm.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Neels Hofmeyr: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/osmo-bsc/timeslot_fsm.c b/src/osmo-bsc/timeslot_fsm.c
index a39549b..113ec36 100644
--- a/src/osmo-bsc/timeslot_fsm.c
+++ b/src/osmo-bsc/timeslot_fsm.c
@@ -123,7 +123,7 @@
 {
struct gsm_lchan *lchan;

-   ts_for_each_lchan(lchan, ts) {
+   ts_for_each_potential_lchan(lchan, ts) {
if (lchan_state >= 0
&& !lchan_state_is(lchan, lchan_state))
continue;

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

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I9cedb77d6578597f1febab36c54b2ee427c7a4a2
Gerrit-Change-Number: 11957
Gerrit-PatchSet: 6
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 


Change in osmo-bsc[master]: bsc: lchan_fsm: Fix invalid duplicated transition

2018-12-05 Thread Pau Espin Pedrol
Pau Espin Pedrol has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/11996 )

Change subject: bsc: lchan_fsm: Fix invalid duplicated transition
..

bsc: lchan_fsm: Fix invalid duplicated transition

When we enter WAIT_RLL_RTP_RELEASED
(lchan_fsm_wait_rll_rtp_released_onenter), we call lchan_do_release()
which in turn dispatches LCHAN_RTP_EV_RELEASE to lchan_rtp_fsm.c, which
will dispatch back an LCHAN_EV_RTP_RELEASED event, which will be handled
by lchan_fsm_wait_rll_rtp_released(), which will change state to
WAIT_BEFORE_RF_RELEASE. When going back the stack (return), we are still
in lchan_fsm_wait_rll_rtp_released_onenter() which again triggers a
change state to WAIT_BEFORE_RF_RELEASE because it checks same conditions
than first one.

20181128203727051 DCHAN osmo-bsc/lchan_fsm.c:1388 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]{ESTABLISHED}: lchan detaches from 
conn SUBSCR_CONN(conn3)[0x61202da0]
20181128203727051 DMSC osmo-bsc/lchan_fsm.c:1391 
SUBSCR_CONN(conn3)[0x61202da0]{CLEARING}: lchan 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0] detaches from conn
20181128203727051 DCHAN osmo-bsc/lchan_fsm.c:1359 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]{ESTABLISHED}: state_chg to 
WAIT_RLL_RTP_RELEASED
20181128203727052 DCHAN osmo-bsc/lchan_fsm.c:959 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]{WAIT_RLL_RTP_RELEASED}: (type=TCH_F) 
SAPI[0] = 1
20181128203727052 DRR osmo-bsc/gsm_04_08_rr.c:254 Sending Channel Release: 
Chan: Number: 0 Type: 2
20181128203727052 DCHAN osmo-bsc/lchan_fsm.c:945 
lchan_rtp(0-0-6-TCH_F_PDCH-0)[0x612027a0]{ESTABLISHED}: Received Event 
LCHAN_RTP_EV_RELEASE
20181128203727052 DCHAN osmo-bsc/lchan_rtp_fsm.c:572 
lchan_rtp(0-0-6-TCH_F_PDCH-0)[0x612027a0]{ESTABLISHED}: Terminating (cause 
= OSMO_FSM_TERM_REGULAR)
20181128203727052 DCHAN osmo-bsc/lchan_rtp_fsm.c:572 
lchan_rtp(0-0-6-TCH_F_PDCH-0)[0x612027a0]{ESTABLISHED}: Removing from 
parent lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]
20181128203727052 DCHAN osmo-bsc/lchan_rtp_fsm.c:572 
lchan_rtp(0-0-6-TCH_F_PDCH-0)[0x612027a0]{ESTABLISHED}: Freeing instance
20181128203727052 DCHAN fsm.c:381 
lchan_rtp(0-0-6-TCH_F_PDCH-0)[0x612027a0]{ESTABLISHED}: Deallocated
20181128203727052 DCHAN osmo-bsc/lchan_rtp_fsm.c:572 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]{WAIT_RLL_RTP_RELEASED}: Received 
Event LCHAN_EV_RTP_RELEASED
20181128203727052 DCHAN osmo-bsc/lchan_fsm.c:856 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]{WAIT_RLL_RTP_RELEASED}: (type=TCH_F) 
Still active SAPIs: 0
20181128203727052 DCHAN osmo-bsc/lchan_fsm.c:1011 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]{WAIT_RLL_RTP_RELEASED}: state_chg to 
WAIT_BEFORE_RF_RELEASE
20181128203727052 DRSL osmo-bsc/abis_rsl.c:633 (bts=0,trx=0,ts=6,ss=0) 
DEACTivate SACCH CMD
20181128203727052 DCHAN osmo-bsc/lchan_fsm.c:986 
lchan(0-0-6-TCH_F_PDCH-0)[0x612039a0]{WAIT_BEFORE_RF_RELEASE}: transition 
to state WAIT_BEFORE_RF_RELEASE not permitted!

Change-Id: I5d95bbd8244cc8e9c1cfb6fe0f76148332386a3d
---
M src/osmo-bsc/lchan_fsm.c
1 file changed, 4 insertions(+), 1 deletion(-)

Approvals:
  Neels Hofmeyr: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/osmo-bsc/lchan_fsm.c b/src/osmo-bsc/lchan_fsm.c
index 6b632d6..c873025 100644
--- a/src/osmo-bsc/lchan_fsm.c
+++ b/src/osmo-bsc/lchan_fsm.c
@@ -956,6 +956,9 @@
if (lchan->sapis[sapi])
LOG_LCHAN(lchan, LOGL_DEBUG, "SAPI[%d] = %d\n", sapi, 
lchan->sapis[sapi]);

+   /* It could be that we receive LCHAN_EV_RTP_RELEASED synchronously and
+  as a result we may end up in state WAIT_BEFORE_RF_RELEASE after
+  lchan_do_release has returned */
lchan_do_release(lchan);

sapis = 0;
@@ -980,7 +983,7 @@
sapis = 0;
}

-   if (!sapis && !lchan->fi_rtp)
+   if (!sapis && !lchan->fi_rtp && fi->state == 
LCHAN_ST_WAIT_RLL_RTP_RELEASED)
lchan_fsm_state_chg(LCHAN_ST_WAIT_BEFORE_RF_RELEASE);
 }


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

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I5d95bbd8244cc8e9c1cfb6fe0f76148332386a3d
Gerrit-Change-Number: 11996
Gerrit-PatchSet: 6
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Pau Espin Pedrol 


  1   2   3   >