Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Xtensa interrupt vectoring: peripheral source - Initial Xtensa vectoring, updated esp32 gpio example to use new interrupt macro. - Only peripheral sources supported. - Only level one priority supported. - CPU & Edge interrupts still need to be handled. * Xtensa interrupt vectoring: CPU & EDGE - Add support for handling CPU interrupts and edge interrupts - PR required to xtensa-lx-rt for CPU handlers * Xtensa interrupt vectoring: Priority - Finally implement priortization - Only three priorities available at the moment. Xtensa programmer guide discourages using highpri interrupts in Rust/C. Guide also mentions using software priortization to increase the number of Priorities available * support CPU interrupts, using patch xtensa-lx-rt * Update example * Add support & examples for the s2 & s3 too * Fix formatting and missing imports * Run interrupt handling in ram, optionally run the vector handler in ram in the examples * Use xtensa_lx::Mutex CS when enabling interrupts * Run clippy on each target * Remove redundant features * Fix C3 builds * make enable unsafe. Add note about preallocated interrupts in vectored mode. * Remove `INTERRUPT_LEVELS` static The interrupt levels static introduces a few issues - A lock is needed when configuring interrupts to keep INTERRUPT_LEVELS in a consistent state - Interrupts enabled from outside the Rust domain wouldn't be serviced, this is the case with the wifi blobs To remove it, the prioty configuration is now calculated dynamically in the interrupt handler. Essentially INTERRUPT_LEVELS is now created once the interrupt triggers. It has some benefits, such as only having to look at interrupts configured on the current core, not both, but there is of course an overhead with doing this in the interrupt. * Allow raw interrupts on levels 4-7, whilst also supporting vectoring on levels 1-3 * rename core number features * Fix examples and formatting * use xtensa-lx-rt release, update pacs * Support passing the trap frame into interrupt handlers * cfg away the #[interrupt] macro when not using vectoring * rename enable to map move vectored feature to chip specific hals * export vectored functions - rename `enable_with_priority` to `enable` - add docs for interrupt macro * Update all examples to use vectored interrupts
- Loading branch information