Linux Kernel
3.7.1
|
#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/skbuff.h>
#include <linux/etherdevice.h>
#include <linux/bitmap.h>
#include <linux/rcupdate.h>
#include <linux/export.h>
#include <net/net_namespace.h>
#include <net/ieee80211_radiotap.h>
#include <net/cfg80211.h>
#include <net/mac80211.h>
#include <asm/unaligned.h>
#include "ieee80211_i.h"
#include "driver-ops.h"
#include "led.h"
#include "mesh.h"
#include "wep.h"
#include "wpa.h"
#include "wme.h"
#include "rate.h"
Go to the source code of this file.
Macros | |
#define | CALL_TXH(txh) |
#define CALL_TXH | ( | txh | ) |
EXPORT_SYMBOL | ( | ieee80211_beacon_get_tim | ) |
EXPORT_SYMBOL | ( | ieee80211_proberesp_get | ) |
EXPORT_SYMBOL | ( | ieee80211_pspoll_get | ) |
EXPORT_SYMBOL | ( | ieee80211_nullfunc_get | ) |
EXPORT_SYMBOL | ( | ieee80211_probereq_get | ) |
EXPORT_SYMBOL | ( | ieee80211_rts_get | ) |
EXPORT_SYMBOL | ( | ieee80211_ctstoself_get | ) |
EXPORT_SYMBOL | ( | ieee80211_get_buffered_bc | ) |
|
read |
ieee80211_beacon_get_tim - beacon generation function : pointer obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback. : pointer to variable that will receive the TIM IE offset. Set to 0 if invalid (in non-AP modes). : pointer to variable that will receive the TIM IE length, (including the ID and length bytes!). Set to 0 if invalid (in non-AP modes).
If the driver implements beaconing modes, it must use this function to obtain the beacon frame/template.
If the beacon frames are generated by the host system (i.e., not in hardware/firmware), the driver uses this function to get each beacon frame from mac80211 – it is responsible for calling this function before the beacon is needed (e.g. based on hardware interrupt).
If the beacon frames are generated by the device, then the driver must use the returned beacon as the template and change the TIM IE according to the current DTIM parameters/TIM bitmap.
void ieee80211_clear_tx_pending | ( | struct ieee80211_local * | local | ) |
void ieee80211_ctstoself_get | ( | struct ieee80211_hw * | hw, |
struct ieee80211_vif * | vif, | ||
const void * | frame, | ||
size_t | frame_len, | ||
const struct ieee80211_tx_info * | frame_txctl, | ||
struct ieee80211_cts * | cts | ||
) |
ieee80211_ctstoself_get - CTS-to-self frame generation function : pointer obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback. : pointer to the frame that is going to be protected by the CTS-to-self. : the frame length (in octets). : &struct ieee80211_tx_info of the frame. : The buffer where to store the CTS-to-self frame.
If the CTS-to-self frames are generated by the host system (i.e., not in hardware/firmware), the low-level driver uses this function to receive the next CTS-to-self frame from the 802.11 code. The low-level is responsible for calling this function before and CTS-to-self frame is needed.
|
read |
ieee80211_get_buffered_bc - accessing buffered broadcast and multicast frames : pointer as obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback.
Function for accessing buffered broadcast and multicast frames. If hardware/firmware does not implement buffering of broadcast/multicast frames when power saving is used, 802.11 code buffers them in the host memory. The low-level driver uses this function to fetch next buffered frame. In most cases, this is used when generating beacon frame. This function returns a pointer to the next buffered skb or NULL if no more buffered frames are available.
Note: buffered frames are returned only after DTIM beacon frame was generated with ieee80211_beacon_get() and the low-level driver must thus call ieee80211_beacon_get() first. ieee80211_get_buffered_bc() returns NULL if the previous generated beacon was not DTIM, so the low-level driver does not need to check for DTIM beacons separately and should be able to use common code for all beacons.
netdev_tx_t ieee80211_monitor_start_xmit | ( | struct sk_buff * | skb, |
struct net_device * | dev | ||
) |
|
read |
ieee80211_nullfunc_get - retrieve a nullfunc template : pointer obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback.
Creates a Nullfunc template which can, for example, uploaded to hardware. The template must be updated after association so that correct BSSID and address is used.
Note: Caller (or hardware) is responsible for setting the &IEEE80211_FCTL_PM bit as well as Duration and Sequence Control fields.
|
read |
ieee80211_probereq_get - retrieve a Probe Request template : pointer obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback. : SSID buffer : length of SSID : buffer containing all IEs except SSID for the template : length of the IE buffer
Creates a Probe Request template which can, for example, be uploaded to hardware.
|
read |
ieee80211_proberesp_get - retrieve a Probe Response template : pointer obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback.
Creates a Probe Response template which can, for example, be uploaded to hardware. The destination address should be set by the caller.
Can only be called in AP mode.
|
read |
ieee80211_pspoll_get - retrieve a PS Poll template : pointer obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback.
Creates a PS Poll a template which can, for example, uploaded to hardware. The template must be updated after association so that correct AID, BSSID and MAC address is used.
Note: Caller (or hardware) is responsible for setting the &IEEE80211_FCTL_PM bit.
void ieee80211_rts_get | ( | struct ieee80211_hw * | hw, |
struct ieee80211_vif * | vif, | ||
const void * | frame, | ||
size_t | frame_len, | ||
const struct ieee80211_tx_info * | frame_txctl, | ||
struct ieee80211_rts * | rts | ||
) |
ieee80211_rts_get - RTS frame generation function : pointer obtained from ieee80211_alloc_hw(). : &struct ieee80211_vif pointer from the add_interface callback. : pointer to the frame that is going to be protected by the RTS. : the frame length (in octets). : &struct ieee80211_tx_info of the frame. : The buffer where to store the RTS frame.
If the RTS frames are generated by the host system (i.e., not in hardware/firmware), the low-level driver uses this function to receive the next RTS frame from the 802.11 code. The low-level is responsible for calling this function before and RTS frame is needed.
netdev_tx_t ieee80211_subif_start_xmit | ( | struct sk_buff * | skb, |
struct net_device * | dev | ||
) |
ieee80211_subif_start_xmit - netif start_xmit function for Ethernet-type subinterfaces (wlan#, WDS, and VLAN interfaces) : packet to be sent : incoming interface
Returns: 0 on success (and frees skb in this case) or 1 on failure (skb will not be freed, and caller is responsible for either retrying later or freeing skb).
This function takes in an Ethernet header and encapsulates it with suitable IEEE 802.11 header based on which interface the packet is coming in. The encapsulated packet will then be passed to master interface, wlan#.11, for transmission (through low-level driver).