coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
cache.c File Reference
#include <stdint.h>
#include <arch/cache.h>
#include <program_loading.h>
Include dependency graph for cache.c:

Go to the source code of this file.

Enumerations

enum  dcache_op {
  OP_DCCSW , OP_DCCISW , OP_DCISW , OP_DCCIMVAC ,
  OP_DCCMVAC , OP_DCIMVAC , OP_DCCSW , OP_DCCISW ,
  OP_DCISW , OP_DCCIVAC , OP_DCCVAC , OP_DCIVAC
}
 

Functions

void tlb_invalidate_all (void)
 
unsigned int dcache_line_bytes (void)
 
static void dcache_op_mva (void const *addr, size_t len, enum dcache_op op)
 
void dcache_clean_by_mva (void const *addr, size_t len)
 
void dcache_clean_invalidate_by_mva (void const *addr, size_t len)
 
void dcache_invalidate_by_mva (void const *addr, size_t len)
 
void dcache_mmu_disable (void)
 
void dcache_mmu_enable (void)
 
void cache_sync_instructions (void)
 
void arch_segment_loaded (uintptr_t start, size_t size, int flags)
 

Enumeration Type Documentation

◆ dcache_op

enum dcache_op
Enumerator
OP_DCCSW 
OP_DCCISW 
OP_DCISW 
OP_DCCIMVAC 
OP_DCCMVAC 
OP_DCIMVAC 
OP_DCCSW 
OP_DCCISW 
OP_DCISW 
OP_DCCIVAC 
OP_DCCVAC 
OP_DCIVAC 

Definition at line 21 of file cache.c.

Function Documentation

◆ arch_segment_loaded()

void arch_segment_loaded ( uintptr_t  start,
size_t  size,
int  flags 
)

Definition at line 138 of file cache.c.

References cache_sync_instructions().

Here is the call graph for this function:

◆ cache_sync_instructions()

void cache_sync_instructions ( void  )

Definition at line 118 of file cache.c.

References dcache_clean_all(), dcache_clean_invalidate_all(), dsb, iciallu(), isb, read_sctlr(), SCTLR_C, and SCTLR_I.

Here is the call graph for this function:

◆ dcache_clean_by_mva()

void dcache_clean_by_mva ( void const *  addr,
size_t  len 
)

Definition at line 79 of file cache.c.

References addr, dcache_op_mva(), and OP_DCCMVAC.

Here is the call graph for this function:

◆ dcache_clean_invalidate_by_mva()

void dcache_clean_invalidate_by_mva ( void const *  addr,
size_t  len 
)

Definition at line 84 of file cache.c.

References addr, dcache_op_mva(), and OP_DCCIMVAC.

Here is the call graph for this function:

◆ dcache_invalidate_by_mva()

void dcache_invalidate_by_mva ( void const *  addr,
size_t  len 
)

Definition at line 89 of file cache.c.

References addr, dcache_op_mva(), and OP_DCIMVAC.

Here is the call graph for this function:

◆ dcache_line_bytes()

unsigned int dcache_line_bytes ( void  )

Definition at line 30 of file cache.c.

References read_ccsidr().

Here is the call graph for this function:

◆ dcache_mmu_disable()

void dcache_mmu_disable ( void  )

Definition at line 99 of file cache.c.

References dcache_clean_invalidate_all(), read_sctlr(), SCTLR_C, SCTLR_M, and write_sctlr().

Here is the call graph for this function:

◆ dcache_mmu_enable()

void dcache_mmu_enable ( void  )

Definition at line 109 of file cache.c.

References read_sctlr(), SCTLR_C, SCTLR_M, and write_sctlr().

Here is the call graph for this function:

◆ dcache_op_mva()

static void dcache_op_mva ( void const *  addr,
size_t  len,
enum dcache_op  op 
)
static

Definition at line 52 of file cache.c.

References addr, dcache_line_bytes(), dccimvac(), dccmvac(), dcimvac(), dsb, isb, OP_DCCIMVAC, OP_DCCMVAC, and OP_DCIMVAC.

Referenced by dcache_clean_by_mva(), dcache_clean_invalidate_by_mva(), and dcache_invalidate_by_mva().

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

◆ tlb_invalidate_all()

void tlb_invalidate_all ( void  )

Definition at line 13 of file cache.c.

References dsb, isb, and tlbiall().

Here is the call graph for this function: