Ticket #1094: madwifi-packet_type.patch

File madwifi-packet_type.patch, 0.7 kB (added by brianbraunstein, 2 years ago)

patch for monitor mode outgoing packet type (skb->pkt_type)

  • net80211/ieee80211_monitor.c

    old new  
    346346                         * The frame passed it's CRC, so we can rely 
    347347                         * on the contents of the frame to set pkttype. 
    348348                         */ 
    349                         if (IEEE80211_IS_MULTICAST(wh->i_addr1)) { 
     349                        if (tx) 
     350                                pkttype = PACKET_OUTGOING; 
     351                        else if (IEEE80211_IS_MULTICAST(wh->i_addr1)) { 
    350352                                if (IEEE80211_ADDR_EQ(wh->i_addr1, dev->broadcast)) 
    351353                                        pkttype = PACKET_BROADCAST; 
    352354                                else 
    353355                                        pkttype = PACKET_MULTICAST; 
    354356                        } else 
    355                                 pkttype = (tx) ? PACKET_OUTGOING : PACKET_HOST; 
     357                                pkttype = PACKET_HOST; 
    356358                } 
    357359 
    358360                if (vap->iv_opmode != IEEE80211_M_MONITOR ||