linux/arch/xtensa
Max Filippov 11e969bc96 xtensa: support coprocessors on SMP
Current coprocessor support on xtensa only works correctly on
uniprocessor configurations. Make it work on SMP too and keep it lazy.

Make coprocessor_owner array per-CPU and move it to struct exc_table for
easy access from the fast_coprocessor exception handler. Allow task to
have live coprocessors only on single CPU, record this CPU number in the
struct thread_info::cp_owner_cpu. Change struct thread_info::cpenable
meaning to be 'coprocessors live on cp_owner_cpu'.
Introduce C-level coprocessor exception handler that flushes and
releases live coprocessors of the task taking 'coprocessor disabled'
exception and call it from the fast_coprocessor handler when the task
has live coprocessors on other CPU.
Make coprocessor_flush_all and coprocessor_release_all work correctly
when called from any CPU by sending IPI to the cp_owner_cpu. Add
function coprocessor_flush_release_all to do flush followed by release
atomically. Add function local_coprocessors_flush_release_all to flush
and release all coprocessors on the local CPU and use it to flush
coprocessor contexts from the CPU that goes offline.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
2022-05-01 19:51:23 -07:00
..
boot xtensa: enable KCSAN 2022-05-01 19:51:22 -07:00
configs rcu: Fix undefined Kconfig macros 2021-09-13 16:32:46 -07:00
include xtensa: support coprocessors on SMP 2022-05-01 19:51:23 -07:00
kernel xtensa: support coprocessors on SMP 2022-05-01 19:51:23 -07:00
lib xtensa: enable KCSAN 2022-05-01 19:51:22 -07:00
mm xtensa: noMMU: allow handling protection faults 2022-05-01 19:51:21 -07:00
platforms xtensa: iss: extract and constify network callbacks 2022-05-01 19:51:20 -07:00
variants
Kbuild xtensa: move core-y in arch/xtensa/Makefile to arch/xtensa/Kbuild 2021-08-11 11:37:13 -07:00
Kconfig xtensa: enable KCSAN 2022-05-01 19:51:22 -07:00
Kconfig.debug xtensa: make stack dump size configurable 2019-11-26 11:33:39 -08:00
Makefile xtensa: add kernel ABI selection to Kconfig 2022-03-09 14:16:35 -08:00