Home
last modified time | relevance | path

Searched refs:mb (Results 1 – 4 of 4) sorted by relevance

/trusty/user/base/lib/spi/common/
Dutils.c61 void mb_init(struct mem_buf* mb, void* buf, size_t sz, size_t align) { in mb_init() argument
64 mb->buf = buf; in mb_init()
65 mb->capacity = sz; in mb_init()
66 mb->align = align; in mb_init()
67 mb->curr_size = 0; in mb_init()
68 mb->pos = 0; in mb_init()
71 void mb_destroy(struct mem_buf* mb) { in mb_destroy() argument
72 mb->buf = NULL; in mb_destroy()
73 mb->capacity = 0; in mb_destroy()
74 mb->align = 0; in mb_destroy()
[all …]
/trusty/user/base/lib/spi/common/include/lib/spi/common/
Dutils.h64 static inline size_t mb_curr_pos(struct mem_buf* mb) { in mb_curr_pos() argument
65 return mb->pos; in mb_curr_pos()
74 static inline size_t mb_size(struct mem_buf* mb) { in mb_size() argument
75 return mb->curr_size; in mb_size()
84 static inline size_t mb_space_left(struct mem_buf* mb) { in mb_space_left() argument
85 return mb_size(mb) - mb_curr_pos(mb); in mb_space_left()
92 static inline void mb_rewind_pos(struct mem_buf* mb) { in mb_rewind_pos() argument
93 mb->pos = 0; in mb_rewind_pos()
105 void mb_init(struct mem_buf* mb, void* buf, size_t cap, size_t align);
114 void mb_destroy(struct mem_buf* mb);
[all …]
/trusty/user/base/lib/spi/srv/common/include/lib/spi/srv/common/
Dcommon.h51 struct mem_buf* mb,
/trusty/user/base/lib/spi/srv/tipc/
Dtipc.c257 struct mem_buf mb; in on_disconnect() local
270 mb_init(&mb, &hdr, sizeof(hdr), SPI_CMD_SHM_ALIGN); in on_disconnect()
271 mb_resize(&mb, sizeof(hdr)); in on_disconnect()
279 rc = spi_srv_handle_batch(spi, &mb, &req, &state); in on_disconnect()