aboutsummaryrefslogtreecommitdiffstats
path: root/include/net
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2011-07-24 23:55:48 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-07-24 23:55:48 -0400
commitee05eff6f79c25617e5b7d7677b8f79d26abbe37 (patch)
tree1efa14a8b5c79c3c986aca34dce13745760ea66c /include/net
parent933b44732caad0c3b65224453c54846c75d97936 (diff)
parentb6c2f86e6305be612f1196459f22343523f7049f (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (145 commits) bnx2x: use pci_pcie_cap() bnx2x: fix bnx2x_stop_on_error flow in bnx2x_sp_rtnl_task bnx2x: enable internal target-read for 57712 and up only bnx2x: count statistic ramrods on EQ to prevent MC assert bnx2x: fix loopback for non 10G link bnx2x: dcb - send all unmapped priorities to same COS as L2 iwlwifi: Fix build with CONFIG_PM disabled. gre: fix improper error handling ipv4: use RT_TOS after some rt_tos conversions via-velocity: remove duplicated #include qlge: remove duplicated #include igb: remove duplicated #include can: c_can: remove duplicated #include bnad: remove duplicated #include net: allow netif_carrier to be called safely from IRQ bna: Header File Consolidation bna: HW Error Counter Fix bna: Add HW Semaphore Unlock Logic bna: IOC Event Name Change bna: Mboxq Flush When IOC Disabled ...
Diffstat (limited to 'include/net')
-rw-r--r--include/net/cfg80211.h33
-rw-r--r--include/net/mac80211.h60
2 files changed, 89 insertions, 4 deletions
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 5390e3245a1a..d17f47fc9e31 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -777,6 +777,7 @@ struct cfg80211_ssid {
777 * @n_channels: total number of channels to scan 777 * @n_channels: total number of channels to scan
778 * @ie: optional information element(s) to add into Probe Request or %NULL 778 * @ie: optional information element(s) to add into Probe Request or %NULL
779 * @ie_len: length of ie in octets 779 * @ie_len: length of ie in octets
780 * @rates: bitmap of rates to advertise for each band
780 * @wiphy: the wiphy this was for 781 * @wiphy: the wiphy this was for
781 * @dev: the interface 782 * @dev: the interface
782 * @aborted: (internal) scan request was notified as aborted 783 * @aborted: (internal) scan request was notified as aborted
@@ -788,6 +789,8 @@ struct cfg80211_scan_request {
788 const u8 *ie; 789 const u8 *ie;
789 size_t ie_len; 790 size_t ie_len;
790 791
792 u32 rates[IEEE80211_NUM_BANDS];
793
791 /* internal */ 794 /* internal */
792 struct wiphy *wiphy; 795 struct wiphy *wiphy;
793 struct net_device *dev; 796 struct net_device *dev;
@@ -1146,9 +1149,15 @@ struct cfg80211_wowlan_trig_pkt_pattern {
1146 * @magic_pkt: wake up on receiving magic packet 1149 * @magic_pkt: wake up on receiving magic packet
1147 * @patterns: wake up on receiving packet matching a pattern 1150 * @patterns: wake up on receiving packet matching a pattern
1148 * @n_patterns: number of patterns 1151 * @n_patterns: number of patterns
1152 * @gtk_rekey_failure: wake up on GTK rekey failure
1153 * @eap_identity_req: wake up on EAP identity request packet
1154 * @four_way_handshake: wake up on 4-way handshake
1155 * @rfkill_release: wake up when rfkill is released
1149 */ 1156 */
1150struct cfg80211_wowlan { 1157struct cfg80211_wowlan {
1151 bool any, disconnect, magic_pkt; 1158 bool any, disconnect, magic_pkt, gtk_rekey_failure,
1159 eap_identity_req, four_way_handshake,
1160 rfkill_release;
1152 struct cfg80211_wowlan_trig_pkt_pattern *patterns; 1161 struct cfg80211_wowlan_trig_pkt_pattern *patterns;
1153 int n_patterns; 1162 int n_patterns;
1154}; 1163};
@@ -1673,11 +1682,21 @@ struct ieee80211_txrx_stypes {
1673 * @WIPHY_WOWLAN_MAGIC_PKT: supports wakeup on magic packet 1682 * @WIPHY_WOWLAN_MAGIC_PKT: supports wakeup on magic packet
1674 * (see nl80211.h) 1683 * (see nl80211.h)
1675 * @WIPHY_WOWLAN_DISCONNECT: supports wakeup on disconnect 1684 * @WIPHY_WOWLAN_DISCONNECT: supports wakeup on disconnect
1685 * @WIPHY_WOWLAN_SUPPORTS_GTK_REKEY: supports GTK rekeying while asleep
1686 * @WIPHY_WOWLAN_GTK_REKEY_FAILURE: supports wakeup on GTK rekey failure
1687 * @WIPHY_WOWLAN_EAP_IDENTITY_REQ: supports wakeup on EAP identity request
1688 * @WIPHY_WOWLAN_4WAY_HANDSHAKE: supports wakeup on 4-way handshake failure
1689 * @WIPHY_WOWLAN_RFKILL_RELEASE: supports wakeup on RF-kill release
1676 */ 1690 */
1677enum wiphy_wowlan_support_flags { 1691enum wiphy_wowlan_support_flags {
1678 WIPHY_WOWLAN_ANY = BIT(0), 1692 WIPHY_WOWLAN_ANY = BIT(0),
1679 WIPHY_WOWLAN_MAGIC_PKT = BIT(1), 1693 WIPHY_WOWLAN_MAGIC_PKT = BIT(1),
1680 WIPHY_WOWLAN_DISCONNECT = BIT(2), 1694 WIPHY_WOWLAN_DISCONNECT = BIT(2),
1695 WIPHY_WOWLAN_SUPPORTS_GTK_REKEY = BIT(3),
1696 WIPHY_WOWLAN_GTK_REKEY_FAILURE = BIT(4),
1697 WIPHY_WOWLAN_EAP_IDENTITY_REQ = BIT(5),
1698 WIPHY_WOWLAN_4WAY_HANDSHAKE = BIT(6),
1699 WIPHY_WOWLAN_RFKILL_RELEASE = BIT(7),
1681}; 1700};
1682 1701
1683/** 1702/**
@@ -1742,9 +1761,13 @@ struct wiphy_wowlan_support {
1742 * this variable determines its size 1761 * this variable determines its size
1743 * @max_scan_ssids: maximum number of SSIDs the device can scan for in 1762 * @max_scan_ssids: maximum number of SSIDs the device can scan for in
1744 * any given scan 1763 * any given scan
1764 * @max_sched_scan_ssids: maximum number of SSIDs the device can scan
1765 * for in any given scheduled scan
1745 * @max_scan_ie_len: maximum length of user-controlled IEs device can 1766 * @max_scan_ie_len: maximum length of user-controlled IEs device can
1746 * add to probe request frames transmitted during a scan, must not 1767 * add to probe request frames transmitted during a scan, must not
1747 * include fixed IEs like supported rates 1768 * include fixed IEs like supported rates
1769 * @max_sched_scan_ie_len: same as max_scan_ie_len, but for scheduled
1770 * scans
1748 * @coverage_class: current coverage class 1771 * @coverage_class: current coverage class
1749 * @fw_version: firmware version for ethtool reporting 1772 * @fw_version: firmware version for ethtool reporting
1750 * @hw_version: hardware version for ethtool reporting 1773 * @hw_version: hardware version for ethtool reporting
@@ -1796,7 +1819,9 @@ struct wiphy {
1796 1819
1797 int bss_priv_size; 1820 int bss_priv_size;
1798 u8 max_scan_ssids; 1821 u8 max_scan_ssids;
1822 u8 max_sched_scan_ssids;
1799 u16 max_scan_ie_len; 1823 u16 max_scan_ie_len;
1824 u16 max_sched_scan_ie_len;
1800 1825
1801 int n_cipher_suites; 1826 int n_cipher_suites;
1802 const u32 *cipher_suites; 1827 const u32 *cipher_suites;
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index ea2c8c36477c..9259e97864d7 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -1586,6 +1586,20 @@ enum ieee80211_ampdu_mlme_action {
1586}; 1586};
1587 1587
1588/** 1588/**
1589 * enum ieee80211_tx_sync_type - TX sync type
1590 * @IEEE80211_TX_SYNC_AUTH: sync TX for authentication
1591 * (and possibly also before direct probe)
1592 * @IEEE80211_TX_SYNC_ASSOC: sync TX for association
1593 * @IEEE80211_TX_SYNC_ACTION: sync TX for action frame
1594 * (not implemented yet)
1595 */
1596enum ieee80211_tx_sync_type {
1597 IEEE80211_TX_SYNC_AUTH,
1598 IEEE80211_TX_SYNC_ASSOC,
1599 IEEE80211_TX_SYNC_ACTION,
1600};
1601
1602/**
1589 * struct ieee80211_ops - callbacks from mac80211 to the driver 1603 * struct ieee80211_ops - callbacks from mac80211 to the driver
1590 * 1604 *
1591 * This structure contains various callbacks that the driver may 1605 * This structure contains various callbacks that the driver may
@@ -1674,6 +1688,26 @@ enum ieee80211_ampdu_mlme_action {
1674 * of the bss parameters has changed when a call is made. The callback 1688 * of the bss parameters has changed when a call is made. The callback
1675 * can sleep. 1689 * can sleep.
1676 * 1690 *
1691 * @tx_sync: Called before a frame is sent to an AP/GO. In the GO case, the
1692 * driver should sync with the GO's powersaving so the device doesn't
1693 * transmit the frame while the GO is asleep. In the regular AP case
1694 * it may be used by drivers for devices implementing other restrictions
1695 * on talking to APs, e.g. due to regulatory enforcement or just HW
1696 * restrictions.
1697 * This function is called for every authentication, association and
1698 * action frame separately since applications might attempt to auth
1699 * with multiple APs before chosing one to associate to. If it returns
1700 * an error, the corresponding authentication, association or frame
1701 * transmission is aborted and reported as having failed. It is always
1702 * called after tuning to the correct channel.
1703 * The callback might be called multiple times before @finish_tx_sync
1704 * (but @finish_tx_sync will be called once for each) but in practice
1705 * this is unlikely to happen. It can also refuse in that case if the
1706 * driver cannot handle that situation.
1707 * This callback can sleep.
1708 * @finish_tx_sync: Called as a counterpart to @tx_sync, unless that returned
1709 * an error. This callback can sleep.
1710 *
1677 * @prepare_multicast: Prepare for multicast filter configuration. 1711 * @prepare_multicast: Prepare for multicast filter configuration.
1678 * This callback is optional, and its return value is passed 1712 * This callback is optional, and its return value is passed
1679 * to configure_filter(). This callback must be atomic. 1713 * to configure_filter(). This callback must be atomic.
@@ -1901,6 +1935,14 @@ struct ieee80211_ops {
1901 struct ieee80211_vif *vif, 1935 struct ieee80211_vif *vif,
1902 struct ieee80211_bss_conf *info, 1936 struct ieee80211_bss_conf *info,
1903 u32 changed); 1937 u32 changed);
1938
1939 int (*tx_sync)(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
1940 const u8 *bssid, enum ieee80211_tx_sync_type type);
1941 void (*finish_tx_sync)(struct ieee80211_hw *hw,
1942 struct ieee80211_vif *vif,
1943 const u8 *bssid,
1944 enum ieee80211_tx_sync_type type);
1945
1904 u64 (*prepare_multicast)(struct ieee80211_hw *hw, 1946 u64 (*prepare_multicast)(struct ieee80211_hw *hw,
1905 struct netdev_hw_addr_list *mc_list); 1947 struct netdev_hw_addr_list *mc_list);
1906 void (*configure_filter)(struct ieee80211_hw *hw, 1948 void (*configure_filter)(struct ieee80211_hw *hw,
@@ -2613,6 +2655,20 @@ static inline void ieee80211_get_tkip_p1k(struct ieee80211_key_conf *keyconf,
2613} 2655}
2614 2656
2615/** 2657/**
2658 * ieee80211_get_tkip_rx_p1k - get a TKIP phase 1 key for RX
2659 *
2660 * This function returns the TKIP phase 1 key for the given IV32
2661 * and transmitter address.
2662 *
2663 * @keyconf: the parameter passed with the set key
2664 * @ta: TA that will be used with the key
2665 * @iv32: IV32 to get the P1K for
2666 * @p1k: a buffer to which the key will be written, as 5 u16 values
2667 */
2668void ieee80211_get_tkip_rx_p1k(struct ieee80211_key_conf *keyconf,
2669 const u8 *ta, u32 iv32, u16 *p1k);
2670
2671/**
2616 * ieee80211_get_tkip_p2k - get a TKIP phase 2 key 2672 * ieee80211_get_tkip_p2k - get a TKIP phase 2 key
2617 * 2673 *
2618 * This function computes the TKIP RC4 key for the IV values 2674 * This function computes the TKIP RC4 key for the IV values
@@ -2973,6 +3029,10 @@ void ieee80211_sta_block_awake(struct ieee80211_hw *hw,
2973 * needs reprogramming of the keys during suspend. Note that due 3029 * needs reprogramming of the keys during suspend. Note that due
2974 * to locking reasons, it is also only safe to call this at few 3030 * to locking reasons, it is also only safe to call this at few
2975 * spots since it must hold the RTNL and be able to sleep. 3031 * spots since it must hold the RTNL and be able to sleep.
3032 *
3033 * The order in which the keys are iterated matches the order
3034 * in which they were originally installed and handed to the
3035 * set_key callback.
2976 */ 3036 */
2977void ieee80211_iter_keys(struct ieee80211_hw *hw, 3037void ieee80211_iter_keys(struct ieee80211_hw *hw,
2978 struct ieee80211_vif *vif, 3038 struct ieee80211_vif *vif,