coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
ramdetect.c File Reference
#include <types.h>
#include <device/mmio.h>
#include <ramdetect.h>
#include <arch/exception.h>
#include <arch/transition.h>
Include dependency graph for ramdetect.c:

Go to the source code of this file.

Enumerations

enum  { ABORT_CHECKER_NOT_TRIGGERED , ABORT_CHECKER_TRIGGERED }
 

Functions

static int abort_checker (struct exc_state *state, uint64_t vector_id)
 
int probe_mb (const uintptr_t dram_start, const uintptr_t size)
 

Variables

static enum { ... }  abort_state = ABORT_CHECKER_NOT_TRIGGERED
 
static struct exception_handler sync_el0 = {.handler = &abort_checker}
 

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
ABORT_CHECKER_NOT_TRIGGERED 
ABORT_CHECKER_TRIGGERED 

Definition at line 9 of file ramdetect.c.

Function Documentation

◆ abort_checker()

static int abort_checker ( struct exc_state state,
uint64_t  vector_id 
)
static

Definition at line 14 of file ramdetect.c.

References ABORT_CHECKER_TRIGGERED, abort_state, EXC_RET_HANDLED, and EXC_RET_IGNORED.

◆ probe_mb()

int probe_mb ( const uintptr_t  dram_start,
const uintptr_t  size 
)

Definition at line 27 of file ramdetect.c.

References ABORT_CHECKER_NOT_TRIGGERED, abort_state, addr, EXC_VID_CUR_SP_EL0_SYNC, exception_handler_register(), exception_handler_unregister(), MiB, read32(), and sync_el0.

Referenced by probe_ramsize().

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

Variable Documentation

◆ 

enum { ... } abort_state

Referenced by abort_checker(), and probe_mb().

◆ sync_el0

struct exception_handler sync_el0 = {.handler = &abort_checker}
static

Definition at line 14 of file ramdetect.c.

Referenced by probe_mb(), and test_exception().