Infuse-IoT SDK API 0.0.1
A Scalable Open Source RTOS
|
Infuse reboot API . More...
Data Structures | |
union | infuse_reboot_info |
Detailed information about the reboot location/cause RISCV platforms have 16 byte alignment requirements for arch_esf. More... | |
struct | infuse_reboot_state |
Reboot state information. More... | |
Macros | |
#define | REBOOT_STATE_THREAD_NAME_MAX 8 |
Enumerations | |
enum | infuse_reboot_reason { INFUSE_REBOOT_ZEPHYR_BASE = K_ERR_CPU_EXCEPTION , INFUSE_REBOOT_ARCH_SPECIFIC = K_ERR_ARCH_START , INFUSE_REBOOT_INFUSE_START = 128 , INFUSE_REBOOT_HW_WATCHDOG = 128 , INFUSE_REBOOT_EXTERNAL_TRIGGER = 129 , INFUSE_REBOOT_RPC = 130 , INFUSE_REBOOT_LTE_MODEM_FAULT = 131 , INFUSE_REBOOT_MCUMGR = 132 , INFUSE_REBOOT_CFG_CHANGE = 133 , INFUSE_REBOOT_SW_WATCHDOG = 134 , INFUSE_REBOOT_DFU = 135 , INFUSE_REBOOT_UNKNOWN = 255 } |
Enumeration of reboot reasons. More... | |
enum | infuse_reboot_info_type { INFUSE_REBOOT_INFO_GENERIC = 0 , INFUSE_REBOOT_INFO_EXCEPTION_BASIC , INFUSE_REBOOT_INFO_EXCEPTION_ESF , INFUSE_REBOOT_INFO_WATCHDOG } |
Type of infuse_reboot_info data. More... | |
Functions | |
_NORETURN void | infuse_reboot (enum infuse_reboot_reason reason, uint32_t info1, uint32_t info2) |
Trigger a system reboot. | |
void | infuse_reboot_delayed (enum infuse_reboot_reason reason, uint32_t info1, uint32_t info2, k_timeout_t delay) |
Trigger a system reboot in the future. | |
int | infuse_reboot_state_query (struct infuse_reboot_state *state) |
Query the reason for the previous reboot. | |
Infuse reboot API .
#define REBOOT_STATE_THREAD_NAME_MAX 8 |
#include <infuse/reboot.h>
#include <infuse/reboot.h>
Type of infuse_reboot_info data.
enum infuse_reboot_reason |
#include <infuse/reboot.h>
Enumeration of reboot reasons.
_NORETURN void infuse_reboot | ( | enum infuse_reboot_reason | reason, |
uint32_t | info1, | ||
uint32_t | info2 ) |
#include <infuse/reboot.h>
Trigger a system reboot.
reason | Reason the system is rebooting |
info1 | Generic information to identify/diagnose the reboot |
info2 | Generic information to identify/diagnose the reboot |
void infuse_reboot_delayed | ( | enum infuse_reboot_reason | reason, |
uint32_t | info1, | ||
uint32_t | info2, | ||
k_timeout_t | delay ) |
#include <infuse/reboot.h>
Trigger a system reboot in the future.
reason | Reason the system is rebooting |
info1 | Generic information to identify/diagnose the reboot |
info2 | Generic information to identify/diagnose the reboot |
delay | Time delay or absolute time to execute the reboot |
int infuse_reboot_state_query | ( | struct infuse_reboot_state * | state | ) |
#include <infuse/reboot.h>
Query the reason for the previous reboot.
If this function returns 0, state->hardware_reason contains the reboot reason and the hardware register values are cleared.
state | State storage area |
0 | On successful state query |
-ENOENT | No stored state exists |
-errno | Other error from retention_read |