Zephyr Project API 4.4.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches

ARM PSCI specific APIs for CPU power management. More...

#include <zephyr/types.h>
#include <zephyr/arch/arm64/arm-smccc.h>
#include <stddef.h>
#include <zephyr/device.h>

Go to the source code of this file.

Macros

#define PSCI_VERSION_MAJOR(ver)
 Extract the major version field from a PSCI version value.
#define PSCI_VERSION_MINOR(ver)
 Extract the minor version field from a PSCI version value.

Functions

uint32_t psci_version (void)
 Get the PSCI firmware version.
int psci_cpu_suspend (uint32_t state, uintptr_t entry_point)
 Function to call PSCI CPU_SUSPEND.

Detailed Description

ARM PSCI specific APIs for CPU power management.

Macro Definition Documentation

◆ PSCI_VERSION_MAJOR

#define PSCI_VERSION_MAJOR ( ver)
Value:
(((ver) & PSCI_VERSION_MAJOR_MASK) >> PSCI_VERSION_MAJOR_SHIFT)

Extract the major version field from a PSCI version value.

Parameters
verPSCI version value

◆ PSCI_VERSION_MINOR

#define PSCI_VERSION_MINOR ( ver)
Value:
((ver) & PSCI_VERSION_MINOR_MASK)

Extract the minor version field from a PSCI version value.

Parameters
verPSCI version value

Function Documentation

◆ psci_cpu_suspend()

int psci_cpu_suspend ( uint32_t state,
uintptr_t entry_point )

Function to call PSCI CPU_SUSPEND.

This function is API for CPU_SUSPEND PSCI SMC call.

Parameters
stateCPU Power state
entry_pointThe address entry when returning from suspend
Return values
0if enter suspend successfully, others for failure

◆ psci_version()

uint32_t psci_version ( void )

Get the PSCI firmware version.

Returns the version of the detected PSCI firmware, with the major version in the upper 16 bits and the minor version in the lower 16 bits. Use PSCI_VERSION_MAJOR() and PSCI_VERSION_MINOR() to decode the fields.

Returns
PSCI firmware version