1 /* 2 * Copyright 2023, NXP 3 * All rights reserved. 4 * 5 * 6 * SPDX-License-Identifier: BSD-3-Clause 7 */ 8 9 #ifndef __SRTM_CHANNEL_STRUCT_H__ 10 #define __SRTM_CHANNEL_STRUCT_H__ 11 12 #include "srtm_defs.h" 13 #include "srtm_list.h" 14 15 /******************************************************************************* 16 * Definitions 17 ******************************************************************************/ 18 /** 19 * @brief SRTM channel struct 20 */ 21 struct _srtm_channel 22 { 23 srtm_list_t node; /*!< SRTM channel list node to link to a list */ 24 srtm_peercore_t core; /*!< SRTM peer core channel belongs to */ 25 26 void (*destroy)(srtm_channel_t channel); 27 srtm_status_t (*start)(srtm_channel_t channel); 28 srtm_status_t (*stop)(srtm_channel_t channel); 29 srtm_status_t (*sendData)(srtm_channel_t channel, void *data, uint32_t len); 30 31 void (*sendDataPreCallback)(srtm_channel_t channel, 32 void *data, 33 uint32_t len); /*!< SRTM send data pre call back function */ 34 void (*sendDataPostCallback)(srtm_channel_t channel, 35 void *data, 36 uint32_t len); /*!< SRTM send data post call back function */ 37 }; 38 39 /******************************************************************************* 40 * API 41 ******************************************************************************/ 42 43 /*! @} */ 44 45 #endif /* __SRTM_CHANNEL_STRUCT_H__ */ 46