Ø Main.c static voidieee80211_tasklet_handler(unsigned long data)
Everything aboutreceive is started from this function. There is a switch statement:switch(skb->pkt_type), two cases: IEEE80211_RX_MSG IEEE80211_TX_STATUS_MSG. Now we only pay attention to RX, in RX path,kernel invokesieee80211_rx(&local->hw,skb).
Ø ieee80211_rx(&local->hw, skb);
This is thereceive path handler. It is called by a low level driver when an 802.11 MPDU isreceived from the hardware.主要有以下操作:
1. 丢弃部分frame:(status->band>= IEEE80211_NUM_BANDS),local->hw.wiphy->bands[status->band]为空,(local->quiescing ||local->suspended),已经正在配置、正在启动时受到frame;
2. ieee80211_rx_monitor(local,skb, rate)添加radiotap头部,复制帧&