coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
tables.c File Reference
#include <console/console.h>
#include <bootmem.h>
#include <boot/tables.h>
#include <boot/coreboot_tables.h>
#include <arch/pirq_routing.h>
#include <arch/smp/mpspec.h>
#include <acpi/acpi.h>
#include <commonlib/helpers.h>
#include <string.h>
#include <cbmem.h>
#include <smbios.h>
Include dependency graph for tables.c:

Go to the source code of this file.

Macros

#define MAX_PIRQ_TABLE_SIZE   (4 * 1024)
 
#define MAX_MP_TABLE_SIZE   (4 * 1024)
 
#define MAX_SMBIOS_SIZE   (4 * KiB)
 
#define FORWARDING_TABLE_ADDR   ((uintptr_t)0x500)
 

Functions

static unsigned long write_pirq_table (unsigned long rom_table_end)
 
static unsigned long write_mptable (unsigned long rom_table_end)
 
static unsigned long write_acpi_table (unsigned long rom_table_end)
 
static unsigned long write_smbios_table (unsigned long rom_table_end)
 
void arch_write_tables (uintptr_t coreboot_table)
 
void bootmem_arch_add_ranges (void)
 

Variables

static uintptr_t forwarding_table = FORWARDING_TABLE_ADDR
 

Macro Definition Documentation

◆ FORWARDING_TABLE_ADDR

#define FORWARDING_TABLE_ADDR   ((uintptr_t)0x500)

Definition at line 180 of file tables.c.

◆ MAX_MP_TABLE_SIZE

#define MAX_MP_TABLE_SIZE   (4 * 1024)

◆ MAX_PIRQ_TABLE_SIZE

#define MAX_PIRQ_TABLE_SIZE   (4 * 1024)

◆ MAX_SMBIOS_SIZE

#define MAX_SMBIOS_SIZE   (4 * KiB)

Function Documentation

◆ arch_write_tables()

void arch_write_tables ( uintptr_t  coreboot_table)

Definition at line 183 of file tables.c.

References ALIGN_UP, CONFIG, forwarding_table, KiB, void(), write_acpi_table(), write_coreboot_forwarding_table(), write_mptable(), write_pirq_table(), and write_smbios_table().

Here is the call graph for this function:

◆ bootmem_arch_add_ranges()

void bootmem_arch_add_ranges ( void  )

Definition at line 212 of file tables.c.

References base, BM_MEM_TABLE, bootmem_add_range(), and forwarding_table.

Here is the call graph for this function:

◆ write_acpi_table()

static unsigned long write_acpi_table ( unsigned long  rom_table_end)
static

Definition at line 76 of file tables.c.

References ALIGN_UP, BIOS_DEBUG, BIOS_ERR, cbmem_add(), CBMEM_ID_ACPI, KiB, memcmp(), memcpy(), post_code, printk, RSDP_SIG, and write_acpi_tables().

Referenced by arch_write_tables().

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

◆ write_mptable()

static unsigned long write_mptable ( unsigned long  rom_table_end)
static

Definition at line 47 of file tables.c.

References ALIGN_UP, BIOS_DEBUG, BIOS_ERR, cbmem_add(), CBMEM_ID_MPTABLE, MAX_MP_TABLE_SIZE, post_code, printk, and write_smp_table().

Referenced by arch_write_tables().

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

◆ write_pirq_table()

static unsigned long write_pirq_table ( unsigned long  rom_table_end)
static

Definition at line 15 of file tables.c.

References ALIGN_UP, BIOS_DEBUG, BIOS_ERR, cbmem_add(), CBMEM_ID_PIRQ, MAX_PIRQ_TABLE_SIZE, post_code, printk, and write_pirq_routing_table().

Referenced by arch_write_tables().

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

◆ write_smbios_table()

static unsigned long write_smbios_table ( unsigned long  rom_table_end)
static

Definition at line 141 of file tables.c.

References ALIGN_UP, BIOS_DEBUG, BIOS_ERR, cbmem_add(), CBMEM_ID_SMBIOS, MAX_SMBIOS_SIZE, memcpy(), printk, and smbios_write_tables().

Referenced by arch_write_tables().

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

Variable Documentation

◆ forwarding_table

uintptr_t forwarding_table = FORWARDING_TABLE_ADDR
static

Definition at line 181 of file tables.c.

Referenced by arch_write_tables(), and bootmem_arch_add_ranges().