Expand description
Constants for version 1.4 of the Arm SMC Calling Convention and version 1.1 of the Arm Power State Coordination Interface (PSCI) version 1.1, and functions to call them.
Note that PSCI and other SMCCC calls may be made via either HVC or SMC. You can choose which one
to use by building this crate with the corresponding feature (i.e. hvc or smc). By default
hvc is enabled. If neither feature is enabled then the functions to make calls will not be
available, but the constants and types are still provided.
This crate currently only supports aarch64 and the SMC64 versions of the various calls, in the cases that both SMC32 and SMC64 versions exist.
Modules
- PSCI error codes.
- Functions for making SMCCC calls.
Enums
- Affinity state values returned by
AFFINITY_INFO. - Selects which affinity level fields are valid in the
target_affinityparameter toAFFINITY_INFO. - The level of multicore support in the Trusted OS, as returned by
MIGRATE_INFO_TYPE. - The power state of a node in the power domain topology, as returned by
NODE_HW_STATE. - The mode to be used by
CPU_SUSPEND, as set byPSCI_SET_SUSPEND_MODE.
Constants
Functions
- Gets the status of an affinity instance.
- Puts the current core into an implementation-defined low power state.
- Puts the current core into an implementation-defined low power state.
- Powers down the current core.
- Powers up a core.
- Suspends execution of a core or topology node.
- Enables or disables memory protection.
- Checks whether a memory range is protected by
MEM_PROTECT. - Asks the Trusted OS to migrate its context to a specific core.
- Identifies the levelof multicore support in the Trusted OS.
- Returns the MPIDR value of the current resident core of the Trusted OS.
- Retuns the true hardware state of a node in the power domain topology.
- Queries whether
SMCCC_VERSIONor a specific PSCI function is implemented, and what features are supported. - Sets the mode used by
CPU_SUSPEND. - Returns the number of times the platform has used the given power state since cold boot.
- Returns the amount of time the platform has spend in the given power state since cold boot.
- Shuts down the system.
- Resets the system.
- Resets the system in an architectural or vendor-specific way.
- Suspends the system to RAM.
- Returns the version of PSCI implemented.