coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
acpi.c File Reference
#include <assert.h>
#include <intelblocks/acpi.h>
#include <soc/pci_devs.h>
#include <soc/util.h>
#include "chip.h"
Include dependency graph for acpi.c:

Go to the source code of this file.

Enumerations

enum  {
  C_STATE_C1 , C_STATE_C3 , C_STATE_C6 , C_STATE_C7 ,
  NUM_C_STATES
}
 

Functions

const acpi_cstate_tsoc_get_cstate_map (size_t *entries)
 
static void print_madt_ioapic (int socket, int stack, int ioapic_id, uint32_t ioapic_base, int gsi_base)
 
const struct madt_ioapic_infosoc_get_ioapic_info (size_t *entries)
 

Variables

static const acpi_cstate_t cstate_map [NUM_C_STATES]
 
static int cstate_set_all []
 
static int cstate_set_c1_c6 []
 

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
C_STATE_C1 
C_STATE_C3 
C_STATE_C6 
C_STATE_C7 
NUM_C_STATES 

Definition at line 13 of file acpi.c.

Function Documentation

◆ print_madt_ioapic()

static void print_madt_ioapic ( int  socket,
int  stack,
int  ioapic_id,
uint32_t  ioapic_base,
int  gsi_base 
)
static

Definition at line 90 of file acpi.c.

References BIOS_DEBUG, and printk.

Referenced by soc_get_ioapic_info().

Here is the caller graph for this function:

◆ soc_get_cstate_map()

const acpi_cstate_t* soc_get_cstate_map ( size_t entries)

◆ soc_get_ioapic_info()

const struct madt_ioapic_info* soc_get_ioapic_info ( size_t entries)

Variable Documentation

◆ cstate_map

const acpi_cstate_t cstate_map[NUM_C_STATES]
static
Initial value:
= {
[C_STATE_C1] = {
.latency = 1,
.power = 0x3e8,
.resource = MWAIT_RES(0, 0),
},
[C_STATE_C3] = {
.latency = 15,
.power = 0x1f4,
.resource = MWAIT_RES(1, 0),
},
[C_STATE_C6] = {
.latency = 41,
.power = 0x15e,
.resource = MWAIT_RES(2, 0),
},
[C_STATE_C7] = {
.latency = 41,
.power = 0x0c8,
.resource = MWAIT_RES(3, 0),
}
}
#define MWAIT_RES(state, sub_state)
Definition: acpi.c:17
@ C_STATE_C1
Definition: acpi.c:28
@ C_STATE_C3
Definition: acpi.c:33
@ C_STATE_C6
Definition: acpi.c:16
@ C_STATE_C7
Definition: acpi.c:17

Definition at line 21 of file acpi.c.

Referenced by soc_get_cstate_map().

◆ cstate_set_all

int cstate_set_all[]
static
Initial value:

Definition at line 49 of file acpi.c.

Referenced by soc_get_cstate_map().

◆ cstate_set_c1_c6

int cstate_set_c1_c6[]
static
Initial value:

Definition at line 56 of file acpi.c.

Referenced by soc_get_cstate_map().