Zephyr API Documentation 4.3.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
mctp_i3c_target.h File Reference
#include <stdint.h>
#include <zephyr/kernel.h>
#include <zephyr/device.h>
#include <zephyr/drivers/i3c.h>
#include <zephyr/pmci/mctp/mctp_i3c_common.h>
#include <libmctp.h>

Go to the source code of this file.

Data Structures

struct  mctp_binding_i3c_target
 An MCTP binding for Zephyr's I3C target interface using GPIO. More...

Macros

#define MCTP_I3C_TARGET_DT_DEFINE(_name, _node_id)
 INTERNAL_HIDDEN.

Macro Definition Documentation

◆ MCTP_I3C_TARGET_DT_DEFINE

#define MCTP_I3C_TARGET_DT_DEFINE ( _name,
_node_id )
Value:
K_SEM_DEFINE(_name##_tx_lock, 1, 1); \
K_SEM_DEFINE(_name##_tx_complete, 0, 1); \
struct mctp_binding_i3c_target _name = { \
.binding = { \
.name = STRINGIFY(_name), .version = 1, \
.start = mctp_i3c_target_start, \
.tx = mctp_i3c_target_tx, \
.pkt_size = MCTP_I3C_MAX_PKT_SIZE, \
}, \
.i3c = DEVICE_DT_GET(DT_PHANDLE(_node_id, i3c)), \
.i3c_target_cfg = { \
.callbacks = &mctp_i3c_target_callbacks, \
}, \
.endpoint_id = DT_PROP(_node_id, endpoint_id), \
.tx_lock = &_name##_tx_lock, \
.tx_complete = &_name##_tx_complete, \
};
#define DEVICE_DT_GET(node_id)
Get a device reference from a devicetree node identifier.
Definition device.h:317
#define DT_PHANDLE(node_id, prop)
Get a node identifier for a phandle property's value.
Definition devicetree.h:1847
#define DT_PROP(node_id, prop)
Get a devicetree property value.
Definition devicetree.h:798
#define K_SEM_DEFINE(name, initial_count, count_limit)
Statically define and initialize a semaphore.
Definition kernel.h:3729
#define STRINGIFY(s)
Definition common.h:165
An MCTP binding for Zephyr's I3C target interface using GPIO.
Definition mctp_i3c_target.h:21

INTERNAL_HIDDEN.

Define a MCTP bus binding for I3C target mode using IBI for signaling

Parameters
_nameSymbolic name of the bus binding variable
_node_idDeviceTree Node containing the configuration of this MCTP binding