Expand description
Runtime gating for user-mode FPU / Vector context handling.
This module complements Cargo feature gates (user-fpu, user-vector) with
a DTB(FDT)-driven runtime switch. When the relevant Cargo feature is enabled,
the kernel will decide at boot whether user-mode access should actually be
allowed based on information found in the device tree.
ยงDTB overrides
If present under /chosen, the following properties override auto-detection:
scarlet,user-fpu(boolean or u32/u64)scarlet,user-vector(boolean or u32/u64)
When absent, the kernel attempts architecture-specific detection when
available (currently implemented for RISC-V via riscv,isa).
Constantsยง
- FLAG_
USER_ ๐FPU - FLAG_
USER_ ๐VECTOR
Staticsยง
- FLAGS ๐
- INITIALIZED ๐
Functionsยง
- arch_
defaults_ ๐from_ fdt - bytes_
to_ ๐cstr - init_
from_ fdt - Initialize runtime user-context switches from the current DTB (FDT).
- read_
boolish_ ๐property - riscv_
extensions_ ๐from_ fdt - riscv_
extensions_ ๐from_ isa_ extensions - riscv_
extensions_ ๐from_ isa_ string - riscv_
isa_ ๐suffix_ has_ vector_ tokens - riscv_
token_ ๐is_ fpu - riscv_
token_ ๐is_ vector - user_
fpu_ enabled - Returns whether user-mode FPU context handling is enabled (feature + DTB).
- user_
vector_ enabled - Returns whether user-mode Vector context handling is enabled (feature + DTB).