19485: sys/shell: Fix missing dependency r=aabadie a=maribu
### Contribution description
The shell commands depend on the shell module being use. This was already the case in KConfig, but was overlooked in the shell's `Makefile.dep`.
In addition, this uncovered that `tests/memarray` had a bogus dependency on shell commands without every using the shell.
### Testing procedure
Ideally binaries should not differ (except for debug section).
### Issues/PRs references
Split out of https://github.com/RIOT-OS/RIOT/pull/19483
Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
19488: usbus: remove deprecated USBUS_HANDLER_FLAG_TR_FAIL flag r=gschorcht a=dylad
### Contribution description
This PR removes the deprecated `USBUS_HANDLER_FLAG_TR_FAIL` flag.
### Testing procedure
CI should be enough.
### Issues/PRs references
Was deprecated by #17046
Co-authored-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
19411: cpu/gd32v: add riotboot support r=benpicco a=gschorcht
### Contribution description
This PR provides `riotboot` support for GD32V.
### Testing procedure
Use any GD32V board with a JTAG adapter and flash the bootloader:
```python
PROGRAMMER=openocd BOARD=sipeed-longan-nano make -C bootloaders/riotboot flash
```
Flash slot 0 and set `RIOT_VERSION` to 1
```python
USEMODULE=stdio_uart FEATURES_REQUIRED=riotboot RIOT_VERSION=1 \
PROGRAMMER=openocd BOARD=sipeed-longan-nano make -C tests/shell riotboot/flash-slot0
...
### Flashing Target ###
Binfile detected, adding ROM base address: 0x08000000
Flashing with IMAGE_OFFSET: 0x08001000
```
```python
> main(): This is RIOT! (Version: 1)
test_shell.
```
Flash slot 1 and set `RIOT_VERSION` to 2
```python
USEMODULE=stdio_uart FEATURES_REQUIRED=riotboot RIOT_VERSION=2 \
PROGRAMMER=openocd BOARD=sipeed-longan-nano make -C tests/shell riotboot/flash-slot1
...
### Flashing Target ###
Binfile detected, adding ROM base address: 0x08000000
Flashing with IMAGE_OFFSET: 0x08010800
```
```python
> main(): This is RIOT! (Version: 2)
test_shell.
```
### Issues/PRs references
Co-authored-by: Gunar Schorcht <gunar@schorcht.net>
The shell_cmds module depends on the shell module. This was correctly
added to KConfig, but the Makefile dependencies missed this one. This
commit adds the missing dep.
To be able to reconfigure the PLL multiplier in clock configuration, the existing value has to be reset first. This becomes necessary when changing the core clock, e.g. when booting with riotboot an application that uses USB.
To allow CPU specific definitions in `cpu.h`, `riscv_common/cpu.h` is renamed to ``riscv_common/cpu_common.h` and included in new `cpu.h` files for FE310 and GD32V.
19450: cpu/esp32: fix compilation issues with GCC 12.2 r=benpicco a=gschorcht
### Contribution description
This PR provides the changes in `cpu/esp32` and `cpu/esp_common` to fix the compilation issues with GCC v12.2. It is required as the first step in the preparation of the upgrade to ESP-IDF version 5.1.
**Please note**: Insead of fixing the ESP-IDF 4.4 code itself by a big bunch of patches to fix the compilation problems with GCC v12.2, it temporarily disables some warnings. The reason is that the ESP-IDF 5.1 requires GCC v12.2 and should be fixed for this compiler version by the vendor.
### Testing procedure
Green CI
The change were already tested with all ESP-specific modules like `esp_now`, `esp_wifi`, `esp_spi` and `esp_ble` for all supported ESP platforms.
### Issues/PRs references
Prerequisite for https://github.com/RIOT-OS/riotdocker/pull/227
Fixes issue #19421
19476: native/syscalls: rename real_clock_gettime to clock_gettime r=benpicco a=Teufelchen1
### Contribution description
When compiling RIOT for native using a recent LLVM and enabling ASAN, one might encounter "Duplicated symbol".
This is due to a name clash with `real_clock_gettime()` in compiler-rt from [LLVM](f50246da65), I renamed RIOTs `real_clock_gettime` and just default to the posix function `clock_gettime`. The wrapper existed, most likely, for consistency only.
(The best solution would probably to convince the LLVM folks to declare their symbol as `static` and refactor a bit)
### Testing procedure
Passing CI should be enough.
Co-authored-by: Gunar Schorcht <gunar@schorcht.net>
Co-authored-by: Teufelchen1 <bennet.blischke@haw-hamburg.de>
19436: cpp11-compat: thread::sleep_for in microseconds r=benpicco a=kfessel
### Contribution description
after reviewing #19369 i found that there is a conversion to nanoseconds just to convert it to microseconds some instrunctions later for ztimer64_usec to handle it this removes one of the conversions (convert once direct to microseconds)
### Testing procedure
run the cpp tests
### Issues/PRs references
#19369
Co-authored-by: Karl Fessel <karl.fessel@ovgu.de>
19447: boards/nucleo-f429zi: Provide 2nd timer r=benpicco a=maribu
### Contribution description
- Add a common timer config with two (instead of only one) timer using TIM2 + TIM5
- Mostly copy-pasting the cfg_timer_tim2.h and cfg_timer_tim5.h together
- Make use of that for the `nucleo-f429zi`
### Testing procedure
E.g. `tests/periph_timer`, but also grepping for TIM2 and TIM5 in `boards/nucleo-f429zi/include/periph_conf.h` to detect any conflict e.g. between PWM and timer config.
### Issues/PRs references
None
Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
19389: drivers/usbdev_synopsys_dwc2: add GD32V support r=bergzand a=gschorcht
### Contribution description
This PR provides the GD32V support in `drivers/usbdev_synopsys_dwc2`. It also includes some cleanup and bug fixes.
To support GD32V (CID 1.000) the PR includes the following changes:
- XFRC interrupts are also used in Non-DMA mode to complete a transfer
- SETUP phase done (STUP) interrupt is used in Non-DMA mode
- additional XFRC interrupts in SETUP stage are ignored
- RX FIFO handling doesn't complete a transfer anymore and is handled directly in ISR
- OTG interrupt handling added
The following fixes, improvements and cleanup has been added:
- USB OTG HS definition dependencies for platforms that don't support USB OTG HS
- thread context switch at ISR exit was added for all platforms
- units in USB FIFO size definitions are clarified
- USB EP number as defined in CMSIS is used
- FIFO allocation documentation is improved
- power modes for STM32 are fixed
- CID/HW debug info added
The PR could be split into a PRs with cleanups and improvements and a PR with GD32V support if necessary.
### Testing procedure
```
BOARD=sipeed-longan-nano make -j8 -C tests/shell
```
should work with `stdio_cdc_acm`.
`periph_usbdev` should still work for other platforms. The PR was tested with `tests/usbus_cdc_ecm` together with `stdio_cdc_acm` if possible:
```
esp32s2 FS CID: 0000, HWREV: 4f54400a, HWCFG: 224dd930 (esp32s2-devkit)
esp32s3 FS CID: 0000, HWREV: 4f54400a, HWCFG: 224dd930 (esp32s3-devkit)
efm32gg12 FS CID: 0000, HWREV: 4f54330a, HWCFG: 228f5910 (sltb009a)
gd32vf103cb FS CID: 1000, HWREV: 00000000, HWCFG: 00000000 (sipeed-longan-nano)
stm32f407vg FS CID: 1200, HWREV: 4f54281a, HWCFG: 229dcd20 (stm32f4discovery)
stm32f429zi HS CID: 1100, HWREV: 4f54281a, HWCFG: 229ed590 (stm32f429i-disc1)
stm32f439zi FS CID: 1200, HWREV: 4f54281a, HWCFG: 229dcd20 (nucleo-f439ze)
stm32f446ze FS CID: 2000, HWREV: 4f54320a, HWCFG: 229ed520 (nucleo-f446ze)
stm32f723ie FS CID: 3000, HWREV: 4f54330a, HWCFG: 229ed520 (stm32f723e-disco)
stm32f723ie HS CID: 3100, HWREV: 4f54330a, HWCFG: 229fe1d0 (stm32f723e-disco)
stm32f746ng FS CID: 2000, HWREV: 4f54320a, HWCFG: 229ed520 (stm32f746g-disco)
stm32f746ng HS CID: 2100, HWREV: 4f54320a, HWCFG: 229fe190 (stm32f746g-disco)
stm32f767zi FS CID: 2000, HWREV: 4f54320a, HWCFG: 229ed520 (nucleo-f767zi)
```
Boards with HS interfaces were tested in DMA and none-DMA mode.
### Issues/PRs references
Co-authored-by: Gunar Schorcht <gunar@schorcht.net>