AM62L FreeRTOS SDK  11.02.00
scp/psci/v0/psci.h File Reference

Introduction

PSCI Driver API/interface file.

Go to the source code of this file.

Data Structures

struct  PSCI_Object
 PSCI driver object. More...
 
struct  PSCI_Config
 PSCI Global Configuration. More...
 

Macros

#define PSCI_BASE_FUNC   (uint32_t) 0x84000000U
 
#define PSCI_FUNC(n)   (PSCI_BASE_FUNC + (n))
 
#define PSCI_FUNC_OFF_64BIT   (uint32_t) 0x40000000U
 
#define PSCI_BASE_FUNC_64BIT    (PSCI_BASE_FUNC + PSCI_FUNC_OFF_64BIT)
 
#define PSCI_FUNC_64BIT(n)   (PSCI_BASE_FUNC_64BIT + (n))
 
#define PSCI_FUNC_PSCI_VERSION   PSCI_FUNC(0)
 
#define PSCI_FUNC_CPU_OFF   PSCI_FUNC(2)
 
#define PSCI_FUNC_SYSTEM_RESET   PSCI_FUNC(9)
 
#define PSCI_FUNC_CPU_ON_64BIT   PSCI_FUNC_64BIT(3)
 
#define PSCI_FUNC_PSCI_FEATURES   PSCI_FUNC(10)
 
#define PSCI_MAJOR_VERSION_SHIFT   (16U)
 
#define PSCI_MINOR_VERSION_MASK    ((1U << PSCI_MAJOR_VERSION_SHIFT) - 1)
 
#define PSCI_MAJOR_VERSION_MASK   ~PSCI_MINOR_VERSION_MASK
 
#define PSCI_MAJOR_VERSION(ver)    (((ver) & PSCI_MAJOR_VERSION_MASK) >> PSCI_MAJOR_VERSION_SHIFT)
 
#define PSCI_MINOR_VERSION(ver)    ((ver) & PSCI_MINOR_VERSION_MASK)
 
#define PSCI_SUCCESS   (0)
 
#define PSCI_NOT_SUPPORTED   (-1)
 
#define PSCI_INVALID_PARAMS   (-2)
 
#define PSCI_DENIED   (-3)
 
#define PSCI_ALREADY_ON   (-4)
 
#define PSCI_ON_PENDING   (-5)
 
#define PSCI_INTERNAL_FAILURE   (-6)
 
#define PSCI_NOT_PRESENT   (-7)
 
#define PSCI_DISABLED   (-8)
 
#define PSCI_INVALID_ADDRESS   (-9)
 

Typedefs

typedef struct PSCI_Config_s * PSCI_Handle
 A handle that is returned from a PSCI_open() call. More...
 

Functions

void PSCI_init (void)
 Initialize the PSCI module. More...
 
void PSCI_deinit (void)
 Deinitialize the PSCI module. More...
 
PSCI_Handle PSCI_open (uint32_t idx)
 Open the PSCI at index idx. More...
 
void PSCI_close (PSCI_Handle handle)
 Function to close the PSCI instance specified by the handle. More...
 
PSCI_Handle PSCI_getHandle (uint32_t driverInstanceIndex)
 This function returns the handle of an open PSCI Instance from the instance index. More...
 
uint32_t PSCI_getInitDriverIndex (void)
 This function returns the initialised instance index. More...
 
int32_t PSCI_getPSCIVersion (PSCI_Handle handle, uint32_t *psciVer)
 Get the PSCI version. More...
 
int32_t PSCI_cpuOff (PSCI_Handle handle)
 Power off the calling CPU. More...
 
int32_t PSCI_cpuOn (PSCI_Handle handle, uint32_t cpuId, uint32_t entryPoint)
 Power on the CPU required. More...
 
int32_t PSCI_systemReset (PSCI_Handle handle)
 Cold reset of the entire system. More...
 
int32_t PSCI_getFeatures (PSCI_Handle handle, uint32_t functionId, uint32_t *feature)
 Get the features of a PSCI function. More...