kernel: arch: introduce k_float_enable()
This patch introduce new API to enable FPU of thread. This is pair of existed k_float_disable() API. And also add empty arch_float_enable() into each architectures that have arch_float_disable(). The arc and riscv already implemented arch_float_enable() so I do not touch these implementations. Motivation: Current Zephyr implementation does not allow to use FPU on main and other system threads like as work queue. Users need to create an other thread with K_FP_REGS for floating point programs. Users can use FPU more easily if they can enable FPU on running threads. Signed-off-by: Katsuhiro Suzuki <katsuhiro@katsuster.net>
This commit is contained in:
parent
f5df09891f
commit
59903e2934
10 changed files with 93 additions and 34 deletions
|
@ -152,7 +152,7 @@ int arch_float_disable(struct k_thread *thread)
|
|||
}
|
||||
|
||||
|
||||
int arch_float_enable(struct k_thread *thread)
|
||||
int arch_float_enable(struct k_thread *thread, unsigned int options)
|
||||
{
|
||||
unsigned int key;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue