From 07bd84c9148864b90cdff326ff1234c1029fb41a Mon Sep 17 00:00:00 2001 From: zhuoshuguo Date: Sat, 18 Feb 2017 13:06:45 +0100 Subject: [PATCH] gnrc_mac: add support for multicast pkt. --- sys/net/gnrc/link_layer/gnrc_mac/internal.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/net/gnrc/link_layer/gnrc_mac/internal.c b/sys/net/gnrc/link_layer/gnrc_mac/internal.c index 5bb3da3263..88aafc743b 100644 --- a/sys/net/gnrc/link_layer/gnrc_mac/internal.c +++ b/sys/net/gnrc/link_layer/gnrc_mac/internal.c @@ -142,9 +142,9 @@ bool gnrc_mac_queue_tx_packet(gnrc_mac_tx_t* tx, uint32_t priority, gnrc_pktsnip gnrc_mac_tx_neighbor_t* neighbor; int neighbor_id; - /* Check whether the packet it for broadcast */ - if (gnrc_netif_hdr_get_flag(pkt)&GNRC_NETIF_HDR_FLAGS_BROADCAST) { - /* Broadcast queue is neighbor 0 by definition */ + /* Check whether the packet it for broadcast or multicast */ + if (gnrc_netif_hdr_get_flag(pkt) & (GNRC_NETIF_HDR_FLAGS_MULTICAST | GNRC_NETIF_HDR_FLAGS_BROADCAST)) { + /* Broadcast/multicast queue is neighbor 0 by definition */ neighbor_id = 0; neighbor = &tx->neighbors[neighbor_id];