1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-26 15:03:53 +01:00

9110 Commits

Author SHA1 Message Date
Gunar Schorcht
323d263629 cpu/esp_common: fix FreeRTOS rmutex handling
The ESP-IDF WiFi interface wrapper always calls `xSemaphoreTakeRecursive` and `xSemaphoreGiveRecursive` for mutexes, regardless of whether they are recursive or not. Instead of an `assert`, the fix now also checks the type of the mutex in the functions for recursive mutexes and then calls the functions for normal mutexes if the mutex is not recursive.
2025-12-02 14:54:52 +01:00
Marian Buschsieweke
0967c6b56f
cpu/sam0_common/periph_i2c: reliably unstuck bus
On a setup I have on my desk I can reliably get the I2C bus stuck. But
the current unstuck logic will not get it unstuck. Adding a full reset
of the SERCOM does fix the issue, though.

Co-authored-by: crasbe <crasbe@gmail.com>
2025-11-27 14:01:16 +01:00
Marian Buschsieweke
ed50187b34
Merge pull request #21915 from maribu/cpu/native/libucontext/fix-lockup
cpu/native: fix lockup on libucontext
2025-11-26 11:56:44 +00:00
Marian Buschsieweke
87af1a4b58
cpu/native: fix lockup on libucontext
The `setcontext()` implementation of glibc does restore the signal
mask to the target thread during the switch, libucontext [does not][1]

[1]: https://man.archlinux.org/man/libucontext.3.en#CAVEATS

Instead, we just manually enable signals again just before the call
to `setcontext()`.

With this, tests like `tests/core/mutex_canel` or `tests/core/irq` now
pass on `native64` when using libucontext.

Co-authored-by: crasbe <crasbe@gmail.com>
2025-11-26 12:43:09 +01:00
Mikolai Gütschow
bb192ee2c6
cpu/native: implement fputc, too 2025-11-24 16:49:16 +01:00
Mikolai Gütschow
f13f2889d7
cpu/native: implement fputs and fwrite 2025-11-24 16:28:57 +01:00
Marian Buschsieweke
8007a1ff6d
Merge pull request #21872 from maribu/dist/tools/PyCortexMDebug
cpu/{sam0_common,stm32}: Provide SVD_VENDOR and SVD_MODEL
2025-11-12 10:00:46 +00:00
Marian Buschsieweke
9a5a8e3d92
cpu/stm32: Provide SVD_VENDOR and SVD_MODEL
With this, running `make USE_PYCORTEXMDEBUG=1 debug` for almost any STM32
based board will directly load the correct SVD file.
2025-11-11 15:15:40 +01:00
Marian Buschsieweke
f5eb7c1b1b
cpu/sam0_common: Provide SVD_VENDOR and SVD_MODEL
With this, running `make USE_PYCORTEXMDEBUG=1 debug` for any SAM0 based
board will directly load the correct SVD file.
2025-11-11 15:09:39 +01:00
crasbe
6da51843d9
Merge pull request #21868 from leandrolanzieri/pr/nrf5x_common/fix_vendor_files
cpu/nrf5x_common: copy vendor files only when newer
2025-11-11 11:32:40 +00:00
Leandro Lanzieri
f25b8d12e3 cpu/nrf5x_common: copy vendor files only when newer 2025-11-11 11:27:00 +01:00
crasbe
cb427b0f0d
Merge pull request #21863 from maribu/dist/tools/PyCortexMDebug
dist/tools/PyCortexMDebug: Integrate GDB extension into RIOT
2025-11-11 10:26:27 +00:00
Karl Fessel
3dd84c64c7 cpu/sam0_common: init: remove superflous reads 2025-11-10 21:16:49 +01:00
Marian Buschsieweke
dde6e6e55e
cpu/stm32f7: Provide SVD_VENDOR and SVD_MODEL
With this, running `make RIOT_USE_PYCORTEXMDEBUG=1 debug` for any STM32F7
based boards will directly load the correct SVD file.

Co-authored-by: crasbe <crasbe@gmail.com>
2025-11-10 19:58:43 +01:00
Marian Buschsieweke
1756601217
cpu/nrf52: Provide SVD_VENDOR and SVD_MODEL
With this, running `make RIOT_USE_PYCORTEXMDEBUG=1 debug` for any nRF52
based boards will directly load the correct SVD file.
2025-11-10 19:58:42 +01:00
crasbe
b1256ffb1b
Merge pull request #21837 from crasbe/pr/nucleo-wl55jc-rtc-support_new
boards/nucleo-wl55jc, cpu/stm32: enable RTC support, increase RTC accuracy
2025-11-07 08:16:46 +00:00
crasbe
71c2d4ab6a cpu/stm32: disable RTC MEM feature for F302 2025-11-06 19:38:51 +01:00
Guillaume Meunier
315e3dab39 cpu/stm32/periph/rtc: don't stop RTC for every lock 2025-11-06 19:38:51 +01:00
Kasper Hjort Berthelsen
07cca537ff boards/nucleo-wl55jc: enable RTC peripheral 2025-11-06 19:38:51 +01:00
crasbe
2844950a39 cpu/stm32: style improvements of rtc_all.c 2025-11-06 19:38:42 +01:00
Benjamin Valentin
15ffad4e39 cpu/sam0_common: clear tamper wake on gpio_irq_disable() 2025-11-05 14:43:37 +01:00
crasbe
df58de4ba2
Merge pull request #20430 from cogip/native_i2c_mock
cpu/native: introduce periph_i2c_mock
2025-11-03 11:33:59 +00:00
Marian Buschsieweke
20ff9dba35
Merge pull request #21836 from benpicco/cpu/sam0-eth/irq-init
cpu/sam0_eth: disable interrupts during init
2025-10-31 17:48:20 +00:00
Marian Buschsieweke
8fe02c5cb2
Merge pull request #21797 from crasbe/pr/stm32_ccmram
cpu/stm32: fix `_ccmram_length` name, make names consistent
2025-10-31 12:46:34 +00:00
Benjamin Valentin
477a00d43f cpu/sam0_eth: disable interrupts during init 2025-10-31 13:36:44 +01:00
benpicco
0995c466c6
Merge pull request #21786 from fabian18/pr/fix_nrf52_after_soft_ack
cpu/nrf52/radio/nrf802154: fix radio after soft ACK
2025-10-31 10:19:54 +00:00
Gilles DOFFE
dab11d7a9c cpu/native: introduce periph_i2c_mock
This allows I2C emulation on native architecture in the same way than
periph_gpio_mock.

All I2C functions from this driver are set as weak to be easily
overridden in each application.

Signed-off-by: Gilles DOFFE <g.doffe@gmail.com>
2025-10-30 23:51:07 +01:00
Gilles DOFFE
197cf51b93 cpu/native: fix GPIO bias flags for kernel >=5.5
Fix duplicate GPIO mode values on native platform when using Linux
kernel 5.5 or later. The kernel renamed GPIOHANDLE_REQUEST_PULL_* flags
to GPIOHANDLE_REQUEST_BIAS_PULL_* in version 5.5.

Without this fix, both GPIO_IN_PU and GPIO_OD_PU would have the same
fallback value (0xFF), causing compilation errors in switch statements.

Error: "duplicate case value"

Signed-off-by: Gilles DOFFE <g.doffe@gmail.com>
2025-10-30 23:51:07 +01:00
Fabian Hüßler
76391f8566 cpu/native/socket_zep: native overhead workaround 2025-10-30 22:08:22 +01:00
crasbe
f7628d8f9a cpu/esp_common: make Xtensa ISR_STACKSIZE conditional 2025-10-30 13:43:06 +01:00
Gilles DOFFE
aab432ff6d cpu/native: remove unused XTIMER_BACKOFF definitions
XTIMER_BACKOFF and XTIMER_ISR_BACKOFF were defined in periph_conf.h
since 2016 for the legacy xtimer module, which required high backoff
values (200) on native to prevent timer underflow issues.

However, since the migration to ztimer, all code now uses
MODULE_ZTIMER_XTIMER_COMPAT which includes ztimer/xtimer_compat.h
before periph_conf.h. This means xtimer_compat.h always defines
XTIMER_BACKOFF=1 first, and the periph_conf.h definitions are never
used.

Remove these unused definitions as they serve no purpose with the
current ztimer-based implementation.

Signed-off-by: Gilles DOFFE <g.doffe@gmail.com>
2025-10-30 08:20:21 +01:00
Benjamin Valentin
88bd202031 treewide: adapt GNRC example paths in documentation 2025-10-29 15:10:43 +01:00
Fabian Hüßler
99cceeff91 cpu/nrf52/radio/nrf802154: fix radio after soft ACK 2025-10-22 20:09:41 +02:00
Fabian Hüßler
f36610e98f cpu/nrf52/radio/nrf802154: swith l2filter processing order 2025-10-22 20:08:19 +02:00
Fabian Hüßler
1f99f9df18 cpu/nrf52/radio/nrf802154: remove ACK state 2025-10-22 20:06:46 +02:00
crasbe
89031c45fb cpu/nrf5x_common: fix vendor header regression
When not using the Rust version of Git-Cache, the build
system clones the full NRFX repository which led to errors during
the build process due to duplicated headers and headers not
found where they were expected.
2025-10-22 11:04:35 +02:00
crasbe
4752d2e291 cpu/nrf5x_common: remove local vendor header files from sourcetree 2025-10-17 23:20:31 +02:00
crasbe
9dd2e5e38f cpu/nrf5x_common: pull and use vendor headers from git 2025-10-17 23:20:31 +02:00
crasbe
e2a61226c3 cpu/stm32: fix _ccmram_length name, make names consistent 2025-10-15 14:11:22 +02:00
crasbe
e0f9f11044 cpu/stm32: update STM32C0 CMSIS version 2025-10-10 12:43:17 +02:00
Jason Parker
7badfe61b7 cpu/stm32: add new STM32C0 lines 2025-10-09 13:40:49 +02:00
krzysztof-cabaj
2cce71925f cpu/stm32/gen_kconfig: move script license to SPDX format 2025-10-08 10:41:13 +02:00
krzysztof-cabaj
26928f994c cpu/stm32/gen_kconfig: templates - move licenses to SPDX format 2025-10-08 10:41:13 +02:00
Marian Buschsieweke
9cbd344fdc
Merge pull request #21718 from maribu/cpu/stm32/usbdev_fs/inverted-disconnect-pin
cpu/stm32/usbdev_fs: allow inverted disconnect GPIO
2025-10-07 18:44:07 +00:00
Marian Buschsieweke
26d8fe4383
cpu/stm32/usbdev_fs: allow inverted disconnect GPIO
The STM32F3 requires a dedicated digital signal to emulate a disconnect
event by pulling D+ down via a 1.5 kOhm resistor. Some boards, such as
the OLIMEXINO-STM32F3, do not directly connect a GPIO but place a
transistor in between. Depending on the exact implementation, the logic
level may end up being inverted compared to directly connecting a
GPIO.

This adds a flag member to the `stm32_usbdev_fs_config_t` and a new flag
to indicate inverted logic. In addition the members in the struct are
sorted by alignment, as this is a foolproof algorithm to prevent wasting
memory on unneeded padding.

Finally, the USB driver is adapted to honor the flag.

Co-authored-by: crasbe <crasbe@gmail.com>
2025-10-07 17:42:28 +02:00
crasbe
1942aa98fd
Merge pull request #21758 from krzysztof-cabaj/cpu_change_to_SPDX_part5
cpu: move licenses from comments to SPDX format (part5)
2025-10-06 11:21:09 +00:00
fabian18
e3fa62f38f
Merge pull request #21533 from fabian18/pr/submac_ack_transmission
ieee802154/submac: add automatic ACK transmission when AUTO_ACK is not supported by driver
2025-10-06 11:05:40 +00:00
Fabian Hüßler
470ee34311 {drivers,cpu}: add IEEE802154_CAP_AUTO_ACK for HAL radios 2025-10-06 10:38:55 +02:00
Fabian Hüßler
4b24183e81 cpu/nrf52/radio/nrf802154: remove driver ACK 2025-10-06 10:38:55 +02:00
Fabian Hüßler
6b065bcea7 socket_zep: remove driver ACK 2025-10-06 10:15:20 +02:00