Zephyr API Documentation  3.5.0
A Scalable Open Source RTOS
3.5.0
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
icmsg.h File Reference
#include <stddef.h>
#include <stdint.h>
#include <zephyr/kernel.h>
#include <zephyr/drivers/mbox.h>
#include <zephyr/ipc/ipc_service.h>
#include <zephyr/sys/atomic.h>
#include <zephyr/sys/spsc_pbuf.h>

Go to the source code of this file.

Data Structures

struct  icmsg_config_t
 
struct  icmsg_data_t
 

Enumerations

enum  icmsg_state { ICMSG_STATE_OFF , ICMSG_STATE_BUSY , ICMSG_STATE_READY }
 

Functions

int icmsg_open (const struct icmsg_config_t *conf, struct icmsg_data_t *dev_data, const struct ipc_service_cb *cb, void *ctx)
 Open an icmsg instance.
 
int icmsg_close (const struct icmsg_config_t *conf, struct icmsg_data_t *dev_data)
 Close an icmsg instance.
 
int icmsg_send (const struct icmsg_config_t *conf, struct icmsg_data_t *dev_data, const void *msg, size_t len)
 Send a message to the remote icmsg instance.
 
int icmsg_get_tx_buffer (const struct icmsg_config_t *conf, struct icmsg_data_t *dev_data, void **data, size_t *size)
 Get an empty TX buffer to be sent using icmsg_send_nocopy.
 
int icmsg_drop_tx_buffer (const struct icmsg_config_t *conf, struct icmsg_data_t *dev_data, const void *data)
 Drop and release a TX buffer.
 
int icmsg_send_nocopy (const struct icmsg_config_t *conf, struct icmsg_data_t *dev_data, const void *msg, size_t len)
 Send a message from a buffer obtained by icmsg_get_tx_buffer to the remote icmsg instance.