coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
pep.c File Reference
#include <acpi/acpigen.h>
#include <assert.h>
#include <console/console.h>
#include <intelblocks/acpi.h>
#include <intelblocks/pmc_ipc.h>
#include <stdlib.h>
#include <types.h>
Include dependency graph for pep.c:

Go to the source code of this file.

Data Structures

struct  reg_info
 

Macros

#define LPI_S0_HELPER_UUID   "c4eb40a0-6cd2-11e2-bcfd-0800200c9a66"
 
#define PEP_S0IX_UUID   "57a6512e-3979-4e9d-9708-ff13b2508972"
 
#define SYSTEM_POWER_MANAGEMENT_HID   "INT33A1"
 
#define SYSTEM_POWER_MANAGEMENT_CID   "PNP0D80"
 
#define EC_S0IX_HOOK   "\\_SB.PCI0.LPCB.EC0.S0IX"
 
#define MAINBOARD_HOOK   "\\_SB.MS0X"
 
#define ENABLE_PM_BITS_HOOK   "\\_SB.PCI0.EGPM"
 
#define RESTORE_PM_BITS_HOOK   "\\_SB.PCI0.RGPM"
 
#define LPI_STATES_ALL   0xff
 
#define MIN_DEVICE_STATE   ACPI_DEVICE_SLEEP_D0
 
#define PEPD_SCOPE   "\\_SB.PCI0"
 

Functions

static void read_pmc_lpm_requirements (const struct soc_pmc_lpm *lpm, struct reg_info *info)
 
static void lpi_get_constraints (void *unused)
 
static void lpi_s0ix_entry (void *unused)
 
static void lpi_s0ix_exit (void *unused)
 
static void pep_s0ix_return_lpm_requirements (void *arg)
 
void generate_acpi_power_engine_with_lpm (const struct soc_pmc_lpm *lpm)
 
void generate_acpi_power_engine (void)
 

Variables

static void(* lpi_s0_helpers [])(void *)
 
static void(* pep_s0ix [])(void *)
 

Macro Definition Documentation

◆ EC_S0IX_HOOK

#define EC_S0IX_HOOK   "\\_SB.PCI0.LPCB.EC0.S0IX"

Definition at line 15 of file pep.c.

◆ ENABLE_PM_BITS_HOOK

#define ENABLE_PM_BITS_HOOK   "\\_SB.PCI0.EGPM"

Definition at line 17 of file pep.c.

◆ LPI_S0_HELPER_UUID

#define LPI_S0_HELPER_UUID   "c4eb40a0-6cd2-11e2-bcfd-0800200c9a66"

Definition at line 11 of file pep.c.

◆ LPI_STATES_ALL

#define LPI_STATES_ALL   0xff

Definition at line 19 of file pep.c.

◆ MAINBOARD_HOOK

#define MAINBOARD_HOOK   "\\_SB.MS0X"

Definition at line 16 of file pep.c.

◆ MIN_DEVICE_STATE

#define MIN_DEVICE_STATE   ACPI_DEVICE_SLEEP_D0

Definition at line 20 of file pep.c.

◆ PEP_S0IX_UUID

#define PEP_S0IX_UUID   "57a6512e-3979-4e9d-9708-ff13b2508972"

Definition at line 12 of file pep.c.

◆ PEPD_SCOPE

#define PEPD_SCOPE   "\\_SB.PCI0"

Definition at line 21 of file pep.c.

◆ RESTORE_PM_BITS_HOOK

#define RESTORE_PM_BITS_HOOK   "\\_SB.PCI0.RGPM"

Definition at line 18 of file pep.c.

◆ SYSTEM_POWER_MANAGEMENT_CID

#define SYSTEM_POWER_MANAGEMENT_CID   "PNP0D80"

Definition at line 14 of file pep.c.

◆ SYSTEM_POWER_MANAGEMENT_HID

#define SYSTEM_POWER_MANAGEMENT_HID   "INT33A1"

Definition at line 13 of file pep.c.

Function Documentation

◆ generate_acpi_power_engine()

void generate_acpi_power_engine ( void  )

Definition at line 207 of file pep.c.

References generate_acpi_power_engine_with_lpm(), and NULL.

Referenced by pmc_fill_ssdt().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ generate_acpi_power_engine_with_lpm()

◆ lpi_get_constraints()

static void lpi_get_constraints ( void unused)
static

◆ lpi_s0ix_entry()

static void lpi_s0ix_entry ( void unused)
static

Definition at line 112 of file pep.c.

References acpigen_emit_namestring(), acpigen_write_if_cond_ref_of(), acpigen_write_if_end(), acpigen_write_integer(), EC_S0IX_HOOK, ENABLE_PM_BITS_HOOK, and MAINBOARD_HOOK.

Here is the call graph for this function:

◆ lpi_s0ix_exit()

static void lpi_s0ix_exit ( void unused)
static

◆ pep_s0ix_return_lpm_requirements()

static void pep_s0ix_return_lpm_requirements ( void arg)
static

Definition at line 163 of file pep.c.

References acpigen_write_return_byte_buffer(), acpigen_write_return_singleton_buffer(), arg, CONFIG, and info.

Here is the call graph for this function:

◆ read_pmc_lpm_requirements()

static void read_pmc_lpm_requirements ( const struct soc_pmc_lpm lpm,
struct reg_info info 
)
static

Variable Documentation

◆ lpi_s0_helpers

void(* lpi_s0_helpers[])(void *) ( void )
static
Initial value:
= {
NULL,
NULL,
NULL,
NULL,
}
static void lpi_s0ix_exit(void *unused)
Definition: pep.c:133
static void lpi_get_constraints(void *unused)
Definition: pep.c:77
static void lpi_s0ix_entry(void *unused)
Definition: pep.c:112
#define NULL
Definition: stddef.h:19

Definition at line 153 of file pep.c.

Referenced by generate_acpi_power_engine_with_lpm().

◆ pep_s0ix

void(* pep_s0ix[])(void *) ( void )
static
Initial value:
= {
NULL,
}
static void pep_s0ix_return_lpm_requirements(void *arg)
Definition: pep.c:163

Definition at line 174 of file pep.c.

Referenced by generate_acpi_power_engine_with_lpm().