FreeRTOS port on GAP8/RISC-V
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pmu_internal.c File Reference

Macros

#define PI_PMU_BOOT_DEV_ROM
 
#define PI_PMU_BOOT_DEV_L2
 
#define PI_PMU_BOOT_POW_STATE_SOC_LV
 
#define PI_PMU_BOOT_POW_STATE_SOC_HV
 
#define PI_PMU_FLL_RET_OFF
 
#define PI_PMU_FLL_RET_ON
 
#define PI_PMU_L2_MEM_RET_OFF
 
#define PI_PMU_L2_MEM_RET_ON
 
#define PI_PMU_MV_TO_DCDC(mV)
 
#define PI_PMU_DCDC_TO_MV(Dc)
 

Enumerations

enum  pi_pmu_scu_seq_e
 

Functions

static void __pi_pmu_handler (void *arg)
 
static void __pi_pmu_task_fifo_enqueue (pi_task_t *task)
 
static pi_task_t__pi_pmu_task_fifo_pop ()
 
static void __pi_pmu_regulator_state_change (pi_pmu_scu_seq_e scu_seq)
 
void __pi_pmu_init (void)
 
int __pi_pmu_voltage_set (pi_pmu_domain_e domain, uint32_t voltage)
 
int __pi_pmu_state_get (pi_pmu_domain_e domain)
 
int __pi_pmu_boot_state_get (pi_pmu_domain_e domain)
 
int __pi_pmu_sleep_mode_set (pi_pmu_domain_e domain, struct pi_pmu_sleep_conf_s *conf)
 
int __pi_pmu_sleep_mode_enable (pi_pmu_domain_e domain)
 

Variables

static struct pmu_data_s g_pmu_data
 

Macro Definition Documentation

#define PI_PMU_BOOT_DEV_L2

Referenced by __pi_pmu_sleep_mode_set().

#define PI_PMU_BOOT_DEV_ROM

Referenced by __pi_pmu_sleep_mode_set().

#define PI_PMU_BOOT_POW_STATE_SOC_HV
#define PI_PMU_BOOT_POW_STATE_SOC_LV
#define PI_PMU_DCDC_TO_MV (   Dc)

Referenced by __pi_pmu_init().

#define PI_PMU_FLL_RET_OFF

Referenced by __pi_pmu_sleep_mode_set().

#define PI_PMU_FLL_RET_ON

Referenced by __pi_pmu_sleep_mode_set().

#define PI_PMU_L2_MEM_RET_OFF

Referenced by __pi_pmu_sleep_mode_set().

#define PI_PMU_L2_MEM_RET_ON

Referenced by __pi_pmu_sleep_mode_set().

#define PI_PMU_MV_TO_DCDC (   mV)

Referenced by __pi_pmu_voltage_set().

Enumeration Type Documentation

WIU_IFR1[0] = SCU_4 SoC-sleep, CL-sleep WIU_IFR1[1] = SCU_5 SoC-ret, CL-sleep WIU_IFR1[2] = SCU_0 SoC-NV, CL-sleep WIU_IFR1[3] = SCU_1 SoC-LV, CL-sleep WIU_IFR1[4] = SCU_2 SoC-NV, CL-ON WIU_IFR1[5] = SCU_3 SoC-LV, CL-ON

Enumerator
PI_PMU_SCU_SEQ_DEEP_SLEEP 
PI_PMU_SCU_SEQ_RET_DEEP_SLEEP 
PI_PMU_SCU_SEQ_HP_CLUSTER_OFF 
PI_PMU_SCU_SEQ_LP_CLUSTER_OFF 
PI_PMU_SCU_SEQ_HP_CLUSTER_ON 
PI_PMU_SCU_SEQ_LP_CLUSTER_ON 

Function Documentation

int __pi_pmu_boot_state_get ( pi_pmu_domain_e  domain)
static void __pi_pmu_handler ( void *  arg)
static
int __pi_pmu_state_get ( pi_pmu_domain_e  domain)
static void __pi_pmu_task_fifo_enqueue ( pi_task_t task)
static
static pi_task_t * __pi_pmu_task_fifo_pop ( )
static

References pmu_data_s::fifo_head.

Referenced by __pi_pmu_handler().

Variable Documentation

struct pmu_data_s g_pmu_data
static