RV_DM Device Interface Functions More...
#include <stdbool.h>#include <stdint.h>#include "sw/device/lib/base/macros.h"#include "sw/device/lib/base/mmio.h"#include "sw/device/lib/dif/dif_base.h"#include "hw/top/dt/rv_dm.h"Go to the source code of this file.
Data Structures | |
| struct | dif_rv_dm |
| A handle to rv_dm. More... | |
Typedefs | |
| typedef struct dif_rv_dm | dif_rv_dm_t |
| A handle to rv_dm. | |
| typedef enum dif_rv_dm_alert | dif_rv_dm_alert_t |
| A rv_dm alert type. | |
Enumerations | |
| enum | dif_rv_dm_alert { kDifRvDmAlertFatalFault = 0 } |
| A rv_dm alert type. More... | |
Functions | |
| OT_WARN_UNUSED_RESULT dif_result_t | dif_rv_dm_init (mmio_region_t base_addr, dif_rv_dm_t *rv_dm) |
| Creates a new handle for a(n) rv_dm peripheral. | |
| OT_WARN_UNUSED_RESULT dif_result_t | dif_rv_dm_init_from_dt (dt_rv_dm_t dt, dif_rv_dm_t *rv_dm) |
| Creates a new handle for a(n) rv_dm peripheral. | |
| OT_WARN_UNUSED_RESULT dif_result_t | dif_rv_dm_get_dt (const dif_rv_dm_t *rv_dm, dt_rv_dm_t *dt) |
| Get the DT handle from this DIF. | |
| OT_WARN_UNUSED_RESULT dif_result_t | dif_rv_dm_alert_force (const dif_rv_dm_t *rv_dm, dif_rv_dm_alert_t alert) |
| Forces a particular alert, causing it to be escalated as if the hardware had raised it. | |
RV_DM Device Interface Functions
Definition in file dif_rv_dm_autogen.h.
| struct dif_rv_dm |
A handle to rv_dm.
This type should be treated as opaque by users.
Definition at line 37 of file dif_rv_dm_autogen.h.
| Data Fields | ||
|---|---|---|
| mmio_region_t | base_addr | The base address for the rv_dm hardware registers. |
| dt_rv_dm_t | dt |
The instance, set to kDtRvDmCount if not initialized through dif_rv_dm_init_from_dt. |
| typedef struct dif_rv_dm dif_rv_dm_t |
A handle to rv_dm.
This type should be treated as opaque by users.
| enum dif_rv_dm_alert |
A rv_dm alert type.
| Enumerator | |
|---|---|
| kDifRvDmAlertFatalFault | This fatal alert is triggered when a fatal TL-UL bus integrity fault is detected. |
Definition at line 98 of file dif_rv_dm_autogen.h.
| OT_WARN_UNUSED_RESULT dif_result_t dif_rv_dm_alert_force | ( | const dif_rv_dm_t * | rv_dm, |
| dif_rv_dm_alert_t | alert ) |
Forces a particular alert, causing it to be escalated as if the hardware had raised it.
| rv_dm | A rv_dm handle. |
| alert | The alert to force. |
Definition at line 62 of file dif_rv_dm_autogen.c.
| OT_WARN_UNUSED_RESULT dif_result_t dif_rv_dm_get_dt | ( | const dif_rv_dm_t * | rv_dm, |
| dt_rv_dm_t * | dt ) |
Get the DT handle from this DIF.
If this DIF was initialized by dif_rv_dm_init_from_dt(dt, ..) then this function will return dt. Otherwise it will return an error.
| rv_dm | A rv_dm handle. | |
| [out] | dt | DT handle. |
kDifBadArg if the DIF has no DT information, kDifOk otherwise. Definition at line 52 of file dif_rv_dm_autogen.c.
| OT_WARN_UNUSED_RESULT dif_result_t dif_rv_dm_init | ( | mmio_region_t | base_addr, |
| dif_rv_dm_t * | rv_dm ) |
Creates a new handle for a(n) rv_dm peripheral.
This function does not actuate the hardware.
| base_addr | The MMIO base address of the rv_dm peripheral. | |
| [out] | rv_dm | Out param for the initialized handle. |
DEPRECATED This function exists solely for the transition to dt-based DIFs and will be removed in the future.
Definition at line 25 of file dif_rv_dm_autogen.c.
| OT_WARN_UNUSED_RESULT dif_result_t dif_rv_dm_init_from_dt | ( | dt_rv_dm_t | dt, |
| dif_rv_dm_t * | rv_dm ) |
Creates a new handle for a(n) rv_dm peripheral.
This function does not actuate the hardware.
| dt | The devicetable description of the device. | |
| [out] | rv_dm | Out param for the initialized handle. |
Definition at line 39 of file dif_rv_dm_autogen.c.