Zephyr Project API
3.2.0
A Scalable Open Source RTOS
|
I3C In-Band Interrupts. More...
Data Structures | |
struct | i3c_ibi |
Struct for IBI request. More... | |
struct | i3c_ibi_payload |
Structure of payload buffer for IBI. More... | |
struct | i3c_ibi_work |
Node about a queued IBI. More... | |
Macros | |
#define | CONFIG_I3C_IBI_MAX_PAYLOAD_SIZE 0 |
Typedefs | |
typedef int(* | i3c_target_ibi_cb_t) (struct i3c_device_desc *target, struct i3c_ibi_payload *payload) |
Function called when In-Band Interrupt received from target device. More... | |
Enumerations | |
enum | i3c_ibi_type { I3C_IBI_TARGET_INTR , I3C_IBI_CONTROLLER_ROLE_REQUEST , I3C_IBI_HOTJOIN , I3C_IBI_TYPE_MAX = I3C_IBI_HOTJOIN , I3C_IBI_WORKQUEUE_CB } |
IBI Types. More... | |
Functions | |
int | i3c_ibi_work_enqueue (struct i3c_ibi_work *ibi_work) |
Queue an IBI work item for future processing. More... | |
int | i3c_ibi_work_enqueue_target_irq (struct i3c_device_desc *target, uint8_t *payload, size_t payload_len) |
Queue a target interrupt IBI for future processing. More... | |
int | i3c_ibi_work_enqueue_hotjoin (const struct device *dev) |
Queue a hot join IBI for future processing. More... | |
int | i3c_ibi_work_enqueue_cb (const struct device *dev, k_work_handler_t work_cb) |
Queue a generic callback for future processing. More... | |
I3C In-Band Interrupts.
#define CONFIG_I3C_IBI_MAX_PAYLOAD_SIZE 0 |
#include <include/zephyr/drivers/i3c/ibi.h>
typedef int(* i3c_target_ibi_cb_t) (struct i3c_device_desc *target, struct i3c_ibi_payload *payload) |
#include <include/zephyr/drivers/i3c/ibi.h>
Function called when In-Band Interrupt received from target device.
This function is invoked by the controller when the controller receives an In-Band Interrupt from the target device.
A success return shall cause the controller to ACK the next byte received. An error return shall cause the controller to NACK the next byte received.
target | the device description structure associated with the device to which the operation is addressed. |
payload | Payload associated with the IBI. NULL if there is no payload. |
enum i3c_ibi_type |
#include <include/zephyr/drivers/i3c/ibi.h>
IBI Types.
Enumerator | |
---|---|
I3C_IBI_TARGET_INTR | Target interrupt |
I3C_IBI_CONTROLLER_ROLE_REQUEST | Controller Role Request |
I3C_IBI_HOTJOIN | Hot Join Request |
I3C_IBI_TYPE_MAX | |
I3C_IBI_WORKQUEUE_CB |
int i3c_ibi_work_enqueue | ( | struct i3c_ibi_work * | ibi_work | ) |
#include <include/zephyr/drivers/i3c/ibi.h>
Queue an IBI work item for future processing.
This queues up an IBI work item in the IBI workqueue for future processing.
Note that this will copy the ibi_work
struct into internal structure. If there is not enough space to copy the ibi_work
struct, this returns -ENOMEM.
ibi_work | Pointer to the IBI work item struct. |
0 | If work item is successfully queued. |
-ENOMEM | If no more free internal node to store IBI work item. |
Others |
int i3c_ibi_work_enqueue_cb | ( | const struct device * | dev, |
k_work_handler_t | work_cb | ||
) |
#include <include/zephyr/drivers/i3c/ibi.h>
Queue a generic callback for future processing.
This queues up a generic callback in the IBI workqueue for future processing.
dev | Pointer to controller device driver instance. |
work_cb | Callback function. |
0 | If work item is successfully queued. |
-ENOMEM | If no more free internal node to store IBI work item. |
Others |
int i3c_ibi_work_enqueue_hotjoin | ( | const struct device * | dev | ) |
#include <include/zephyr/drivers/i3c/ibi.h>
Queue a hot join IBI for future processing.
This queues up a hot join IBI in the IBI workqueue for future processing.
dev | Pointer to controller device driver instance. |
0 | If work item is successfully queued. |
-ENOMEM | If no more free internal node to store IBI work item. |
Others |
int i3c_ibi_work_enqueue_target_irq | ( | struct i3c_device_desc * | target, |
uint8_t * | payload, | ||
size_t | payload_len | ||
) |
#include <include/zephyr/drivers/i3c/ibi.h>
Queue a target interrupt IBI for future processing.
This queues up a target interrupt IBI in the IBI workqueue for future processing.
target | Pointer to target device descriptor. |
payload | Pointer to IBI payload byte array. |
payload_len | Length of payload byte array. |
0 | If work item is successfully queued. |
-ENOMEM | If no more free internal node to store IBI work item. |
Others |