Skip to content

Commit

Permalink
Merge pull request #2892 from authmillenon/ng_ipv6/enh/use-netapi-rcv
Browse files Browse the repository at this point in the history
ng_ipv6: use netapi_receive()
  • Loading branch information
haukepetersen committed Apr 30, 2015
2 parents 4741a01 + af1f7b4 commit 195a8d8
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions sys/net/network_layer/ng_ipv6/ng_ipv6.c
Original file line number Diff line number Diff line change
Expand Up @@ -471,16 +471,12 @@ static inline bool _pkt_not_for_me(kernel_pid_t *iface, ng_ipv6_hdr_t *hdr)
static void _dispatch_rcv_pkt(ng_nettype_t type, uint32_t demux_ctx,
ng_pktsnip_t *pkt)
{
msg_t msg;
ng_netreg_entry_t *entry = ng_netreg_lookup(type, demux_ctx);

msg.type = NG_NETAPI_MSG_TYPE_RCV;
msg.content.ptr = (char *)pkt;

while (entry) {
DEBUG("ipv6: Send receive command for %p to %" PRIu16 "\n", (void *)pkt,
entry->pid);
msg_send(&msg, entry->pid);
ng_netapi_receive(entry->pid, pkt);
entry = ng_netreg_getnext(entry);
}
}
Expand Down

0 comments on commit 195a8d8

Please sign in to comment.