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

325 Commits

Author SHA1 Message Date
Marian Buschsieweke
aed175b14b
core/thread: drop unused thread_arch_t
No architecture makes use of thread_arch_t anymore, so let's drop it.
2023-05-21 22:17:52 +02:00
9b32854b13
cpu/cortexm_common: remove CMSIS vendor code 2023-05-14 21:08:28 +02:00
2e59f8e9b6
cpu/cortexm_common: use cmsis package instead of internal vendor headers 2023-05-14 21:08:27 +02:00
bors[bot]
718a4513b5
Merge #19368 #19529 #19531
19368: debug: add DEBUG_BREAKPOINT() macro, set breakpoint on failed assertion r=benpicco a=benpicco



19529: cpu/stm32/periph/dac: optimize setting DAC r=benpicco a=Enoch247

### Contribution description

The current implmentation right shifted the 16 bit value passed into `dac_set()` down to the 12 bits that the DAC is actually capable of. This patch drops the shift and instead writes the 16 bit value to the DAC's left aligned 12 bit wide data holding register.


### Testing procedure

do something like:
``` c
#include "perip/dac.h"

int main(void)
{
    dac_set(DAC_LINE(0), 0xffff/2);
    return 0;
}
```
- observe DAC's output is half of vref


### Issues/PRs references

- none known


19531: tests/unittests: allow passing `UNIT_TESTS` via env r=benpicco a=kaspar030



Co-authored-by: Benjamin Valentin <benpicco@beuth-hochschule.de>
Co-authored-by: Joshua DeWeese <jdeweese@primecontrols.com>
Co-authored-by: Kaspar Schleiser <kaspar@schleiser.de>
2023-05-02 18:08:42 +00:00
Benjamin Valentin
e850dcd921 cpu/cortexm_common: define ARCHITECTURE_BREAKPOINT() 2023-04-27 13:19:17 +02:00
Gunar Schorcht
06426c41b0 sys/riotboot: common default NUM_SLOT, SLOT_* config 2023-04-18 06:20:14 +02:00
Keith Packard
fb01e6a3fb cpu: Add TLS symbols for newer picolibc to linker scripts
Newer picolibc versions require some additional symbols defined in the
linker script to correctly manage alignment constraints on thread
local storage.

Signed-off-by: Keith Packard <keithp@keithp.com>
2023-03-02 22:55:22 -08:00
Gunar Schorcht
c46545d5a7 cpu/common_cortex: handling RIOTBOOT_LEN for tinyusb_dfu 2023-01-15 18:09:55 +01:00
Benjamin Valentin
59a3e613fe cpu/cortexm_common: measure time spent with IRQ disabled 2022-11-24 21:27:20 +01:00
Benjamin Valentin
04287b4795 cpu/cortexm_common: improve formatting of irq_arch.h 2022-10-24 18:08:33 +02:00
5cc43e5d5e cpu/cortexm: clear FPU state in cpu_switch_context_exit() 2022-10-05 22:17:26 +02:00
Benjamin Valentin
ea917f4b07 cpu: cpu_print_last_instruction() -> cpu_get_caller_pc() 2022-09-15 10:49:56 +02:00
Benjamin Valentin
8cf20a286d cpu/cortexm_common: allow to overwrite nmi_handler
If a user wants to handle NMI events, let them do so by
providing an implementation for nmi_handler() instead of
paniking.
2022-06-20 18:22:22 +02:00
benpicco
a64f722a42
Merge pull request #17781 from benpicco/hard_fault-BKPT
cpu/cortexm_common: remove breakpoint from hard_fault_handler
2022-06-07 15:28:08 +02:00
6f52b90e58
cpu/cortexm_common: enable FPU on cortexm33 2022-05-05 21:16:10 +02:00
chrysn
facb5e633f
Merge pull request #17436 from Ollrogge/reserve_flash
cpu: add flash_writable section to linker script
2022-03-17 21:44:32 +01:00
Benjamin Valentin
1fa1d348d8 cpu/cortexm_common: remove breakpoint from hard_fault_handler
The hard fault handler would normally call core_panic() which in turn
calls ps() - this already helps debugging a lot of crashes caused by
a thread stack overflow.

With the breakpoint in place, the code will not advance to this, leaving
users unknown of this feature in the dark.

On top, the breakpoint is not very helpful if thread stacks are already
corrupted.

Let's just drop it for simplicity's sake - it's not there for any other
architectures.
2022-03-09 23:32:46 +01:00
Ollrogge
5587f5d88f cpu/cortexm_common: add flash_writable section to linker script 2022-03-07 11:23:44 +01:00
chrysn
f7dfa2f84d
Merge pull request #17133 from chrysn-pull-requests/doc-develhelp-stackoverflow-precision
doc: Start documenting pseudomodules
2022-01-27 15:09:22 +01:00
chrysn
bb8402fc0b doc: Document the MPU pseudomodules 2022-01-27 13:49:25 +01:00
Fabian Hüßler
70d3d647d1 cpu/{cortexm_common, stm32}: add support for backup RAM 2022-01-21 15:53:18 +01:00
8272e4fbd2
Merge pull request #17359 from benpicco/irq_is_in-bool
core: change return type of irq_is_in(), irq_is_enabled() to bool
2022-01-06 18:13:20 +01:00
chrysn
afdabcf9b6
Merge pull request #16274 from chrysn-pull-requests/rust-application
Add some Rust building infrastructure and example
2021-12-16 16:17:28 +01:00
chrysn
1838cdf69c rust: Add triples for M23 and M33 (but keep disabled) 2021-12-16 13:29:31 +01:00
chrysn
b557fdce55 rust: Enable on Cortex-M0(+) boards 2021-12-16 13:29:31 +01:00
MrKevinWeiss
51fdbdd75c
cpu/cortexm: fix kconfig libc_implemention 2021-12-15 08:39:00 +01:00
chrysn
a2e1b92e1d makefiles: Define RUST_TARGET for use with Cargo / Rust
For RISC-V and Cortex-M-not-3, triples are known and have worked in some
configuration, but do not work at the moment and stay disabled until the
reference platforms (native, M3) have been established well.
2021-12-14 12:55:13 +01:00
Leandro Lanzieri
df7ce1c647
makefiles/kconfig: use two lists for boards and CPUs default configs
This introduces KCONFIG_BOARD_CONFIG and KCONFIG_CPU_CONFIG variable for
boards and CPUs (including common directories) to add default
configuration files to be merged. The current approach, as it uses
Makefile.features, would include boards first, not allowing them to
override CPU configurations.
2021-12-13 12:33:21 +01:00
Benjamin Valentin
41a5b7ef7a core: change return type of irq_is_in(), irq_is_enabled() to bool
This only cleans up the API, no change in behavior or users of the API
is expected.
2021-12-08 15:53:15 +01:00
Erik Ekman
b5f96d2040 cpu/cortexm_common: Suppress cppcheck errors
cpu/cortexm_common/thread_arch.c:262: error (comparePointers): Comparing pointers that point to different objects
cpu/cortexm_common/thread_arch.c:266: error (comparePointers): Subtracting pointers that point to different objects
2021-11-25 13:08:51 +01:00
Marian Buschsieweke
7885130809
cpu/cortexm_common: make CI happy 2021-11-16 21:52:55 +01:00
Ollrogge
37403c09eb periph/flashpage: fix wrong doxygen group 2021-11-15 17:25:59 +01:00
Francisco
7f3344870d
Merge pull request #16972 from Ollrogge/flashpage_pr
periph/flashpage: extend API
2021-10-26 12:51:05 +02:00
Ollrogge
d38f6c68b5 cpu/cortexm_common: extend flashpage API 2021-10-19 22:33:15 +02:00
Benjamin Valentin
3e20e939c6 cpu: drop cpu_init() from public headers
Boards are no longer supposed fo call the function, so drop it from
public header files.
2021-10-18 17:31:26 +02:00
Benjamin Valentin
bcb0df8e18 cpu/cortexm_common: call cpu_init() 2021-10-13 23:21:56 +02:00
Jean Pierre Dudey
ffff68deaf
Merge pull request #16813 from jeandudey/doc1
cpu: fix doxygen grouping warnings
2021-09-13 11:30:27 +02:00
Jean-Pierre De Jesus DIAZ
51bab0a5a9 cpu/cortexm_common: fix doxygen grouping warnings
Signed-off-by: Jean-Pierre De Jesus DIAZ <me@jeandudey.tech>
2021-09-11 12:45:15 +02:00
MrKevinWeiss
636c6c4cdb
cpu/cortexm: Use DEVELHELP to add stack guard 2021-09-08 12:40:30 +02:00
Hauke Petersen
65b7f84568 cpu/cortexm_common: implement irq_is_enabled() 2021-08-25 08:01:05 +02:00
8f10f22b1f cpu/cortexm: ldscripts: bkup-ram -> bkup_ram
Fixes this error with binutils 2.37:

```
/usr/lib/gcc/arm-none-eabi/11.2.0/../../../../arm-none-eabi/bin/ld:cortexm_base.ld:217: warning: memory region `bkup' not declared
/usr/lib/gcc/arm-none-eabi/11.2.0/../../../../arm-none-eabi/bin/ld:cortexm_base.ld:217: syntax error
```
2021-08-18 10:29:38 +02:00
Jan Romann
4384795cb9
treewide: Remove excessive newlines 2021-08-13 19:50:38 +02:00
Benjamin Valentin
6d42c9fcfe cpu: make newlib_nano a DEFAULT_MODULE
This allows to disable nanospecs with

    DISABLE_MODULE += newlib_nano

if a full-features version of newlib is desired.
2021-05-04 12:12:36 +02:00
Sebastiaan de Schaetzen
e3c9b0c4ca cortexm: initialise fpu early 2021-04-29 13:19:47 +02:00
Hauke Petersen
899fe63fe2 cpu/cortexm_common/kconfig: add dbgpin feature 2021-02-26 11:34:52 +01:00
Hauke Petersen
47a031e483 cpu/cortexm_common: add dbgpin initialization 2021-02-26 11:34:52 +01:00
4dc8895093
cpu/cortexm_common: always add jlink as supported programmer 2021-02-24 13:27:04 +01:00
858b5ca6ed xfa: remove obsolete empty xfa.ld 2021-02-18 10:46:08 +01:00
d8d34e033c cpu/cortexm_common: add XFA handling to linkerscript
The global core/ldscripts/xfa.ld doesn't match our cortexm_base.ld.
This commit directly adds the two XFA lines to cortexm_base.ld.
In addition to that, a dummy (empty) xfa.ld is added, which the linker will pick
instead of core/ldscripts/xfa.ld, effectingly not using it.
2021-02-18 10:46:08 +01:00
Francisco Molina
63a2a6ce1b
treewide: model newlib as a FEATURE 2021-01-27 09:24:25 +01:00