Zephyr API Documentation  3.6.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
error.h File Reference

RISCV public error handling. More...

#include <zephyr/arch/riscv/syscall.h>
#include <zephyr/arch/riscv/exception.h>
#include <stdbool.h>
#include <syscalls/error.h>

Go to the source code of this file.

Macros

#define ARCH_EXCEPT(reason_p)
 

Functions

void user_fault (unsigned int reason)
 

Detailed Description

RISCV public error handling.

RISCV-specific kernel error handling interface. Included by riscv/arch.h.

Macro Definition Documentation

◆ ARCH_EXCEPT

#define ARCH_EXCEPT (   reason_p)
Value:
do { \
if (k_is_user_context()) { \
arch_syscall_invoke1(reason_p, \
K_SYSCALL_USER_FAULT); \
} else { \
compiler_barrier(); \
arch_syscall_invoke1(reason_p, \
} \
CODE_UNREACHABLE; /* LCOV_EXCL_LINE */ \
} while (false)
#define RV_ECALL_RUNTIME_EXCEPT
Definition: syscall.h:22
static __pinned_func bool k_is_user_context(void)
Indicate whether the CPU is currently in user mode.
Definition: syscall.h:115

Function Documentation

◆ user_fault()

void user_fault ( unsigned int  reason)