[riot-notifications] [RIOT-OS/RIOT] tests/gnrc_tcp_*: #2 not working on 6Lo-based boards (#10956)

Peter Kietzmann notifications at github.com
Wed Feb 6 10:54:09 CET 2019


#### Description
In #10947 and #10950 we found and fixed an issue which let a board hard fault running the above mentioned apps. Now that this is fixed it turns out the code is executed but the protocol doesn't work. Looking at a sniffer, all I see is Router Solicitations, nothing more. Digging a bit deeper it seems that TCP packets are dropped within the network stack:

- The packet is dropped in the NIB [here](https://github.com/RIOT-OS/RIOT/blob/master/sys/net/gnrc/network_layer/ipv6/nib/nib.c#L209) because `netif` is NULL
- `netif` is NULL because it was initialized [here](https://github.com/RIOT-OS/RIOT/blob/master/sys/net/gnrc/network_layer/ipv6/gnrc_ipv6.c#L527) and **not** set again baceause the `pkt->type` is **not** `GNRC_NETTYPE_NETIF`, compare [this statement](https://github.com/RIOT-OS/RIOT/blob/master/sys/net/gnrc/network_layer/ipv6/gnrc_ipv6.c#L533)

I think this is missing somewhere:
`gnrc_pktsnip_t *netif = gnrc_netif_hdr_build(NULL, 0, NULL, 0);`


#### Steps to reproduce the issue
- Optionally enable debug messages in [gnrc_ipv6.c](https://github.com/RIOT-OS/RIOT/blob/master/sys/net/gnrc/network_layer/ipv6/gnrc_ipv6.c) and [nib.c](https://github.com/RIOT-OS/RIOT/blob/master/sys/net/gnrc/network_layer/ipv6/nib/nib.c) 
- Optionally use a 802.15.4 sniffer on channel 20 (RIOT defualt channel)

**server**
``TCP_LOCAL_ADDR=<ll_addr_server> BOARD=samr21-xpro make flash term SERIAL=XXX PORT=/dev/ttyXXX``

**client**
``TCP_TARGET_ADDR=<ll_addr_server> BOARD=samr21-xpro make flash term SERIAL=XXX PORT=/dev/ttyXXX``


#### Expected results
TCP connection should be established.


#### Actual results
No packets are sent -> no connection establishment. Instead, with above mentioned and enabled debug messages, would should get information from the NIB module that host is unreachable.

#### Versions
```
Operating System Environment
-----------------------------
       Operating System: "Ubuntu" "18.04.1 LTS (Bionic Beaver)"
                 Kernel: Linux 4.15.0-45-generic x86_64 x86_64

Installed compiler toolchains
-----------------------------
             native gcc: gcc (Ubuntu 7.3.0-27ubuntu1~18.04) 7.3.0
      arm-none-eabi-gcc: arm-none-eabi-gcc (GNU Tools for Arm Embedded Processors 7-2018-q3-update) 7.3.1 20180622 (release) [ARM/embedded-7-branch revision 261907]
                avr-gcc: missing
       mips-mti-elf-gcc: missing
             msp430-gcc: msp430-gcc (GCC) 4.6.3 20120301 (mspgcc LTS 20120406 unpatched)
   riscv-none-embed-gcc: missing
   xtensa-esp32-elf-gcc: missing
   xtensa-lx106-elf-gcc: missing
                  clang: missing

Installed compiler libs
-----------------------
   arm-none-eabi-newlib: "3.0.0"
    mips-mti-elf-newlib: missing
riscv-none-embed-newlib: missing
xtensa-esp32-elf-newlib: missing
xtensa-lx106-elf-newlib: missing
               avr-libc: missing (missing)

Installed development tools
---------------------------
                  cmake: cmake version 3.10.2
               cppcheck: missing
                doxygen: 1.8.13
                 flake8: 3.6.0 (mccabe: 0.6.1, pycodestyle: 2.4.0, pyflakes: 2.0.0) CPython 3.6.7 on Linux
                    git: git version 2.17.1
                   make: GNU Make 4.1
                openocd: Open On-Chip Debugger 0.10.0
                 python: Python 2.7.15rc1
                python2: Python 2.7.15rc1
                python3: Python 3.6.7
             coccinelle: missing
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/issues/10956
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190206/a29bb369/attachment.html>


More information about the notifications mailing list