Change in libusrp[master]: Avoid compiler warning 'dynamic exception specifications are deprecat...

2019-02-07 Thread Pau Espin Pedrol
Pau Espin Pedrol has posted comments on this change. ( 
https://gerrit.osmocom.org/12853 )

Change subject: Avoid compiler warning 'dynamic exception specifications are 
deprecated in C++11 [-Wdeprecated]'
..


Patch Set 1: Code-Review+2


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

Gerrit-Project: libusrp
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie472e6f92944cfe1af7d63cd644879573d080ca2
Gerrit-Change-Number: 12853
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Huemer 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: osmith 
Gerrit-Comment-Date: Thu, 07 Feb 2019 17:30:14 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-sysmon[master]: Add OpenVPN probe

2019-02-07 Thread Pau Espin Pedrol
Pau Espin Pedrol has posted comments on this change. ( 
https://gerrit.osmocom.org/12763 )

Change subject: Add OpenVPN probe
..


Patch Set 7: Code-Review-1

Some of my previous comments are not fixed despite being marked as "Done".


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

Gerrit-Project: osmo-sysmon
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4493e19b9a09dcebd289457eacd1719f7f8cc31c
Gerrit-Change-Number: 12763
Gerrit-PatchSet: 7
Gerrit-Owner: Max 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Thu, 07 Feb 2019 17:29:40 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-sysmon[master]: Add OpenVPN probe

2019-02-07 Thread Pau Espin Pedrol
Pau Espin Pedrol has posted comments on this change. ( 
https://gerrit.osmocom.org/12763 )

Change subject: Add OpenVPN probe
..


Patch Set 7:

(5 comments)

https://gerrit.osmocom.org/#/c/12763/7/src/osysmon_main.c
File src/osysmon_main.c:

https://gerrit.osmocom.org/#/c/12763/7/src/osysmon_main.c@252
PS7, Line 252:  sleep(1);
why not always polling osmocom event loop with a timeout of 1 second instead of 
instant polling + sleep?


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c
File src/osysmon_openvpn.c:

https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@263
PS5, Line 263:
> What makes you think that? It should be automatically cleaned by talloc on 
> vty refresh.
Why keeping it until then if it's not longer needed? Do we believe on garbage 
collectors now?


https://gerrit.osmocom.org/#/c/12763/7/src/osysmon_openvpn.c
File src/osysmon_openvpn.c:

https://gerrit.osmocom.org/#/c/12763/7/src/osysmon_openvpn.c@45
PS7, Line 45:   fprintf(stderr, "OpenVPN [%s]: " fmt, make_authority(ctx, 
vpn->cfg), ##args)
make_authority memleaks here, or at least unnecesarily delays  its free.


https://gerrit.osmocom.org/#/c/12763/7/src/osysmon_openvpn.c@67
PS7, Line 67:   uint8_t *m = msgb_data(msg);
would be clearer to cast here already if we know it's a string:
char *m = (char*) msgb_data(msg);

then you can remove the cast in line 80.


https://gerrit.osmocom.org/#/c/12763/7/src/osysmon_openvpn.c@104
PS7, Line 104: static struct openvpn_client *openvpn_client_find_or_make(const 
struct osysmon_state *os,
that's not making aything, its only finding.



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

Gerrit-Project: osmo-sysmon
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4493e19b9a09dcebd289457eacd1719f7f8cc31c
Gerrit-Change-Number: 12763
Gerrit-PatchSet: 7
Gerrit-Owner: Max 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Thu, 07 Feb 2019 17:29:06 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in osmo-sysmon[master]: Introduce generic host config and related helpers

2019-02-07 Thread Pau Espin Pedrol
Pau Espin Pedrol has posted comments on this change. ( 
https://gerrit.osmocom.org/12761 )

Change subject: Introduce generic host config and related helpers
..


Patch Set 6: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/#/c/12761/6/src/simple_ctrl.c
File src/simple_ctrl.c:

https://gerrit.osmocom.org/#/c/12761/6/src/simple_ctrl.c@42
PS6, Line 42:   fprintf(stderr, "CTRL %s error: " fmt, make_authority(sch, 
>cfg), ##args)
memleak of make_authority. At least until you free sch. I don't really like 
unnecesarily leaking stuff for a while for no good reason.

do {
foo = make_authority();
fprintf(... , foo);
talloc_free(foo);
} while(0);



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

Gerrit-Project: osmo-sysmon
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie321655a92cdbefbfaa056ac0d583397c83beccb
Gerrit-Change-Number: 12761
Gerrit-PatchSet: 6
Gerrit-Owner: Max 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Thu, 07 Feb 2019 17:19:37 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes


Change in osmo-sysmon[master]: Add OpenVPN probe

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12763 )

Change subject: Add OpenVPN probe
..


Patch Set 7:

(13 comments)

This change is ready for review.

https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c
File src/osysmon_openvpn.c:

https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@68
PS5, Line 68:
> get_authority memleak,
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@74
PS5, Line 74:   return NULL;
> get_authority memleak.
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@79
PS5, Line 79:
> if that's a string, then you can simply use osmo_strlcpy afaik.
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@82
PS5, Line 82:   for (tok = strtok(tmp, ","); tok && i < MAX_RESP_COMPONENTS; 
tok = strtok(NULL, ",")) {
> add missing {}, otherwise it's confusing. […]
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@83
PS5, Line 83:   /* The string format is documented in 
https://openvpn.net/community-resources/management-interface/ */
> if I understand correctly, first time switch is checked against i=0 (because 
> it's incremented afterw […]
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@127
PS5, Line 127: {
> (!msg)
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@134
PS5, Line 134:  }
> mem leak, get_authority allocates stuff. […]
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@149
PS5, Line 149:  struct openvpn_client *vpn = openvpn_client_find_or_make(os, 
host, port);
> that's weird from API point of view. […]
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@159
PS5, Line 159:  vpn->cfg = host_cfg_alloc(vpn, name, host, port);
> Instead of talloc_free + return false in lots of places, use a goto to end of 
> function.
Done


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@178
PS5, Line 178:  if (osmo_stream_cli_open(vpn->mgmt) < 0) {
> was this already fixed? otherwise please open a ticket and put the ticket 
> number in the commit for l […]
libosmo-netif patches are under review ATM


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@263
PS5, Line 263:
> possible memleak of remote later on, to be checked.
What makes you think that? It should be automatically cleaned by talloc on vty 
refresh.


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@267
PS5, Line 267:  osmo_stream_cli_send(vpn->mgmt, msg);
> Not sure what is this for.
Not what you're referring to:
- msgb_printf is to print stuff into msgb, documented in libosmocore
- osmo_stream_cli_send is to send msgb, documented in libosmo-netif


https://gerrit.osmocom.org/#/c/12763/5/src/osysmon_openvpn.c@287
PS5, Line 287:  struct value_node *vn_vpn = value_node_add(parent, 
"OpenVPN", NULL);
> No need to count, just check if the list is not empty.
Done



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

Gerrit-Project: osmo-sysmon
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4493e19b9a09dcebd289457eacd1719f7f8cc31c
Gerrit-Change-Number: 12763
Gerrit-PatchSet: 7
Gerrit-Owner: Max 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Thu, 07 Feb 2019 16:45:30 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in osmo-sysmon[master]: Introduce generic host config and related helpers

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12761 )

Change subject: Introduce generic host config and related helpers
..


Patch Set 6:

(6 comments)

This change is ready for review.

https://gerrit.osmocom.org/#/c/12761/5/contrib/jenkins.sh
File contrib/jenkins.sh:

https://gerrit.osmocom.org/#/c/12761/5/contrib/jenkins.sh@27
PS5, Line 27: 
> why is this line needed?
Done


https://gerrit.osmocom.org/#/c/12761/5/src/client.c
File src/client.c:

https://gerrit.osmocom.org/#/c/12761/5/src/client.c@34
PS5, Line 34: {
> can be simplified: #define MATCH(a, b) (strcmp(a,b) == 0) […]
Done


https://gerrit.osmocom.org/#/c/12761/5/src/client.c@38
PS5, Line 38:   switch (k) {
> separate lines please.
Done


https://gerrit.osmocom.org/#/c/12761/5/src/client.c@56
PS5, Line 56:   struct host_cfg *cfg = talloc_zero(ctx, struct host_cfg);
> This is basically a constructor/allocator, so better name it like we usually 
> do, like talloc_host_cf […]
Done


https://gerrit.osmocom.org/#/c/12761/5/src/client.c@79
PS5, Line 79:
> It's allocating something and the method is not const, so I'd better name it 
> "create_authority" or " […]
Done


https://gerrit.osmocom.org/#/c/12761/5/src/client.c@81
PS5, Line 81:
> Is this really needed?
Yes, it's easier to use it that way because it's used by both logging and 
polling code.



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

Gerrit-Project: osmo-sysmon
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie321655a92cdbefbfaa056ac0d583397c83beccb
Gerrit-Change-Number: 12761
Gerrit-PatchSet: 6
Gerrit-Owner: Max 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Comment-Date: Thu, 07 Feb 2019 16:41:15 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in libosmo-netif[master]: Stream client: report reconnection event as INFO

2019-02-07 Thread Max
Max has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12854 )

Change subject: Stream client: report reconnection event as INFO
..

Stream client: report reconnection event as INFO

This helps to avoid unnecessary debug output in reconnection logic tests
in follow-up patches.

Change-Id: Ic96430a9e9294e72de23b0bbacdbf3e99a453f1d
---
M src/stream.c
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/src/stream.c b/src/stream.c
index 7b97d2a..1880e25 100644
--- a/src/stream.c
+++ b/src/stream.c
@@ -172,11 +172,11 @@
osmo_stream_cli_close(cli);

if (cli->reconnect_timeout < 0) {
-   LOGSCLI(cli, LOGL_DEBUG, "not reconnecting, disabled.\n");
+   LOGSCLI(cli, LOGL_INFO, "not reconnecting, disabled.\n");
return;
}

-   LOGSCLI(cli, LOGL_DEBUG, "retrying in %d seconds...\n",
+   LOGSCLI(cli, LOGL_INFO, "retrying in %d seconds...\n",
cli->reconnect_timeout);
osmo_timer_schedule(>timer, cli->reconnect_timeout, 0);
cli->state = STREAM_CLI_STATE_CONNECTING;

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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ic96430a9e9294e72de23b0bbacdbf3e99a453f1d
Gerrit-Change-Number: 12854
Gerrit-PatchSet: 2
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: osmith 


Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/12625 )

Change subject: assignment_fsm: fix channel allocator preferences
..


Patch Set 8:

(1 comment)

https://gerrit.osmocom.org/#/c/12625/8/include/osmocom/bsc/gsm_data.h
File include/osmocom/bsc/gsm_data.h:

https://gerrit.osmocom.org/#/c/12625/8/include/osmocom/bsc/gsm_data.h@104
PS8, Line 104:  bool full_rate;
> We ignore the MS channel preference on purpose and do "late assignment" 
> instead. […]
I hope I understood this right, though. My reply above talks about Channel 
Request coming in from the MS.
I think you were instead referring to an Assignment Command from the MSC with 
GSM0808_CHAN_SIGN?
I think osmo-msc currently never sends Assignment Command with CHAN_SIGN, does 
it?? In what situations?



--
To view, visit https://gerrit.osmocom.org/12625
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: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-CC: tnt 
Gerrit-Comment-Date: Thu, 07 Feb 2019 16:20:32 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in osmo-ccid-firmware[master]: add README file

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12859 )

Change subject: add README file
..


Patch Set 1: Code-Review+2


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I9286493e4e2d20f00a33e7b565adde10198f179a
Gerrit-Change-Number: 12859
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Comment-Date: Thu, 07 Feb 2019 16:18:26 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ccid-firmware[master]: add GPLv2 license

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12858 )

Change subject: add GPLv2 license
..

add GPLv2 license

Change-Id: I761b3af3db43aa0da679c2f83aa89c92a7aae668
---
A sysmoOCTSIM/LICENSE
1 file changed, 488 insertions(+), 0 deletions(-)

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



diff --git a/sysmoOCTSIM/LICENSE b/sysmoOCTSIM/LICENSE
new file mode 100644
index 000..f15a3c0
--- /dev/null
+++ b/sysmoOCTSIM/LICENSE
@@ -0,0 +1,488 @@
+The sysmocom sysmoOCTSIM firmware is under the GPLv2 or later license.
+It uses the Microchip ASFv4 library under the ASF license.
+The CMSIS definitions are under the Apache-2.0 license
+The header of each file indicates under which license the corresponding source 
code is.
+You can find the complete text of the licenses below.
+
+= GPLv2
+
+GNU GENERAL PUBLIC LICENSE
+   Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users.  This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it.  (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.)  You can apply it to
+your programs, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+  To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+  For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have.  You must make sure that they, too, receive or can get the
+source code.  And you must show them these terms so they know their
+rights.
+
+  We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+  Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software.  If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+  Finally, any free program is threatened constantly by software
+patents.  We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary.  To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.
+
+GNU GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License.  The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language.  (Hereinafter, translation is included without limitation in
+the term "modification".)  Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true 

Change in osmo-ccid-firmware[master]: add GPLv2 license

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12858 )

Change subject: add GPLv2 license
..


Patch Set 1: Code-Review+2


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I761b3af3db43aa0da679c2f83aa89c92a7aae668
Gerrit-Change-Number: 12858
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Comment-Date: Thu, 07 Feb 2019 16:18:14 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ccid-firmware[master]: add README file

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12859 )

Change subject: add README file
..

add README file

Change-Id: I9286493e4e2d20f00a33e7b565adde10198f179a
---
A sysmoOCTSIM/README.md
1 file changed, 46 insertions(+), 0 deletions(-)

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



diff --git a/sysmoOCTSIM/README.md b/sysmoOCTSIM/README.md
new file mode 100644
index 000..1927255
--- /dev/null
+++ b/sysmoOCTSIM/README.md
@@ -0,0 +1,46 @@
+The sysmocom sysmoOCTSIM is a USB CCID device with eight smart card slots.
+This is the open source firmware for this device.
+
+Hardware
+
+
+The sysmocom sysmoOCTSIM hardware is proprietary.
+
+It has the following specifications:
+
+- 8 smart cards slots for 2FF cards (e.g. normal SIM format)
+- each slot is driven individually (e.g. they are not multiplexed)
+- each card can be operated in class A (5.0 V), B (3.0 V), or C (1.8 V)
+- the ISO/IEC 7816-4 T=0 communication protocol is used
+- each card can be clock up to 20 MHz (e.g. maximum allowed by the standard)
+
+For more detailed specification refer to the USB description of the device.
+
+Firmware
+
+
+Compiling
+-
+
+GNU make and the arm-none-eabi-gcc compiler are required to build the firmware.
+
+The compile the firmware, run the following commands:
+
+```
+cd sysmoOCTSIM/gcc
+make
+```
+
+The `sysmoOCTSIM/gcc/AtmelStart.bin` file is the resulting firmware for the 
device.
+
+Flashing
+
+
+The device comes pre-flash with a USB DFU bootloader (e.g. 
[osmo-asf4-dfu](https://git.osmocom.org/osmo-asf4-dfu/)).
+To start the USB DFU bootloader, press on the button on the front right of the 
panel while powering up the device.
+
+Use the [dfu-util](http://dfu-util.sourceforge.net/) utility to flash the 
firmware onto the device:
+
+```
+dfu-util --device 1d50:6141 --download sysmoOCTSIM/gcc/AtmelStart.bin
+```

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I9286493e4e2d20f00a33e7b565adde10198f179a
Gerrit-Change-Number: 12859
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: relocate application to after the DFU bootloader

2019-02-07 Thread Kévin Redon
Kévin Redon has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12813 )

Change subject: relocate application to after the DFU bootloader
..

relocate application to after the DFU bootloader

without this relocation the DFU bootloader can jump to the
application but following executed code would not be the one from
the application.

Change-Id: Ieeefcf80918fd10e48debab6ff08505f6588811c
---
M sysmoOCTSIM/gcc/Makefile
R sysmoOCTSIM/gcc/gcc/same54n19a_dfu.ld
D sysmoOCTSIM/gcc/gcc/same54p20a_sram.ld
3 files changed, 5 insertions(+), 167 deletions(-)

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



diff --git a/sysmoOCTSIM/gcc/Makefile b/sysmoOCTSIM/gcc/Makefile
index 7bc5fd3..572fb21 100644
--- a/sysmoOCTSIM/gcc/Makefile
+++ b/sysmoOCTSIM/gcc/Makefile
@@ -184,7 +184,7 @@
$(QUOTE)arm-none-eabi-gcc$(QUOTE) -o $(OUTPUT_FILE_NAME).elf 
$(OBJS_AS_ARGS) -Wl,--start-group -lm -Wl,--end-group -mthumb \
 -Wl,-Map="$(OUTPUT_FILE_NAME).map" --specs=nano.specs -Wl,--gc-sections 
-mcpu=cortex-m4 \
  \
--T"../gcc/gcc/same54n19a_flash.ld" \
+-T"../gcc/gcc/same54n19a_dfu.ld" \
 -L"../gcc/gcc"
@echo Finished building target: $@

diff --git a/sysmoOCTSIM/gcc/gcc/same54p20a_flash.ld 
b/sysmoOCTSIM/gcc/gcc/same54n19a_dfu.ld
similarity index 95%
rename from sysmoOCTSIM/gcc/gcc/same54p20a_flash.ld
rename to sysmoOCTSIM/gcc/gcc/same54n19a_dfu.ld
index 08099d2..7d76cc2 100644
--- a/sysmoOCTSIM/gcc/gcc/same54p20a_flash.ld
+++ b/sysmoOCTSIM/gcc/gcc/same54n19a_dfu.ld
@@ -1,7 +1,7 @@
 /**
  * \file
  *
- * \brief Linker script for running in internal FLASH on the SAME54P20A
+ * \brief Linker script for running in internal FLASH on the SAME54N19A
  *
  * Copyright (c) 2018 Microchip Technology Inc.
  *
@@ -35,14 +35,14 @@
 /* Memory Spaces Definitions */
 MEMORY
 {
-  rom  (rx)  : ORIGIN = 0x, LENGTH = 0x0010
-  ram  (rwx) : ORIGIN = 0x2000, LENGTH = 0x0004
+  rom  (rx)  : ORIGIN = 0x + 16K, LENGTH = 0x0008 - 16K
+  ram  (rwx) : ORIGIN = 0x2000, LENGTH = 0x0003
   bkupram  (rwx) : ORIGIN = 0x4700, LENGTH = 0x2000
   qspi (rwx) : ORIGIN = 0x0400, LENGTH = 0x0100
 }

 /* The stack size used by the application. NOTE: you need to adjust according 
to your application. */
-STACK_SIZE = DEFINED(STACK_SIZE) ? STACK_SIZE : DEFINED(__stack_size__) ? 
__stack_size__ : 0x1;
+STACK_SIZE = DEFINED(STACK_SIZE) ? STACK_SIZE : DEFINED(__stack_size__) ? 
__stack_size__ : 0xC000;

 /* Section Definitions */
 SECTIONS
diff --git a/sysmoOCTSIM/gcc/gcc/same54p20a_sram.ld 
b/sysmoOCTSIM/gcc/gcc/same54p20a_sram.ld
deleted file mode 100644
index b3be5b3..000
--- a/sysmoOCTSIM/gcc/gcc/same54p20a_sram.ld
+++ /dev/null
@@ -1,162 +0,0 @@
-/**
- * \file
- *
- * \brief Linker script for running in internal SRAM on the SAME54P20A
- *
- * Copyright (c) 2018 Microchip Technology Inc.
- *
- * \asf_license_start
- *
- * \page License
- *
- * SPDX-License-Identifier: Apache-2.0
- *
- * Licensed under the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the Licence at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an AS IS BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- * \asf_license_stop
- *
- */
-
-
-OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
-OUTPUT_ARCH(arm)
-SEARCH_DIR(.)
-
-/* Memory Spaces Definitions */
-MEMORY
-{
-  ram  (rwx) : ORIGIN = 0x2000, LENGTH = 0x0004
-  bkupram  (rwx) : ORIGIN = 0x4700, LENGTH = 0x2000
-  qspi (rwx) : ORIGIN = 0x0400, LENGTH = 0x0100
-}
-
-/* The stack size used by the application. NOTE: you need to adjust according 
to your application. */
-STACK_SIZE = DEFINED(STACK_SIZE) ? STACK_SIZE : DEFINED(__stack_size__) ? 
__stack_size__ : 0x1;
-
-/* Section Definitions */
-SECTIONS
-{
-.text :
-{
-. = ALIGN(4);
-_sfixed = .;
-KEEP(*(.vectors .vectors.*))
-*(.text .text.* .gnu.linkonce.t.*)
-*(.glue_7t) *(.glue_7)
-*(.rodata .rodata* .gnu.linkonce.r.*)
-*(.ARM.extab* .gnu.linkonce.armextab.*)
-
-/* Support C constructors, and C destructors in both user code
-   and the C library. This also provides support for C++ code. */
-. = ALIGN(4);
-KEEP(*(.init))
-. = ALIGN(4);
-__preinit_array_start = .;
-KEEP (*(.preinit_array))
-__preinit_array_end = .;
-
-. = ALIGN(4);
-__init_array_start = .;
-KEEP (*(SORT(.init_array.*)))
-KEEP 

Change in osmo-ccid-firmware[master]: add debug welcome message output

2019-02-07 Thread Kévin Redon
Kévin Redon has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12812 )

Change subject: add debug welcome message output
..

add debug welcome message output

Change-Id: I8dde644caa56152b17da674e187006726991ff9c
---
M sysmoOCTSIM/main.c
1 file changed, 2 insertions(+), 0 deletions(-)

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



diff --git a/sysmoOCTSIM/main.c b/sysmoOCTSIM/main.c
index f2584d2..d74153d 100644
--- a/sysmoOCTSIM/main.c
+++ b/sysmoOCTSIM/main.c
@@ -44,6 +44,8 @@

usb_start();

+   const char* welcome = "\r\n\r\nsysmocom sysmoOCTSIM\r\n";
+   while (io_write(_debug.io, (const uint8_t*)welcome, 
strlen(welcome)) != strlen(welcome)); // print welcome message
while (true) { // main loop
if (data_arrived) { // input on UART debug
data_arrived = false; // clear flag

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I8dde644caa56152b17da674e187006726991ff9c
Gerrit-Change-Number: 12812
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Kévin Redon 


Change in osmo-ccid-firmware[master]: name pin according to schematic

2019-02-07 Thread Kévin Redon
Kévin Redon has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12810 )

Change subject: name pin according to schematic
..

name pin according to schematic

Change-Id: I94a7f2216c288150b044a6190804f9b7247eb10c
---
M sysmoOCTSIM/atmel_start_config.atstart
M sysmoOCTSIM/atmel_start_pins.h
M sysmoOCTSIM/driver_init.c
M sysmoOCTSIM/main.c
4 files changed, 175 insertions(+), 7 deletions(-)

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



diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index 5c7cc2c..b6303f9 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -1030,6 +1030,46 @@
 configuration:
   usb_gclk_selection: Generic clock generator 1
 pads:
+  SIMCLK_20MHZ:
+name: PA11
+definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PA11
+mode: Advanced
+user_label: SIMCLK_20MHZ
+configuration:
+  pad_direction: Out
+  pad_function: M
+  pad_initial_level: Low
+  pad_pull_config: 'Off'
+  SWITCH:
+name: PC14
+definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PC14
+mode: Digital input
+user_label: SWITCH
+configuration: null
+  VB0:
+name: PA20
+definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PA20
+mode: Digital input
+user_label: VB0
+configuration: null
+  VB1:
+name: PA21
+definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PA21
+mode: Digital input
+user_label: VB1
+configuration: null
+  VB2:
+name: PA22
+definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PA22
+mode: Digital input
+user_label: VB2
+configuration: null
+  VB3:
+name: PA23
+definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PA23
+mode: Digital input
+user_label: VB3
+configuration: null
   USBUP_D_N:
 name: PA24
 definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PA24
@@ -1042,11 +1082,11 @@
 mode: Advanced
 user_label: USBUP_D_P
 configuration: null
-  LED_system:
+  USER_LED:
 name: PC26
 definition: Atmel:SAME54_Drivers:0.0.1::SAME54N19A-AF::pad::PC26
 mode: Digital output
-user_label: LED_system
+user_label: USER_LED
 configuration: null
   UART_TX:
 name: PB30
diff --git a/sysmoOCTSIM/atmel_start_pins.h b/sysmoOCTSIM/atmel_start_pins.h
index 884a562..fea4388 100644
--- a/sysmoOCTSIM/atmel_start_pins.h
+++ b/sysmoOCTSIM/atmel_start_pins.h
@@ -27,10 +27,16 @@
 #define GPIO_PIN_FUNCTION_M 12
 #define GPIO_PIN_FUNCTION_N 13

+#define SIMCLK_20MHZ GPIO(GPIO_PORTA, 11)
+#define VB0 GPIO(GPIO_PORTA, 20)
+#define VB1 GPIO(GPIO_PORTA, 21)
+#define VB2 GPIO(GPIO_PORTA, 22)
+#define VB3 GPIO(GPIO_PORTA, 23)
 #define USBUP_D_N GPIO(GPIO_PORTA, 24)
 #define USBUP_D_P GPIO(GPIO_PORTA, 25)
 #define UART_TX GPIO(GPIO_PORTB, 30)
 #define UART_RX GPIO(GPIO_PORTB, 31)
-#define LED_system GPIO(GPIO_PORTC, 26)
+#define SWITCH GPIO(GPIO_PORTC, 14)
+#define USER_LED GPIO(GPIO_PORTC, 26)

 #endif // ATMEL_START_PINS_H_INCLUDED
diff --git a/sysmoOCTSIM/driver_init.c b/sysmoOCTSIM/driver_init.c
index dea4ebc..4ab622f 100644
--- a/sysmoOCTSIM/driver_init.c
+++ b/sysmoOCTSIM/driver_init.c
@@ -176,9 +176,131 @@
 {
init_mcu();

+   // GPIO on PA11
+
+   gpio_set_pin_direction(SIMCLK_20MHZ,
+  //  Pin direction
+  //  pad_direction
+  //  Off
+  //  In
+  //  Out
+  GPIO_DIRECTION_OUT);
+
+   gpio_set_pin_level(SIMCLK_20MHZ,
+  //  Initial level
+  //  pad_initial_level
+  //  Low
+  //  High
+  false);
+
+   gpio_set_pin_pull_mode(SIMCLK_20MHZ,
+  //  Pull configuration
+  //  pad_pull_config
+  //  Off
+  //  Pull-up
+  //  Pull-down
+  GPIO_PULL_OFF);
+
+   gpio_set_pin_function(SIMCLK_20MHZ,
+ //  Pin function
+ //  pad_function
+ //  Auto : use driver pinmux if signal is 
imported by driver, else turn off function
+ //  Auto
+ //  Off
+ //  A
+ //  B
+ //  C
+ //  D
+ //  E
+ //  F
+ //  G
+ //  H
+ //  I
+   

Change in osmo-ccid-firmware[master]: echo back UART input

2019-02-07 Thread Kévin Redon
Kévin Redon has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12807 )

Change subject: echo back UART input
..

echo back UART input

let main run the main loop instead of the CDC ACM example.
also rename the CDC ACM example functions.

Change-Id: I44b15079672b4058de1fa08365541317d54958dc
---
M sysmoOCTSIM/main.c
M sysmoOCTSIM/usb_start.c
M sysmoOCTSIM/usb_start.h
3 files changed, 17 insertions(+), 17 deletions(-)

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



diff --git a/sysmoOCTSIM/main.c b/sysmoOCTSIM/main.c
index de954f4..dfe3b03 100644
--- a/sysmoOCTSIM/main.c
+++ b/sysmoOCTSIM/main.c
@@ -19,19 +19,19 @@
 #include "atmel_start.h"
 #include "atmel_start_pins.h"

-volatile static uint32_t data_arrived = 0;
+volatile static bool data_arrived = false;

 static void tx_cb_UART_debug(const struct usart_async_descriptor *const 
io_descr)
 {
/* Transfer completed */
-   gpio_toggle_pin_level(LED_system);
+   //gpio_toggle_pin_level(LED_system);
 }
 
 static void rx_cb_UART_debug(const struct usart_async_descriptor *const 
io_descr)
 {
/* Receive completed */
gpio_toggle_pin_level(LED_system);
-   data_arrived = 1;
+   data_arrived = true;
 }

 int main(void)
@@ -42,5 +42,15 @@
usart_async_register_callback(_debug, USART_ASYNC_RXC_CB, 
rx_cb_UART_debug);
usart_async_enable(_debug);

-   cdcd_acm_example();
+   usb_start();
+
+   while (true) { // main loop
+   if (data_arrived) { // input on UART debug
+   data_arrived = false; // clear flag
+   uint8_t recv_char; // to store the input
+   while (io_read(_debug.io, _char, 1) == 1) { 
// read input
+   while (io_write(_debug.io, _char, 1) 
!= 1); // echo back to output
+   }
+   }
+   }
 }
diff --git a/sysmoOCTSIM/usb_start.c b/sysmoOCTSIM/usb_start.c
index de86172..d02edc0 100644
--- a/sysmoOCTSIM/usb_start.c
+++ b/sysmoOCTSIM/usb_start.c
@@ -93,25 +93,15 @@
 }

 /**
- * Example of using CDC ACM Function.
- * \note
- * In this example, we will use a PC as a USB host:
- * - Connect the DEBUG USB on XPLAINED board to PC for program download.
- * - Connect the TARGET USB on XPLAINED board to PC for running program.
- * The application will behave as a virtual COM.
- * - Open a HyperTerminal or other COM tools in PC side.
- * - Send out a character or string and it will echo the content received.
+ * \brief Start USB stack
  */
-void cdcd_acm_example(void)
+void usb_start(void)
 {
while (!cdcdf_acm_is_enabled()) {
// wait cdc acm to be installed
};

cdcdf_acm_register_callback(CDCDF_ACM_CB_STATE_C, 
(FUNC_PTR)usb_device_cb_state_c);
-
-   while (1) {
-   }
 }

 void usb_init(void)
diff --git a/sysmoOCTSIM/usb_start.h b/sysmoOCTSIM/usb_start.h
index 48b2735..daf30cc 100644
--- a/sysmoOCTSIM/usb_start.h
+++ b/sysmoOCTSIM/usb_start.h
@@ -15,7 +15,7 @@
 #include "cdcdf_acm.h"
 #include "cdcdf_acm_desc.h"

-void cdcd_acm_example(void);
+void usb_start(void);
 void cdc_device_acm_init(void);

 /**

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I44b15079672b4058de1fa08365541317d54958dc
Gerrit-Change-Number: 12807
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Kévin Redon 


Change in osmo-ccid-firmware[master]: add 20 MHz clock output

2019-02-07 Thread Kévin Redon
Kévin Redon has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12809 )

Change subject: add 20 MHz clock output
..

add 20 MHz clock output

use GCLK5 to output 20 MHz clock on PA11/GCLK_IO[5] for SIM cards
clock.
this can be further divided by the NCN8025 before reaching the SIM.

Change-Id: I2c0d6a31ec63a87e04ef4e3afbedce3a221324cc
---
M sysmoOCTSIM/atmel_start_config.atstart
M sysmoOCTSIM/config/hpl_gclk_config.h
2 files changed, 10 insertions(+), 10 deletions(-)

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



diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index 09c0b2d..5c7cc2c 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -648,7 +648,7 @@
   enable_gclk_gen_2: true
   enable_gclk_gen_3: true
   enable_gclk_gen_4: false
-  enable_gclk_gen_5: false
+  enable_gclk_gen_5: true
   enable_gclk_gen_6: false
   enable_gclk_gen_7: false
   enable_gclk_gen_8: false
@@ -688,9 +688,9 @@
   gclk_arch_gen_4_oe: false
   gclk_arch_gen_4_oov: false
   gclk_arch_gen_4_runstdby: false
-  gclk_arch_gen_5_enable: false
+  gclk_arch_gen_5_enable: true
   gclk_arch_gen_5_idc: false
-  gclk_arch_gen_5_oe: false
+  gclk_arch_gen_5_oe: true
   gclk_arch_gen_5_oov: false
   gclk_arch_gen_5_runstdby: false
   gclk_arch_gen_6_enable: false
@@ -734,9 +734,9 @@
   gclk_gen_4_div: 1
   gclk_gen_4_div_sel: false
   gclk_gen_4_oscillator: External Crystal Oscillator 8-48MHz (XOSC1)
-  gclk_gen_5_div: 1
+  gclk_gen_5_div: 5
   gclk_gen_5_div_sel: false
-  gclk_gen_5_oscillator: External Crystal Oscillator 8-48MHz (XOSC1)
+  gclk_gen_5_oscillator: Digital Phase Locked Loop (DPLL1)
   gclk_gen_6_div: 1
   gclk_gen_6_div_sel: false
   gclk_gen_6_oscillator: External Crystal Oscillator 8-48MHz (XOSC1)
diff --git a/sysmoOCTSIM/config/hpl_gclk_config.h 
b/sysmoOCTSIM/config/hpl_gclk_config.h
index d16af6f..6b7586c 100644
--- a/sysmoOCTSIM/config/hpl_gclk_config.h
+++ b/sysmoOCTSIM/config/hpl_gclk_config.h
@@ -387,7 +387,7 @@
 //  Indicates whether generic clock 5 configuration is enabled or not
 //  enable_gclk_gen_5
 #ifndef CONF_GCLK_GENERATOR_5_CONFIG
-#define CONF_GCLK_GENERATOR_5_CONFIG 0
+#define CONF_GCLK_GENERATOR_5_CONFIG 1
 #endif

 //  Generic Clock Generator Control
@@ -404,7 +404,7 @@
 //  This defines the clock source for generic clock generator 5
 //  gclk_gen_5_oscillator
 #ifndef CONF_GCLK_GEN_5_SOURCE
-#define CONF_GCLK_GEN_5_SOURCE GCLK_GENCTRL_SRC_XOSC1
+#define CONF_GCLK_GEN_5_SOURCE GCLK_GENCTRL_SRC_DPLL1
 #endif

 //  Run in Standby
@@ -425,7 +425,7 @@
 //  Indicates whether Output Enable is enabled or not
 //  gclk_arch_gen_5_oe
 #ifndef CONF_GCLK_GEN_5_OE
-#define CONF_GCLK_GEN_5_OE 0
+#define CONF_GCLK_GEN_5_OE 1
 #endif

 //  Output Off Value
@@ -446,7 +446,7 @@
 //  Indicates whether Generic Clock Generator Enable is enabled or not
 //  gclk_arch_gen_5_enable
 #ifndef CONF_GCLK_GEN_5_GENEN
-#define CONF_GCLK_GEN_5_GENEN 0
+#define CONF_GCLK_GEN_5_GENEN 1
 #endif
 // 

@@ -454,7 +454,7 @@
 // Generic clock generator 5 division <0x-0x>
 //  gclk_gen_5_div
 #ifndef CONF_GCLK_GEN_5_DIV
-#define CONF_GCLK_GEN_5_DIV 1
+#define CONF_GCLK_GEN_5_DIV 5
 #endif
 // 
 // 

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I2c0d6a31ec63a87e04ef4e3afbedce3a221324cc
Gerrit-Change-Number: 12809
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Kévin Redon 


Change in osmo-ccid-firmware[master]: fix DPLL input clock division

2019-02-07 Thread Kévin Redon
Kévin Redon has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12806 )

Change subject: fix DPLL input clock division
..

fix DPLL input clock division

Change-Id: I3df1356d36b54d0cc34fd827265b1e4b9d55509f
---
M sysmoOCTSIM/config/hpl_oscctrl_config.h
1 file changed, 12 insertions(+), 4 deletions(-)

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



diff --git a/sysmoOCTSIM/config/hpl_oscctrl_config.h 
b/sysmoOCTSIM/config/hpl_oscctrl_config.h
index 0676cb5..17bcfc2 100644
--- a/sysmoOCTSIM/config/hpl_oscctrl_config.h
+++ b/sysmoOCTSIM/config/hpl_oscctrl_config.h
@@ -404,6 +404,7 @@
 //  Select the clock source.
 //  fdpll0_ref_clock
 #ifndef CONF_FDPLL0_GCLK
+// directly use XOSC1 as clock input (no need to use an additional GCLK)
 #define CONF_FDPLL0_GCLK GCLK_GENCTRL_SRC_XOSC1
 #endif

@@ -438,13 +439,15 @@
 //  Loop Divider Ratio Integer Part <0x0-0x1FFF>
 //  fdpll0_ldr
 #ifndef CONF_FDPLL0_LDR
-#define CONF_FDPLL0_LDR 0x3b
+// 2 MHz input clock * ( <59> + 1 = 60 ) = 120 MHz output clock
+#define CONF_FDPLL0_LDR 59
 #endif

 //  Clock Divider <0x0-0x7FF>
 //  fdpll0_clock_div
 #ifndef CONF_FDPLL0_DIV
-#define CONF_FDPLL0_DIV 0x6
+// XOSC1 = 12 MHz, divide by 2 * ( <2> + 1 ) = 6 to have a 2 MHz clock input 
(maximum is 3.4 MHz)
+#define CONF_FDPLL0_DIV 2
 #endif

 //  DCO Filter Enable
@@ -485,6 +488,7 @@
 // <0x3=>XOSC1 clock reference
 //  fdpll0_arch_refclk
 #ifndef CONF_FDPLL0_REFCLK
+// XOSC1 is used as input signal, thus also use it as reference
 #define CONF_FDPLL0_REFCLK 0x3
 #endif

@@ -529,6 +533,7 @@
 //  Select the clock source.
 //  fdpll1_ref_clock
 #ifndef CONF_FDPLL1_GCLK
+// directly use XOSC1 as clock input (no need to use an additional GCLK)
 #define CONF_FDPLL1_GCLK GCLK_GENCTRL_SRC_XOSC1
 #endif

@@ -563,13 +568,15 @@
 //  Loop Divider Ratio Integer Part <0x0-0x1FFF>
 //  fdpll1_ldr
 #ifndef CONF_FDPLL1_LDR
-#define CONF_FDPLL1_LDR 0x31
+// 2 MHz input clock * ( <49> + 1 = 50 ) = 100 MHz output clock
+#define CONF_FDPLL1_LDR 49
 #endif

 //  Clock Divider <0x0-0x7FF>
 //  fdpll1_clock_div
 #ifndef CONF_FDPLL1_DIV
-#define CONF_FDPLL1_DIV 0x6
+// XOSC1 = 12 MHz, divide by 2 * ( <2> + 1 ) = 6 to have a 2 MHz clock input 
(maximum is 3.4 MHz)
+#define CONF_FDPLL1_DIV 2
 #endif

 //  DCO Filter Enable
@@ -610,6 +617,7 @@
 // <0x3=>XOSC1 clock reference
 //  fdpll1_arch_refclk
 #ifndef CONF_FDPLL1_REFCLK
+// XOSC1 is used as input signal, thus also use it as reference
 #define CONF_FDPLL1_REFCLK 0x3
 #endif


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I3df1356d36b54d0cc34fd827265b1e4b9d55509f
Gerrit-Change-Number: 12806
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Kévin Redon 


Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/12625 )

Change subject: assignment_fsm: fix channel allocator preferences
..


Patch Set 8:

(1 comment)

https://gerrit.osmocom.org/#/c/12625/8/include/osmocom/bsc/gsm_data.h
File include/osmocom/bsc/gsm_data.h:

https://gerrit.osmocom.org/#/c/12625/8/include/osmocom/bsc/gsm_data.h@104
PS8, Line 104:  bool full_rate;
> Just wondering if it wouldn't be worth directly using GSM_LCHAN_xxx constant 
> in there rather than fu […]
We ignore the MS channel preference on purpose and do "late assignment" instead.
In osmo-nitb, we used to accept the TCH/F request from the MS and assign that,
while on the MT side the CN's preference would be stronger, which could end up 
TCH/H (for dyn TS).
Hence we would actively allow mismatching TCH kinds.
Now, we always look at the MSC preferences during TCH/* Assignment.
It is ok if we assign a TCH/F for SDCCH use at first, but it only really makes 
sense if there are no SDCCH left.
We now do that. Recently there have been fixes for that behavior.
So this channel_mode_and_rate is really only about TCH/F or TCH/H, no 
additional channel types should ever become relevant.

Even if BTS has only TCH/H pchan configured, an MS will ask for TCH, F 
preferred.
I'm not sure what's the benefit there, maybe that a phone already knows it is 
going to make a call
and attempts to pre-empt the need to re-assign from SDCCH to TCH?
It might make sense to revisit that once we properly support Channel Mode 
Modify commands and late RTP addition.
Even then, the choice for SDCCH or TCH will happen before this code path; this 
here is for voice assignment.



--
To view, visit https://gerrit.osmocom.org/12625
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: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-CC: tnt 
Gerrit-Comment-Date: Thu, 07 Feb 2019 16:05:41 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread Neels Hofmeyr
Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/12625 )

Change subject: assignment_fsm: fix channel allocator preferences
..


Patch Set 8: Code-Review-1

(2 comments)

developing a habit of removing +2 votes ... to make sure the comments are 
looked at first.

https://gerrit.osmocom.org/#/c/12625/8/src/osmo-bsc/osmo_bsc_bssap.c
File src/osmo-bsc/osmo_bsc_bssap.c:

https://gerrit.osmocom.org/#/c/12625/8/src/osmo-bsc/osmo_bsc_bssap.c@635
PS8, Line 635:  switch (ct->ch_rate_type & GSM0808_SPEECH_PERM) {
> Wait what ? GSM0808_SPEECH_PERM is not a mask, it's an actual possible value 
> of the field defined in […]
do you really need the mask at all?


https://gerrit.osmocom.org/#/c/12625/8/src/osmo-bsc/osmo_bsc_bssap.c@637
PS8, Line 637:  rc = match_codec_pref(>ch_mode_rate_pref, ct, 
>codec_list, msc, conn_get_bts(conn),
> Given this is used for speech, I'd use the GSM0808_SPEECH_xxx constants. […]
agree



--
To view, visit https://gerrit.osmocom.org/12625
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: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-CC: tnt 
Gerrit-Comment-Date: Thu, 07 Feb 2019 15:56:10 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes


Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread Neels Hofmeyr
Neels Hofmeyr has removed a vote on this change.

Change subject: assignment_fsm: fix channel allocator preferences
..


Removed Code-Review+2 by Harald Welte 
--
To view, visit https://gerrit.osmocom.org/12625
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: deleteVote
Gerrit-Change-Id: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-CC: tnt 


Change in osmo-ccid-firmware[master]: add README file

2019-02-07 Thread Kévin Redon
Kévin Redon has uploaded this change for review. ( 
https://gerrit.osmocom.org/12859


Change subject: add README file
..

add README file

Change-Id: I9286493e4e2d20f00a33e7b565adde10198f179a
---
A sysmoOCTSIM/README.md
1 file changed, 46 insertions(+), 0 deletions(-)



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

diff --git a/sysmoOCTSIM/README.md b/sysmoOCTSIM/README.md
new file mode 100644
index 000..1927255
--- /dev/null
+++ b/sysmoOCTSIM/README.md
@@ -0,0 +1,46 @@
+The sysmocom sysmoOCTSIM is a USB CCID device with eight smart card slots.
+This is the open source firmware for this device.
+
+Hardware
+
+
+The sysmocom sysmoOCTSIM hardware is proprietary.
+
+It has the following specifications:
+
+- 8 smart cards slots for 2FF cards (e.g. normal SIM format)
+- each slot is driven individually (e.g. they are not multiplexed)
+- each card can be operated in class A (5.0 V), B (3.0 V), or C (1.8 V)
+- the ISO/IEC 7816-4 T=0 communication protocol is used
+- each card can be clock up to 20 MHz (e.g. maximum allowed by the standard)
+
+For more detailed specification refer to the USB description of the device.
+
+Firmware
+
+
+Compiling
+-
+
+GNU make and the arm-none-eabi-gcc compiler are required to build the firmware.
+
+The compile the firmware, run the following commands:
+
+```
+cd sysmoOCTSIM/gcc
+make
+```
+
+The `sysmoOCTSIM/gcc/AtmelStart.bin` file is the resulting firmware for the 
device.
+
+Flashing
+
+
+The device comes pre-flash with a USB DFU bootloader (e.g. 
[osmo-asf4-dfu](https://git.osmocom.org/osmo-asf4-dfu/)).
+To start the USB DFU bootloader, press on the button on the front right of the 
panel while powering up the device.
+
+Use the [dfu-util](http://dfu-util.sourceforge.net/) utility to flash the 
firmware onto the device:
+
+```
+dfu-util --device 1d50:6141 --download sysmoOCTSIM/gcc/AtmelStart.bin
+```

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I9286493e4e2d20f00a33e7b565adde10198f179a
Gerrit-Change-Number: 12859
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 


Change in osmo-ccid-firmware[master]: add GPLv2 license

2019-02-07 Thread Kévin Redon
Kévin Redon has uploaded this change for review. ( 
https://gerrit.osmocom.org/12858


Change subject: add GPLv2 license
..

add GPLv2 license

Change-Id: I761b3af3db43aa0da679c2f83aa89c92a7aae668
---
A sysmoOCTSIM/LICENSE
1 file changed, 488 insertions(+), 0 deletions(-)



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

diff --git a/sysmoOCTSIM/LICENSE b/sysmoOCTSIM/LICENSE
new file mode 100644
index 000..f15a3c0
--- /dev/null
+++ b/sysmoOCTSIM/LICENSE
@@ -0,0 +1,488 @@
+The sysmocom sysmoOCTSIM firmware is under the GPLv2 or later license.
+It uses the Microchip ASFv4 library under the ASF license.
+The CMSIS definitions are under the Apache-2.0 license
+The header of each file indicates under which license the corresponding source 
code is.
+You can find the complete text of the licenses below.
+
+= GPLv2
+
+GNU GENERAL PUBLIC LICENSE
+   Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users.  This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it.  (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.)  You can apply it to
+your programs, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+  To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+  For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have.  You must make sure that they, too, receive or can get the
+source code.  And you must show them these terms so they know their
+rights.
+
+  We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+  Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software.  If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+  Finally, any free program is threatened constantly by software
+patents.  We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary.  To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.
+
+GNU GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License.  The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language.  (Hereinafter, translation is included without limitation in
+the term "modification".)  Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true 

Change in libosmo-netif[master]: Stream client: report reconnection event as INFO

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12854 )

Change subject: Stream client: report reconnection event as INFO
..


Patch Set 2: Code-Review+2


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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic96430a9e9294e72de23b0bbacdbf3e99a453f1d
Gerrit-Change-Number: 12854
Gerrit-PatchSet: 2
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: osmith 
Gerrit-Comment-Date: Thu, 07 Feb 2019 15:29:44 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ccid-firmware[master]: blink LED on UART activity

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12805 )

Change subject: blink LED on UART activity
..

blink LED on UART activity

Change-Id: Ib230be6003f28931ab4c60228796ec0af6c783d9
---
M sysmoOCTSIM/main.c
1 file changed, 36 insertions(+), 34 deletions(-)

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



diff --git a/sysmoOCTSIM/main.c b/sysmoOCTSIM/main.c
index fe02810..de954f4 100644
--- a/sysmoOCTSIM/main.c
+++ b/sysmoOCTSIM/main.c
@@ -1,44 +1,46 @@
-/**
- * \file
- *
- * \brief Application implement
- *
- * Copyright (c) 2015-2018 Microchip Technology Inc. and its subsidiaries.
- *
- * \asf_license_start
- *
- * \page License
- *
- * Subject to your compliance with these terms, you may use Microchip
- * software and any derivatives exclusively with Microchip products.
- * It is your responsibility to comply with third party license terms 
applicable
- * to your use of third party software (including open source software) that
- * may accompany Microchip software.
- *
- * THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS".  NO WARRANTIES,
- * WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,
- * INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,
- * AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE
- * LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL
- * LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE
- * SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE
- * POSSIBILITY OR THE DAMAGES ARE FORESEEABLE.  TO THE FULLEST EXTENT
- * ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY
- * RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,
- * THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.
- *
- * \asf_license_stop
- *
- */
 /*
- * Support and FAQ: visit https://www.microchip.com/support/;>Microchip Support
- */
+ * Copyright (C) 2019 sysmocom -s.f.m.c. GmbH, Author: Kevin Redon 

+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, 
USA.
+*/

 #include "atmel_start.h"
 #include "atmel_start_pins.h"

+volatile static uint32_t data_arrived = 0;
+
+static void tx_cb_UART_debug(const struct usart_async_descriptor *const 
io_descr)
+{
+   /* Transfer completed */
+   gpio_toggle_pin_level(LED_system);
+}
+
+static void rx_cb_UART_debug(const struct usart_async_descriptor *const 
io_descr)
+{
+   /* Receive completed */
+   gpio_toggle_pin_level(LED_system);
+   data_arrived = 1;
+}
+
 int main(void)
 {
atmel_start_init();
+
+   usart_async_register_callback(_debug, USART_ASYNC_TXC_CB, 
tx_cb_UART_debug);
+   usart_async_register_callback(_debug, USART_ASYNC_RXC_CB, 
rx_cb_UART_debug);
+   usart_async_enable(_debug);
+
cdcd_acm_example();
 }

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib230be6003f28931ab4c60228796ec0af6c783d9
Gerrit-Change-Number: 12805
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: blink LED on UART activity

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12805 )

Change subject: blink LED on UART activity
..


Patch Set 2: Code-Review+2


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ib230be6003f28931ab4c60228796ec0af6c783d9
Gerrit-Change-Number: 12805
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Comment-Date: Thu, 07 Feb 2019 15:29:07 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ccid-firmware[master]: set DPLL1 to 100 MHz

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12799 )

Change subject: set DPLL1 to 100 MHz
..

set DPLL1 to 100 MHz

use GCLK11 to bring external crystal oscillator XOSC1 from 12 MHz
to 2MHz
use DPLL1 to multiply 2 MHz to 100 MHz.
the division is first needed because the DPLL0 maximum input
frequency is 3.2 MHz
100 MHz is the maximum input frequency for the SERCOM peripherals

Change-Id: I0482c39cc0db04c585d21738dbce57ca3b55
---
M sysmoOCTSIM/atmel_start_config.atstart
M sysmoOCTSIM/config/hpl_gclk_config.h
M sysmoOCTSIM/config/hpl_oscctrl_config.h
M sysmoOCTSIM/hpl/core/hpl_init.c
4 files changed, 22 insertions(+), 21 deletions(-)

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



diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index 5e27536..3899d79 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -647,7 +647,7 @@
   enable_gclk_gen_1: true
   enable_gclk_gen_10: false
   enable_gclk_gen_11: true
-  enable_gclk_gen_2: false
+  enable_gclk_gen_2: true
   enable_gclk_gen_3: true
   enable_gclk_gen_4: false
   enable_gclk_gen_5: false
@@ -675,7 +675,7 @@
   gclk_arch_gen_1_oe: false
   gclk_arch_gen_1_oov: false
   gclk_arch_gen_1_runstdby: false
-  gclk_arch_gen_2_enable: false
+  gclk_arch_gen_2_enable: true
   gclk_arch_gen_2_idc: false
   gclk_arch_gen_2_oe: false
   gclk_arch_gen_2_oov: false
@@ -728,8 +728,8 @@
   gclk_gen_1_div_sel: false
   gclk_gen_1_oscillator: Digital Frequency Locked Loop (DFLL48M)
   gclk_gen_2_div: 1
-  gclk_gen_2_div_sel: true
-  gclk_gen_2_oscillator: External Crystal Oscillator 8-48MHz (XOSC0)
+  gclk_gen_2_div_sel: false
+  gclk_gen_2_oscillator: Digital Phase Locked Loop (DPLL1)
   gclk_gen_3_div: 1
   gclk_gen_3_div_sel: false
   gclk_gen_3_oscillator: 32kHz External Crystal Oscillator (XOSC32K)
@@ -830,7 +830,7 @@
   dfll_ref_clock: Generic clock generator 3
   enable_dfll: true
   enable_fdpll0: true
-  enable_fdpll1: false
+  enable_fdpll1: true
   enable_xosc0: false
   enable_xosc1: true
   fdpll0_arch_dcoen: false
@@ -848,19 +848,19 @@
   fdpll0_ldrfrac: 0
   fdpll0_ref_clock: Generic clock generator 11
   fdpll1_arch_dcoen: false
-  fdpll1_arch_enable: false
+  fdpll1_arch_enable: true
   fdpll1_arch_filter: 0
   fdpll1_arch_lbypass: false
   fdpll1_arch_ltime: No time-out, automatic lock
   fdpll1_arch_ondemand: false
-  fdpll1_arch_refclk: XOSC32K clock reference
+  fdpll1_arch_refclk: XOSC1 clock reference
   fdpll1_arch_runstdby: false
   fdpll1_arch_wuf: false
   fdpll1_clock_dcofilter: 0
-  fdpll1_clock_div: 0
-  fdpll1_ldr: 1463
-  fdpll1_ldrfrac: 13
-  fdpll1_ref_clock: 32kHz External Crystal Oscillator (XOSC32K)
+  fdpll1_clock_div: 6
+  fdpll1_ldr: 49
+  fdpll1_ldrfrac: 0
+  fdpll1_ref_clock: Generic clock generator 11
   xosc0_arch_cfden: false
   xosc0_arch_enable: false
   xosc0_arch_enalc: false
diff --git a/sysmoOCTSIM/config/hpl_gclk_config.h 
b/sysmoOCTSIM/config/hpl_gclk_config.h
index fbaa9b7..398a617 100644
--- a/sysmoOCTSIM/config/hpl_gclk_config.h
+++ b/sysmoOCTSIM/config/hpl_gclk_config.h
@@ -159,7 +159,7 @@
 //  Indicates whether generic clock 2 configuration is enabled or not
 //  enable_gclk_gen_2
 #ifndef CONF_GCLK_GENERATOR_2_CONFIG
-#define CONF_GCLK_GENERATOR_2_CONFIG 0
+#define CONF_GCLK_GENERATOR_2_CONFIG 1
 #endif

 //  Generic Clock Generator Control
@@ -176,7 +176,7 @@
 //  This defines the clock source for generic clock generator 2
 //  gclk_gen_2_oscillator
 #ifndef CONF_GCLK_GEN_2_SOURCE
-#define CONF_GCLK_GEN_2_SOURCE GCLK_GENCTRL_SRC_XOSC0
+#define CONF_GCLK_GEN_2_SOURCE GCLK_GENCTRL_SRC_DPLL1
 #endif

 //  Run in Standby
@@ -190,7 +190,7 @@
 //  Indicates whether Divide Selection is enabled or not
 // gclk_gen_2_div_sel
 #ifndef CONF_GCLK_GEN_2_DIVSEL
-#define CONF_GCLK_GEN_2_DIVSEL 1
+#define CONF_GCLK_GEN_2_DIVSEL 0
 #endif

 //  Output Enable
@@ -218,7 +218,7 @@
 //  Indicates whether Generic Clock Generator Enable is enabled or not
 //  gclk_arch_gen_2_enable
 #ifndef CONF_GCLK_GEN_2_GENEN
-#define CONF_GCLK_GEN_2_GENEN 0
+#define CONF_GCLK_GEN_2_GENEN 1
 #endif
 // 

diff --git a/sysmoOCTSIM/config/hpl_oscctrl_config.h 
b/sysmoOCTSIM/config/hpl_oscctrl_config.h
index 6b3cc19..06ee571 100644
--- a/sysmoOCTSIM/config/hpl_oscctrl_config.h
+++ b/sysmoOCTSIM/config/hpl_oscctrl_config.h
@@ -529,7 +529,7 @@
 //  Select the clock source.
 //  fdpll1_ref_clock
 #ifndef CONF_FDPLL1_GCLK
-#define CONF_FDPLL1_GCLK GCLK_GENCTRL_SRC_XOSC32K
+#define CONF_FDPLL1_GCLK GCLK_PCHCTRL_GEN_GCLK11_Val
 #endif

 //  Digital Phase Locked Loop Control
@@ -537,7 +537,7 

Change in osmo-ccid-firmware[master]: change USB description to sysmoOCTSIM

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12794 )

Change subject: change USB description to sysmoOCTSIM
..

change USB description to sysmoOCTSIM

Change-Id: I1f9819df5b4737a9a6dfa69c918d05c60ec5f86a
---
M sysmoOCTSIM/atmel_start_config.atstart
M sysmoOCTSIM/config/usbd_config.h
2 files changed, 20 insertions(+), 17 deletions(-)

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



diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index 8a87ba2..f3620ee 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -68,16 +68,16 @@
   usb_cdcd_acm_epaddr: EndpointAddress = 0x82
   usb_cdcd_acm_iconfig_en: false
   usb_cdcd_acm_iconfig_str: ''
-  usb_cdcd_acm_idproduct: 9220
-  usb_cdcd_acm_idvender: 1003
-  usb_cdcd_acm_imanufact_en: false
-  usb_cdcd_acm_imanufact_str: Atmel
-  usb_cdcd_acm_iproduct_en: false
-  usb_cdcd_acm_iproduct_str: CDC ACM Serial Bridge Demo
+  usb_cdcd_acm_idproduct: 24897
+  usb_cdcd_acm_idvender: 7504
+  usb_cdcd_acm_imanufact_en: true
+  usb_cdcd_acm_imanufact_str: sysmocom
+  usb_cdcd_acm_iproduct_en: true
+  usb_cdcd_acm_iproduct_str: sysmoOCTSIM
   usb_cdcd_acm_iserialnum_en: false
   usb_cdcd_acm_iserialnum_str: 123456789ABCDEF
   usb_cdcd_acm_langid: '0x0409'
-  usb_cdcd_acm_str_en: false
+  usb_cdcd_acm_str_en: true
 definition: Atmel:USB:0.0.1::USB_Device_CDC_ACM
 functionality: USB_Device_CDC_ACM
 api: USB:Device:CDC_ACM
diff --git a/sysmoOCTSIM/config/usbd_config.h b/sysmoOCTSIM/config/usbd_config.h
index e8334ec..0be4363 100644
--- a/sysmoOCTSIM/config/usbd_config.h
+++ b/sysmoOCTSIM/config/usbd_config.h
@@ -19,7 +19,7 @@
 //  Enable String Descriptors
 //  usb_cdcd_acm_str_en
 #ifndef CONF_USB_CDCD_ACM_STR_EN
-#define CONF_USB_CDCD_ACM_STR_EN 0
+#define CONF_USB_CDCD_ACM_STR_EN 1
 #endif
 //  Language IDs
 //  Language IDs in c format, split by comma (E.g., 0x0409 ...)
@@ -29,7 +29,7 @@
 #endif

 #ifndef CONF_USB_CDCD_ACM_LANGID_DESC
-#define CONF_USB_CDCD_ACM_LANGID_DESC
+#define CONF_USB_CDCD_ACM_LANGID_DESC 4, 0x03, 0x09, 0x04,
 #endif
 // 

@@ -56,13 +56,13 @@
 //  idVender <0x-0x>
 //  usb_cdcd_acm_idvender
 #ifndef CONF_USB_CDCD_ACM_IDVENDER
-#define CONF_USB_CDCD_ACM_IDVENDER 0x3eb
+#define CONF_USB_CDCD_ACM_IDVENDER 0x1d50
 #endif

 //  idProduct <0x-0x>
 //  usb_cdcd_acm_idproduct
 #ifndef CONF_USB_CDCD_ACM_IDPRODUCT
-#define CONF_USB_CDCD_ACM_IDPRODUCT 0x2404
+#define CONF_USB_CDCD_ACM_IDPRODUCT 0x6141
 #endif

 //  bcdDevice <0x-0x>
@@ -74,7 +74,7 @@
 //  Enable string descriptor of iManufact
 //  usb_cdcd_acm_imanufact_en
 #ifndef CONF_USB_CDCD_ACM_IMANUFACT_EN
-#define CONF_USB_CDCD_ACM_IMANUFACT_EN 0
+#define CONF_USB_CDCD_ACM_IMANUFACT_EN 1
 #endif

 #ifndef CONF_USB_CDCD_ACM_IMANUFACT
@@ -84,11 +84,12 @@
 //  Unicode string of iManufact
 //  usb_cdcd_acm_imanufact_str
 #ifndef CONF_USB_CDCD_ACM_IMANUFACT_STR
-#define CONF_USB_CDCD_ACM_IMANUFACT_STR "Atmel"
+#define CONF_USB_CDCD_ACM_IMANUFACT_STR "sysmocom"
 #endif

 #ifndef CONF_USB_CDCD_ACM_IMANUFACT_STR_DESC
-#define CONF_USB_CDCD_ACM_IMANUFACT_STR_DESC
+#define CONF_USB_CDCD_ACM_IMANUFACT_STR_DESC   
\
+   18, 0x03, 's', 0x00, 'y', 0x00, 's', 0x00, 'm', 0x00, 'o', 0x00, 'c', 
0x00, 'o', 0x00, 'm', 0x00,
 #endif

 // 
@@ -96,7 +97,7 @@
 //  Enable string descriptor of iProduct
 //  usb_cdcd_acm_iproduct_en
 #ifndef CONF_USB_CDCD_ACM_IPRODUCT_EN
-#define CONF_USB_CDCD_ACM_IPRODUCT_EN 0
+#define CONF_USB_CDCD_ACM_IPRODUCT_EN 1
 #endif

 #ifndef CONF_USB_CDCD_ACM_IPRODUCT
@@ -107,11 +108,13 @@
 //  Unicode string of iProduct
 //  usb_cdcd_acm_iproduct_str
 #ifndef CONF_USB_CDCD_ACM_IPRODUCT_STR
-#define CONF_USB_CDCD_ACM_IPRODUCT_STR "CDC ACM Serial Bridge Demo"
+#define CONF_USB_CDCD_ACM_IPRODUCT_STR "sysmoOCTSIM"
 #endif

 #ifndef CONF_USB_CDCD_ACM_IPRODUCT_STR_DESC
-#define CONF_USB_CDCD_ACM_IPRODUCT_STR_DESC
+#define CONF_USB_CDCD_ACM_IPRODUCT_STR_DESC
\
+   24, 0x03, 's', 0x00, 'y', 0x00, 's', 0x00, 'm', 0x00, 'o', 0x00, 'O', 
0x00, 'C', 0x00, 'T', 0x00, 'S', 0x00, 'I',  \
+   0x00, 'M', 0x00,
 #endif

 // 

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I1f9819df5b4737a9a6dfa69c918d05c60ec5f86a
Gerrit-Change-Number: 12794
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: use XOSC1 directly for DPLL1

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12800 )

Change subject: use XOSC1 directly for DPLL1
..

use XOSC1 directly for DPLL1

DPLL1 can take directly XOSC1 as input and divide it to 2 MHz.
thus the intermediate GCLK11 is not needed.
we now also completely de-configure GCLK11
this configuration is not supported by Atmel START since it does
not know about the division and thinks the input frequency
exceeds the maximum
GCLK2 is also disabled for now because it is not used

Change-Id: Icee7f5a13019c47cebc23376cabb18cb31178ece
---
M sysmoOCTSIM/config/hpl_gclk_config.h
M sysmoOCTSIM/config/hpl_oscctrl_config.h
2 files changed, 4 insertions(+), 4 deletions(-)

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



diff --git a/sysmoOCTSIM/config/hpl_gclk_config.h 
b/sysmoOCTSIM/config/hpl_gclk_config.h
index 398a617..0ad8ead 100644
--- a/sysmoOCTSIM/config/hpl_gclk_config.h
+++ b/sysmoOCTSIM/config/hpl_gclk_config.h
@@ -218,7 +218,7 @@
 //  Indicates whether Generic Clock Generator Enable is enabled or not
 //  gclk_arch_gen_2_enable
 #ifndef CONF_GCLK_GEN_2_GENEN
-#define CONF_GCLK_GEN_2_GENEN 1
+#define CONF_GCLK_GEN_2_GENEN 0
 #endif
 // 

@@ -843,7 +843,7 @@
 //  Indicates whether generic clock 11 configuration is enabled or not
 //  enable_gclk_gen_11
 #ifndef CONF_GCLK_GENERATOR_11_CONFIG
-#define CONF_GCLK_GENERATOR_11_CONFIG 1
+#define CONF_GCLK_GENERATOR_11_CONFIG 0
 #endif

 //  Generic Clock Generator Control
diff --git a/sysmoOCTSIM/config/hpl_oscctrl_config.h 
b/sysmoOCTSIM/config/hpl_oscctrl_config.h
index 06ee571..0676cb5 100644
--- a/sysmoOCTSIM/config/hpl_oscctrl_config.h
+++ b/sysmoOCTSIM/config/hpl_oscctrl_config.h
@@ -507,7 +507,7 @@
 //  Indicates whether configuration for FDPLL1 is enabled or not
 //  enable_fdpll1
 #ifndef CONF_FDPLL1_CONFIG
-#define CONF_FDPLL1_CONFIG 0
+#define CONF_FDPLL1_CONFIG 1
 #endif

 //  Reference Clock Source
@@ -529,7 +529,7 @@
 //  Select the clock source.
 //  fdpll1_ref_clock
 #ifndef CONF_FDPLL1_GCLK
-#define CONF_FDPLL1_GCLK GCLK_PCHCTRL_GEN_GCLK11_Val
+#define CONF_FDPLL1_GCLK GCLK_GENCTRL_SRC_XOSC1
 #endif

 //  Digital Phase Locked Loop Control

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Icee7f5a13019c47cebc23376cabb18cb31178ece
Gerrit-Change-Number: 12800
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: remove usage of GCLK11

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12798 )

Change subject: remove usage of GCLK11
..

remove usage of GCLK11

DPLL0 can take directly XOSC1 as input and divide it to 2 MHz.
thus the intermediate GCLK11 is not needed.
this configuration is not supported by Atmel START since it does
not know about the division and thinks the input frequency
exceeds the maximum

Change-Id: I121ad850cf118b641fe522b513ffd7e00b30b710
---
M sysmoOCTSIM/config/hpl_gclk_config.h
M sysmoOCTSIM/config/hpl_oscctrl_config.h
2 files changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/sysmoOCTSIM/config/hpl_gclk_config.h 
b/sysmoOCTSIM/config/hpl_gclk_config.h
index 8d10f38..fbaa9b7 100644
--- a/sysmoOCTSIM/config/hpl_gclk_config.h
+++ b/sysmoOCTSIM/config/hpl_gclk_config.h
@@ -902,7 +902,7 @@
 //  Indicates whether Generic Clock Generator Enable is enabled or not
 //  gclk_arch_gen_11_enable
 #ifndef CONF_GCLK_GEN_11_GENEN
-#define CONF_GCLK_GEN_11_GENEN 1
+#define CONF_GCLK_GEN_11_GENEN 0
 #endif
 // 

diff --git a/sysmoOCTSIM/config/hpl_oscctrl_config.h 
b/sysmoOCTSIM/config/hpl_oscctrl_config.h
index d59ac43..6b3cc19 100644
--- a/sysmoOCTSIM/config/hpl_oscctrl_config.h
+++ b/sysmoOCTSIM/config/hpl_oscctrl_config.h
@@ -404,7 +404,7 @@
 //  Select the clock source.
 //  fdpll0_ref_clock
 #ifndef CONF_FDPLL0_GCLK
-#define CONF_FDPLL0_GCLK GCLK_PCHCTRL_GEN_GCLK11_Val
+#define CONF_FDPLL0_GCLK GCLK_GENCTRL_SRC_XOSC1
 #endif

 //  Digital Phase Locked Loop Control

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I121ad850cf118b641fe522b513ffd7e00b30b710
Gerrit-Change-Number: 12798
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: add system LED definition

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12804 )

Change subject: add system LED definition
..

add system LED definition

Change-Id: I97dc71ac00b64fdd05e0ff4c7e16e1b68b57b695
---
M sysmoOCTSIM/atmel_start_config.atstart
M sysmoOCTSIM/atmel_start_pins.h
M sysmoOCTSIM/driver_init.c
3 files changed, 22 insertions(+), 0 deletions(-)

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



diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index af87e97..7492bf6 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -1044,6 +1044,13 @@
 configuration:
   usb_gclk_selection: Generic clock generator 1
 pads:
+  LED_system:
+name: PC18
+definition: Atmel:SAME54_Drivers:0.0.1::SAME54P20A-AU::pad::PC18
+mode: Digital output
+user_label: LED_system
+configuration:
+  pad_initial_level: High
   PA24:
 name: PA24
 definition: Atmel:SAME54_Drivers:0.0.1::SAME54P20A-AU::pad::PA24
diff --git a/sysmoOCTSIM/atmel_start_pins.h b/sysmoOCTSIM/atmel_start_pins.h
index 3631847..7c774ed 100644
--- a/sysmoOCTSIM/atmel_start_pins.h
+++ b/sysmoOCTSIM/atmel_start_pins.h
@@ -31,5 +31,6 @@
 #define PA25 GPIO(GPIO_PORTA, 25)
 #define PB24 GPIO(GPIO_PORTB, 24)
 #define PB25 GPIO(GPIO_PORTB, 25)
+#define LED_system GPIO(GPIO_PORTC, 18)

 #endif // ATMEL_START_PINS_H_INCLUDED
diff --git a/sysmoOCTSIM/driver_init.c b/sysmoOCTSIM/driver_init.c
index efd24bc..9fbc7ed 100644
--- a/sysmoOCTSIM/driver_init.c
+++ b/sysmoOCTSIM/driver_init.c
@@ -176,6 +176,20 @@
 {
init_mcu();

+   // GPIO on PC18
+
+   gpio_set_pin_level(LED_system,
+  //  Initial level
+  //  pad_initial_level
+  //  Low
+  //  High
+  true);
+
+   // Set pin direction to output
+   gpio_set_pin_direction(LED_system, GPIO_DIRECTION_OUT);
+
+   gpio_set_pin_function(LED_system, GPIO_PIN_FUNCTION_OFF);
+
UART_debug_init();

USB_DEVICE_INSTANCE_init();

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I97dc71ac00b64fdd05e0ff4c7e16e1b68b57b695
Gerrit-Change-Number: 12804
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: rename application to main

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12802 )

Change subject: rename application to main
..

rename application to main

also remove unused armcc.
only the GCC cross-compiler is used.
the ARMCC Makefile would not be maintained.

Change-Id: Ib6ec525885943afba9b24df88a5bee8009df95b5
---
D sysmoOCTSIM/armcc/Makefile
D sysmoOCTSIM/armcc/arm_addon/armcc/arm/startup_same54.s
D sysmoOCTSIM/armcc/arm_addon/armcc/system_same54.c
M sysmoOCTSIM/gcc/Makefile
R sysmoOCTSIM/main.c
5 files changed, 4 insertions(+), 895 deletions(-)

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



diff --git a/sysmoOCTSIM/armcc/Makefile b/sysmoOCTSIM/armcc/Makefile
deleted file mode 100644
index 3a130a8..000
--- a/sysmoOCTSIM/armcc/Makefile
+++ /dev/null
@@ -1,233 +0,0 @@
-
-
-# Automatically-generated file. Do not edit!
-
-
-ifdef SystemRoot
-   SHELL = cmd.exe
-   MK_DIR = mkdir
-else
-   ifeq ($(shell uname), Linux)
-   MK_DIR = mkdir -p
-   endif
-
-   ifeq ($(shell uname | cut -d _ -f 1), CYGWIN)
-   MK_DIR = mkdir -p
-   endif
-
-   ifeq ($(shell uname | cut -d _ -f 1), MINGW32)
-   MK_DIR = mkdir -p
-   endif
-
-   ifeq ($(shell uname | cut -d _ -f 1), MINGW64)
-   MK_DIR = mkdir -p
-   endif
-endif
-
-# List the subdirectories for creating object files
-SUB_DIRS +=  \
- \
-hpl/pm \
-hpl/osc32kctrl \
-hpl/ramecc \
-hpl/dmac \
-usb/class/cdc/device \
-hal/src \
-hpl/mclk \
-usb \
-armcc/arm_addon/armcc/arm \
-hal/utils/src \
-hpl/sercom \
-examples \
-hpl/gclk \
-usb/device \
-hpl/oscctrl \
-armcc/arm_addon/armcc \
-hpl/usb \
-hpl/core \
-hpl/cmcc
-
-# List the object files
-OBJS +=  \
-hal/src/hal_io.o \
-armcc/arm_addon/armcc/system_same54.o \
-hpl/core/hpl_core_m4.o \
-usb/class/cdc/device/cdcdf_acm.o \
-hpl/dmac/hpl_dmac.o \
-hpl/usb/hpl_usb.o \
-hal/src/hal_delay.o \
-hpl/pm/hpl_pm.o \
-hpl/core/hpl_init.o \
-hpl/gclk/hpl_gclk.o \
-hal/utils/src/utils_list.o \
-hal/utils/src/utils_assert.o \
-usb_start.o \
-hpl/oscctrl/hpl_oscctrl.o \
-hal/src/hal_usart_sync.o \
-hpl/mclk/hpl_mclk.o \
-hpl/ramecc/hpl_ramecc.o \
-usb/usb_protocol.o \
-hal/src/hal_init.o \
-hal/src/hal_usb_device.o \
-hpl/osc32kctrl/hpl_osc32kctrl.o \
-examples/driver_examples.o \
-driver_init.o \
-hpl/sercom/hpl_sercom.o \
-hal/src/hal_gpio.o \
-hal/utils/src/utils_event.o \
-hal/src/hal_sleep.o \
-hal/src/hal_cache.o \
-hpl/cmcc/hpl_cmcc.o \
-atmel_start.o \
-usb_cdc_echo_main.o \
-usb/device/usbdc.o \
-hal/src/hal_atomic.o \
-armcc/arm_addon/armcc/arm/startup_same54.o
-
-OBJS_AS_ARGS +=  \
-"hal/src/hal_io.o" \
-"armcc/arm_addon/armcc/system_same54.o" \
-"hpl/core/hpl_core_m4.o" \
-"usb/class/cdc/device/cdcdf_acm.o" \
-"hpl/dmac/hpl_dmac.o" \
-"hpl/usb/hpl_usb.o" \
-"hal/src/hal_delay.o" \
-"hpl/pm/hpl_pm.o" \
-"hpl/core/hpl_init.o" \
-"hpl/gclk/hpl_gclk.o" \
-"hal/utils/src/utils_list.o" \
-"hal/utils/src/utils_assert.o" \
-"usb_start.o" \
-"hpl/oscctrl/hpl_oscctrl.o" \
-"hal/src/hal_usart_sync.o" \
-"hpl/mclk/hpl_mclk.o" \
-"hpl/ramecc/hpl_ramecc.o" \
-"usb/usb_protocol.o" \
-"hal/src/hal_init.o" \
-"hal/src/hal_usb_device.o" \
-"hpl/osc32kctrl/hpl_osc32kctrl.o" \
-"examples/driver_examples.o" \
-"driver_init.o" \
-"hpl/sercom/hpl_sercom.o" \
-"hal/src/hal_gpio.o" \
-"hal/utils/src/utils_event.o" \
-"hal/src/hal_sleep.o" \
-"hal/src/hal_cache.o" \
-"hpl/cmcc/hpl_cmcc.o" \
-"atmel_start.o" \
-"usb_cdc_echo_main.o" \
-"usb/device/usbdc.o" \
-"hal/src/hal_atomic.o" \
-"armcc/arm_addon/armcc/arm/startup_same54.o"
-
-# List the dependency files
-DEPS := $(OBJS:%.o=%.d)
-
-DEPS_AS_ARGS +=  \
-"hal/utils/src/utils_event.d" \
-"hal/src/hal_io.d" \
-"armcc/arm_addon/armcc/system_same54.d" \
-"hpl/ramecc/hpl_ramecc.d" \
-"hpl/core/hpl_core_m4.d" \
-"usb/class/cdc/device/cdcdf_acm.d" \
-"hpl/usb/hpl_usb.d" \
-"hal/utils/src/utils_list.d" \
-"hpl/cmcc/hpl_cmcc.d" \
-"usb_start.d" \
-"hal/utils/src/utils_assert.d" \
-"hal/src/hal_delay.d" \
-"hpl/core/hpl_init.d" \
-"hpl/pm/hpl_pm.d" \
-"usb/usb_protocol.d" \
-"hpl/gclk/hpl_gclk.d" \
-"hal/src/hal_usb_device.d" \
-"hpl/dmac/hpl_dmac.d" \
-"hal/src/hal_init.d" \
-"hal/src/hal_usart_sync.d" \
-"usb_cdc_echo_main.d" \
-"hpl/mclk/hpl_mclk.d" \
-"driver_init.d" \
-"hpl/osc32kctrl/hpl_osc32kctrl.d" \
-"examples/driver_examples.d" \
-"hal/src/hal_cache.d" \
-"hal/src/hal_sleep.d" \
-"hpl/sercom/hpl_sercom.d" \
-"hal/src/hal_gpio.d" \
-"hal/src/hal_atomic.d" \
-"usb/device/usbdc.d" \
-"hpl/oscctrl/hpl_oscctrl.d" \
-"armcc/arm_addon/armcc/arm/startup_same54.d" \
-"atmel_start.d"
-
-OUTPUT_FILE_NAME :=AtmelStart
-QUOTE := "
-OUTPUT_FILE_PATH +=$(OUTPUT_FILE_NAME).elf
-OUTPUT_FILE_PATH_AS_ARGS +=$(OUTPUT_FILE_NAME).elf
-
-vpath 

Change in osmo-ccid-firmware[master]: rename project to sysmoOCTSIM

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12793 )

Change subject: rename project to sysmoOCTSIM
..

rename project to sysmoOCTSIM

Change-Id: I1ff2ac6e2ae1b1b4765f2ca27c5b3fa6e93baa95
---
M sysmoOCTSIM/AtmelStart.gpdsc
M sysmoOCTSIM/atmel_start_config.atstart
2 files changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/sysmoOCTSIM/AtmelStart.gpdsc b/sysmoOCTSIM/AtmelStart.gpdsc
index 20a44d8..4784595 100644
--- a/sysmoOCTSIM/AtmelStart.gpdsc
+++ b/sysmoOCTSIM/AtmelStart.gpdsc
@@ -1,6 +1,6 @@
 http://www.w3.org/2001/XMLSchema-instance; 
schemaVersion="1.0" xs:noNamespaceSchemaLocation="PACK.xsd">
   Atmel
-  USB CDC Echo
+  sysmoOCTSIM
   Project generated by Atmel Start
   http://start.atmel.com/
   
diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index f0369f4..8a87ba2 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -1,5 +1,5 @@
 format_version: '2'
-name: USB CDC Echo
+name: sysmoOCTSIM
 versions:
   api: '1.0'
   backend: 1.4.93

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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I1ff2ac6e2ae1b1b4765f2ca27c5b3fa6e93baa95
Gerrit-Change-Number: 12793
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: switch CPU clock to 120 MHz

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12797 )

Change subject: switch CPU clock to 120 MHz
..

switch CPU clock to 120 MHz

use GCLK11 to bring external crystal oscillator XOSC1 from 12 MHz
to 2MHz
use DPLL0 to multiply 2 MHz to 120 MHz.
the division is first needed because the DPLL0 maximum input
frequency is 3.2 MHz

Change-Id: I642e724ec56a376addf21cc58ecd2ef1b40bd116
---
M sysmoOCTSIM/atmel_start_config.atstart
M sysmoOCTSIM/config/hpl_gclk_config.h
M sysmoOCTSIM/config/hpl_oscctrl_config.h
M sysmoOCTSIM/config/peripheral_clk_config.h
M sysmoOCTSIM/hpl/core/hpl_init.c
5 files changed, 28 insertions(+), 27 deletions(-)

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



diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index 385c890..5e27536 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -646,7 +646,7 @@
   enable_gclk_gen_0: true
   enable_gclk_gen_1: true
   enable_gclk_gen_10: false
-  enable_gclk_gen_11: false
+  enable_gclk_gen_11: true
   enable_gclk_gen_2: false
   enable_gclk_gen_3: true
   enable_gclk_gen_4: false
@@ -665,7 +665,7 @@
   gclk_arch_gen_10_oe: false
   gclk_arch_gen_10_oov: false
   gclk_arch_gen_10_runstdby: false
-  gclk_arch_gen_11_enable: false
+  gclk_arch_gen_11_enable: true
   gclk_arch_gen_11_idc: false
   gclk_arch_gen_11_oe: false
   gclk_arch_gen_11_oov: false
@@ -717,13 +717,13 @@
   gclk_arch_gen_9_runstdby: false
   gclk_gen_0_div: 1
   gclk_gen_0_div_sel: false
-  gclk_gen_0_oscillator: External Crystal Oscillator 8-48MHz (XOSC1)
+  gclk_gen_0_oscillator: Digital Phase Locked Loop (DPLL0)
   gclk_gen_10_div: 1
   gclk_gen_10_div_sel: false
   gclk_gen_10_oscillator: External Crystal Oscillator 8-48MHz (XOSC0)
-  gclk_gen_11_div: 1
+  gclk_gen_11_div: 6
   gclk_gen_11_div_sel: false
-  gclk_gen_11_oscillator: External Crystal Oscillator 8-48MHz (XOSC0)
+  gclk_gen_11_oscillator: External Crystal Oscillator 8-48MHz (XOSC1)
   gclk_gen_1_div: 1
   gclk_gen_1_div_sel: false
   gclk_gen_1_oscillator: Digital Frequency Locked Loop (DFLL48M)
@@ -829,24 +829,24 @@
   dfll_mul: 48000
   dfll_ref_clock: Generic clock generator 3
   enable_dfll: true
-  enable_fdpll0: false
+  enable_fdpll0: true
   enable_fdpll1: false
   enable_xosc0: false
   enable_xosc1: true
   fdpll0_arch_dcoen: false
-  fdpll0_arch_enable: false
+  fdpll0_arch_enable: true
   fdpll0_arch_filter: 0
   fdpll0_arch_lbypass: false
   fdpll0_arch_ltime: No time-out, automatic lock
   fdpll0_arch_ondemand: false
-  fdpll0_arch_refclk: XOSC32K clock reference
+  fdpll0_arch_refclk: XOSC1 clock reference
   fdpll0_arch_runstdby: false
   fdpll0_arch_wuf: false
   fdpll0_clock_dcofilter: 0
-  fdpll0_clock_div: 0
-  fdpll0_ldr: 1463
-  fdpll0_ldrfrac: 13
-  fdpll0_ref_clock: 32kHz External Crystal Oscillator (XOSC32K)
+  fdpll0_clock_div: 6
+  fdpll0_ldr: 59
+  fdpll0_ldrfrac: 0
+  fdpll0_ref_clock: Generic clock generator 11
   fdpll1_arch_dcoen: false
   fdpll1_arch_enable: false
   fdpll1_arch_filter: 0
diff --git a/sysmoOCTSIM/config/hpl_gclk_config.h 
b/sysmoOCTSIM/config/hpl_gclk_config.h
index 306d90e..8d10f38 100644
--- a/sysmoOCTSIM/config/hpl_gclk_config.h
+++ b/sysmoOCTSIM/config/hpl_gclk_config.h
@@ -25,7 +25,7 @@
 //  This defines the clock source for generic clock generator 0
 //  gclk_gen_0_oscillator
 #ifndef CONF_GCLK_GEN_0_SOURCE
-#define CONF_GCLK_GEN_0_SOURCE GCLK_GENCTRL_SRC_XOSC1
+#define CONF_GCLK_GEN_0_SOURCE GCLK_GENCTRL_SRC_DPLL0
 #endif

 //  Run in Standby
@@ -843,7 +843,7 @@
 //  Indicates whether generic clock 11 configuration is enabled or not
 //  enable_gclk_gen_11
 #ifndef CONF_GCLK_GENERATOR_11_CONFIG
-#define CONF_GCLK_GENERATOR_11_CONFIG 0
+#define CONF_GCLK_GENERATOR_11_CONFIG 1
 #endif

 //  Generic Clock Generator Control
@@ -860,7 +860,7 @@
 //  This defines the clock source for generic clock generator 11
 //  gclk_gen_11_oscillator
 #ifndef CONF_GCLK_GEN_11_SOURCE
-#define CONF_GCLK_GEN_11_SOURCE GCLK_GENCTRL_SRC_XOSC0
+#define CONF_GCLK_GEN_11_SOURCE GCLK_GENCTRL_SRC_XOSC1
 #endif

 //  Run in Standby
@@ -902,7 +902,7 @@
 //  Indicates whether Generic Clock Generator Enable is enabled or not
 //  gclk_arch_gen_11_enable
 #ifndef CONF_GCLK_GEN_11_GENEN
-#define CONF_GCLK_GEN_11_GENEN 0
+#define CONF_GCLK_GEN_11_GENEN 1
 #endif
 // 

@@ -910,7 +910,7 @@
 // Generic clock generator 11 division <0x-0x>
 //  gclk_gen_11_div
 #ifndef CONF_GCLK_GEN_11_DIV
-#define CONF_GCLK_GEN_11_DIV 1
+#define CONF_GCLK_GEN_11_DIV 6
 #endif
 // 
 // 
diff --git 

Change in osmo-ccid-firmware[master]: start with USB CDC echo example

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12792 )

Change subject: start with USB CDC echo example
..

start with USB CDC echo example

this is the Atmel START USB CDC Echo example project for the
SAM E54 Xplained Pro board using an Atmel ATSAME54P20A
microcontroller.
Atmel START information:
- Version: 1.4.1810 (Dec 18, 2018, 5:52 AM GMT+1)
- Server: 1.4.93
- Content version: 1.0.1340

This will serve as basis for the sysmoOCTSIM project

A jenkins contrib script has also been added to the
osmo-ccid-firmware project to build the sysmoOCTSIM firmware

Change-Id: I356de75e7b730d63fb819248e71d36f785932199
---
A contrib/jenkins.sh
A sysmoOCTSIM/AtmelStart.env_conf
A sysmoOCTSIM/AtmelStart.gpdsc
A sysmoOCTSIM/CMSIS/Documentation/Core/html/index.html
A sysmoOCTSIM/CMSIS/Include/arm_common_tables.h
A sysmoOCTSIM/CMSIS/Include/arm_const_structs.h
A sysmoOCTSIM/CMSIS/Include/arm_math.h
A sysmoOCTSIM/CMSIS/Include/cmsis_armcc.h
A sysmoOCTSIM/CMSIS/Include/cmsis_armclang.h
A sysmoOCTSIM/CMSIS/Include/cmsis_compiler.h
A sysmoOCTSIM/CMSIS/Include/cmsis_gcc.h
A sysmoOCTSIM/CMSIS/Include/core_armv8mbl.h
A sysmoOCTSIM/CMSIS/Include/core_armv8mml.h
A sysmoOCTSIM/CMSIS/Include/core_cm0.h
A sysmoOCTSIM/CMSIS/Include/core_cm0plus.h
A sysmoOCTSIM/CMSIS/Include/core_cm23.h
A sysmoOCTSIM/CMSIS/Include/core_cm3.h
A sysmoOCTSIM/CMSIS/Include/core_cm33.h
A sysmoOCTSIM/CMSIS/Include/core_cm4.h
A sysmoOCTSIM/CMSIS/Include/core_cm7.h
A sysmoOCTSIM/CMSIS/Include/core_sc000.h
A sysmoOCTSIM/CMSIS/Include/core_sc300.h
A sysmoOCTSIM/CMSIS/Include/tz_context.h
A sysmoOCTSIM/armcc/Makefile
A sysmoOCTSIM/armcc/arm_addon/armcc/arm/startup_same54.s
A sysmoOCTSIM/armcc/arm_addon/armcc/system_same54.c
A sysmoOCTSIM/atmel_start.c
A sysmoOCTSIM/atmel_start.h
A sysmoOCTSIM/atmel_start_config.atstart
A sysmoOCTSIM/atmel_start_pins.h
A sysmoOCTSIM/config/hpl_cmcc_config.h
A sysmoOCTSIM/config/hpl_dmac_config.h
A sysmoOCTSIM/config/hpl_gclk_config.h
A sysmoOCTSIM/config/hpl_mclk_config.h
A sysmoOCTSIM/config/hpl_osc32kctrl_config.h
A sysmoOCTSIM/config/hpl_oscctrl_config.h
A sysmoOCTSIM/config/hpl_port_config.h
A sysmoOCTSIM/config/hpl_usb_config.h
A sysmoOCTSIM/config/peripheral_clk_config.h
A sysmoOCTSIM/config/usbd_config.h
A sysmoOCTSIM/documentation/usb_cdc_echo.rst
A sysmoOCTSIM/documentation/usb_device_cdc.rst
A sysmoOCTSIM/documentation/usb_device_core.rst
A sysmoOCTSIM/documentation/usb_protocol_cdc.rst
A sysmoOCTSIM/documentation/usb_protocol_core.rst
A sysmoOCTSIM/driver_init.c
A sysmoOCTSIM/driver_init.h
A sysmoOCTSIM/examples/driver_examples.c
A sysmoOCTSIM/examples/driver_examples.h
A sysmoOCTSIM/gcc/Makefile
A sysmoOCTSIM/gcc/gcc/same54p20a_flash.ld
A sysmoOCTSIM/gcc/gcc/same54p20a_sram.ld
A sysmoOCTSIM/gcc/gcc/startup_same54.c
A sysmoOCTSIM/gcc/system_same54.c
A sysmoOCTSIM/hal/documentation/usb_device_async.rst
A sysmoOCTSIM/hal/include/hal_atomic.h
A sysmoOCTSIM/hal/include/hal_cache.h
A sysmoOCTSIM/hal/include/hal_delay.h
A sysmoOCTSIM/hal/include/hal_gpio.h
A sysmoOCTSIM/hal/include/hal_init.h
A sysmoOCTSIM/hal/include/hal_io.h
A sysmoOCTSIM/hal/include/hal_sleep.h
A sysmoOCTSIM/hal/include/hal_usb_device.h
A sysmoOCTSIM/hal/include/hpl_cmcc.h
A sysmoOCTSIM/hal/include/hpl_core.h
A sysmoOCTSIM/hal/include/hpl_delay.h
A sysmoOCTSIM/hal/include/hpl_dma.h
A sysmoOCTSIM/hal/include/hpl_gpio.h
A sysmoOCTSIM/hal/include/hpl_init.h
A sysmoOCTSIM/hal/include/hpl_irq.h
A sysmoOCTSIM/hal/include/hpl_missing_features.h
A sysmoOCTSIM/hal/include/hpl_ramecc.h
A sysmoOCTSIM/hal/include/hpl_reset.h
A sysmoOCTSIM/hal/include/hpl_sleep.h
A sysmoOCTSIM/hal/include/hpl_usb.h
A sysmoOCTSIM/hal/include/hpl_usb_device.h
A sysmoOCTSIM/hal/include/hpl_usb_host.h
A sysmoOCTSIM/hal/src/hal_atomic.c
A sysmoOCTSIM/hal/src/hal_cache.c
A sysmoOCTSIM/hal/src/hal_delay.c
A sysmoOCTSIM/hal/src/hal_gpio.c
A sysmoOCTSIM/hal/src/hal_init.c
A sysmoOCTSIM/hal/src/hal_io.c
A sysmoOCTSIM/hal/src/hal_sleep.c
A sysmoOCTSIM/hal/src/hal_usb_device.c
A sysmoOCTSIM/hal/utils/include/compiler.h
A sysmoOCTSIM/hal/utils/include/err_codes.h
A sysmoOCTSIM/hal/utils/include/events.h
A sysmoOCTSIM/hal/utils/include/parts.h
A sysmoOCTSIM/hal/utils/include/utils.h
A sysmoOCTSIM/hal/utils/include/utils_assert.h
A sysmoOCTSIM/hal/utils/include/utils_event.h
A sysmoOCTSIM/hal/utils/include/utils_increment_macro.h
A sysmoOCTSIM/hal/utils/include/utils_list.h
A sysmoOCTSIM/hal/utils/include/utils_repeat_macro.h
A sysmoOCTSIM/hal/utils/src/utils_assert.c
A sysmoOCTSIM/hal/utils/src/utils_event.c
A sysmoOCTSIM/hal/utils/src/utils_list.c
A sysmoOCTSIM/hal/utils/src/utils_syscalls.c
A sysmoOCTSIM/hpl/cmcc/hpl_cmcc.c
A sysmoOCTSIM/hpl/core/hpl_core_m4.c
A sysmoOCTSIM/hpl/core/hpl_core_port.h
A sysmoOCTSIM/hpl/core/hpl_init.c
A sysmoOCTSIM/hpl/dmac/hpl_dmac.c
A sysmoOCTSIM/hpl/gclk/hpl_gclk.c
A sysmoOCTSIM/hpl/gclk/hpl_gclk_base.h
A sysmoOCTSIM/hpl/mclk/hpl_mclk.c
A 

Change in osmo-ccid-firmware[master]: use external 32.768 kHz oscillator for RTC

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12796 )

Change subject: use external 32.768 kHz oscillator for RTC
..

use external 32.768 kHz oscillator for RTC

Change-Id: Ic4630abececdb631e8cc15baab7137fc15e2a66a
---
M sysmoOCTSIM/atmel_start_config.atstart
M sysmoOCTSIM/config/hpl_osc32kctrl_config.h
2 files changed, 4 insertions(+), 4 deletions(-)

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



diff --git a/sysmoOCTSIM/atmel_start_config.atstart 
b/sysmoOCTSIM/atmel_start_config.atstart
index f3620ee..385c890 100644
--- a/sysmoOCTSIM/atmel_start_config.atstart
+++ b/sysmoOCTSIM/atmel_start_config.atstart
@@ -787,8 +787,8 @@
   enable_xosc32k: true
   osculp32k_calib: 0
   osculp32k_calib_enable: false
-  rtc_1khz_selection: true
-  rtc_source_oscillator: 32kHz Ultra Low Power Internal Oscillator 
(OSCULP32K)
+  rtc_1khz_selection: false
+  rtc_source_oscillator: 32kHz External Crystal Oscillator (XOSC32K)
   xosc32k_arch_cfden: false
   xosc32k_arch_cfdeo: false
   xosc32k_arch_cgm: Standard mode
diff --git a/sysmoOCTSIM/config/hpl_osc32kctrl_config.h 
b/sysmoOCTSIM/config/hpl_osc32kctrl_config.h
index d0b0d34..943dfea 100644
--- a/sysmoOCTSIM/config/hpl_osc32kctrl_config.h
+++ b/sysmoOCTSIM/config/hpl_osc32kctrl_config.h
@@ -17,14 +17,14 @@
 //  This defines the clock source for RTC
 //  rtc_source_oscillator
 #ifndef CONF_RTCCTRL_SRC
-#define CONF_RTCCTRL_SRC GCLK_GENCTRL_SRC_OSCULP32K
+#define CONF_RTCCTRL_SRC GCLK_GENCTRL_SRC_XOSC32K
 #endif

 //  Use 1 kHz output
 //  rtc_1khz_selection
 #ifndef CONF_RTCCTRL_1KHZ

-#define CONF_RTCCTRL_1KHZ 1
+#define CONF_RTCCTRL_1KHZ 0

 #endif


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ic4630abececdb631e8cc15baab7137fc15e2a66a
Gerrit-Change-Number: 12796
Gerrit-PatchSet: 2
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-ccid-firmware[master]: start with USB CDC echo example

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12792 )

Change subject: start with USB CDC echo example
..


Patch Set 3: Code-Review+2


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I356de75e7b730d63fb819248e71d36f785932199
Gerrit-Change-Number: 12792
Gerrit-PatchSet: 3
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Kévin Redon 
Gerrit-Comment-Date: Thu, 07 Feb 2019 15:28:06 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ccid-firmware[master]: start with USB CDC echo example

2019-02-07 Thread Kévin Redon
Kévin Redon has posted comments on this change. ( 
https://gerrit.osmocom.org/12792 )

Change subject: start with USB CDC echo example
..


Patch Set 3:

> I'm fine with committing the complete example in one go.  However,
 > in order to get build verification of patches, we also need to add
 > a "contrib/jenkins.sh" script. Please test + add the script and
 > make it part of this commit.  I will then modify the jenkins jobs
 > to do the automatic "+V" builds for this repository.

contrib/jenkins.sh script added to this commit and tested against followup 
commits


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I356de75e7b730d63fb819248e71d36f785932199
Gerrit-Change-Number: 12792
Gerrit-PatchSet: 3
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Kévin Redon 
Gerrit-CC: Harald Welte 
Gerrit-Comment-Date: Thu, 07 Feb 2019 15:16:15 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in osmo-ci[master]: gerrit-verifications: Add osmo-ccid-firmware

2019-02-07 Thread Kévin Redon
Kévin Redon has posted comments on this change. ( 
https://gerrit.osmocom.org/12824 )

Change subject: gerrit-verifications: Add osmo-ccid-firmware
..


Patch Set 1:

osmo-ccid-firmware has now a contrib/jenkins.sh script


--
To view, visit https://gerrit.osmocom.org/12824
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: I713d345240dec319ee07d99e9381fc1af6a2d86d
Gerrit-Change-Number: 12824
Gerrit-PatchSet: 1
Gerrit-Owner: Harald Welte 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Kévin Redon 
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 15:14:52 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in osmo-ccid-firmware[master]: start with USB CDC echo example

2019-02-07 Thread Kévin Redon
Kévin Redon has uploaded a new patch set (#3). ( 
https://gerrit.osmocom.org/12792 )

Change subject: start with USB CDC echo example
..

start with USB CDC echo example

this is the Atmel START USB CDC Echo example project for the
SAM E54 Xplained Pro board using an Atmel ATSAME54P20A
microcontroller.
Atmel START information:
- Version: 1.4.1810 (Dec 18, 2018, 5:52 AM GMT+1)
- Server: 1.4.93
- Content version: 1.0.1340

This will serve as basis for the sysmoOCTSIM project

A jenkins contrib script has also been added to the
osmo-ccid-firmware project to build the sysmoOCTSIM firmware

Change-Id: I356de75e7b730d63fb819248e71d36f785932199
---
A contrib/jenkins.sh
A sysmoOCTSIM/AtmelStart.env_conf
A sysmoOCTSIM/AtmelStart.gpdsc
A sysmoOCTSIM/CMSIS/Documentation/Core/html/index.html
A sysmoOCTSIM/CMSIS/Include/arm_common_tables.h
A sysmoOCTSIM/CMSIS/Include/arm_const_structs.h
A sysmoOCTSIM/CMSIS/Include/arm_math.h
A sysmoOCTSIM/CMSIS/Include/cmsis_armcc.h
A sysmoOCTSIM/CMSIS/Include/cmsis_armclang.h
A sysmoOCTSIM/CMSIS/Include/cmsis_compiler.h
A sysmoOCTSIM/CMSIS/Include/cmsis_gcc.h
A sysmoOCTSIM/CMSIS/Include/core_armv8mbl.h
A sysmoOCTSIM/CMSIS/Include/core_armv8mml.h
A sysmoOCTSIM/CMSIS/Include/core_cm0.h
A sysmoOCTSIM/CMSIS/Include/core_cm0plus.h
A sysmoOCTSIM/CMSIS/Include/core_cm23.h
A sysmoOCTSIM/CMSIS/Include/core_cm3.h
A sysmoOCTSIM/CMSIS/Include/core_cm33.h
A sysmoOCTSIM/CMSIS/Include/core_cm4.h
A sysmoOCTSIM/CMSIS/Include/core_cm7.h
A sysmoOCTSIM/CMSIS/Include/core_sc000.h
A sysmoOCTSIM/CMSIS/Include/core_sc300.h
A sysmoOCTSIM/CMSIS/Include/tz_context.h
A sysmoOCTSIM/armcc/Makefile
A sysmoOCTSIM/armcc/arm_addon/armcc/arm/startup_same54.s
A sysmoOCTSIM/armcc/arm_addon/armcc/system_same54.c
A sysmoOCTSIM/atmel_start.c
A sysmoOCTSIM/atmel_start.h
A sysmoOCTSIM/atmel_start_config.atstart
A sysmoOCTSIM/atmel_start_pins.h
A sysmoOCTSIM/config/hpl_cmcc_config.h
A sysmoOCTSIM/config/hpl_dmac_config.h
A sysmoOCTSIM/config/hpl_gclk_config.h
A sysmoOCTSIM/config/hpl_mclk_config.h
A sysmoOCTSIM/config/hpl_osc32kctrl_config.h
A sysmoOCTSIM/config/hpl_oscctrl_config.h
A sysmoOCTSIM/config/hpl_port_config.h
A sysmoOCTSIM/config/hpl_usb_config.h
A sysmoOCTSIM/config/peripheral_clk_config.h
A sysmoOCTSIM/config/usbd_config.h
A sysmoOCTSIM/documentation/usb_cdc_echo.rst
A sysmoOCTSIM/documentation/usb_device_cdc.rst
A sysmoOCTSIM/documentation/usb_device_core.rst
A sysmoOCTSIM/documentation/usb_protocol_cdc.rst
A sysmoOCTSIM/documentation/usb_protocol_core.rst
A sysmoOCTSIM/driver_init.c
A sysmoOCTSIM/driver_init.h
A sysmoOCTSIM/examples/driver_examples.c
A sysmoOCTSIM/examples/driver_examples.h
A sysmoOCTSIM/gcc/Makefile
A sysmoOCTSIM/gcc/gcc/same54p20a_flash.ld
A sysmoOCTSIM/gcc/gcc/same54p20a_sram.ld
A sysmoOCTSIM/gcc/gcc/startup_same54.c
A sysmoOCTSIM/gcc/system_same54.c
A sysmoOCTSIM/hal/documentation/usb_device_async.rst
A sysmoOCTSIM/hal/include/hal_atomic.h
A sysmoOCTSIM/hal/include/hal_cache.h
A sysmoOCTSIM/hal/include/hal_delay.h
A sysmoOCTSIM/hal/include/hal_gpio.h
A sysmoOCTSIM/hal/include/hal_init.h
A sysmoOCTSIM/hal/include/hal_io.h
A sysmoOCTSIM/hal/include/hal_sleep.h
A sysmoOCTSIM/hal/include/hal_usb_device.h
A sysmoOCTSIM/hal/include/hpl_cmcc.h
A sysmoOCTSIM/hal/include/hpl_core.h
A sysmoOCTSIM/hal/include/hpl_delay.h
A sysmoOCTSIM/hal/include/hpl_dma.h
A sysmoOCTSIM/hal/include/hpl_gpio.h
A sysmoOCTSIM/hal/include/hpl_init.h
A sysmoOCTSIM/hal/include/hpl_irq.h
A sysmoOCTSIM/hal/include/hpl_missing_features.h
A sysmoOCTSIM/hal/include/hpl_ramecc.h
A sysmoOCTSIM/hal/include/hpl_reset.h
A sysmoOCTSIM/hal/include/hpl_sleep.h
A sysmoOCTSIM/hal/include/hpl_usb.h
A sysmoOCTSIM/hal/include/hpl_usb_device.h
A sysmoOCTSIM/hal/include/hpl_usb_host.h
A sysmoOCTSIM/hal/src/hal_atomic.c
A sysmoOCTSIM/hal/src/hal_cache.c
A sysmoOCTSIM/hal/src/hal_delay.c
A sysmoOCTSIM/hal/src/hal_gpio.c
A sysmoOCTSIM/hal/src/hal_init.c
A sysmoOCTSIM/hal/src/hal_io.c
A sysmoOCTSIM/hal/src/hal_sleep.c
A sysmoOCTSIM/hal/src/hal_usb_device.c
A sysmoOCTSIM/hal/utils/include/compiler.h
A sysmoOCTSIM/hal/utils/include/err_codes.h
A sysmoOCTSIM/hal/utils/include/events.h
A sysmoOCTSIM/hal/utils/include/parts.h
A sysmoOCTSIM/hal/utils/include/utils.h
A sysmoOCTSIM/hal/utils/include/utils_assert.h
A sysmoOCTSIM/hal/utils/include/utils_event.h
A sysmoOCTSIM/hal/utils/include/utils_increment_macro.h
A sysmoOCTSIM/hal/utils/include/utils_list.h
A sysmoOCTSIM/hal/utils/include/utils_repeat_macro.h
A sysmoOCTSIM/hal/utils/src/utils_assert.c
A sysmoOCTSIM/hal/utils/src/utils_event.c
A sysmoOCTSIM/hal/utils/src/utils_list.c
A sysmoOCTSIM/hal/utils/src/utils_syscalls.c
A sysmoOCTSIM/hpl/cmcc/hpl_cmcc.c
A sysmoOCTSIM/hpl/core/hpl_core_m4.c
A sysmoOCTSIM/hpl/core/hpl_core_port.h
A sysmoOCTSIM/hpl/core/hpl_init.c
A sysmoOCTSIM/hpl/dmac/hpl_dmac.c
A sysmoOCTSIM/hpl/gclk/hpl_gclk.c
A sysmoOCTSIM/hpl/gclk/hpl_gclk_base.h
A sysmoOCTSIM/hpl/mclk/hpl_mclk.c
A 

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

2019-02-07 Thread jenkins
See 


--
[...truncated 3.69 KB...]

+ ./configure
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for style of include used by make... GNU
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... 
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for /usr/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/nm -B
checking whether ln -s works... yes
checking how to recognise dependent libraries... pass_all
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... g++ -E
checking for g77... no
checking for f77... no
checking for xlf... no
checking for frt... no
checking for pgf77... no
checking for cf77... no
checking for fort77... no
checking for fl32... no
checking for af77... no
checking for f90... no
checking for xlf90... no
checking for pgf90... no
checking for pghpf... no
checking for epcf90... no
checking for gfortran... no
checking for g95... no
checking for f95... no
checking for fort... no
checking for xlf95... no
checking for ifort... no
checking for ifc... no
checking for efc... no
checking for pgf95... no
checking for lf95... no
checking for ftn... no
checking whether we are using the GNU Fortran 77 compiler... no
checking whether  accepts -g... no
checking the maximum length of command line arguments... 32768
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for objdir... .libs
checking for ar... ar
checking for ranlib... ranlib
checking for strip... strip
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared 
libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
configure: creating libtool
appending configuration tag "CXX" to libtool
checking for ld used by g++... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared 
libraries... yes
checking for g++ option to produce PIC... -fPIC
checking if g++ PIC flag -fPIC works... yes
checking if g++ static flag -static works... yes
checking if g++ supports -c -o file.o... yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared 
libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
appending configuration tag "F77" to libtool
checking for autoconf... /usr/bin/autoconf
checking for autoheader... /usr/bin/autoheader
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed

Change in osmo-msc[master]: libmsc/gsm_04_80.c: use gsm0480_create_release_complete()

2019-02-07 Thread Vadim Yanitskiy
Vadim Yanitskiy has posted comments on this change. ( 
https://gerrit.osmocom.org/12840 )

Change subject: libmsc/gsm_04_80.c: use gsm0480_create_release_complete()
..


Patch Set 2:

(1 comment)

https://gerrit.osmocom.org/#/c/12840/2/include/osmocom/msc/gsm_04_80.h
File include/osmocom/msc/gsm_04_80.h:

https://gerrit.osmocom.org/#/c/12840/2/include/osmocom/msc/gsm_04_80.h@14
PS2, Line 14:  uint8_t transaction_id)
> Missing ; is responsible for the build failure
Oh, right, I forgot this... Thanks a lot!
The build failure itself is caused by a patch that is still not merged.



--
To view, visit https://gerrit.osmocom.org/12840
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: Id2975c3383f18e83124ba38927c03980d67ddadb
Gerrit-Change-Number: 12840
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: daniel 
Gerrit-Comment-Date: Thu, 07 Feb 2019 15:00:27 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in libusrp[master]: Avoid compiler warning 'dynamic exception specifications are deprecat...

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12853 )

Change subject: Avoid compiler warning 'dynamic exception specifications are 
deprecated in C++11 [-Wdeprecated]'
..


Patch Set 1: Code-Review+1


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

Gerrit-Project: libusrp
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie472e6f92944cfe1af7d63cd644879573d080ca2
Gerrit-Change-Number: 12853
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Huemer 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 14:41:43 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-ccid-firmware[master]: ignore output files

2019-02-07 Thread Kévin Redon
Kévin Redon has removed a vote on this change.

Change subject: ignore output files
..


Removed Verified+1 by Kévin Redon 
--
To view, visit https://gerrit.osmocom.org/12795
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: deleteVote
Gerrit-Change-Id: I425129f10aa2ff879fde96bfafbcb7c4b4119959
Gerrit-Change-Number: 12795
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Kévin Redon 
Gerrit-Reviewer: Max 


Change in osmo-ci[master]: Add timeout wrapper to regular gerrit verification jobs

2019-02-07 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12857


Change subject: Add timeout wrapper to regular gerrit verification jobs
..

Add timeout wrapper to regular gerrit verification jobs

Use 'timeout' utility (from GNU coreutils) to wrap jenkins.sh call to
ensure that verification job terminates within 15 minutes. Docker-based
are left untouched.

This change is prompted by recent issue with libosmo-netif test which
was hanging forever preventing other tests from being executed.

Change-Id: I9d0eb6b9eddf3e17120e74d7570d42291c0750ae
---
M jobs/gerrit-verifications.yml
1 file changed, 7 insertions(+), 7 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ci refs/changes/57/12857/1

diff --git a/jobs/gerrit-verifications.yml b/jobs/gerrit-verifications.yml
index a2f68f5..e89c9f7 100644
--- a/jobs/gerrit-verifications.yml
+++ b/jobs/gerrit-verifications.yml
@@ -20,7 +20,7 @@
 combination_filter: ''
 sequential: false
 # most common build invocation
-cmd: ./contrib/jenkins.sh
+cmd: timeout 15m ./contrib/jenkins.sh
 repos_url: 'ssh://jenk...@gerrit.osmocom.org:29418/{repos}'
 gerrit_project: '{repos}'

@@ -47,7 +47,7 @@
   - libosmo-abis
   - libosmo-netif
   - libosmo-sccp:
-  cmd: WITH_MANUALS=1 ./contrib/jenkins.sh
+  cmd: WITH_MANUALS=1 timeout 15m ./contrib/jenkins.sh

   - libosmocore:
   a1_name: arch
@@ -91,7 +91,7 @@
   - openggsn:
   a1_name: GTP
   a1: !!python/tuple [--enable-gtp-linux,--disable-gtp-linux]
-  cmd: ./contrib/jenkins.sh
+  cmd: timeout 15m ./contrib/jenkins.sh

   - osmo-bsc:
   concurrent: true
@@ -136,12 +136,12 @@
   combination_filter: >
 (GTP == "--enable-gtp-linux" && WITH_MANUALS == "0") ||
 (GTP == "--disable-gtp-linux" && WITH_MANUALS == "1")
-  cmd: ./contrib/jenkins.sh
+  cmd: timeout 15m ./contrib/jenkins.sh

   - osmo-gsm-manuals

   - osmo-hlr:
-  cmd: WITH_MANUALS=1 ./contrib/jenkins.sh
+  cmd: WITH_MANUALS=1 timeout 15m ./contrib/jenkins.sh

   - osmo-iuh

@@ -235,7 +235,7 @@
   osmocom:amd64 /build/contrib/jenkins.sh

   - osmo-sip-connector:
-  cmd: WITH_MANUALS=1 ./contrib/jenkins.sh
+  cmd: WITH_MANUALS=1 timeout 15m ./contrib/jenkins.sh

   - osmo-trx:
   a1_name: INSTR
@@ -249,7 +249,7 @@
 (INSTR == "--with-sse" && WITH_MANUALS == "1")

   - osmocom-bb:
-  cmd: WITH_MANUALS=1 ./contrib/jenkins.sh
+  cmd: WITH_MANUALS=1 timeout 15m ./contrib/jenkins.sh
   - osmo-tetra
   - osmo-sysmon
   - osmo-remsim

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

Gerrit-Project: osmo-ci
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I9d0eb6b9eddf3e17120e74d7570d42291c0750ae
Gerrit-Change-Number: 12857
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in osmo-ccid-firmware[master]: ignore output files

2019-02-07 Thread Kévin Redon
Kévin Redon has posted comments on this change. ( 
https://gerrit.osmocom.org/12795 )

Change subject: ignore output files
..


Patch Set 1: Verified+1


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

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I425129f10aa2ff879fde96bfafbcb7c4b4119959
Gerrit-Change-Number: 12795
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Kévin Redon 
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 12:54:18 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmo-sccp[master]: Don't use deprecated osmo_stream_cli_open2()

2019-02-07 Thread Max
Max has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12852 )

Change subject: Don't use deprecated osmo_stream_cli_open2()
..

Don't use deprecated osmo_stream_cli_open2()

Using osmo_stream_cli_open() with explicit timeout set via
osmo_stream_cli_set_reconnect_timeout() will have the same
effect. Update comment explaining this as well as the code.

Change-Id: Iffe6ea48a170880faef071c7c4a1bc0605aa9855
---
M src/osmo_ss7.c
1 file changed, 4 insertions(+), 3 deletions(-)

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



diff --git a/src/osmo_ss7.c b/src/osmo_ss7.c
index 39d92fa..05668b0 100644
--- a/src/osmo_ss7.c
+++ b/src/osmo_ss7.c
@@ -1261,12 +1261,13 @@
else
osmo_stream_cli_set_read_cb(asp->client, 
xua_cli_read_cb);
osmo_stream_cli_set_data(asp->client, asp);
-   rc = osmo_stream_cli_open2(asp->client, 1);
+   rc = osmo_stream_cli_open(asp->client);
if (rc < 0) {
LOGSS7(asp->inst, LOGL_ERROR, "Unable to open stream"
" client for ASP %s\n", asp->cfg.name);
-   /* we don't return error in here because 
osmo_stream_cli_open2()
-  will continue to retry to connect so the error is 
transient  */
+   /* we don't return error in here because 
osmo_stream_cli_open()
+  will continue to retry (due to timeout being 
explicitly set with
+  osmo_stream_cli_set_reconnect_timeout() above) to 
connect so the error is transient */
}
/* TODO: make this configurable and not implicit */
role = XUA_ASPFSM_ROLE_ASP;

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

Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Iffe6ea48a170880faef071c7c4a1bc0605aa9855
Gerrit-Change-Number: 12852
Gerrit-PatchSet: 1
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 


Change in libosmo-sccp[master]: Don't use deprecated osmo_stream_cli_open2()

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12852 )

Change subject: Don't use deprecated osmo_stream_cli_open2()
..


Patch Set 1:

This change is ready for review.


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

Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iffe6ea48a170880faef071c7c4a1bc0605aa9855
Gerrit-Change-Number: 12852
Gerrit-PatchSet: 1
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 12:48:26 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in libosmo-netif[master]: Deprecate osmo_stream_cli_open2()

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12845 )

Change subject: Deprecate osmo_stream_cli_open2()
..


Patch Set 6:

This change is ready for review.


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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Id988ed0274b363db049f59cbf6a193727c8c3c8a
Gerrit-Change-Number: 12845
Gerrit-PatchSet: 6
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: osmith 
Gerrit-Comment-Date: Thu, 07 Feb 2019 12:45:43 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in libosmo-netif[master]: Add stream client/server test

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12837 )

Change subject: Add stream client/server test
..


Patch Set 18:

This change is ready for review.


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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I336f79970982ed8e1d73b73d54fa4c27ba8bce8e
Gerrit-Change-Number: 12837
Gerrit-PatchSet: 18
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Pau Espin Pedrol 
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: osmith 
Gerrit-Comment-Date: Thu, 07 Feb 2019 12:45:17 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in osmo-ttcn3-hacks[master]: MSC_Tests: Enable SGs interface by default

2019-02-07 Thread dexter
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/12855


Change subject: MSC_Tests: Enable SGs interface by default
..

MSC_Tests: Enable SGs interface by default

Since the current master of osmo-msc now implements an SGs interface.
Lets enable the TTCN3 side of the SGs interface as well.

Change-Id: I6a07000ef52c9774fd603e2be914e6f2a6a3cce4
Related: OS#3614
---
M msc/MSC_Tests.ttcn
1 file changed, 1 insertion(+), 1 deletion(-)



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

diff --git a/msc/MSC_Tests.ttcn b/msc/MSC_Tests.ttcn
index 8d29e7a..eca0eb6 100644
--- a/msc/MSC_Tests.ttcn
+++ b/msc/MSC_Tests.ttcn
@@ -119,7 +119,7 @@
charstring mp_mme_name := 
"mmec01.mmegi0001.mme.epc.mnc070.mcc901.3gppnetwork.org";
charstring mp_vlr_name := "vlr.example.net";

-   boolean mp_sgsap_enable := false;
+   boolean mp_sgsap_enable := true;

BSSAP_Configurations mp_bssap_cfg := {
{

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

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I6a07000ef52c9774fd603e2be914e6f2a6a3cce4
Gerrit-Change-Number: 12855
Gerrit-PatchSet: 1
Gerrit-Owner: dexter 


Change in osmo-ttcn3-hacks[master]: MSC_Tests: make sure SGs tests don't interfere

2019-02-07 Thread dexter
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/12856


Change subject: MSC_Tests: make sure SGs tests don't interfere
..

MSC_Tests: make sure SGs tests don't interfere

The IMSIs used with the SGs tests are partially re-used in other SGs
testcases and also in unrelated testcases. Lets give each SGs test a
unique IMSI to prevent unrelated interference with other tests.

Change-Id: I417d9c5f0fbab7483d1b31dc20a99f63ee1bbfe6
Related: OS#3614
---
M msc/MSC_Tests.ttcn
1 file changed, 18 insertions(+), 18 deletions(-)



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

diff --git a/msc/MSC_Tests.ttcn b/msc/MSC_Tests.ttcn
index eca0eb6..1f6ee87 100644
--- a/msc/MSC_Tests.ttcn
+++ b/msc/MSC_Tests.ttcn
@@ -3571,7 +3571,7 @@
 testcase TC_sgsap_reset() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_reset), 10);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_reset), 11810);
vc_conn.done;
 }

@@ -3663,7 +3663,7 @@
 testcase TC_sgsap_lu() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_lu), 10);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_lu), 11811);
vc_conn.done;
 }

@@ -3701,7 +3701,7 @@
var BSC_ConnHdlr vc_conn;
f_init();

-   vc_conn := f_start_handler(refers(f_tc_sgsap_lu_imsi_reject), 3);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_lu_imsi_reject), 11812);
vc_conn.done;
 }

@@ -3762,7 +3762,7 @@
var BSC_ConnHdlr vc_conn;
f_init();

-   vc_conn := f_start_handler(refers(f_tc_sgsap_lu_and_nothing), 3);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_lu_and_nothing), 11813);
vc_conn.done;
 }

@@ -3784,7 +3784,7 @@
 testcase TC_sgsap_expl_imsi_det_eps() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_expl_imsi_det_eps), 10);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_expl_imsi_det_eps), 11814);
vc_conn.done;
 }

@@ -3807,7 +3807,7 @@
 testcase TC_sgsap_expl_imsi_det_noneps() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_expl_imsi_det_noneps), 
1081);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_expl_imsi_det_noneps), 
11815);
vc_conn.done;
 }

@@ -3856,7 +3856,7 @@
 testcase TC_sgsap_paging_rej() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_rej), 1082);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_rej), 11816);
vc_conn.done;
 }

@@ -3903,7 +3903,7 @@
 testcase TC_sgsap_paging_subscr_rej() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_subscr_rej), 1083);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_subscr_rej), 11817);
vc_conn.done;
 }

@@ -3945,7 +3945,7 @@
 testcase TC_sgsap_paging_ue_unr() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_ue_unr), 10);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_ue_unr), 11818);
vc_conn.done;
 }

@@ -3984,7 +3984,7 @@
 testcase TC_sgsap_paging_and_nothing() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_and_nothing), 92);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_and_nothing), 
11819);
vc_conn.done;
 }

@@ -4040,7 +4040,7 @@
 testcase TC_sgsap_paging_and_lu() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_and_lu), 9792);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_paging_and_lu), 11820);
vc_conn.done;
 }

@@ -4069,7 +4069,7 @@
 testcase TC_sgsap_unexp_ud() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_unexp_ud), 2145);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_unexp_ud), 11821);
vc_conn.done;
 }

@@ -4093,7 +4093,7 @@
 testcase TC_sgsap_unsol_ud() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_unsol_ud), 146);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_unsol_ud), 11822);
vc_conn.done;
 }

@@ -4239,7 +4239,7 @@
 testcase TC_sgsap_mt_sms() runs on MTC_CT {
var BSC_ConnHdlr vc_conn;
f_init();
-   vc_conn := f_start_handler(refers(f_tc_sgsap_mt_sms), 1145);
+   vc_conn := f_start_handler(refers(f_tc_sgsap_mt_sms), 11823);
vc_conn.done;
 }

@@ -4267,7 +4267,7 @@
 testcase TC_sgsap_mo_sms() runs on MTC_CT 

Change in osmo-sysmon[master]: ctrl: log host/port on errors

2019-02-07 Thread Max
Max has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12318 )

Change subject: ctrl: log host/port on errors
..

ctrl: log host/port on errors

In case of multiple ctrl-client entries in .cfg file it's impossible to
see which one is causing particular ctrl error. Fix this by introducing
macro wrapper for stderr logging which always show host:port relevant to
the error.

Change-Id: I788d51359965a66c54075a3971aa7824c3bfb0bf
Related: SYS#2655
---
M src/simple_ctrl.c
1 file changed, 24 insertions(+), 16 deletions(-)

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



diff --git a/src/simple_ctrl.c b/src/simple_ctrl.c
index 2261323..b56fc83 100644
--- a/src/simple_ctrl.c
+++ b/src/simple_ctrl.c
@@ -37,6 +37,9 @@

 #include "simple_ctrl.h"

+#define CTRL_ERR(cfg, fmt, args...) \
+   fprintf(stderr, "CTRL %s:%u error: " fmt, cfg.remote_host, 
cfg.remote_port, ##args)
+
 /***
  * blocking I/O with timeout helpers
  ***/
@@ -98,20 +101,28 @@
int fd;
uint32_t next_id;
uint32_t tout_msec;
+   struct ctrl_cfg cfg;
 };

 struct simple_ctrl_handle *simple_ctrl_open(void *ctx, const char *host, 
uint16_t dport,
uint32_t tout_msec)
 {
-   struct simple_ctrl_handle *sch;
+   struct simple_ctrl_handle *sch = talloc_zero(ctx, struct 
simple_ctrl_handle);
fd_set writeset;
int off = 0;
int rc, fd;

+   if (!sch)
+   return NULL;
+
+   sch->cfg.name = talloc_strdup(sch, "simple-ctrl");
+   sch->cfg.remote_host = talloc_strdup(sch, host);
+   sch->cfg.remote_port = dport;
+
fd = osmo_sock_init(AF_INET, SOCK_STREAM, IPPROTO_TCP, host, dport,
OSMO_SOCK_F_CONNECT | OSMO_SOCK_F_NONBLOCK);
if (fd < 0) {
-   fprintf(stderr, "CTRL: error connecting socket: %s\n", 
strerror(errno));
+   CTRL_ERR(sch->cfg, "connecting socket: %s\n", strerror(errno));
return NULL;
}

@@ -120,23 +131,20 @@
FD_SET(fd, );
rc = select(fd+1, NULL, , NULL, timeval_from_msec(tout_msec));
if (rc == 0) {
-   fprintf(stderr, "CTRL: timeout during connect\n");
+   CTRL_ERR(sch->cfg, "timeout during connect\n");
goto out_close;
}
if (rc < 0) {
-   fprintf(stderr, "CTRL: error connecting socket: %s\n", 
strerror(errno));
+   CTRL_ERR(sch->cfg, "error connecting socket: %s\n", 
strerror(errno));
goto out_close;
}

/* set FD blocking again */
if (ioctl(fd, FIONBIO, (unsigned char *)) < 0) {
-   fprintf(stderr, "CTRL: cannot set socket blocking: %s\n", 
strerror(errno));
+   CTRL_ERR(sch->cfg, "cannot set socket blocking: %s\n", 
strerror(errno));
goto out_close;
}

-   sch = talloc_zero(ctx, struct simple_ctrl_handle);
-   if (!sch)
-   goto out_close;
sch->fd = fd;
sch->tout_msec = tout_msec;
return sch;
@@ -165,10 +173,10 @@

rc = read_timeout(sch->fd, (uint8_t *) , sizeof(hh), sch->tout_msec);
if (rc < 0) {
-   fprintf(stderr, "CTRL: Error during read: %d\n", rc);
+   CTRL_ERR(sch->cfg, "read(): %d\n", rc);
return NULL;
} else if (rc < sizeof(hh)) {
-   fprintf(stderr, "CTRL: ERROR: short read (header)\n");
+   CTRL_ERR(sch->cfg, "short read (header)\n");
return NULL;
}
len = ntohs(hh.len);
@@ -182,7 +190,7 @@
resp->l2h = resp->tail;
rc = read(sch->fd, resp->l2h, len);
if (rc < len) {
-   fprintf(stderr, "CTRL: ERROR: short read (payload)\n");
+   CTRL_ERR(sch->cfg, "short read (payload)\n");
msgb_free(resp);
return NULL;
}
@@ -214,7 +222,7 @@
*tmp = '\0';
return resp;
} else {
-   fprintf(stderr, "unknown IPA message %s\n", 
msgb_hexdump(resp));
+   CTRL_ERR(sch->cfg, "unknown IPA message %s\n", 
msgb_hexdump(resp));
msgb_free(resp);
}
}
@@ -229,10 +237,10 @@

rc = write_timeout(sch->fd, msg->data, msg->len, sch->tout_msec);
if (rc < 0) {
-   fprintf(stderr, "CTRL: Error during write: %d\n", rc);
+   CTRL_ERR(sch->cfg, "write(): %d\n", rc);
return rc;
} else if (rc < msg->len) {
-   fprintf(stderr, "CTRL: ERROR: short write\n");
+   CTRL_ERR(sch->cfg, "short 

Change in libosmo-netif[master]: Stream client: report reconnection event as INFO

2019-02-07 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12854


Change subject: Stream client: report reconnection event as INFO
..

Stream client: report reconnection event as INFO

This helps to avoid unnecessary debug output in reconnection logic tests
in follow-up patches.

Change-Id: Ic96430a9e9294e72de23b0bbacdbf3e99a453f1d
---
M src/stream.c
1 file changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/54/12854/1

diff --git a/src/stream.c b/src/stream.c
index 7b97d2a..1880e25 100644
--- a/src/stream.c
+++ b/src/stream.c
@@ -172,11 +172,11 @@
osmo_stream_cli_close(cli);

if (cli->reconnect_timeout < 0) {
-   LOGSCLI(cli, LOGL_DEBUG, "not reconnecting, disabled.\n");
+   LOGSCLI(cli, LOGL_INFO, "not reconnecting, disabled.\n");
return;
}

-   LOGSCLI(cli, LOGL_DEBUG, "retrying in %d seconds...\n",
+   LOGSCLI(cli, LOGL_INFO, "retrying in %d seconds...\n",
cli->reconnect_timeout);
osmo_timer_schedule(>timer, cli->reconnect_timeout, 0);
cli->state = STREAM_CLI_STATE_CONNECTING;

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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic96430a9e9294e72de23b0bbacdbf3e99a453f1d
Gerrit-Change-Number: 12854
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in libusrp[master]: Avoid compiler warning 'dynamic exception specifications are deprecat...

2019-02-07 Thread Alexander Huemer
Alexander Huemer has uploaded this change for review. ( 
https://gerrit.osmocom.org/12853


Change subject: Avoid compiler warning 'dynamic exception specifications are 
deprecated in C++11 [-Wdeprecated]'
..

Avoid compiler warning 'dynamic exception specifications are deprecated in 
C++11 [-Wdeprecated]'

Change-Id: Ie472e6f92944cfe1af7d63cd644879573d080ca2
---
M host/include/usrp/usrp_local_sighandler.h
M host/lib/usrp_local_sighandler.cc
2 files changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libusrp refs/changes/53/12853/1

diff --git a/host/include/usrp/usrp_local_sighandler.h 
b/host/include/usrp/usrp_local_sighandler.h
index ee33675..5553680 100644
--- a/host/include/usrp/usrp_local_sighandler.h
+++ b/host/include/usrp/usrp_local_sighandler.h
@@ -55,7 +55,7 @@
   ~usrp_local_sighandler ();

   /* throw usrp_signal (signum) */
-  static void throw_signal (int signum) throw (usrp_signal);
+  static void throw_signal (int signum);
 };

 #endif /* INCLUDED_USRP_LOCAL_SIGHANDLER_H */
diff --git a/host/lib/usrp_local_sighandler.cc 
b/host/lib/usrp_local_sighandler.cc
index 5901397..81bc3d1 100644
--- a/host/lib/usrp_local_sighandler.cc
+++ b/host/lib/usrp_local_sighandler.cc
@@ -64,7 +64,7 @@
 }
 
 void
-usrp_local_sighandler::throw_signal(int signum) throw(usrp_signal)
+usrp_local_sighandler::throw_signal(int signum)
 {
   throw usrp_signal (signum);
 }

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

Gerrit-Project: libusrp
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie472e6f92944cfe1af7d63cd644879573d080ca2
Gerrit-Change-Number: 12853
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Huemer 


Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread tnt
tnt has posted comments on this change. ( https://gerrit.osmocom.org/12625 )

Change subject: assignment_fsm: fix channel allocator preferences
..


Patch Set 8:

(1 comment)

https://gerrit.osmocom.org/#/c/12625/8/include/osmocom/bsc/gsm_data.h
File include/osmocom/bsc/gsm_data.h:

https://gerrit.osmocom.org/#/c/12625/8/include/osmocom/bsc/gsm_data.h@104
PS8, Line 104:  bool full_rate;
Just wondering if it wouldn't be worth directly using GSM_LCHAN_xxx constant in 
there rather than full_rate flag. Because when eventually getting to 3784 we 
will need to express SDCCH/TCH_HS/TCH_FS preferences.

Also about ch_mode_rate_pref, for the same reason it might be worth making it 
an array with a int indicating the # of items because there is 3 possible 
alternative to specify there.

Just my 2ct. Ping @hwelte



--
To view, visit https://gerrit.osmocom.org/12625
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: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-CC: tnt 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:49:16 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in osmo-sysmon[master]: ctrl: log host/port on errors

2019-02-07 Thread daniel
daniel has posted comments on this change. ( https://gerrit.osmocom.org/12318 )

Change subject: ctrl: log host/port on errors
..


Patch Set 7: Code-Review+2


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

Gerrit-Project: osmo-sysmon
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I788d51359965a66c54075a3971aa7824c3bfb0bf
Gerrit-Change-Number: 12318
Gerrit-PatchSet: 7
Gerrit-Owner: Max 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: daniel 
Gerrit-Reviewer: osmith 
Gerrit-CC: Pau Espin Pedrol 
Gerrit-CC: Stefan Sperling 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:36:55 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Jenkins build is back to normal : master-osmo-trx » --with-sse,1,a3=default,a4=default,osmocom-master-debian9 #867

2019-02-07 Thread jenkins
See 




Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread tnt
tnt has posted comments on this change. ( https://gerrit.osmocom.org/12625 )

Change subject: assignment_fsm: fix channel allocator preferences
..


Patch Set 8:

(2 comments)

https://gerrit.osmocom.org/#/c/12625/8/src/osmo-bsc/osmo_bsc_bssap.c
File src/osmo-bsc/osmo_bsc_bssap.c:

https://gerrit.osmocom.org/#/c/12625/8/src/osmo-bsc/osmo_bsc_bssap.c@635
PS8, Line 635:  switch (ct->ch_rate_type & GSM0808_SPEECH_PERM) {
Wait what ? GSM0808_SPEECH_PERM is not a mask, it's an actual possible value of 
the field defined in GSM 08.08 3.2.2.11.

"""
Full or Half rate TCH channel. Preference between the permitted speech versions 
as indicated in
octet 5, 5a etc., changes between full and half rate allowed also after first 
channel allocation as a result of the request
"""


https://gerrit.osmocom.org/#/c/12625/8/src/osmo-bsc/osmo_bsc_bssap.c@637
PS8, Line 637:  rc = match_codec_pref(>ch_mode_rate_pref, ct, 
>codec_list, msc, conn_get_bts(conn),
Given this is used for speech, I'd use the GSM0808_SPEECH_xxx constants.  (I 
know, they have the same values but still).



--
To view, visit https://gerrit.osmocom.org/12625
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: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-CC: tnt 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:32:41 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


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

2019-02-07 Thread daniel
daniel has posted comments on this change. ( https://gerrit.osmocom.org/11992 )

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


Patch Set 10: Code-Review-1

(3 comments)

https://gerrit.osmocom.org/#/c/11992/10/src/libmsc/gsm_09_11.c
File src/libmsc/gsm_09_11.c:

https://gerrit.osmocom.org/#/c/11992/10/src/libmsc/gsm_09_11.c@153
PS10, Line 153: if (conn->network->ncss_guard_timeout > 0) {
This seems like possible race condition if you disable the ncss_guard_timeout 
from VTY while USSD sessions are active. Existing timers will not be 
rescheduled.


https://gerrit.osmocom.org/#/c/11992/10/src/libmsc/gsm_09_11.c@156
PS10, Line 156: }
else if (osmo_timer_pending(>ss.watchdog)) {
  osmo_timer_del(>ss.watchdog);
}


https://gerrit.osmocom.org/#/c/11992/10/src/libmsc/gsm_09_11.c@279
PS10, Line 279: }
My comment above may apply here and elsewere as well



--
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: comment
Gerrit-Change-Id: Icf4d87c45e90324764073e8230e0fb9cb96dd9cb
Gerrit-Change-Number: 11992
Gerrit-PatchSet: 10
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: daniel 
Gerrit-CC: Stefan Sperling 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:33:59 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes


Change in osmo-asf4-dfu[sysmoOCTSIM]: use sysmoOCTSIM USB PID and strings

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12790 )

Change subject: use sysmoOCTSIM USB PID and strings
..

use sysmoOCTSIM USB PID and strings

Change-Id: I1294d5f648240ddbaddeffcfffb4b0d61a88a39e
---
M config/usbd_config.h
1 file changed, 5 insertions(+), 5 deletions(-)

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



diff --git a/config/usbd_config.h b/config/usbd_config.h
index c20dfb2..801ee3c 100644
--- a/config/usbd_config.h
+++ b/config/usbd_config.h
@@ -85,7 +85,7 @@
 // <0x6140=> osmo-ASF4-DFU
 //  usb_dfud_idproduct
 #ifndef CONF_USB_OSMOASF4DFU_IDPRODUCT
-#define CONF_USB_OSMOASF4DFU_IDPRODUCT 0x6140
+#define CONF_USB_OSMOASF4DFU_IDPRODUCT 0x6141
 #endif

 //  bcdDevice <0x-0x>
@@ -107,11 +107,11 @@
 //  Unicode string of iManufact
 //  usb_dfud_imanufact_str
 #ifndef CONF_USB_DFUD_IMANUFACT_STR
-#define CONF_USB_DFUD_IMANUFACT_STR "osmocom"
+#define CONF_USB_DFUD_IMANUFACT_STR "sysmocom"
 #endif

 #ifndef CONF_USB_DFUD_IMANUFACT_STR_DESC
-#define CONF_USB_DFUD_IMANUFACT_STR_DESC 16, 0x03, 'o', 0x00, 's', 0x00, 'm', 
0x00, 'o', 0x00, 'c', 0x00, 'o', 0x00, 'm', 0x00,
+#define CONF_USB_DFUD_IMANUFACT_STR_DESC 18, 0x03, 's', 0x00, 'y', 0x00, 's', 
0x00, 'm', 0x00, 'o', 0x00, 'c', 0x00, 'o', 0x00, 'm', 0x00,
 #endif

 // 
@@ -130,11 +130,11 @@
 //  Unicode string of iProduct
 //  usb_dfud_iproduct_str
 #ifndef CONF_USB_DFUD_IPRODUCT_STR
-#define CONF_USB_DFUD_IPRODUCT_STR "osmo-ASF4-DFU"
+#define CONF_USB_DFUD_IPRODUCT_STR "sysmoOCTSIM (osmo-ASF4-DFU)"
 #endif

 #ifndef CONF_USB_DFUD_IPRODUCT_STR_DESC
-#define CONF_USB_DFUD_IPRODUCT_STR_DESC 28, 0x03, 'o', 0x00, 's', 0x00, 'm', 
0x00, 'o', 0x00, '-', 0x00, 'A', 0x00, 'S', 0x00, 'F', 0x00, '4', 0x00, '-', 
0x00, 'D', 0x00, 'F', 0x00, 'U', 0x00,
+#define CONF_USB_DFUD_IPRODUCT_STR_DESC 56, 0x03, 's', 0x00, 'y', 0x00, 's', 
0x00, 'm', 0x00, 'o', 0x00, 'O', 0x00, 'C', 0x00, 'T', 0x00, 'S', 0x00, 'I', 
0x00, 'M', 0x00, ' ', 0x00, '(', 0x00, 'o', 0x00, 's', 0x00, 'm', 0x00, 'o', 
0x00, '-', 0x00, 'A', 0x00, 'S', 0x00, 'F', 0x00, '4', 0x00, '-', 0x00, 'D', 
0x00, 'F', 0x00, 'U', 0x00, ')', 0x00,
 #endif

 // 

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

Gerrit-Project: osmo-asf4-dfu
Gerrit-Branch: sysmoOCTSIM
Gerrit-MessageType: merged
Gerrit-Change-Id: I1294d5f648240ddbaddeffcfffb4b0d61a88a39e
Gerrit-Change-Number: 12790
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-asf4-dfu[sysmoOCTSIM]: document flashing procedure for sysmoOCTSIM

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12791 )

Change subject: document flashing procedure for sysmoOCTSIM
..

document flashing procedure for sysmoOCTSIM

the sysmoOCTSIM board does not have an onboard EDBG adapter such as
the SAM E54 Xplained Pro board.
instead SWD is used directly.

Change-Id: I85aa4db62464d0a1b558968d0423e2adbe491a4f
---
M README.md
1 file changed, 12 insertions(+), 10 deletions(-)

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



diff --git a/README.md b/README.md
index 031bc27..e39f5c1 100644
--- a/README.md
+++ b/README.md
@@ -1,8 +1,7 @@
 This is an implementation of the DFU mode of the [USB DFU Device Class 
Specification](https://usb.org/document-library/device-firmware-upgrade-11-new-version-31-aug-2004)
 for the Microchip SAM D5x/E5x micro-controller.
 It is meant to be used as bootloader to allow flashing the main application 
over USB.
 
-The code has been developed for the Microchip [SAM E54 Xplained 
Pro](https://www.microchip.com/DevelopmentTools/ProductDetails/PartNo/ATSAME54-XPRO)
 development board using a [SAM 
E54](https://www.microchip.com/wwwproducts/en/ATSAME54P20A) micro-controller.
-It should work on any chip of the SAM D5x/E5x device family by replacing the 
corresponding device-specific definitions (usually including the chip name in 
the file name).
+This branch is specific to the proprietary sysmocom sysmoOCTSIM hardware.

 The code uses the [Atmel START](https://start.atmel.com/) ASFv4 library.

@@ -31,7 +30,7 @@
 Flashing
 

-To flash the bootloader you can either use the [edbg 
tool](https://github.com/ataradov/edbg) over the EDBG interface of the SAM E54 
Xplained Pro development board, or OpenICD with any SWJ adapter.
+To flash the bootloader you can use OpenOCD with any SWJ adapter.

 The USB DFU bootloader should be flashed in a protected area of the flash 
memory to prevent for erasing it, as specified in data sheet section 25.6.2 
Memory Organization.
 The bootloader size is configured in the NVM user configuration BOOTPROT 
field, as specified in data sheet section 25.6.9 NVM User Configuration.
@@ -40,11 +39,14 @@
 This setting will also tell the bootloader where to flash the application 
firmware to (e.g. after the bootloader reserved space).
 The LED will blink once per second if this size is not set.

-EDBG
-
+ST-LINK/V2
+--

-To flash the USB DFU bootloader, perform the following actions:
-* remove reserved bootloader space so we can erase it: `edbg --target 
atmel_cm4v2 --fuse wv,29:26,15`
-* erase the whole flash: `edbg --target atmel_cm4v2 --fuse v,29:26,15 --erase`
-* program the bootloader: `edbg --target atmel_cm4v2 --fuse v,29:26,15 
--program --verify --file AtmelStart.bin`
-* reserve bootloader space: `edbg --target atmel_cm4v2 --fuse wv,29:26,13`
+To flash the USB DFU bootloader, we will use OpenOCD (with the [SAM E54 
patch](http://openocd.zylin.com/#/c/4272/) and a ST-LINK/V2 SWD adapter.
+The command will perform the following actions:
+* remove reserved bootloader space so we can erase it (and reset MCU for 
change to be effective)
+* erase the whole flash
+* program the bootloader
+* reserve bootloader space
+
+`openocd --file interface/stlink.cfg --command "transport select hla_swd" 
--command "set CHIPNAME same54" --command "set CPUTAPID 0x2ba01477" --file 
target/atsame5x.cfg --command "init" --command "reset halt" --command "atsame5 
bootloader 0" --command "flash erase_sector 0 0 last" --command "reset halt" 
--command "program ./AtmelStart.bin" --command "atsame5 bootloader 16384"  
--command "reset run" --command "shutdown"`

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

Gerrit-Project: osmo-asf4-dfu
Gerrit-Branch: sysmoOCTSIM
Gerrit-MessageType: merged
Gerrit-Change-Id: I85aa4db62464d0a1b558968d0423e2adbe491a4f
Gerrit-Change-Number: 12791
Gerrit-PatchSet: 1
Gerrit-Owner: Kévin Redon 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)


Change in osmo-asf4-dfu[sysmoOCTSIM]: change LED and switch to sysmoOCTSIM board

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12789 )

Change subject: change LED and switch to sysmoOCTSIM board
..

change LED and switch to sysmoOCTSIM board

Change-Id: I481d96a284240310b634f6dc0806d4a1972cd3b9
---
M atmel_start_pins.h
M driver_init.c
M usb_dfu_main.c
M usb_start.c
4 files changed, 8 insertions(+), 10 deletions(-)

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



diff --git a/atmel_start_pins.h b/atmel_start_pins.h
index 86e1dfb..7460529 100644
--- a/atmel_start_pins.h
+++ b/atmel_start_pins.h
@@ -27,11 +27,11 @@
 #define GPIO_PIN_FUNCTION_M 12
 #define GPIO_PIN_FUNCTION_N 13

-/** LED pin to indicate system state (pull low to switch on) */
-#define LED_SYSTEM GPIO(GPIO_PORTC, 18)
+/** LED pin to indicate system state (pull high to switch on) */
+#define LED_SYSTEM GPIO(GPIO_PORTC, 26)

 /** User button to force DFu bootloader (connected to ground when pressed) */
-#define BUTTON_FORCE_DFU GPIO(GPIO_PORTB, 31)
+#define BUTTON_FORCE_DFU GPIO(GPIO_PORTC, 14)

 /** USB D+/D- pins */
 #define PA24 GPIO(GPIO_PORTA, 24)
diff --git a/driver_init.c b/driver_init.c
index a91b0eb..d5a151f 100644
--- a/driver_init.c
+++ b/driver_init.c
@@ -144,13 +144,12 @@
init_mcu();

// configure system LED
-   gpio_set_pin_level(LED_SYSTEM, true); // switch off LED
+   gpio_set_pin_level(LED_SYSTEM, false); // switch off LED
gpio_set_pin_direction(LED_SYSTEM, GPIO_DIRECTION_OUT);
gpio_set_pin_function(LED_SYSTEM, GPIO_PIN_FUNCTION_OFF);

// configure force DFU user button
gpio_set_pin_direction(BUTTON_FORCE_DFU, GPIO_DIRECTION_IN);
-   gpio_set_pin_pull_mode(BUTTON_FORCE_DFU, GPIO_PULL_UP);
gpio_set_pin_function(BUTTON_FORCE_DFU, GPIO_PIN_FUNCTION_OFF);

USB_DEVICE_INSTANCE_init();
diff --git a/usb_dfu_main.c b/usb_dfu_main.c
index 449b311..6a524e4 100644
--- a/usb_dfu_main.c
+++ b/usb_dfu_main.c
@@ -48,8 +48,7 @@
  */
 static bool check_force_dfu(void)
 {
-   gpio_set_pin_pull_mode(BUTTON_FORCE_DFU, GPIO_PULL_UP); // pull button 
high
-   return (0 == gpio_get_pin_level(BUTTON_FORCE_DFU)); // signal is low 
when button is pressed
+   return (0 == gpio_get_pin_level(BUTTON_FORCE_DFU)); // signal is low 
when button is pressed (pulled high externally)
 }

 /** Check if the application is valid
diff --git a/usb_start.c b/usb_start.c
index ad91840..ab0f332 100644
--- a/usb_start.c
+++ b/usb_start.c
@@ -80,7 +80,7 @@
 void usb_dfu(void)
 {
while (!dfudf_is_enabled()); // wait for DFU to be installed
-   gpio_set_pin_level(LED_SYSTEM, false); // switch LED on to indicate USB 
DFU stack is ready
+   gpio_set_pin_level(LED_SYSTEM, true); // switch LED on to indicate USB 
DFU stack is ready

ASSERT(hri_nvmctrl_read_STATUS_BOOTPROT_bf(FLASH_0.dev.hw) <= 15);
uint32_t application_start_address = (15 - 
hri_nvmctrl_read_STATUS_BOOTPROT_bf(FLASH_0.dev.hw)) * 8192; // calculate 
bootloader size to know where we should write the application firmware
@@ -89,7 +89,7 @@
while (true) { // main DFU infinite loop
// run the second part of the USB DFU state machine handling 
non-USB aspects
if (USB_DFU_STATE_DFU_DNLOAD_SYNC == dfu_state || 
USB_DFU_STATE_DFU_DNBUSY == dfu_state) { // there is some data to be flashed
-   gpio_set_pin_level(LED_SYSTEM, true); // switch LED off 
to indicate we are flashing
+   gpio_set_pin_level(LED_SYSTEM, false); // switch LED 
off to indicate we are flashing
if (dfu_download_length > 0) { // there is some data to 
be flashed
int32_t rc = flash_write(_0, 
application_start_address + dfu_download_offset, dfu_download_data, 
dfu_download_length); // write downloaded data chunk to flash
if (ERR_NONE == rc) {
@@ -108,7 +108,7 @@
// this case should not happen, but it's not a 
critical error
dfu_state = USB_DFU_STATE_DFU_DNLOAD_IDLE; // 
indicate flashing can continue
}
-   gpio_set_pin_level(LED_SYSTEM, false); // switch LED on 
to indicate USB DFU can resume
+   gpio_set_pin_level(LED_SYSTEM, true); // switch LED on 
to indicate USB DFU can resume
}
if (USB_DFU_STATE_DFU_MANIFEST == dfu_state) { // we can start 
manifestation (finish flashing)
// in theory every DFU files should have a suffix to 
with a CRC to check the data

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

Gerrit-Project: osmo-asf4-dfu
Gerrit-Branch: sysmoOCTSIM
Gerrit-MessageType: merged
Gerrit-Change-Id: 

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

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/11992 )

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


Patch Set 10:

(2 comments)

looks fine to me, except for two typo (ESME/EUSE)  in the commit message, and 
inconsistent naming watchdog vs. guard timer.

https://gerrit.osmocom.org/#/c/11992/10//COMMIT_MSG
Commit Message:

https://gerrit.osmocom.org/#/c/11992/10//COMMIT_MSG@9
PS10, Line 9: ESME
EUSE?


https://gerrit.osmocom.org/#/c/11992/10/include/osmocom/msc/transaction.h
File include/osmocom/msc/transaction.h:

https://gerrit.osmocom.org/#/c/11992/10/include/osmocom/msc/transaction.h@89
PS10, Line 89: watchdog;
in the CC sub-struct above we call it "timer_guard".  I would appreciate if we 
could align here and refer to it as a guard timer, not as a watchdog.  They 
both do the same thing, right?



--
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: comment
Gerrit-Change-Id: Icf4d87c45e90324764073e8230e0fb9cb96dd9cb
Gerrit-Change-Number: 11992
Gerrit-PatchSet: 10
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-CC: Stefan Sperling 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:21:45 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: No


Change in libosmocore[master]: gsm/gsm0480: introduce gsm0480_create_release_complete()

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12839 )

Change subject: gsm/gsm0480: introduce gsm0480_create_release_complete()
..


Patch Set 2: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/12839
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: Ie3ac85fcef90a5e532334ba3482804d5305c88d7
Gerrit-Change-Number: 12839
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:18:21 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-bsc[master]: bsc_vty: add features to disable specific lchans via vty

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12624 )

Change subject: bsc_vty: add features to disable specific lchans via vty
..


Patch Set 8: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/12624
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: I397e68e26d6a1727890353fa34f4897b54795866
Gerrit-Change-Number: 12624
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: dexter 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:16:44 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libusrp[master]: usrp2: firmware: ignore .lk build artifacts

2019-02-07 Thread Harald Welte
Harald Welte has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12849 )

Change subject: usrp2: firmware: ignore .lk build artifacts
..

usrp2: firmware: ignore .lk build artifacts

Change-Id: I79cbb834f02dc3f804e5a1476724245407f0eade
---
M firmware/src/usrp2/.gitignore
1 file changed, 1 insertion(+), 0 deletions(-)

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



diff --git a/firmware/src/usrp2/.gitignore b/firmware/src/usrp2/.gitignore
index 54a9e94..d1557f9 100644
--- a/firmware/src/usrp2/.gitignore
+++ b/firmware/src/usrp2/.gitignore
@@ -6,6 +6,7 @@
 /*.rel
 /*.rst
 /*.sym
+/*.lk
 /blink_leds.asm
 /usrp_common.asm
 /command_loop.asm

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

Gerrit-Project: libusrp
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I79cbb834f02dc3f804e5a1476724245407f0eade
Gerrit-Change-Number: 12849
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Huemer 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 


Change in libusrp[master]: usrp2: firmware: ignore .lk build artifacts

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12849 )

Change subject: usrp2: firmware: ignore .lk build artifacts
..


Patch Set 1: Code-Review+2


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

Gerrit-Project: libusrp
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I79cbb834f02dc3f804e5a1476724245407f0eade
Gerrit-Change-Number: 12849
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Huemer 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:17:03 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12625 )

Change subject: assignment_fsm: fix channel allocator preferences
..


Patch Set 8: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/12625
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: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:16:31 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: libmsc/gsm_04_80.c: add msc_send_ussd_release_complete_cause()

2019-02-07 Thread daniel
daniel has posted comments on this change. ( https://gerrit.osmocom.org/12843 )

Change subject: libmsc/gsm_04_80.c: add msc_send_ussd_release_complete_cause()
..


Patch Set 2: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/#/c/12843/2/include/osmocom/msc/gsm_04_80.h
File include/osmocom/msc/gsm_04_80.h:

https://gerrit.osmocom.org/#/c/12843/2/include/osmocom/msc/gsm_04_80.h@17
PS2, Line 17:uint8_t cause_loc, uint8_t 
cause_val)
; missing here as well



--
To view, visit https://gerrit.osmocom.org/12843
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: I3b9e8e4f473d113d5b9e9e5d33f7914202077203
Gerrit-Change-Number: 12843
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: daniel 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:16:18 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: libmsc/gsm_04_80.c: use gsm0480_create_release_complete()

2019-02-07 Thread daniel
daniel has posted comments on this change. ( https://gerrit.osmocom.org/12840 )

Change subject: libmsc/gsm_04_80.c: use gsm0480_create_release_complete()
..


Patch Set 2: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/#/c/12840/2/include/osmocom/msc/gsm_04_80.h
File include/osmocom/msc/gsm_04_80.h:

https://gerrit.osmocom.org/#/c/12840/2/include/osmocom/msc/gsm_04_80.h@14
PS2, Line 14:  uint8_t transaction_id)
Missing ; is responsible for the build failure



--
To view, visit https://gerrit.osmocom.org/12840
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: Id2975c3383f18e83124ba38927c03980d67ddadb
Gerrit-Change-Number: 12840
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: daniel 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:14:00 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes


Change in libosmo-netif[master]: Use timeout in jenkins job

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12851 )

Change subject: Use timeout in jenkins job
..


Patch Set 1:

This change is ready for review.


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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I815d65f31eec4e0c758478471a553ec2afb59a8d
Gerrit-Change-Number: 12851
Gerrit-PatchSet: 1
Gerrit-Owner: Max 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-CC: Harald Welte 
Gerrit-CC: osmith 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:12:42 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in osmo-bsc[master]: bsc_vty: add features to disable specific lchans via vty

2019-02-07 Thread Harald Welte
Harald Welte has posted comments on this change. ( 
https://gerrit.osmocom.org/12624 )

Change subject: bsc_vty: add features to disable specific lchans via vty
..


Patch Set 8: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/12624
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: I397e68e26d6a1727890353fa34f4897b54795866
Gerrit-Change-Number: 12624
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: dexter 
Gerrit-CC: Vadim Yanitskiy 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:10:20 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmo-netif[master]: Use timeout in jenkins job

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12851 )

Change subject: Use timeout in jenkins job
..


Patch Set 1:

> did we see problems here? has this happened before? should we also do this in 
> other projects?

Yes, the problem is with the follow-up patch which I'm unable to reproduce 
locally yet. So this is just experimental patch (hence WIP). Ideally this 
should be done in jobs/gerrit-verifications.yml for all (most?) jobs. Maybe 
with slightly longer timeout. I'll drop this patch once osmo-ci patch is ready.


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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I815d65f31eec4e0c758478471a553ec2afb59a8d
Gerrit-Change-Number: 12851
Gerrit-PatchSet: 1
Gerrit-Owner: Max 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-CC: Harald Welte 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:11:43 +
Gerrit-HasComments: No
Gerrit-HasLabels: No


Change in libosmo-sccp[master]: Don't use deprecated osmo_stream_cli_open2()

2019-02-07 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12852


Change subject: Don't use deprecated osmo_stream_cli_open2()
..

Don't use deprecated osmo_stream_cli_open2()

Using osmo_stream_cli_open() with explicit timeout set via
osmo_stream_cli_set_reconnect_timeout() will have the same
effect. Update comment explaining this as well as the code.

Change-Id: Iffe6ea48a170880faef071c7c4a1bc0605aa9855
---
M src/osmo_ss7.c
1 file changed, 4 insertions(+), 3 deletions(-)



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

diff --git a/src/osmo_ss7.c b/src/osmo_ss7.c
index 39d92fa..05668b0 100644
--- a/src/osmo_ss7.c
+++ b/src/osmo_ss7.c
@@ -1261,12 +1261,13 @@
else
osmo_stream_cli_set_read_cb(asp->client, 
xua_cli_read_cb);
osmo_stream_cli_set_data(asp->client, asp);
-   rc = osmo_stream_cli_open2(asp->client, 1);
+   rc = osmo_stream_cli_open(asp->client);
if (rc < 0) {
LOGSS7(asp->inst, LOGL_ERROR, "Unable to open stream"
" client for ASP %s\n", asp->cfg.name);
-   /* we don't return error in here because 
osmo_stream_cli_open2()
-  will continue to retry to connect so the error is 
transient  */
+   /* we don't return error in here because 
osmo_stream_cli_open()
+  will continue to retry (due to timeout being 
explicitly set with
+  osmo_stream_cli_set_reconnect_timeout() above) to 
connect so the error is transient */
}
/* TODO: make this configurable and not implicit */
role = XUA_ASPFSM_ROLE_ASP;

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

Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iffe6ea48a170880faef071c7c4a1bc0605aa9855
Gerrit-Change-Number: 12852
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Change in libosmocore[master]: protocol/gsm_04_14: Fix the OPEN LOOP message type

2019-02-07 Thread tnt
tnt has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/12850 )

Change subject: protocol/gsm_04_14: Fix the OPEN LOOP message type
..

protocol/gsm_04_14: Fix the OPEN LOOP message type

Change-Id: Id4350dee4353ebf9de0450dd5dab6e4f2ee7c3a6
Signed-off-by: Sylvain Munaut 
---
M include/osmocom/gsm/protocol/gsm_04_14.h
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Jenkins Builder: Verified
  Max: Looks good to me, but someone else must approve
  Vadim Yanitskiy: Looks good to me, but someone else must approve
  tnt: Looks good to me, approved



diff --git a/include/osmocom/gsm/protocol/gsm_04_14.h 
b/include/osmocom/gsm/protocol/gsm_04_14.h
index 5ef7837..deb474e 100644
--- a/include/osmocom/gsm/protocol/gsm_04_14.h
+++ b/include/osmocom/gsm/protocol/gsm_04_14.h
@@ -20,7 +20,7 @@
 };

 #define GSM414_MT_CLOSE_TCH_LOOP_ACK   0x01/* 8.2 */
-#define GSM414_MT_OPEN_LOOP_CMD0x02/* 8.3 */
+#define GSM414_MT_OPEN_LOOP_CMD0x06/* 8.3 */
 #define GSM414_OPEN_LOOP_ACK_IE0x81

 #define GSM414_MT_CLOSE_MSLOT_LOOP_CMD 0x20/* 8.4 */

--
To view, visit https://gerrit.osmocom.org/12850
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: Id4350dee4353ebf9de0450dd5dab6e4f2ee7c3a6
Gerrit-Change-Number: 12850
Gerrit-PatchSet: 1
Gerrit-Owner: tnt 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: tnt 


Change in libosmocore[master]: protocol/gsm_04_14: Fix the OPEN LOOP message type

2019-02-07 Thread tnt
tnt has posted comments on this change. ( https://gerrit.osmocom.org/12850 )

Change subject: protocol/gsm_04_14: Fix the OPEN LOOP message type
..


Patch Set 1: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/12850
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: Id4350dee4353ebf9de0450dd5dab6e4f2ee7c3a6
Gerrit-Change-Number: 12850
Gerrit-PatchSet: 1
Gerrit-Owner: tnt 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Reviewer: tnt 
Gerrit-Comment-Date: Thu, 07 Feb 2019 10:02:09 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmo-netif[master]: Use timeout in jenkins job

2019-02-07 Thread Max
Max has uploaded this change for review. ( https://gerrit.osmocom.org/12851


Change subject: Use timeout in jenkins job
..

Use timeout in jenkins job

Automatically terminate 'make distcheck' jenkins build job after 5
minutes timeout to make sure tests won't hang indefinitely.

Change-Id: I815d65f31eec4e0c758478471a553ec2afb59a8d
---
M contrib/jenkins.sh
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/51/12851/1

diff --git a/contrib/jenkins.sh b/contrib/jenkins.sh
index f2013a5..7d0d1f2 100755
--- a/contrib/jenkins.sh
+++ b/contrib/jenkins.sh
@@ -37,7 +37,7 @@
 autoreconf --install --force
 ./configure --enable-sanitize --enable-werror
 $MAKE $PARALLEL_MAKE
-$MAKE distcheck \
+timeout 5m $MAKE distcheck \
   || cat-testlogs.sh

 osmo-clean-workspace.sh

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

Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I815d65f31eec4e0c758478471a553ec2afb59a8d
Gerrit-Change-Number: 12851
Gerrit-PatchSet: 1
Gerrit-Owner: Max 


Build failed in Jenkins: master-osmo-trx » --with-sse,1,a3=default,a4=default,osmocom-master-debian9 #866

2019-02-07 Thread jenkins
See 


--
[...truncated 107.33 KB...]
Reading and parsing tag files
Parsing files
Building group list...
Building directory list...
Building namespace list...
Building file list...
Building class list...
Associating documentation with classes...
Computing nesting relations for classes...
Building example list...
Searching for enumerations...
Searching for documented typedefs...
Searching for members imported via using declarations...
Searching for included using directives...
Searching for documented variables...
Building interface member list...
Building member list...
Searching for friends...
Searching for documented defines...
Computing class inheritance relations...
Computing class usage relations...
Flushing cached template relations that have become invalid...
Computing class relations...
Add enum values to enums...
Searching for member function documentation...
Creating members for template instances...
Building page list...
Search for main page...
Computing page relations...
Determining the scope of groups...
Sorting lists...
Freeing entry tree
Determining which enums are documented
Computing member relations...
Building full member lists recursively...
Adding members to member groups.
Computing member references...
Inheriting documentation...
Generating disk names...
Adding source references...
Adding xrefitems...
Sorting member lists...
Computing dependencies between directories...
Generating citations page...
Counting data structures...
Resolving user defined references...
Finding anchors and sections in the documentation...
Transferring function references...
Combining using relations...
Adding members to index pages...
Generating style sheet...
Generating search indices...
Generating example documentation...
Generating file sources...
Generating file documentation...
Generating page documentation...
Generating group documentation...
Generating class documentation...
Generating namespace index...
Generating graph info page...
Generating directory documentation...
Generating index page...
Generating page index...
Generating module index...
Generating namespace index...
Generating namespace member index...
Generating annotated compound index...
Generating alphabetical compound index...
Generating hierarchical class index...
Generating graphical class hierarchy...
Generating member index...
Generating file index...
Generating file member index...
Generating example index...
finalizing index lists...
writing tag file...
Running dot...
Running dot for graph 1/1
lookup cache used 0/65536 hits=0 misses=0
finished...
make[5]: Entering directory 
'
make[5]: Nothing to be done for 'install-exec-am'.
/bin/mkdir -p 

 /bin/mkdir -p 
'
/usr/bin/install -c -m 644 usrp_guide.html 

 /usr/bin/install -c -m 644 ../README 
'
cp -r html 

make[5]: Leaving directory 
'
make[4]: Leaving directory 
'
make[3]: Leaving directory 
'
make[2]: Leaving directory 
'
Making install in firmware
make[2]: Entering directory 

Change in osmo-msc[master]: libmsc/gsm_04_80.c: use gsm0480_create_release_complete()

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12840 )

Change subject: libmsc/gsm_04_80.c: use gsm0480_create_release_complete()
..


Patch Set 2: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/12840
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: Id2975c3383f18e83124ba38927c03980d67ddadb
Gerrit-Change-Number: 12840
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 09:39:05 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-msc[master]: libmsc/gsm_04_80.c: add msc_send_ussd_release_complete_cause()

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12843 )

Change subject: libmsc/gsm_04_80.c: add msc_send_ussd_release_complete_cause()
..


Patch Set 2: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/12843
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: I3b9e8e4f473d113d5b9e9e5d33f7914202077203
Gerrit-Change-Number: 12843
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Yanitskiy 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 09:38:30 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-bsc[master]: bsc_vty: add features to disable specific lchans via vty

2019-02-07 Thread dexter
Hello Neels Hofmeyr, Harald Welte, Jenkins Builder,

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

https://gerrit.osmocom.org/12624

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

Change subject: bsc_vty: add features to disable specific lchans via vty
..

bsc_vty: add features to disable specific lchans via vty

In some test and debug situations it is useful to have the ability to
lock certain lchans in a way that the BSC can not allocate them. One
application might be to simulate an exhaustion of all TCH/H channels in
order to force the BSC to take one of the available TCH/F.

Lets add a command to the vty which alloes us sen lchans from
LCHAN_ST_UNUSED
to LCHAN_ST_BORKEN and vice versa.

Change-Id: I397e68e26d6a1727890353fa34f4897b54795866
Related: OS#3503
---
M src/osmo-bsc/bsc_vty.c
M src/osmo-bsc/lchan_fsm.c
2 files changed, 48 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/24/12624/8
--
To view, visit https://gerrit.osmocom.org/12624
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I397e68e26d6a1727890353fa34f4897b54795866
Gerrit-Change-Number: 12624
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-Reviewer: dexter 
Gerrit-CC: Vadim Yanitskiy 


Change in osmo-bsc[master]: assignment_fsm: fix channel allocator preferences

2019-02-07 Thread dexter
Hello Max, Neels Hofmeyr, Harald Welte, Jenkins Builder,

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

https://gerrit.osmocom.org/12625

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

Change subject: assignment_fsm: fix channel allocator preferences
..

assignment_fsm: fix channel allocator preferences

When the MSC allocates a channel through the ASSIGNMENT REQUEST, it may
ask for a TCH/H and a TCH/F at the same time and tell which of the two
types it prefers.

The process of channel allocation currently selects, based on the BTS,
MSC and MS capabilites exactly one apropriate codec/rate (e.g. TCH/H)
and then tries to allocate it. If that allocation fails, there is no way
to try the second choice and the assignment fails.

For example: The MSC asks for TCH/F and TCH/H, prefering TCH/F, then the
channel allocator will try TCH/F and if it fails (all TCH/F are
currently in use), then TCH/H is never tried.

Since the BSC currently only trys the first best codec/rate that is
supported it also ignores the preference.

Lets fix those problems by including the preference information and both
possible codec/rate settings into the channel allocation decision.

Change-Id: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Related: OS#3503
---
M include/osmocom/bsc/codec_pref.h
M include/osmocom/bsc/gsm_data.h
M src/osmo-bsc/assignment_fsm.c
M src/osmo-bsc/bsc_vty.c
M src/osmo-bsc/codec_pref.c
M src/osmo-bsc/handover_fsm.c
M src/osmo-bsc/osmo_bsc_bssap.c
M tests/codec_pref/codec_pref_test.c
8 files changed, 321 insertions(+), 117 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/25/12625/8
--
To view, visit https://gerrit.osmocom.org/12625
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I5239e05c1cfbcb8af28f43373a58fa6c2d216c51
Gerrit-Change-Number: 12625
Gerrit-PatchSet: 8
Gerrit-Owner: dexter 
Gerrit-Assignee: Neels Hofmeyr 
Gerrit-Reviewer: Harald Welte 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Neels Hofmeyr 
Gerrit-CC: Vadim Yanitskiy 


Change in libosmocore[master]: protocol/gsm_04_14: Fix the OPEN LOOP message type

2019-02-07 Thread Vadim Yanitskiy
Vadim Yanitskiy has posted comments on this change. ( 
https://gerrit.osmocom.org/12850 )

Change subject: protocol/gsm_04_14: Fix the OPEN LOOP message type
..


Patch Set 1: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/12850
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: Id4350dee4353ebf9de0450dd5dab6e4f2ee7c3a6
Gerrit-Change-Number: 12850
Gerrit-PatchSet: 1
Gerrit-Owner: tnt 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Reviewer: Vadim Yanitskiy 
Gerrit-Comment-Date: Thu, 07 Feb 2019 09:25:33 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmocore[master]: protocol/gsm_04_14: Fix the OPEN LOOP message type

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12850 )

Change subject: protocol/gsm_04_14: Fix the OPEN LOOP message type
..


Patch Set 1: Code-Review+1


--
To view, visit https://gerrit.osmocom.org/12850
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: Id4350dee4353ebf9de0450dd5dab6e4f2ee7c3a6
Gerrit-Change-Number: 12850
Gerrit-PatchSet: 1
Gerrit-Owner: tnt 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 09:24:48 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libusrp[master]: usrp2: firmware: ignore .lk build artifacts

2019-02-07 Thread Max
Max has posted comments on this change. ( https://gerrit.osmocom.org/12849 )

Change subject: usrp2: firmware: ignore .lk build artifacts
..


Patch Set 1: Code-Review+1


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

Gerrit-Project: libusrp
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I79cbb834f02dc3f804e5a1476724245407f0eade
Gerrit-Change-Number: 12849
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Huemer 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: Max 
Gerrit-Comment-Date: Thu, 07 Feb 2019 09:22:49 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in libosmocore[master]: protocol/gsm_04_14: Fix the OPEN LOOP message type

2019-02-07 Thread tnt
tnt has uploaded this change for review. ( https://gerrit.osmocom.org/12850


Change subject: protocol/gsm_04_14: Fix the OPEN LOOP message type
..

protocol/gsm_04_14: Fix the OPEN LOOP message type

Change-Id: Id4350dee4353ebf9de0450dd5dab6e4f2ee7c3a6
Signed-off-by: Sylvain Munaut 
---
M include/osmocom/gsm/protocol/gsm_04_14.h
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/50/12850/1

diff --git a/include/osmocom/gsm/protocol/gsm_04_14.h 
b/include/osmocom/gsm/protocol/gsm_04_14.h
index 5ef7837..deb474e 100644
--- a/include/osmocom/gsm/protocol/gsm_04_14.h
+++ b/include/osmocom/gsm/protocol/gsm_04_14.h
@@ -20,7 +20,7 @@
 };

 #define GSM414_MT_CLOSE_TCH_LOOP_ACK   0x01/* 8.2 */
-#define GSM414_MT_OPEN_LOOP_CMD0x02/* 8.3 */
+#define GSM414_MT_OPEN_LOOP_CMD0x06/* 8.3 */
 #define GSM414_OPEN_LOOP_ACK_IE0x81

 #define GSM414_MT_CLOSE_MSLOT_LOOP_CMD 0x20/* 8.4 */

--
To view, visit https://gerrit.osmocom.org/12850
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: Id4350dee4353ebf9de0450dd5dab6e4f2ee7c3a6
Gerrit-Change-Number: 12850
Gerrit-PatchSet: 1
Gerrit-Owner: tnt