diff options
Diffstat (limited to 'demos')
-rw-r--r-- | demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tscommon.h | 1 | ||||
-rw-r--r-- | demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tssockskel.c | 8 |
2 files changed, 7 insertions, 2 deletions
diff --git a/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tscommon.h b/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tscommon.h index 8d1dbca68..079c6396e 100644 --- a/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tscommon.h +++ b/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tscommon.h @@ -67,6 +67,7 @@ typedef struct skel_req { uint32_t stub_op;
uint32_t stub_op_code;
uint32_t stub_op_result;
+ uint32_t stub_op_p_sz[METHOD_MAX_PARAMS];
uint32_t stub_op_p[METHOD_MAX_PARAMS];
} skel_req_t;
diff --git a/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tssockskel.c b/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tssockskel.c index da9096fd8..e3b2246a2 100644 --- a/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tssockskel.c +++ b/demos/ATSAMA5D2/RT-SAMA5D2-XPLAINED-NSEC/daemons/tssockskel.c @@ -21,7 +21,7 @@ */
#include "ch.h"
-#include "chfifo.h"
+#include "chobjfifos.h"
#include "tsclient.h"
#include "tssockskel.h"
#include <string.h>
@@ -162,6 +162,7 @@ static void l_recv(skel_req_t *skreqp) { /* call the api exposed by the TCP/IP stack.*/
result = recv((int)skreqp->stub_op_p[0], mem, len,
(int)skreqp->stub_op_p[3]);
+ skreqp->stub_op_p_sz[1] = result;
skreqp->stub_op_p[1] = (uint32_t)mem;
}
@@ -215,6 +216,9 @@ static void l_select(skel_req_t *skreqp) { maxfdpl = skreqp->stub_op_p[0];
+ skreqp->stub_op_p_sz[1] = sizeof (fd_set);
+ skreqp->stub_op_p_sz[2] = sizeof (fd_set);
+ skreqp->stub_op_p_sz[3] = sizeof (fd_set);
skreqp->stub_op_p[1] = (uint32_t)&readset;
skreqp->stub_op_p[2] = (uint32_t)&writeset;
skreqp->stub_op_p[3] = (uint32_t)&exceptset;
@@ -321,7 +325,7 @@ static THD_FUNCTION(TsSkelsDaemon, arg) { sizeof *skreqp);
chFifoReturnObject(&skel_req_fifo, skreqp);
- /* Start to receive ops.*/
+ /* Start to receive ops from stubs.*/
for (;/* ever */;) {
chEvtWaitAny(ALL_EVENTS);
(void)chEvtGetAndClearFlags(&el);
|