1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-24 05:53:49 +01:00

Merge pull request #6627 from zhuoshuguo/add_support_for_multicast_for_gnrc_mac

gnrc_mac: add support for multicast pkt.
This commit is contained in:
Martine Lenders 2017-03-14 09:52:59 +01:00 committed by GitHub
commit 01f76715aa

View File

@ -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];