Benjamin Valentin
5602587dd7
sys/sema_inv: add inverse Semaphore
...
It is often desiderable to sync on multiple threads, e.g. there can be a controller
thread that waits for `n` worker threads to finish their job.
An inverse semaphore provides an easy primitive to implement this pattern.
After being initialized with a value `n` (in counter mode), a call to `sema_inv_wait()`
will block until each of the `n` threads has called `sema_inv_post()` exactly once.
There are situations where workers might post an event more than once
(unless additional state is introduced).
For this case, the alternative mask mode is provided.
Here the inverse semaphore is initialized with a bit mask, each worker can clear one
or multiple bits with `sema_inv_post_mask()`. A worker can clear it's bit multiple times.
2021-01-17 00:17:58 +01:00
Marian Buschsieweke
9029d6f7c2
Merge pull request #15757 from maribu/sock-aux-cleanup
...
sys/net/gnrc/sock: cleanup & fix aux handling
2021-01-12 22:57:21 +01:00
Marian Buschsieweke
dd68fb7273
tests/gnrc_sock_{ip,udp}: fix copy paste error
2021-01-12 22:00:43 +01:00
Marian Buschsieweke
8f24cc840c
sys/net/gnrc/sock: cleanup & fix aux handling
...
The logic used to check whether the RX timestamp was provided in the GNRC
implementation of `sock_ip_recv_buf_aux()` is incorrect: It still uses in-band
signalling via a timestamp of zero, but a dedicated flag was added to allow for
timestamps of zero.
Additionally, it is not necessary to check if a bit is set only to clear it -
clearing it unconditionally is faster and smaller.
2021-01-12 21:31:24 +01:00
Martine Lenders
3fdf9f925e
Merge pull request #15745 from aabadie/pr/ci/tests-on-iotlab-fix
...
ci/test-on-iotlab: fix unsupported set-env command
2021-01-12 19:20:01 +01:00
703c33fd3e
Merge pull request #15752 from aabadie/pr/tests/usbus_hid_cleanup
...
tests/usbus_hid: uncrustify and cleanup Makefile
2021-01-12 18:52:32 +01:00
benpicco
20f2ab44ac
Merge pull request #15556 from benpicco/cpu/samd51-spurious_tamper
...
cpu/samd5x: RTC: add timeout to spurious tamper event
2021-01-12 18:22:49 +01:00
Benjamin Valentin
3a7aa5d09a
cpu/sam0_common: RTC: add timeout to spurious tamper event
...
Errate 2.17.4 says:
> Upon enabling the RTC tamper detection feature, a false tamper
> detection *can* be reported by the RTC.
It turns out that this spurious event is not always generated.
If RTC alarm is used and the CPU was previously woken from hibernate
by RTC, it *can* happen that the false tamper event is *not* generated.
In this case, we will block indefinitely on the mutex.
To solve this, add a timeout to the event.
Also poll the event instead of using a mutex, as we have already set
`PM->SLEEPCFG.bit.SLEEPMODE` at this point.
2021-01-12 17:36:40 +01:00
Martine Lenders
7a6dec464e
Merge pull request #15644 from miri64/dist/enh/externc-annotate
...
dist/tools/externc: annotate errors in Github Action
2021-01-12 17:24:57 +01:00
Martine Lenders
750e656b6f
Merge pull request #15645 from miri64/dist/enh/cppcheck-annotate
...
dist/tools/cppcheck: annotate errors in Github Action
2021-01-12 17:24:40 +01:00
60688d15c7
tests/usbus_hid: cleanup USB variable access in Makefile
2021-01-12 17:24:00 +01:00
c7781189b7
tests/usbus_hid: uncrustify main.c
2021-01-12 17:23:10 +01:00
Martine Lenders
d5ec8494ec
Merge pull request #15749 from miri64/dist/fix/headerguards-multi-patch
...
dist/tools/headerguards: fix annotation for multiple patches per file
2021-01-12 17:22:01 +01:00
benpicco
acd846653a
Merge pull request #15728 from leandrolanzieri/pr/cpu/kinetis/fix_lptmr_timer
...
cpu/kinetis: fix compile issue in LPTMR timer
2021-01-12 16:29:49 +01:00
a469942ecf
Merge pull request #15747 from miri64/dist/enh/coccinelle-annotate
...
dist/tools/coccinelle: annotate errors in Github Action
2021-01-12 15:38:42 +01:00
Leandro Lanzieri
2cf3c603c7
cpu/kinetis/timer: consider no LPTMR when no config present
2021-01-12 15:31:37 +01:00
Leandro Lanzieri
c516832211
boards/pba-d-01-kw2x: not define LPTMR_ISR_1
2021-01-12 15:31:34 +01:00
Martine Lenders
b711515e76
dist/tools/headerguards: fix annotation for multiple patches per file
2021-01-12 15:04:02 +01:00
Martine Lenders
b5a0dd5ab7
dist/tools/coccinelle: annotate errors in Github Action
2021-01-12 14:51:51 +01:00
daa75c9ccd
Merge pull request #15746 from miri64/dist/enh/headerguard-annotate
...
dist/tools/headerguards: annotate errors in Github Action
2021-01-12 14:17:54 +01:00
Martine Lenders
3ffe6f665f
dist/tools/headerguards: annotate errors in Github Action
2021-01-12 12:52:54 +01:00
Martine Lenders
94d9555b72
Merge pull request #15737 from miri64/readme/enh/merge-chance
...
README: Add merge-chance badge
2021-01-12 12:21:59 +01:00
2e2f950ca7
Merge pull request #15460 from dylad/pr/usbus/dfu_riotboot
...
usbus/dfu: add Device Firmware Upgrade support for USBUS (2nd attempt)
2021-01-12 12:04:58 +01:00
benpicco
eb26cd83c4
Merge pull request #15743 from benpicco/tests/periph_flashpage-print_offset
...
tests/periph_flashpage: print config page address
2021-01-12 11:49:01 +01:00
dylad
7fc5bb483b
makefiles/dfu-util: automatically generate DFU_USB_ID
2021-01-12 11:34:22 +01:00
dylad
bca340d338
cpu/nrf52: update RIOTBOOT_LEN w/ MODULE_USBUS_DFU
2021-01-12 11:34:22 +01:00
dylad
25d0dffa61
Kconfig: add Kconfig support for DFU
2021-01-12 11:34:22 +01:00
dylad
e87bb6a0f9
bootloader: create new bootloader application with DFU support
2021-01-12 11:34:22 +01:00
dylad
beb0fb752c
sys/riotboot: add DFU support to riotboot
2021-01-12 11:34:22 +01:00
dylad
f3908bed9f
sys/auto_init: add support for USB DFU
2021-01-12 11:34:22 +01:00
dylad
9d02efb4ea
cpu/cortexm_common: increase RIOTBOOT_LEN size when usbus_dfu is used
2021-01-12 11:34:22 +01:00
dylad
669a8ec7b3
usbus/dfu: introduce initial Device Firmware Upgrade support for USBUS
2021-01-12 11:34:22 +01:00
4363b3ea2e
ci/test-on-iotlab: fix unsupported set-env function
2021-01-12 11:23:12 +01:00
Marian Buschsieweke
ca34879a91
Merge pull request #15744 from aabadie/pr/ci/gh_actions_block_feature_freeze
...
ci/check-labels: fail for PR blocked by feature freeze label
2021-01-12 11:19:58 +01:00
42f6f028eb
ci/check-labels: fail for PR blocked by feature freeze label
2021-01-12 10:45:55 +01:00
Martine Lenders
2eec26a0f8
Merge pull request #15740 from aabadie/pr/tools/headerguards_check_fix
...
tools/headerguards: also catch messages from stderr
2021-01-12 10:31:46 +01:00
Martine Lenders
19565f4aea
Merge pull request #15741 from aabadie/pr/boards/lpc1768_common_conf
...
boards/lpc1768: move vendor conf code to CPU level
2021-01-12 10:30:03 +01:00
1be0a29f62
Merge pull request #15742 from aabadie/pr/sys/posix_fcntl_headerguard_fix
...
[RFC] sys/posix/fcntl: fix headerguard
2021-01-12 10:12:19 +01:00
Benjamin Valentin
4e1ee2253f
tests/periph_flashpage: print config page offset
2021-01-12 08:43:38 +01:00
benpicco
fee3a8540f
Merge pull request #15725 from seeseemelk/bugfix/stm32-uart-fw
...
stm32/periph/uart: set flow control bits before enabling uart
2021-01-12 08:38:45 +01:00
Sebastiaan de Schaetzen
6e90111eb9
stm32/periph/uart: set flow control bits before enabling uart
2021-01-12 07:37:19 +01:00
Dylan Laduranty
916f554d2a
Merge pull request #14629 from Ollrogge/usb_hid_pr
...
USB HID minimal implementation
2021-01-11 20:17:52 +01:00
Martine Lenders
628b45d975
dist/tools/externc: annotate errors in Github Action
2021-01-11 16:59:16 +01:00
Martine Lenders
1c310c6926
dist/tools/cppcheck: annotate errors in Github Action
2021-01-11 16:58:47 +01:00
Martine Lenders
f1600af701
Merge pull request #15642 from miri64/dist/enh/doccheck-annotate
...
dist/tools/doccheck: annotate errors in Github Action
2021-01-11 16:55:05 +01:00
Martine Lenders
619d013d6e
github_annotate.sh: fix usage and function of _github_annotate
2021-01-11 15:57:14 +01:00
Martine Lenders
429a2a8724
github_annotate.sh: fix escaped echo for bash scripts
2021-01-11 15:57:14 +01:00
Martine Lenders
9ee568e319
dist/tools/doccheck: annotate errors in Github Action
2021-01-11 15:57:14 +01:00
benpicco
08ef8622f7
Merge pull request #15362 from benpicco/tests/mtd_raw
...
tests/mtd_raw: add simple test for MTD
2021-01-11 15:41:00 +01:00
Martine Lenders
db81377af7
dist/tools/doccheck: only exit after when every check ran
...
Doxygen takes an eternity to finish anyways, so it does not hurt to not
early exit for the group checks.
2021-01-11 15:27:21 +01:00