IPC backend configuration structure.  
 More...
#include <ipc_service_backend.h>
 | 
| int(*  | open_instance )(const struct device *instance) | 
|   | Pointer to the function that will be used to open an instance.  More...
  | 
|   | 
| int(*  | close_instance )(const struct device *instance) | 
|   | Pointer to the function that will be used to close an instance.  More...
  | 
|   | 
| int(*  | send )(const struct device *instance, void *token, const void *data, size_t len) | 
|   | Pointer to the function that will be used to send data to the endpoint.  More...
  | 
|   | 
| int(*  | register_endpoint )(const struct device *instance, void **token, const struct ipc_ept_cfg *cfg) | 
|   | Pointer to the function that will be used to register endpoints.  More...
  | 
|   | 
| int(*  | deregister_endpoint )(const struct device *instance, void *token) | 
|   | Pointer to the function that will be used to deregister endpoints.  More...
  | 
|   | 
| int(*  | get_tx_buffer_size )(const struct device *instance, void *token) | 
|   | Pointer to the function that will return the TX buffer size.  More...
  | 
|   | 
| int(*  | get_tx_buffer )(const struct device *instance, void *token, void **data, uint32_t *len, k_timeout_t wait) | 
|   | Pointer to the function that will return an empty TX buffer.  More...
  | 
|   | 
| int(*  | drop_tx_buffer )(const struct device *instance, void *token, const void *data) | 
|   | Pointer to the function that will drop a TX buffer.  More...
  | 
|   | 
| int(*  | send_nocopy )(const struct device *instance, void *token, const void *data, size_t len) | 
|   | Pointer to the function that will be used to send data to the endpoint when the TX buffer has been obtained using ipc_service_get_tx_buffer.  More...
  | 
|   | 
| int(*  | hold_rx_buffer )(const struct device *instance, void *token, void *data) | 
|   | Pointer to the function that will hold the RX buffer.  More...
  | 
|   | 
| int(*  | release_rx_buffer )(const struct device *instance, void *token, void *data) | 
|   | Pointer to the function that will release the RX buffer.  More...
  | 
|   | 
IPC backend configuration structure. 
This structure is used for configuration backend during registration. 
 
◆ close_instance
      
        
          | int(* ipc_service_backend::close_instance) (const struct device *instance) | 
        
      
 
Pointer to the function that will be used to close an instance. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer. | 
  
   
- Return values
 - 
  
    | -EALREADY | when the instance is not already inited. | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ deregister_endpoint
      
        
          | int(* ipc_service_backend::deregister_endpoint) (const struct device *instance, void *token) | 
        
      
 
Pointer to the function that will be used to deregister endpoints. 
- Parameters
 - 
  
    | [in] | instance | Instance from which to deregister the endpoint.  | 
    | [in] | token | Backend-specific token. | 
  
   
- Return values
 - 
  
    | -EINVAL | when the endpoint configuration or instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -EBUSY | when the instance is busy or not ready. | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ drop_tx_buffer
      
        
          | int(* ipc_service_backend::drop_tx_buffer) (const struct device *instance, void *token, const void *data) | 
        
      
 
Pointer to the function that will drop a TX buffer. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer.  | 
    | [in] | token | Backend-specific token.  | 
    | [in] | data | Pointer to the TX buffer. | 
  
   
- Return values
 - 
  
    | -EINVAL | when instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -ENOTSUP | when this function is not supported.  | 
    | -EALREADY | when the buffer was already dropped. | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ get_tx_buffer
Pointer to the function that will return an empty TX buffer. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer.  | 
    | [in] | token | Backend-specific token.  | 
    | [out] | data | Pointer to the empty TX buffer.  | 
    | [in,out] | len | Pointer to store the TX buffer size.  | 
    | [in] | wait | Timeout waiting for an available TX buffer. | 
  
   
- Return values
 - 
  
    | -EINVAL | when instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -ENOTSUP | when the operation or the timeout is not supported.  | 
    | -ENOBUFS | when there are no TX buffers available.  | 
    | -EALREADY | when a buffer was already claimed and not yet released.  | 
    | -ENOMEM | when the requested size is too big (and the size parameter contains the maximum allowed size). | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ get_tx_buffer_size
      
        
          | int(* ipc_service_backend::get_tx_buffer_size) (const struct device *instance, void *token) | 
        
      
 
Pointer to the function that will return the TX buffer size. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer.  | 
    | [in] | token | Backend-specific token. | 
  
   
- Return values
 - 
  
    | -EINVAL | when instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -ENOTSUP | when the operation is not supported. | 
    | size | TX buffer size on success.  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ hold_rx_buffer
      
        
          | int(* ipc_service_backend::hold_rx_buffer) (const struct device *instance, void *token, void *data) | 
        
      
 
Pointer to the function that will hold the RX buffer. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer.  | 
    | [in] | token | Backend-specific token.  | 
    | [in] | data | Pointer to the RX buffer to hold. | 
  
   
- Return values
 - 
  
    | -EINVAL | when instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -EALREADY | when the buffer data has been already hold.  | 
    | -ENOTSUP | when this function is not supported. | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ open_instance
      
        
          | int(* ipc_service_backend::open_instance) (const struct device *instance) | 
        
      
 
Pointer to the function that will be used to open an instance. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer. | 
  
   
- Return values
 - 
  
    | -EALREADY | when the instance is already opened. | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ register_endpoint
      
        
          | int(* ipc_service_backend::register_endpoint) (const struct device *instance, void **token, const struct ipc_ept_cfg *cfg) | 
        
      
 
Pointer to the function that will be used to register endpoints. 
- Parameters
 - 
  
    | [in] | instance | Instance to register the endpoint onto.  | 
    | [out] | token | Backend-specific token.  | 
    | [in] | cfg | Endpoint configuration. | 
  
   
- Return values
 - 
  
    | -EINVAL | when the endpoint configuration or instance is invalid.  | 
    | -EBUSY | when the instance is busy or not ready. | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ release_rx_buffer
      
        
          | int(* ipc_service_backend::release_rx_buffer) (const struct device *instance, void *token, void *data) | 
        
      
 
Pointer to the function that will release the RX buffer. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer.  | 
    | [in] | token | Backend-specific token.  | 
    | [in] | data | Pointer to the RX buffer to release. | 
  
   
- Return values
 - 
  
    | -EINVAL | when instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -EALREADY | when the buffer data has been already released.  | 
    | -ENOTSUP | when this function is not supported. | 
    | 0 | on success  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ send
      
        
          | int(* ipc_service_backend::send) (const struct device *instance, void *token, const void *data, size_t len) | 
        
      
 
Pointer to the function that will be used to send data to the endpoint. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer.  | 
    | [in] | token | Backend-specific token.  | 
    | [in] | data | Pointer to the buffer to send.  | 
    | [in] | len | Number of bytes to send. | 
  
   
- Return values
 - 
  
    | -EINVAL | when instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -EBADMSG | when the message is invalid.  | 
    | -EBUSY | when the instance is busy or not ready.  | 
    | -ENOMEM | when no memory / buffers are available. | 
    | bytes | number of bytes sent.  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
◆ send_nocopy
      
        
          | int(* ipc_service_backend::send_nocopy) (const struct device *instance, void *token, const void *data, size_t len) | 
        
      
 
Pointer to the function that will be used to send data to the endpoint when the TX buffer has been obtained using ipc_service_get_tx_buffer. 
- Parameters
 - 
  
    | [in] | instance | Instance pointer.  | 
    | [in] | token | Backend-specific token.  | 
    | [in] | data | Pointer to the buffer to send.  | 
    | [in] | len | Number of bytes to send. | 
  
   
- Return values
 - 
  
    | -EINVAL | when instance is invalid.  | 
    | -ENOENT | when the endpoint is not registered with the instance.  | 
    | -EBADMSG | when the data is invalid (i.e. invalid data format, invalid length, ...)  | 
    | -EBUSY | when the instance is busy or not ready. | 
    | bytes | number of bytes sent.  | 
    | other | errno codes depending on the implementation of the backend.  | 
  
   
 
 
The documentation for this struct was generated from the following file: