![]() |
SyterKit 0.4.0.x
SyterKit is a bare-metal framework
|
#include <stdbool.h>#include <stddef.h>#include <stdint.h>#include <stdlib.h>#include <types.h>#include <mmu.h>#include <timer.h>#include <csr.h>#include <common.h>#include <log.h>#include <sys-clic.h>
Classes | |
| struct | pt_regs_t |
| struct | insn_fetch_t |
| union | endian_buf_t |
| struct | instruction_info_t |
Macros | |
| #define | EXTRACT_FIELD(val, which) (((val) & (which)) / ((which) & ~((which) -1))) |
| #define | INSERT_FIELD(val, which, fieldval) (((val) & ~(which)) | ((fieldval) * ((which) & ~((which) -1)))) |
| #define | _STRINGIFY(x) #x |
| #define | STRINGIFY(x) _STRINGIFY(x) |
| #define | DEFINE_MPRV_READ_FLAGS(name, type, insn, flags) |
| #define | DEFINE_MPRV_READ(name, type, insn) DEFINE_MPRV_READ_FLAGS(name, type, insn, 0x00020000) |
| #define | DEFINE_MPRV_READ_MXR(name, type, insn) DEFINE_MPRV_READ_FLAGS(name, type, insn, 0x00020000 | 0x00080000) |
| #define | DEFINE_MPRV_WRITE(name, type, insn) |
Functions | |
| static const char * | mstatus_to_previous_mode (unsigned long ms) |
| static void | show_regs (struct pt_regs_t *regs) |
| static struct instruction_info_t * | match_instruction (unsigned long insn) |
| static int | fetch_16bit_instruction (unsigned long vaddr, unsigned long *insn) |
| static int | fetch_32bit_instruction (unsigned long vaddr, unsigned long *insn) |
| static void | redirect_trap (void) |
| static void | handle_misaligned (struct pt_regs_t *regs) |
| void | riscv_handle_exception (struct pt_regs_t *regs) |
Variables | |
| static struct instruction_info_t | insn_info [] |
| static const char * | interrupt_names [] |
| static const char * | exception_names [] |
| #define _STRINGIFY | ( | x | ) | #x |
| #define DEFINE_MPRV_READ | ( | name, | |
| type, | |||
| insn | |||
| ) | DEFINE_MPRV_READ_FLAGS(name, type, insn, 0x00020000) |
| #define DEFINE_MPRV_READ_FLAGS | ( | name, | |
| type, | |||
| insn, | |||
| flags | |||
| ) |
| #define DEFINE_MPRV_READ_MXR | ( | name, | |
| type, | |||
| insn | |||
| ) | DEFINE_MPRV_READ_FLAGS(name, type, insn, 0x00020000 | 0x00080000) |
| #define DEFINE_MPRV_WRITE | ( | name, | |
| type, | |||
| insn | |||
| ) |
| #define INSERT_FIELD | ( | val, | |
| which, | |||
| fieldval | |||
| ) | (((val) & ~(which)) | ((fieldval) * ((which) & ~((which) -1)))) |
| #define STRINGIFY | ( | x | ) | _STRINGIFY(x) |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
| void riscv_handle_exception | ( | struct pt_regs_t * | regs | ) |
|
static |
|
static |
|
static |
|
static |