1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/dist/tools
bors[bot] ddf1fe252d
Merge #19733 #19747 #19769 #19782
19733: cpu/msp430: reorganize code r=maribu a=maribu

### Contribution description

RIOT supports two distinct families of the MSP430: The [MSP430 x1xx] MCU family and the [MSP430 F2xx/G2xx] MCU family. For both incompatible MCU families the code was located in the msp430fxyz folder, resulting in case of the UART driver in particularly bizarre code looking roughly like this:

```C
#ifndef UART_USE_USCI
/* implementation of x1xx peripheral ... */
#else
/* implementation of F2xx/G2xx peripheral ... */
#endif
/* zero shared code between both variants */
```

This moves peripheral drivers shared between the two families to msp430_common and splits the SPI and UART driver into two MCU families.

In addition, it cleans up the `msp430_regs.h` by dropping most of it and using the macros and symbols provided by the vendor header files. There is little reason for us to maintain constants when TI is already doing that.

[MSP430 x1xx]: https://www.ti.com/lit/ug/slau049f/slau049f.pdf
[MSP430 F2xx/G2xx]: https://www.ti.com/lit/ug/slau144k/slau144k.pdf


19747: gnrc/ipv6/nib: reset rs_sent counter also for not-6LN interfaces r=maribu a=fabian18



19769: cpu/nrf53: add initial support with nRF5340DK-APP board r=maribu a=dylad

### Contribution description

This PR adds support for nRF5340 MCU and its associated Nordic development board, nRF5340DK.
This MCU provides a dual Cortex-M33, one application core running at up to 128MHz, and one network core running at up to 64MHz.
Peripherals are inherited from others Nordic MCUs families so it shouldn't be hard to add more of them in followup PRs.

For now, only the minimal set of peripherals is supported:
- GPIO / GPIO_IRQ
- UART
- TIMER

### Testing procedure
Build the usual test application for the supported peripherals and flash the board.
nRF5340DK provides two serial ports on its embedded debugger. RIOT's shell should be available on the first one (/dev/ttyACM0)


### Issues/PRs references
#18576
#19267 


19782: cpu/msp430: fix for ti's msp430-gcc-opensource package ld version r=maribu a=hugueslarrive

### Contribution description
My msp430 toolchain (https://www.ti.com/tool/MSP430-GCC-OPENSOURCE) was broken by #19484:
```
hugues@p700:~/github/cpu_msp430_common/RIOT$ BOARD=msb-430 make -j64 -C examples/hello-world
make : on entre dans le répertoire « /home/hugues/github/cpu_msp430_common/RIOT/examples/hello-world »
Building application "hello-world" for "msb-430" with MCU "msp430fxyz".

"make" -C /home/hugues/github/cpu_msp430_common/RIOT/boards/common/init
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/boards/msb-430
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/core
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/core/lib
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430fxyz
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/drivers
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/boards/common/msb-430
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/drivers/periph_common
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/auto_init
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/div
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/libc
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/malloc_thread_safe
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430_common
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/newlib_syscalls_default
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430fxyz/periph
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/preprocessor
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/stdio_uart
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430_common/periph
/opt/ti/msp430-gcc/bin/../lib/gcc/msp430-elf/9.3.1/../../../../msp430-elf/bin/ld: .rodata not found for insert
collect2: error: ld returned 1 exit status
make: *** [/home/hugues/github/cpu_msp430_common/RIOT/examples/hello-world/../../Makefile.include:761 : /home/hugues/github/cpu_msp430_common/RIOT/examples/hello-world/bin/msb-430/hello-world.elf] Erreur 1
make : on quitte le répertoire « /home/hugues/github/cpu_msp430_common/RIOT/examples/hello-world »
hugues@p700:~/github/cpu_msp430_common/RIOT$ /opt/ti/msp430-gcc/msp430-elf/bin/ld --version
GNU ld (Mitto Systems Limited - msp430-gcc 9.3.1.11) 2.34
Copyright (C) 2020 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) a later version.
This program has absolutely no warranty.
hugues@p700:~/github/cpu_msp430_common/RIOT$ /opt/ti/msp430-gcc/msp430-elf/bin/ld --version | grep -Eo '[0-9]\.[0-9]+'
9.3
1.11
2.34
hugues@p700:~/github/cpu_msp430_common/RIOT$ /opt/ti/msp430-gcc/msp430-elf/bin/ld --version | grep -Eo '[0-9]\.[0-9]+$'
2.34
```


### Testing procedure
```
hugues@p700:~/github/cpu_msp430_common/RIOT$ BOARD=msb-430 make -j64 -C examples/hello-world
make : on entre dans le répertoire « /home/hugues/github/cpu_msp430_common/RIOT/examples/hello-world »
Building application "hello-world" for "msb-430" with MCU "msp430fxyz".

"make" -C /home/hugues/github/cpu_msp430_common/RIOT/boards/common/init
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/boards/msb-430
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/core
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/core/lib
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430fxyz
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/drivers
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/boards/common/msb-430
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/drivers/periph_common
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/auto_init
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/div
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/libc
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/malloc_thread_safe
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/newlib_syscalls_default
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/preprocessor
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430_common
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/sys/stdio_uart
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430fxyz/periph
"make" -C /home/hugues/github/cpu_msp430_common/RIOT/cpu/msp430_common/periph
   text	   data	    bss	    dec	    hex	filename
   8612	    722	    866	  10200	   27d8	/home/hugues/github/cpu_msp430_common/RIOT/examples/hello-world/bin/msb-430/hello-world.elf
make : on quitte le répertoire « /home/hugues/github/cpu_msp430_common/RIOT/examples/hello-world »
```


### Issues/PRs references
Introduced by #19484, highlighted in #16727.


Co-authored-by: Marian Buschsieweke <marian.buschsieweke@posteo.net>
Co-authored-by: Fabian Hüßler <fabian.huessler@ml-pa.com>
Co-authored-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
Co-authored-by: Hugues Larrive <hlarrive@pm.me>
2023-07-04 18:43:26 +00:00
..
avarice dist/tools/avarice/debug.sh: less noise 2021-04-22 08:45:57 +02:00
backport_pr tools/backport_pr: remove Unnecessary "else" after "raise" 2023-02-01 16:00:28 +01:00
benchmark_udp tools/benchmark_udp: fix build 2022-03-11 16:32:28 +01:00
bmp dist/tools: Use /usr/bin/env to lookup Python. 2023-04-10 14:39:42 +02:00
boards_supported makefiles/tests: add unit test for info-boards-supported 2021-02-17 15:40:05 +01:00
bootterm makefiles/tools/serial.inc.mk: add support for bootterm 2022-10-15 00:20:09 +02:00
bossa-1.8 dist/tools/bossa-1.8: add missing include 2022-09-08 20:41:07 +02:00
bossa-1.9 dist/tools/bossa-1.9: add missing include 2022-09-08 20:41:26 +02:00
bossa-nrf52 dist/tools/bossa-nrf52: add missing include 2022-09-08 20:41:40 +02:00
buildsystem_sanity_check buildsystem: add target debug-client 2023-06-10 00:04:56 +02:00
cc2538-bsl dist/tools/cc2538-bsl: bump version 2020-11-18 14:47:19 +01:00
ci dist/tools: Use /usr/bin/env to lookup Python. 2023-04-10 14:39:42 +02:00
cmake dist/tools/cmake: handle strings with \" 2019-09-27 19:28:32 +02:00
coccinelle dist/tools/coccinelle/force: remove static.cocci 2021-11-05 08:45:55 +01:00
codespell dist/tools/codespell: ignore false positives 2023-05-02 09:53:16 +02:00
commit-msg dist/tools/commit-msg: annotate errors in Github Action 2021-01-11 14:04:53 +01:00
compile_and_test_for_board setup.cfg: remove bad option 2022-06-02 11:42:53 +02:00
compile_commands dist/tools/compile_commands: add another workaround 2023-05-22 13:26:03 +02:00
compile_test compile_like_murdock.py: fix path to test applications 2023-05-13 19:08:37 +02:00
cosy dist/tools/cosy: provide patch for PR #13 2022-07-20 11:31:59 +02:00
cppcheck cppcheck: output all annotations as error on script error 2021-11-04 15:43:02 +01:00
cpy2remed tools/cpy2remed: add support for removable media name NOD_xxxx 2022-11-18 08:10:02 -05:00
desvirt dist/tools/desvirt: use RIOTTOOLS variable 2018-05-09 18:01:48 +02:00
dhcpv6-pd_ia tools/dhcpv6-pd_ia: create /run/kea on startup 2022-02-17 18:34:07 +01:00
dlcache dist/tools: Use /usr/bin/env bash for bash scripts 2020-10-30 13:13:40 +01:00
doccheck Merge #19733 #19747 #19769 #19782 2023-07-04 18:43:26 +00:00
dose dist: add dose UNIX tool 2022-08-02 11:03:03 +02:00
eclipsesym treewide: fix typos 2022-09-15 23:31:40 +02:00
edbg dist/tools/edbg: bump edbg version 2023-03-01 17:33:07 +01:00
elf2uf2 dist/tools: fix compilation of elf2uf2 2023-05-23 08:49:37 +02:00
emulator tree-wide: emulators: s/RUNTIME_TMP_DIR/EMULATOR_TMP_DIR 2022-03-04 13:44:51 +01:00
esptools esptools/install.sh: Fix shellcheck issues 2023-02-27 13:58:34 +01:00
ethos tools/ethos: add support for radvd / auto_subnets 2022-04-22 22:22:28 +02:00
externc dist/tools/externc: annotate errors in Github Action 2021-01-11 16:59:16 +01:00
feature_resolution tests/feature_resolution: add build system unit tests 2021-02-10 21:05:38 +01:00
fixdep dist: tools: import fixdep from linux 2020-08-10 12:17:59 +02:00
flake8 tools/flake8: ignore pythonlibs/riotctrl_* directories 2021-10-22 10:25:15 +02:00
flatc dist/tools/flatc: Fix compilation on musl 2022-11-09 22:33:23 +01:00
fuzzing fuzzing: Initialize 2020-04-17 17:11:15 +02:00
genconfigheader genconfigheader: use lazysponge for file management 2018-08-20 11:34:55 +02:00
generate_c11_atomics_cpp_compat_header dist/tools: Added script for C11 atomics compat 2019-10-24 23:08:35 +02:00
generate_pp_successor_header dist/tools: add script to generate preprocessor successors 2022-10-14 09:59:17 +02:00
git dist/tools: Use /usr/bin/env bash for bash scripts 2020-10-30 13:13:40 +01:00
goodfet dist/tools/goodfet: set serial parity to none on exit 2022-03-28 10:19:50 +02:00
has_minimal_version tools: fix shebang in has_minimal_version.sh 2019-09-16 11:27:15 +02:00
headerguards headerguards: move annotation by offset 2021-03-11 13:32:33 +01:00
insufficient_memory dist/tools/insufficient_memory: fix collection of app folders 2023-05-16 14:59:53 +02:00
jlink tools/jlink.sh: start gdb server with setsid 2023-06-09 15:33:14 +02:00
kconfiglib tools/kconfiglib: Update to RIOT-OS package 2023-05-31 12:55:47 +02:00
lazysponge dist/tools/lazysponge: fix typos 2019-11-23 22:39:37 +01:00
licenses dist/tools: Use /usr/bin/env bash for bash scripts 2020-10-30 13:13:40 +01:00
lpc2k_pgm dist/tools/lpc2k_pgm: fix headerguards 2020-12-01 16:21:50 +01:00
mcuboot pycrypto: use pycryptodome instead 2021-11-02 13:28:42 +01:00
mkconstfs tools/mkconstfs: Add an improved tool. 2018-07-02 10:15:56 +02:00
mosquitto_rsmb tools/mosquitto_rsmb: bump to latest version 2023-01-03 10:23:36 +01:00
mspdebug tools/mspdebug: fix make debug and make debugserver 2023-05-24 17:00:38 +02:00
nrf52_resetpin_cfg dist/tools: add "RESET_PIN" value for the dwm1001 2022-10-28 13:47:44 +02:00
openocd dist/tools/openocd: start debug-server in background and wait 2023-06-15 19:27:15 +02:00
openvisualizer build-system: Allow out of tree BUILD_DIR 2023-05-16 22:23:03 +02:00
packer cpu/mips: Remove all mips 2022-09-27 13:42:37 +02:00
pioasm tools/pioasm: Add PIO assembler pioasm 2023-05-12 23:03:05 +02:00
pktbuf-stats treewide: s/gnrc_pktbuf_cmd/shell_cmd_gnrc_pktbuf/ 2022-09-24 14:50:43 +02:00
pr_check tools/pr_check: add Update keywork to need squashing check 2022-03-17 20:01:06 +01:00
programmer dist/tools: always print how to disable programmer wrapper 2021-03-02 10:42:39 +01:00
pyocd make: namespace pyocd FLASH_TARGET_TYPE variable 2021-02-23 21:22:52 +01:00
pyterm dist/tools: Use /usr/bin/env to lookup Python. 2023-04-10 14:39:42 +02:00
radvd tools/radvd: fix help text 2021-11-23 20:02:47 +01:00
randhex tools: add tool for generating random hexadecimal values 2020-01-20 14:51:26 +01:00
release-stats release-stats: simplify script usage 2019-04-30 16:06:59 +02:00
riotboot_gen_hdr core/byteoder: Moved to sys 2020-08-14 16:28:59 +02:00
riotboot_serial tools/riotboot_serial: add flasher tool for riotboot serial loader 2021-07-20 22:50:41 +02:00
robotis-loader boards/opencm904: move robotis-loader in common place 2020-12-01 18:31:41 +01:00
setsid tools/setsid: cleanup and allow Makefile to be used standalone 2020-07-10 13:30:46 +02:00
shellcheck shellcheck: annotate errors in Github Action 2021-01-13 22:03:11 +01:00
sliptty tools/sliptty: add support for radvd / auto_subnets 2022-04-22 22:22:28 +02:00
stm32loader dist/tools: Add stm32loader flash utility 2018-09-18 18:07:42 +02:00
suit dist/tools: Use /usr/bin/env to lookup Python. 2023-04-10 14:39:42 +02:00
tapsetup tapsetup: add --delay option 2022-11-11 16:54:21 +01:00
teensy-loader-cli dist/tools: adapt tools that are built using pkg.mk 2020-06-26 09:25:45 +02:00
testprogs build system: Fix linker feature test with newlib 4.3.0 2023-02-02 20:47:37 +01:00
toolchains tools: remove toolchain build script for x86 2017-11-16 10:42:09 +01:00
tunslip treewide: Remove excessive newlines 2021-08-13 19:50:38 +02:00
uf2 tools/uf2: add uf2conv.py as a flash tool 2020-12-02 10:20:17 +01:00
uhcpd net/uhcp[cd]: use modules to select client/server code 2021-11-09 21:42:45 +01:00
uncrustify treewide: replace occurrences of tests/driver_ with new path 2023-05-06 15:38:21 +02:00
usb-cdc-ecm tools/usb-cdc-ecm: add support for radvd / auto_subnets 2022-04-22 22:22:28 +02:00
usb-serial dist/tools/usb-serial: Fix handling of None while quoting 2023-06-21 22:13:21 +02:00
vagrant treewide: fix path to shell related tests in doc 2023-05-13 18:27:58 +02:00
vera++ dist/tools/vera++: fix exclude rules for tests/pkg/utensor 2023-05-06 07:55:01 +02:00
whitespacecheck dist/whitespacecheck: ignore .svg files 2022-08-16 11:31:23 +02:00
zep_dispatch examples/gnrc_border_router: add option to re-use existing TAP interface 2022-11-08 15:06:33 +01:00
Makefile dist: add dose UNIX tool 2022-08-02 11:03:03 +02:00