Zephyr API Documentation 4.0.0-rc2
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
reset.h File Reference

Public Reset Controller driver APIs. More...

#include <errno.h>
#include <zephyr/types.h>
#include <zephyr/device.h>
#include <zephyr/syscalls/reset.h>

Go to the source code of this file.

Data Structures

struct  reset_dt_spec
 Reset controller device configuration. More...
 

Macros

#define RESET_DT_SPEC_GET_BY_IDX(node_id, idx)
 Static initializer for a reset_dt_spec.
 
#define RESET_DT_SPEC_GET_BY_IDX_OR(node_id, idx, default_value)
 Like RESET_DT_SPEC_GET_BY_IDX(), with a fallback to a default value.
 
#define RESET_DT_SPEC_GET(node_id)
 Equivalent to RESET_DT_SPEC_GET_BY_IDX(node_id, 0).
 
#define RESET_DT_SPEC_GET_OR(node_id, default_value)
 Equivalent to RESET_DT_SPEC_GET_BY_IDX_OR(node_id, 0, default_value).
 
#define RESET_DT_SPEC_INST_GET_BY_IDX(inst, idx)
 Static initializer for a reset_dt_spec from a DT_DRV_COMPAT instance's Reset Controller property at an index.
 
#define RESET_DT_SPEC_INST_GET_BY_IDX_OR(inst, idx, default_value)
 Static initializer for a reset_dt_spec from a DT_DRV_COMPAT instance's 'resets' property at an index, with fallback.
 
#define RESET_DT_SPEC_INST_GET(inst)
 Equivalent to RESET_DT_SPEC_INST_GET_BY_IDX(inst, 0).
 
#define RESET_DT_SPEC_INST_GET_OR(inst, default_value)
 Equivalent to RESET_DT_SPEC_INST_GET_BY_IDX_OR(node_id, 0, default_value).
 

Functions

int reset_status (const struct device *dev, uint32_t id, uint8_t *status)
 Get the reset status.
 
static int reset_status_dt (const struct reset_dt_spec *spec, uint8_t *status)
 Get the reset status from a reset_dt_spec.
 
int reset_line_assert (const struct device *dev, uint32_t id)
 Put the device in reset state.
 
static int reset_line_assert_dt (const struct reset_dt_spec *spec)
 Assert the reset state from a reset_dt_spec.
 
int reset_line_deassert (const struct device *dev, uint32_t id)
 Take out the device from reset state.
 
static int reset_line_deassert_dt (const struct reset_dt_spec *spec)
 Deassert the reset state from a reset_dt_spec.
 
int reset_line_toggle (const struct device *dev, uint32_t id)
 Reset the device.
 
static int reset_line_toggle_dt (const struct reset_dt_spec *spec)
 Reset the device from a reset_dt_spec.
 

Detailed Description

Public Reset Controller driver APIs.