1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

6127 Commits

Author SHA1 Message Date
JulianHolzwarth
1bcb4fcc5f xtimer/xtimer.c: _mutex_timeout improvements
Only yields and change threads status when thread was removed from mutex list.
2019-08-09 17:29:40 +02:00
JulianHolzwarth
a321dfc51d xtimer/xtimer.c: ensure modifing mutex is done with interrupt disabled
if xtimer_set spins the callback is executed in the thread context.

comment to explain irq_disable
and when this line could be removed
(when xtimer stops executing the callback funtion from thread context)
2019-08-09 17:28:54 +02:00
JulianHolzwarth
ca8169f323 sys/include/xtimer.h: xtimer_mutex_lock_timeout() change comment
removing line because core_thread_flags is not required
2019-07-05 17:28:35 +02:00
Martine Lenders
f3493aa2b6
Merge pull request #11796 from kaspar030/pktbuf_remove_uio.h
gnrc/pktbuf: remove obsolete sys/uio.h include
2019-07-04 21:29:36 +02:00
de244e6679 gnrc/pktbuf: remove obsolete sys/uio.h include
This was previously used by gnrc_pktbuf_get_iovec() for the definitions
of "struct iovec", which has been removed a while ago.
2019-07-04 16:12:57 +02:00
Robin
4729bea46e
stm32_eth: Multiple Improvements of the original codebase
stm32eth: Move to stm32_common periph
cpu/stm32_periph_eth: Rebase to current master branch

- Update DMA to use new vendor headers
- Update send to use iolist. It looks like the packet headers are now transfered as seperate iolist entries which results in the eth periph sending each header as own packet. To fix this a rather ugly workaround is used where the whole iolist content is first copied to a static buffer. This will be fixed soon in another commit
- If MAC is set to zero use luid to generate one
- Small code style fixes

cpu/stm312f7: Add periph config for on-board ethernet
boards/nucleo-f767zi: Add config for on board ethernet
tests/stm32_eth_lwip: Remove board restriction
boards/common/nucleo: Add luid module if stm32 ethernet is used
tests/stm32_eth_gnrc: Add Testcase for gnrc using the stm32 eth periph
stm32_eth: Rework netdev driver layour
tests/stm32_eth_*: Use netdev driver header file for prototypes
stm32_eth: Add auto init for stm32 eth netdev driver
boards/stm32: Enable ethernet conf for nucleo boards
stm32_eth_auto_init: Add dont be pendantic flag
stm32_eth: Remove dma specific stuff from periph_cpu.h

Looks like this was implemented in PR #9171 and 021697ae94 with the same interface.

stm32_eth: Remove eth feature from stm32f4discovery boards
stm32_eth: Migrate to stm32 DMA API
stm32_eth: Add iolist to module deps
stm32_eth: Rework send function to use iolist
stm32_eth: Fix ci build warnings
stm32_eth: Fix bug introduced with iolist usage
stm32_eth: Remove redundant static buffer
stm32_eth: Fix feature dependencies
stm32_eth: Fix wrong header guard name
stm32_eth: Implement correct l2 netstats interface
stm32_eth: Rename public functions to stm32_eth_*
stm32_eth: Fix doccheck
stm32_eth: Move register DEFINE to appropriate header file
stm32_eth: remove untested configuration for f446ze boards
stm32_eth: Move periph configuration struct to stm32_common
stm32_eth: Fix naming of eth_phy_read and eth_phy_write
stm32_eth: Remove obsolete test applications
2019-07-04 15:27:26 +02:00
Hauke Petersen
eb50d4704a net/emcute: make cli ID conform to standard 2019-07-04 11:04:22 +02:00
Hauke Petersen
785f59fb7f net/asymcute: make cli ID len conform to standard 2019-07-04 11:03:37 +02:00
Hauke Petersen
16fa111c76 net/mqttsn: add min&max allowed len for client ID 2019-07-04 11:02:45 +02:00
Kevin "Bear Puncher" Weiss
6176878153
Merge pull request #11786 from miri64/gnrc_tftp/fix/set-dst-port-on-server-init
gnrc_tftp: set port on server init
2019-07-04 08:49:31 +02:00
Martine Lenders
16f0751102
Merge pull request #11745 from miri64/gnrc_ipv6/fix/rm-dangerous-dup
gnrc_ipv6: remove obsolete and harmful reception code
2019-07-03 23:50:06 +02:00
Martine Lenders
0cc4c50919
Merge pull request #11780 from miri64/gnrc_pktbuf/cleanup/rm-duplicate_upto
gnrc_pktbuf: remove gnrc_pktbuf_duplicate_upto
2019-07-03 17:44:08 +02:00
Martine S. Lenders
1c946a1af4 gnrc_tftp: set port on server init 2019-07-03 16:49:43 +02:00
Ken Bannister
3d33400b04
Merge pull request #11779 from miri64/gcoap/doc/rm-req_send2
gcoap: remove all references to `gcoap_req_send2()`
2019-07-03 10:35:27 -04:00
Kevin "Bear Puncher" Weiss
cd6544ebe0
Merge pull request #11778 from miri64/gnrc_tftp/doc/deprecate
gnrc_tftp: add deprecation note
2019-07-03 16:09:39 +02:00
Martine S. Lenders
01fc3d8f0b gnrc_tftp: add deprecation note 2019-07-03 15:11:41 +02:00
Martine S. Lenders
b83430aa62 gnrc_pktbuf: remove gnrc_pktbuf_duplicate_upto
The removal of this function was already announced for the 2019.04
release. So it is safe to remove it.
2019-07-03 15:09:18 +02:00
Martine S. Lenders
7e70bf3ac1 cord_epsim: replace gcoap_req_send2() 2019-07-03 15:02:22 +02:00
Martine S. Lenders
0579ef952e cord_ep: replace gcoap_req_send2() 2019-07-03 15:02:15 +02:00
Martine S. Lenders
c9179a26c8 gcoap: replace internal references to gcoap_req_send2()
`gcoap_req_send2()` is deprecated and was replaced with
`gcoap_req_send()`.
2019-07-03 15:00:06 +02:00
Martine Lenders
e8650f5b9a
Merge pull request #11773 from miri64/gnrc_tftp/fix/uninitialized-values
gnrc_tftp: initialize unititialized 'tftp_context_t'
2019-07-03 14:52:46 +02:00
Martine S. Lenders
ea449f3f9e gnrc_ipv6: remove obsolete and harmful reception code
When reworking the reception of IPv6 packets I reset a previously set
`ipv6` snip as follows  when the IPv6 extension handler returns a
packet (see first hunk of this commit):

```C
ipv6 = pkt->next->next
```

With `gnrc_ipv6_ext` this makes *somewhat* sense, `pkt->next` was
previously equal to `ipv6` and after the function call `pkt->next`
is the marked extension header, while `pkt->next->next` is the IPv6
header. However, since `ipv6` is already write-protected i.e.
`ipv6->users == 1` (see ll. 665-675), any additional call of
`gnrc_pktbuf_start_write()` [won't][start-write-doc] duplicate the
packet. In fact, the only `gnrc_pktbuf_start_write()` in
`gnrc_ipv6_ext` is used to send the *result* to the subscribers of that
extension header type, leaving the original packet unchanged for the
caller. As such `ipv6` remains the pointer to the IPv6 header whether
we set it in the line above or not. So we actually don't need that
line.

However, the extension header handling also returns a packet when
`gnrc_ipv6_ext` is not compiled in. In that case it is just a dummy
define that returns the packet you give provide it which means that
this still holds true: `pkt->next == ipv6`.
So setting `ipv6` in this case is actually harmful, as `ipv6` now
points to the NETIF header [following the IPv6 header][pkt-structure]
in the packet and this causes the `user` counter of that NETIF header
`hdr` to be decremented if `hdr->users > 1` in the write-protection I
removed in hunk 2 of this commit:

```C
/* pkt might not be writable yet, if header was given above */
ipv6 = gnrc_pktbuf_start_write(ipv6);
if (ipv6 == NULL) {
    DEBUG("ipv6: unable to get write access to packet: dropping it\n");
    gnrc_pktbuf_release(pkt);
    return;
}
```

But as we already established, `ipv6->users` is already 1, so we don't
actually need the write protection here either.

Since the packet stays unchanged after the `ipv6` snip, we also don't
need to re-search for `netif_hdr` after the other two lines are
removed.

[start-write-doc]: https://doc.riot-os.org/group__net__gnrc__pktbuf.html#ga640418467294ae3d408c109ab27bd617
[pkt-structure]: https://doc.riot-os.org/group__net__gnrc__pkt.html#ga278e783e56a5ee6f1bd7b81077ed82a7
2019-07-03 14:44:03 +02:00
Martine S. Lenders
7ba928faa3 gnrc_tftp: make it working again with link-local addresses 2019-07-03 14:04:26 +02:00
Martine Lenders
2fce0950bf gnrc_tftp: set dst_port when duplicated data received 2019-07-03 12:51:10 +02:00
22796b7438
riotboot/flashwrite: fix typo in doxygen documentation 2019-07-02 11:39:51 +02:00
Martine Lenders
3d9c7ee5de gnrc_tftp: set source port for server 2019-07-01 22:56:42 +02:00
Martine Lenders
5ec0b1609a gnrc_tftp: initialize unititialized 'tftp_context_t' values to 0 2019-07-01 22:55:31 +02:00
Sebastian Meiling
57361470dd
Merge pull request #11737 from nmeum/pr/gnrc_tftp_mode_compare
gnrc_tftp: Fix out-of-bounds memory access when comparing modes
2019-07-01 09:26:03 +02:00
Leandro Lanzieri
326ec30074
Merge pull request #11741 from jcarrano/deprecate-ubjson
sys/ubjson: deprecate module.
2019-06-28 19:41:21 +02:00
Juan Carrano
2d782bc225 sys/ubjson: add deprecation notices to the documentation.
Add @deprecated doxygen tags to the module, the header and the main
reader and writer functions.
2019-06-28 18:32:51 +02:00
Juan Carrano
3b8deac3e9 sys/ubjson: deprecate module.
Summary for Users
=================

 Deprecation is scheduled for 2020.01.
 Users which depend on this module and cannot switch libraries may copy
 the code into to their own application.

As expressed in PR #11724, the UBJSON module has issues which are not easy
or worth fixing.

Before removing the module, it should be marked as deprecated to give users
time to either migrate to another library, or copy the code to their own
private repo.

The deprecation warning has been supressed from the unit tests. This has the
ugly side-effect of supressing deprecation warning in other unit tests too,
but that should not last long, only until the module is finally deleted.
2019-06-28 18:28:16 +02:00
Jose Alamos
ca8c78116f drivers/sx127x: add NETOPT_RX_SYMBOL_TIMEOUT setter 2019-06-27 15:43:50 +02:00
Jose Alamos
268e6df950 drivers/sx127x: add NETOPT_RANDOM option handling 2019-06-27 15:43:50 +02:00
Jose Alamos
77162b8c6f drivers/sx127x: add NETOPT_SYNCWORD option handling 2019-06-27 15:43:50 +02:00
Hauke Petersen
83c679a99c net/ble.h: add some svc and char UUIDs 2019-06-27 11:56:09 +02:00
Sören Tempel
a26942632a gnrc_tftp: Fix out-of-bounds memory access when comparing modes 2019-06-27 10:21:42 +02:00
Sebastian Meiling
4f5ce88ba6
Merge pull request #7421 from OTAkeys/pr/dev_urandom
devfs: add /dev/urandom and /dev/hwrng
2019-06-26 21:33:32 +02:00
Gaëtan Harter
eab0a88642
Merge pull request #11679 from JulianHolzwarth/pr/xtimer_mutex_lock_timeout/first_tests
tests/xtimer_mutex_lock_timeout: add simple case test
2019-06-26 16:27:39 +02:00
Martine S. Lenders
299c1a2959 shell_commands: fix regression to ifconfig introduced in #10350
The indentation of `ifconfig` is currently broken, due to an attempt to
fix some `scan-build` errors.
2019-06-26 10:30:26 +02:00
7b8612b38d
sys/net: add netopt options for lorawan 2019-06-25 13:53:25 +02:00
f52d5ebde7
drivers: sys: replace USE_ETHOS_FOR_STDIO macro by MODULE_STDIO_ETHOS 2019-06-23 22:16:03 +02:00
968e53b74f
Merge pull request #11726 from keestux/usb-some-refactoring
usbus: simplify adding entry to list
2019-06-20 17:45:35 +02:00
14d9f54abb
Merge pull request #11598 from aabadie/pr/missing_stdio_uart_rx
Add stdin pseudo module and set it as dependency for applications using getchar
2019-06-20 17:11:46 +02:00
Martine Lenders
3ee75c3ca9 gnrc_sixlowpan_iphc: assure ctx != NULL for dst compression
For the source address compression it was already done the same way in
12bcc46f15
2019-06-20 16:18:23 +02:00
Martine Lenders
2cb0ccc800 shell_commands: gnrc_netif: fix _newline() handling 2019-06-20 16:18:23 +02:00
Martine Lenders
3edb52de0c gnrc_rpl_dodag: remove new_best assignment at initialization
The variable is without usage reassigned with `dodag->parent` below.
2019-06-20 16:18:23 +02:00
Martine Lenders
fa95cc8090 gnrc_ipv6_nib: assure netif != NULL in route info callback 2019-06-20 16:18:23 +02:00
c10905623d
sys/stdio_uart: document stdin module requirement 2019-06-20 16:01:45 +02:00
Kees Bakker
4a06b9109b usbus: simplify adding entry to list 2019-06-19 22:22:10 +02:00
Martine S. Lenders
9ba22083ee sock_ip: fix documenation referring to UDP sock 2019-06-19 14:18:45 +02:00