MCPcopy Create free account
hub / github.com/apache/nuttx / rpmsg_test_hold_rx_work

Function rpmsg_test_hold_rx_work

drivers/rpmsg/rpmsg_test.c:111–132  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

109 ****************************************************************************/
110
111static void rpmsg_test_hold_rx_work(FAR void *arg)
112{
113 FAR struct rpmsg_test_priv_s *priv = arg;
114 FAR struct rpmsg_test_msg_s *msg;
115 bool ret;
116
117 /* Check all the rx buffer value (should still be MAGIC2) and release
118 * all the held rx buffers.
119 */
120
121 syslog(LOG_EMERG, "Rpmsg Test: release rx buffers start\n");
122
123 while (!list_is_empty(&priv->rxhead))
124 {
125 msg = (FAR struct rpmsg_test_msg_s *)list_remove_head(&priv->rxhead);
126 ret = rpmsg_test_memcmp(msg->data, RPMSG_TEST_MAGIC2, msg->len);
127 DEBUGASSERT(ret);
128 rpmsg_release_rx_buffer(priv->ept, msg);
129 }
130
131 syslog(LOG_EMERG, "Rpmsg Test: release rx buffers end\n");
132}
133
134/****************************************************************************
135 * Name: rpmsg_test_hold_rx_cb

Callers

nothing calls this directly

Calls 3

list_remove_headFunction · 0.85
rpmsg_test_memcmpFunction · 0.85
syslogFunction · 0.50

Tested by

no test coverage detected