Skip to content

Commit

Permalink
pkg/lwip: support gcoap break from network recv on mbox
Browse files Browse the repository at this point in the history
  • Loading branch information
kb2ma committed Feb 10, 2020
1 parent 029d9c2 commit ee1edde
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pkg/lwip/contrib/sys_arch.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
#include "lwip/opt.h"
#include "lwip/sys.h"

#ifdef MODULE_GCOAP
#include "net/gcoap.h"
#endif
#include "msg.h"
#include "sema.h"
#include "thread.h"
Expand Down Expand Up @@ -155,6 +158,10 @@ u32_t sys_arch_mbox_fetch(sys_mbox_t *mbox, void **msg, u32_t timeout)
case _MSG_SUCCESS:
*msg = m.content.ptr;
return (u32_t)((stop - start) / US_PER_MS);
#ifdef MODULE_GCOAP
/* Used by gcoap to break out of blocking wait on network recv. */
case GCOAP_MSG_TYPE_INTR:
#endif
case _MSG_TIMEOUT:
break;
default: /* should not happen */
Expand Down

0 comments on commit ee1edde

Please sign in to comment.