diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/ieee80211.h | 9 | ||||
-rw-r--r-- | include/linux/mISDNdsp.h | 4 | ||||
-rw-r--r-- | include/linux/mISDNhw.h | 2 | ||||
-rw-r--r-- | include/linux/mISDNif.h | 19 | ||||
-rw-r--r-- | include/linux/netdevice.h | 86 | ||||
-rw-r--r-- | include/linux/pci_ids.h | 2 | ||||
-rw-r--r-- | include/linux/phy.h | 4 | ||||
-rw-r--r-- | include/net/cfg80211.h | 78 | ||||
-rw-r--r-- | include/net/mac80211.h | 29 |
9 files changed, 128 insertions, 105 deletions
diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h index 05c29c01174c..34de8b21f6d4 100644 --- a/include/linux/ieee80211.h +++ b/include/linux/ieee80211.h | |||
@@ -493,6 +493,7 @@ struct ieee80211s_hdr { | |||
493 | /* Mesh flags */ | 493 | /* Mesh flags */ |
494 | #define MESH_FLAGS_AE_A4 0x1 | 494 | #define MESH_FLAGS_AE_A4 0x1 |
495 | #define MESH_FLAGS_AE_A5_A6 0x2 | 495 | #define MESH_FLAGS_AE_A5_A6 0x2 |
496 | #define MESH_FLAGS_AE 0x3 | ||
496 | #define MESH_FLAGS_PS_DEEP 0x4 | 497 | #define MESH_FLAGS_PS_DEEP 0x4 |
497 | 498 | ||
498 | /** | 499 | /** |
@@ -1085,6 +1086,14 @@ enum ieee80211_spectrum_mgmt_actioncode { | |||
1085 | WLAN_ACTION_SPCT_CHL_SWITCH = 4, | 1086 | WLAN_ACTION_SPCT_CHL_SWITCH = 4, |
1086 | }; | 1087 | }; |
1087 | 1088 | ||
1089 | /* Security key length */ | ||
1090 | enum ieee80211_key_len { | ||
1091 | WLAN_KEY_LEN_WEP40 = 5, | ||
1092 | WLAN_KEY_LEN_WEP104 = 13, | ||
1093 | WLAN_KEY_LEN_CCMP = 16, | ||
1094 | WLAN_KEY_LEN_TKIP = 32, | ||
1095 | }; | ||
1096 | |||
1088 | /* | 1097 | /* |
1089 | * IEEE 802.11-2007 7.3.2.9 Country information element | 1098 | * IEEE 802.11-2007 7.3.2.9 Country information element |
1090 | * | 1099 | * |
diff --git a/include/linux/mISDNdsp.h b/include/linux/mISDNdsp.h index 6b71d2dce508..41d1eeb9b3bd 100644 --- a/include/linux/mISDNdsp.h +++ b/include/linux/mISDNdsp.h | |||
@@ -12,7 +12,8 @@ struct mISDN_dsp_element { | |||
12 | void *(*new)(const char *arg); | 12 | void *(*new)(const char *arg); |
13 | void (*free)(void *p); | 13 | void (*free)(void *p); |
14 | void (*process_tx)(void *p, unsigned char *data, int len); | 14 | void (*process_tx)(void *p, unsigned char *data, int len); |
15 | void (*process_rx)(void *p, unsigned char *data, int len); | 15 | void (*process_rx)(void *p, unsigned char *data, int len, |
16 | unsigned int txlen); | ||
16 | int num_args; | 17 | int num_args; |
17 | struct mISDN_dsp_element_arg | 18 | struct mISDN_dsp_element_arg |
18 | *args; | 19 | *args; |
@@ -24,6 +25,7 @@ extern void mISDN_dsp_element_unregister(struct mISDN_dsp_element *elem); | |||
24 | struct dsp_features { | 25 | struct dsp_features { |
25 | int hfc_id; /* unique id to identify the chip (or -1) */ | 26 | int hfc_id; /* unique id to identify the chip (or -1) */ |
26 | int hfc_dtmf; /* set if HFCmulti card supports dtmf */ | 27 | int hfc_dtmf; /* set if HFCmulti card supports dtmf */ |
28 | int hfc_conf; /* set if HFCmulti card supports conferences */ | ||
27 | int hfc_loops; /* set if card supports tone loops */ | 29 | int hfc_loops; /* set if card supports tone loops */ |
28 | int hfc_echocanhw; /* set if card supports echocancelation*/ | 30 | int hfc_echocanhw; /* set if card supports echocancelation*/ |
29 | int pcm_id; /* unique id to identify the pcm bus (or -1) */ | 31 | int pcm_id; /* unique id to identify the pcm bus (or -1) */ |
diff --git a/include/linux/mISDNhw.h b/include/linux/mISDNhw.h index 97ffdc1d3442..ce900f4c2458 100644 --- a/include/linux/mISDNhw.h +++ b/include/linux/mISDNhw.h | |||
@@ -185,7 +185,7 @@ extern int dchannel_senddata(struct dchannel *, struct sk_buff *); | |||
185 | extern int bchannel_senddata(struct bchannel *, struct sk_buff *); | 185 | extern int bchannel_senddata(struct bchannel *, struct sk_buff *); |
186 | extern void recv_Dchannel(struct dchannel *); | 186 | extern void recv_Dchannel(struct dchannel *); |
187 | extern void recv_Echannel(struct dchannel *, struct dchannel *); | 187 | extern void recv_Echannel(struct dchannel *, struct dchannel *); |
188 | extern void recv_Bchannel(struct bchannel *); | 188 | extern void recv_Bchannel(struct bchannel *, unsigned int id); |
189 | extern void recv_Dchannel_skb(struct dchannel *, struct sk_buff *); | 189 | extern void recv_Dchannel_skb(struct dchannel *, struct sk_buff *); |
190 | extern void recv_Bchannel_skb(struct bchannel *, struct sk_buff *); | 190 | extern void recv_Bchannel_skb(struct bchannel *, struct sk_buff *); |
191 | extern void confirm_Bsend(struct bchannel *bch); | 191 | extern void confirm_Bsend(struct bchannel *bch); |
diff --git a/include/linux/mISDNif.h b/include/linux/mISDNif.h index 5da3d95b27f1..45100b39a7cf 100644 --- a/include/linux/mISDNif.h +++ b/include/linux/mISDNif.h | |||
@@ -229,6 +229,7 @@ | |||
229 | #define OPTION_L2_PTP 2 | 229 | #define OPTION_L2_PTP 2 |
230 | #define OPTION_L2_FIXEDTEI 3 | 230 | #define OPTION_L2_FIXEDTEI 3 |
231 | #define OPTION_L2_CLEANUP 4 | 231 | #define OPTION_L2_CLEANUP 4 |
232 | #define OPTION_L1_HOLD 5 | ||
232 | 233 | ||
233 | /* should be in sync with linux/kobject.h:KOBJ_NAME_LEN */ | 234 | /* should be in sync with linux/kobject.h:KOBJ_NAME_LEN */ |
234 | #define MISDN_MAX_IDLEN 20 | 235 | #define MISDN_MAX_IDLEN 20 |
@@ -291,19 +292,19 @@ struct mISDN_devrename { | |||
291 | 292 | ||
292 | /* MPH_INFORMATION_REQ payload */ | 293 | /* MPH_INFORMATION_REQ payload */ |
293 | struct ph_info_ch { | 294 | struct ph_info_ch { |
294 | __u32 protocol; | 295 | __u32 protocol; |
295 | __u64 Flags; | 296 | __u64 Flags; |
296 | }; | 297 | }; |
297 | 298 | ||
298 | struct ph_info_dch { | 299 | struct ph_info_dch { |
299 | struct ph_info_ch ch; | 300 | struct ph_info_ch ch; |
300 | __u16 state; | 301 | __u16 state; |
301 | __u16 num_bch; | 302 | __u16 num_bch; |
302 | }; | 303 | }; |
303 | 304 | ||
304 | struct ph_info { | 305 | struct ph_info { |
305 | struct ph_info_dch dch; | 306 | struct ph_info_dch dch; |
306 | struct ph_info_ch bch[]; | 307 | struct ph_info_ch bch[]; |
307 | }; | 308 | }; |
308 | 309 | ||
309 | /* timer device ioctl */ | 310 | /* timer device ioctl */ |
@@ -317,6 +318,7 @@ struct ph_info { | |||
317 | #define IMCTRLREQ _IOR('I', 69, int) | 318 | #define IMCTRLREQ _IOR('I', 69, int) |
318 | #define IMCLEAR_L2 _IOR('I', 70, int) | 319 | #define IMCLEAR_L2 _IOR('I', 70, int) |
319 | #define IMSETDEVNAME _IOR('I', 71, struct mISDN_devrename) | 320 | #define IMSETDEVNAME _IOR('I', 71, struct mISDN_devrename) |
321 | #define IMHOLD_L1 _IOR('I', 72, int) | ||
320 | 322 | ||
321 | static inline int | 323 | static inline int |
322 | test_channelmap(u_int nr, u_char *map) | 324 | test_channelmap(u_int nr, u_char *map) |
@@ -362,7 +364,8 @@ clear_channelmap(u_int nr, u_char *map) | |||
362 | #define MISDN_CTRL_HFC_RECEIVE_ON 0x4006 | 364 | #define MISDN_CTRL_HFC_RECEIVE_ON 0x4006 |
363 | #define MISDN_CTRL_HFC_ECHOCAN_ON 0x4007 | 365 | #define MISDN_CTRL_HFC_ECHOCAN_ON 0x4007 |
364 | #define MISDN_CTRL_HFC_ECHOCAN_OFF 0x4008 | 366 | #define MISDN_CTRL_HFC_ECHOCAN_OFF 0x4008 |
365 | 367 | #define MISDN_CTRL_HFC_WD_INIT 0x4009 | |
368 | #define MISDN_CTRL_HFC_WD_RESET 0x400A | ||
366 | 369 | ||
367 | /* socket options */ | 370 | /* socket options */ |
368 | #define MISDN_TIME_STAMP 0x0001 | 371 | #define MISDN_TIME_STAMP 0x0001 |
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index f8574e76b743..8e03b06e638e 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -901,49 +901,10 @@ struct net_device | |||
901 | /* max exchange id for FCoE LRO by ddp */ | 901 | /* max exchange id for FCoE LRO by ddp */ |
902 | unsigned int fcoe_ddp_xid; | 902 | unsigned int fcoe_ddp_xid; |
903 | #endif | 903 | #endif |
904 | |||
905 | #ifdef CONFIG_COMPAT_NET_DEV_OPS | ||
906 | struct { | ||
907 | int (*init)(struct net_device *dev); | ||
908 | void (*uninit)(struct net_device *dev); | ||
909 | int (*open)(struct net_device *dev); | ||
910 | int (*stop)(struct net_device *dev); | ||
911 | int (*hard_start_xmit) (struct sk_buff *skb, | ||
912 | struct net_device *dev); | ||
913 | u16 (*select_queue)(struct net_device *dev, | ||
914 | struct sk_buff *skb); | ||
915 | void (*change_rx_flags)(struct net_device *dev, | ||
916 | int flags); | ||
917 | void (*set_rx_mode)(struct net_device *dev); | ||
918 | void (*set_multicast_list)(struct net_device *dev); | ||
919 | int (*set_mac_address)(struct net_device *dev, | ||
920 | void *addr); | ||
921 | int (*validate_addr)(struct net_device *dev); | ||
922 | int (*do_ioctl)(struct net_device *dev, | ||
923 | struct ifreq *ifr, int cmd); | ||
924 | int (*set_config)(struct net_device *dev, | ||
925 | struct ifmap *map); | ||
926 | int (*change_mtu)(struct net_device *dev, int new_mtu); | ||
927 | int (*neigh_setup)(struct net_device *dev, | ||
928 | struct neigh_parms *); | ||
929 | void (*tx_timeout) (struct net_device *dev); | ||
930 | struct net_device_stats* (*get_stats)(struct net_device *dev); | ||
931 | void (*vlan_rx_register)(struct net_device *dev, | ||
932 | struct vlan_group *grp); | ||
933 | void (*vlan_rx_add_vid)(struct net_device *dev, | ||
934 | unsigned short vid); | ||
935 | void (*vlan_rx_kill_vid)(struct net_device *dev, | ||
936 | unsigned short vid); | ||
937 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
938 | void (*poll_controller)(struct net_device *dev); | ||
939 | #endif | ||
940 | }; | ||
941 | #endif | ||
942 | }; | 904 | }; |
943 | #define to_net_dev(d) container_of(d, struct net_device, dev) | 905 | #define to_net_dev(d) container_of(d, struct net_device, dev) |
944 | 906 | ||
945 | #define NETDEV_ALIGN 32 | 907 | #define NETDEV_ALIGN 32 |
946 | #define NETDEV_ALIGN_CONST (NETDEV_ALIGN - 1) | ||
947 | 908 | ||
948 | static inline | 909 | static inline |
949 | struct netdev_queue *netdev_get_tx_queue(const struct net_device *dev, | 910 | struct netdev_queue *netdev_get_tx_queue(const struct net_device *dev, |
@@ -1014,9 +975,7 @@ static inline bool netdev_uses_trailer_tags(struct net_device *dev) | |||
1014 | */ | 975 | */ |
1015 | static inline void *netdev_priv(const struct net_device *dev) | 976 | static inline void *netdev_priv(const struct net_device *dev) |
1016 | { | 977 | { |
1017 | return (char *)dev + ((sizeof(struct net_device) | 978 | return (char *)dev + ALIGN(sizeof(struct net_device), NETDEV_ALIGN); |
1018 | + NETDEV_ALIGN_CONST) | ||
1019 | & ~NETDEV_ALIGN_CONST); | ||
1020 | } | 979 | } |
1021 | 980 | ||
1022 | /* Set the sysfs physical device reference for the network logical device | 981 | /* Set the sysfs physical device reference for the network logical device |
@@ -1046,6 +1005,12 @@ void netif_napi_add(struct net_device *dev, struct napi_struct *napi, | |||
1046 | void netif_napi_del(struct napi_struct *napi); | 1005 | void netif_napi_del(struct napi_struct *napi); |
1047 | 1006 | ||
1048 | struct napi_gro_cb { | 1007 | struct napi_gro_cb { |
1008 | /* Virtual address of skb_shinfo(skb)->frags[0].page + offset. */ | ||
1009 | void *frag0; | ||
1010 | |||
1011 | /* Length of frag0. */ | ||
1012 | unsigned int frag0_len; | ||
1013 | |||
1049 | /* This indicates where we are processing relative to skb->data. */ | 1014 | /* This indicates where we are processing relative to skb->data. */ |
1050 | int data_offset; | 1015 | int data_offset; |
1051 | 1016 | ||
@@ -1145,9 +1110,9 @@ extern int dev_restart(struct net_device *dev); | |||
1145 | #ifdef CONFIG_NETPOLL_TRAP | 1110 | #ifdef CONFIG_NETPOLL_TRAP |
1146 | extern int netpoll_trap(void); | 1111 | extern int netpoll_trap(void); |
1147 | #endif | 1112 | #endif |
1148 | extern void *skb_gro_header(struct sk_buff *skb, unsigned int hlen); | ||
1149 | extern int skb_gro_receive(struct sk_buff **head, | 1113 | extern int skb_gro_receive(struct sk_buff **head, |
1150 | struct sk_buff *skb); | 1114 | struct sk_buff *skb); |
1115 | extern void skb_gro_reset_offset(struct sk_buff *skb); | ||
1151 | 1116 | ||
1152 | static inline unsigned int skb_gro_offset(const struct sk_buff *skb) | 1117 | static inline unsigned int skb_gro_offset(const struct sk_buff *skb) |
1153 | { | 1118 | { |
@@ -1164,23 +1129,34 @@ static inline void skb_gro_pull(struct sk_buff *skb, unsigned int len) | |||
1164 | NAPI_GRO_CB(skb)->data_offset += len; | 1129 | NAPI_GRO_CB(skb)->data_offset += len; |
1165 | } | 1130 | } |
1166 | 1131 | ||
1167 | static inline void skb_gro_reset_offset(struct sk_buff *skb) | 1132 | static inline void *skb_gro_header_fast(struct sk_buff *skb, |
1133 | unsigned int offset) | ||
1168 | { | 1134 | { |
1169 | NAPI_GRO_CB(skb)->data_offset = 0; | 1135 | return NAPI_GRO_CB(skb)->frag0 + offset; |
1136 | } | ||
1137 | |||
1138 | static inline int skb_gro_header_hard(struct sk_buff *skb, unsigned int hlen) | ||
1139 | { | ||
1140 | return NAPI_GRO_CB(skb)->frag0_len < hlen; | ||
1141 | } | ||
1142 | |||
1143 | static inline void *skb_gro_header_slow(struct sk_buff *skb, unsigned int hlen, | ||
1144 | unsigned int offset) | ||
1145 | { | ||
1146 | NAPI_GRO_CB(skb)->frag0 = NULL; | ||
1147 | NAPI_GRO_CB(skb)->frag0_len = 0; | ||
1148 | return pskb_may_pull(skb, hlen) ? skb->data + offset : NULL; | ||
1170 | } | 1149 | } |
1171 | 1150 | ||
1172 | static inline void *skb_gro_mac_header(struct sk_buff *skb) | 1151 | static inline void *skb_gro_mac_header(struct sk_buff *skb) |
1173 | { | 1152 | { |
1174 | return skb_headlen(skb) ? skb_mac_header(skb) : | 1153 | return NAPI_GRO_CB(skb)->frag0 ?: skb_mac_header(skb); |
1175 | page_address(skb_shinfo(skb)->frags[0].page) + | ||
1176 | skb_shinfo(skb)->frags[0].page_offset; | ||
1177 | } | 1154 | } |
1178 | 1155 | ||
1179 | static inline void *skb_gro_network_header(struct sk_buff *skb) | 1156 | static inline void *skb_gro_network_header(struct sk_buff *skb) |
1180 | { | 1157 | { |
1181 | return skb_headlen(skb) ? skb_network_header(skb) : | 1158 | return (NAPI_GRO_CB(skb)->frag0 ?: skb->data) + |
1182 | page_address(skb_shinfo(skb)->frags[0].page) + | 1159 | skb_network_offset(skb); |
1183 | skb_shinfo(skb)->frags[0].page_offset + skb_network_offset(skb); | ||
1184 | } | 1160 | } |
1185 | 1161 | ||
1186 | static inline int dev_hard_header(struct sk_buff *skb, struct net_device *dev, | 1162 | static inline int dev_hard_header(struct sk_buff *skb, struct net_device *dev, |
@@ -1712,6 +1688,12 @@ static inline void __netif_tx_unlock_bh(struct netdev_queue *txq) | |||
1712 | spin_unlock_bh(&txq->_xmit_lock); | 1688 | spin_unlock_bh(&txq->_xmit_lock); |
1713 | } | 1689 | } |
1714 | 1690 | ||
1691 | static inline void txq_trans_update(struct netdev_queue *txq) | ||
1692 | { | ||
1693 | if (txq->xmit_lock_owner != -1) | ||
1694 | txq->trans_start = jiffies; | ||
1695 | } | ||
1696 | |||
1715 | /** | 1697 | /** |
1716 | * netif_tx_lock - grab network device transmit lock | 1698 | * netif_tx_lock - grab network device transmit lock |
1717 | * @dev: network device | 1699 | * @dev: network device |
@@ -1993,4 +1975,4 @@ static inline u32 dev_ethtool_get_flags(struct net_device *dev) | |||
1993 | } | 1975 | } |
1994 | #endif /* __KERNEL__ */ | 1976 | #endif /* __KERNEL__ */ |
1995 | 1977 | ||
1996 | #endif /* _LINUX_DEV_H */ | 1978 | #endif /* _LINUX_NETDEVICE_H */ |
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 3038ac25491f..12db06cf0e23 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h | |||
@@ -1914,6 +1914,8 @@ | |||
1914 | #define PCI_SUBDEVICE_ID_CCD_SWYX4S 0xB540 | 1914 | #define PCI_SUBDEVICE_ID_CCD_SWYX4S 0xB540 |
1915 | #define PCI_SUBDEVICE_ID_CCD_JH4S20 0xB550 | 1915 | #define PCI_SUBDEVICE_ID_CCD_JH4S20 0xB550 |
1916 | #define PCI_SUBDEVICE_ID_CCD_IOB8ST_1 0xB552 | 1916 | #define PCI_SUBDEVICE_ID_CCD_IOB8ST_1 0xB552 |
1917 | #define PCI_SUBDEVICE_ID_CCD_JHSE1 0xB553 | ||
1918 | #define PCI_SUBDEVICE_ID_CCD_JH8S 0xB55B | ||
1917 | #define PCI_SUBDEVICE_ID_CCD_BN4S 0xB560 | 1919 | #define PCI_SUBDEVICE_ID_CCD_BN4S 0xB560 |
1918 | #define PCI_SUBDEVICE_ID_CCD_BN8S 0xB562 | 1920 | #define PCI_SUBDEVICE_ID_CCD_BN8S 0xB562 |
1919 | #define PCI_SUBDEVICE_ID_CCD_BNE1 0xB563 | 1921 | #define PCI_SUBDEVICE_ID_CCD_BNE1 0xB563 |
diff --git a/include/linux/phy.h b/include/linux/phy.h index c216e4e503b3..b1368b8f6572 100644 --- a/include/linux/phy.h +++ b/include/linux/phy.h | |||
@@ -79,7 +79,7 @@ typedef enum { | |||
79 | * Need to be a little smaller than phydev->dev.bus_id to leave room | 79 | * Need to be a little smaller than phydev->dev.bus_id to leave room |
80 | * for the ":%02x" | 80 | * for the ":%02x" |
81 | */ | 81 | */ |
82 | #define MII_BUS_ID_SIZE (BUS_ID_SIZE - 3) | 82 | #define MII_BUS_ID_SIZE (20 - 3) |
83 | 83 | ||
84 | /* | 84 | /* |
85 | * The Bus class for PHYs. Devices which provide access to | 85 | * The Bus class for PHYs. Devices which provide access to |
@@ -407,7 +407,7 @@ struct phy_driver { | |||
407 | /* A Structure for boards to register fixups with the PHY Lib */ | 407 | /* A Structure for boards to register fixups with the PHY Lib */ |
408 | struct phy_fixup { | 408 | struct phy_fixup { |
409 | struct list_head list; | 409 | struct list_head list; |
410 | char bus_id[BUS_ID_SIZE]; | 410 | char bus_id[20]; |
411 | u32 phy_uid; | 411 | u32 phy_uid; |
412 | u32 phy_uid_mask; | 412 | u32 phy_uid_mask; |
413 | int (*run)(struct phy_device *phydev); | 413 | int (*run)(struct phy_device *phydev); |
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index 9e17a83d3432..f20da7d63b1e 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h | |||
@@ -56,9 +56,9 @@ enum ieee80211_band { | |||
56 | * on this channel. | 56 | * on this channel. |
57 | * @IEEE80211_CHAN_NO_IBSS: IBSS is not allowed on this channel. | 57 | * @IEEE80211_CHAN_NO_IBSS: IBSS is not allowed on this channel. |
58 | * @IEEE80211_CHAN_RADAR: Radar detection is required on this channel. | 58 | * @IEEE80211_CHAN_RADAR: Radar detection is required on this channel. |
59 | * @IEEE80211_CHAN_NO_FAT_ABOVE: extension channel above this channel | 59 | * @IEEE80211_CHAN_NO_HT40PLUS: extension channel above this channel |
60 | * is not permitted. | 60 | * is not permitted. |
61 | * @IEEE80211_CHAN_NO_FAT_BELOW: extension channel below this channel | 61 | * @IEEE80211_CHAN_NO_HT40MINUS: extension channel below this channel |
62 | * is not permitted. | 62 | * is not permitted. |
63 | */ | 63 | */ |
64 | enum ieee80211_channel_flags { | 64 | enum ieee80211_channel_flags { |
@@ -66,10 +66,13 @@ enum ieee80211_channel_flags { | |||
66 | IEEE80211_CHAN_PASSIVE_SCAN = 1<<1, | 66 | IEEE80211_CHAN_PASSIVE_SCAN = 1<<1, |
67 | IEEE80211_CHAN_NO_IBSS = 1<<2, | 67 | IEEE80211_CHAN_NO_IBSS = 1<<2, |
68 | IEEE80211_CHAN_RADAR = 1<<3, | 68 | IEEE80211_CHAN_RADAR = 1<<3, |
69 | IEEE80211_CHAN_NO_FAT_ABOVE = 1<<4, | 69 | IEEE80211_CHAN_NO_HT40PLUS = 1<<4, |
70 | IEEE80211_CHAN_NO_FAT_BELOW = 1<<5, | 70 | IEEE80211_CHAN_NO_HT40MINUS = 1<<5, |
71 | }; | 71 | }; |
72 | 72 | ||
73 | #define IEEE80211_CHAN_NO_HT40 \ | ||
74 | (IEEE80211_CHAN_NO_HT40PLUS | IEEE80211_CHAN_NO_HT40MINUS) | ||
75 | |||
73 | /** | 76 | /** |
74 | * struct ieee80211_channel - channel definition | 77 | * struct ieee80211_channel - channel definition |
75 | * | 78 | * |
@@ -778,10 +781,11 @@ enum wiphy_params_flags { | |||
778 | * @get_key: get information about the key with the given parameters. | 781 | * @get_key: get information about the key with the given parameters. |
779 | * @mac_addr will be %NULL when requesting information for a group | 782 | * @mac_addr will be %NULL when requesting information for a group |
780 | * key. All pointers given to the @callback function need not be valid | 783 | * key. All pointers given to the @callback function need not be valid |
781 | * after it returns. | 784 | * after it returns. This function should return an error if it is |
785 | * not possible to retrieve the key, -ENOENT if it doesn't exist. | ||
782 | * | 786 | * |
783 | * @del_key: remove a key given the @mac_addr (%NULL for a group key) | 787 | * @del_key: remove a key given the @mac_addr (%NULL for a group key) |
784 | * and @key_index | 788 | * and @key_index, return -ENOENT if the key doesn't exist. |
785 | * | 789 | * |
786 | * @set_default_key: set the default key on an interface | 790 | * @set_default_key: set the default key on an interface |
787 | * | 791 | * |
@@ -994,7 +998,7 @@ struct wiphy { | |||
994 | * know whether it points to a wiphy your driver has registered | 998 | * know whether it points to a wiphy your driver has registered |
995 | * or not. Assign this to something global to your driver to | 999 | * or not. Assign this to something global to your driver to |
996 | * help determine whether you own this wiphy or not. */ | 1000 | * help determine whether you own this wiphy or not. */ |
997 | void *privid; | 1001 | const void *privid; |
998 | 1002 | ||
999 | struct ieee80211_supported_band *bands[IEEE80211_NUM_BANDS]; | 1003 | struct ieee80211_supported_band *bands[IEEE80211_NUM_BANDS]; |
1000 | 1004 | ||
@@ -1070,7 +1074,7 @@ static inline const char *wiphy_name(struct wiphy *wiphy) | |||
1070 | * The returned pointer must be assigned to each netdev's | 1074 | * The returned pointer must be assigned to each netdev's |
1071 | * ieee80211_ptr for proper operation. | 1075 | * ieee80211_ptr for proper operation. |
1072 | */ | 1076 | */ |
1073 | struct wiphy *wiphy_new(struct cfg80211_ops *ops, int sizeof_priv); | 1077 | struct wiphy *wiphy_new(const struct cfg80211_ops *ops, int sizeof_priv); |
1074 | 1078 | ||
1075 | /** | 1079 | /** |
1076 | * wiphy_register - register a wiphy with cfg80211 | 1080 | * wiphy_register - register a wiphy with cfg80211 |
@@ -1240,6 +1244,53 @@ extern int ieee80211_radiotap_iterator_init( | |||
1240 | extern int ieee80211_radiotap_iterator_next( | 1244 | extern int ieee80211_radiotap_iterator_next( |
1241 | struct ieee80211_radiotap_iterator *iterator); | 1245 | struct ieee80211_radiotap_iterator *iterator); |
1242 | 1246 | ||
1247 | extern const unsigned char rfc1042_header[6]; | ||
1248 | extern const unsigned char bridge_tunnel_header[6]; | ||
1249 | |||
1250 | /** | ||
1251 | * ieee80211_get_hdrlen_from_skb - get header length from data | ||
1252 | * | ||
1253 | * Given an skb with a raw 802.11 header at the data pointer this function | ||
1254 | * returns the 802.11 header length in bytes (not including encryption | ||
1255 | * headers). If the data in the sk_buff is too short to contain a valid 802.11 | ||
1256 | * header the function returns 0. | ||
1257 | * | ||
1258 | * @skb: the frame | ||
1259 | */ | ||
1260 | unsigned int ieee80211_get_hdrlen_from_skb(const struct sk_buff *skb); | ||
1261 | |||
1262 | /** | ||
1263 | * ieee80211_hdrlen - get header length in bytes from frame control | ||
1264 | * @fc: frame control field in little-endian format | ||
1265 | */ | ||
1266 | unsigned int ieee80211_hdrlen(__le16 fc); | ||
1267 | |||
1268 | /** | ||
1269 | * ieee80211_data_to_8023 - convert an 802.11 data frame to 802.3 | ||
1270 | * @skb: the 802.11 data frame | ||
1271 | * @addr: the device MAC address | ||
1272 | * @iftype: the virtual interface type | ||
1273 | */ | ||
1274 | int ieee80211_data_to_8023(struct sk_buff *skb, u8 *addr, | ||
1275 | enum nl80211_iftype iftype); | ||
1276 | |||
1277 | /** | ||
1278 | * ieee80211_data_from_8023 - convert an 802.3 frame to 802.11 | ||
1279 | * @skb: the 802.3 frame | ||
1280 | * @addr: the device MAC address | ||
1281 | * @iftype: the virtual interface type | ||
1282 | * @bssid: the network bssid (used only for iftype STATION and ADHOC) | ||
1283 | * @qos: build 802.11 QoS data frame | ||
1284 | */ | ||
1285 | int ieee80211_data_from_8023(struct sk_buff *skb, u8 *addr, | ||
1286 | enum nl80211_iftype iftype, u8 *bssid, bool qos); | ||
1287 | |||
1288 | /** | ||
1289 | * cfg80211_classify8021d - determine the 802.1p/1d tag for a data frame | ||
1290 | * @skb: the data frame | ||
1291 | */ | ||
1292 | unsigned int cfg80211_classify8021d(struct sk_buff *skb); | ||
1293 | |||
1243 | /* | 1294 | /* |
1244 | * Regulatory helper functions for wiphys | 1295 | * Regulatory helper functions for wiphys |
1245 | */ | 1296 | */ |
@@ -1303,9 +1354,10 @@ extern void wiphy_apply_custom_regulatory( | |||
1303 | * freq_reg_info - get regulatory information for the given frequency | 1354 | * freq_reg_info - get regulatory information for the given frequency |
1304 | * @wiphy: the wiphy for which we want to process this rule for | 1355 | * @wiphy: the wiphy for which we want to process this rule for |
1305 | * @center_freq: Frequency in KHz for which we want regulatory information for | 1356 | * @center_freq: Frequency in KHz for which we want regulatory information for |
1306 | * @bandwidth: the bandwidth requirement you have in KHz, if you do not have one | 1357 | * @desired_bw_khz: the desired max bandwidth you want to use per |
1307 | * you can set this to 0. If this frequency is allowed we then set | 1358 | * channel. Note that this is still 20 MHz if you want to use HT40 |
1308 | * this value to the maximum allowed bandwidth. | 1359 | * as HT40 makes use of two channels for its 40 MHz width bandwidth. |
1360 | * If set to 0 we'll assume you want the standard 20 MHz. | ||
1309 | * @reg_rule: the regulatory rule which we have for this frequency | 1361 | * @reg_rule: the regulatory rule which we have for this frequency |
1310 | * | 1362 | * |
1311 | * Use this function to get the regulatory rule for a specific frequency on | 1363 | * Use this function to get the regulatory rule for a specific frequency on |
@@ -1320,7 +1372,9 @@ extern void wiphy_apply_custom_regulatory( | |||
1320 | * freq_in_rule_band() for our current definition of a band -- this is purely | 1372 | * freq_in_rule_band() for our current definition of a band -- this is purely |
1321 | * subjective and right now its 802.11 specific. | 1373 | * subjective and right now its 802.11 specific. |
1322 | */ | 1374 | */ |
1323 | extern int freq_reg_info(struct wiphy *wiphy, u32 center_freq, u32 *bandwidth, | 1375 | extern int freq_reg_info(struct wiphy *wiphy, |
1376 | u32 center_freq, | ||
1377 | u32 desired_bw_khz, | ||
1324 | const struct ieee80211_reg_rule **reg_rule); | 1378 | const struct ieee80211_reg_rule **reg_rule); |
1325 | 1379 | ||
1326 | /* | 1380 | /* |
diff --git a/include/net/mac80211.h b/include/net/mac80211.h index d10ed1776fcd..d72346ff3247 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h | |||
@@ -173,7 +173,6 @@ enum ieee80211_bss_change { | |||
173 | * @timestamp: beacon timestamp | 173 | * @timestamp: beacon timestamp |
174 | * @beacon_int: beacon interval | 174 | * @beacon_int: beacon interval |
175 | * @assoc_capability: capabilities taken from assoc resp | 175 | * @assoc_capability: capabilities taken from assoc resp |
176 | * @ht: BSS's HT configuration | ||
177 | * @basic_rates: bitmap of basic rates, each bit stands for an | 176 | * @basic_rates: bitmap of basic rates, each bit stands for an |
178 | * index into the rate table configured by the driver in | 177 | * index into the rate table configured by the driver in |
179 | * the current band. | 178 | * the current band. |
@@ -673,16 +672,6 @@ enum ieee80211_key_alg { | |||
673 | }; | 672 | }; |
674 | 673 | ||
675 | /** | 674 | /** |
676 | * enum ieee80211_key_len - key length | ||
677 | * @LEN_WEP40: WEP 5-byte long key | ||
678 | * @LEN_WEP104: WEP 13-byte long key | ||
679 | */ | ||
680 | enum ieee80211_key_len { | ||
681 | LEN_WEP40 = 5, | ||
682 | LEN_WEP104 = 13, | ||
683 | }; | ||
684 | |||
685 | /** | ||
686 | * enum ieee80211_key_flags - key flags | 675 | * enum ieee80211_key_flags - key flags |
687 | * | 676 | * |
688 | * These flags are used for communication about keys between the driver | 677 | * These flags are used for communication about keys between the driver |
@@ -1813,24 +1802,6 @@ struct sk_buff * | |||
1813 | ieee80211_get_buffered_bc(struct ieee80211_hw *hw, struct ieee80211_vif *vif); | 1802 | ieee80211_get_buffered_bc(struct ieee80211_hw *hw, struct ieee80211_vif *vif); |
1814 | 1803 | ||
1815 | /** | 1804 | /** |
1816 | * ieee80211_get_hdrlen_from_skb - get header length from data | ||
1817 | * | ||
1818 | * Given an skb with a raw 802.11 header at the data pointer this function | ||
1819 | * returns the 802.11 header length in bytes (not including encryption | ||
1820 | * headers). If the data in the sk_buff is too short to contain a valid 802.11 | ||
1821 | * header the function returns 0. | ||
1822 | * | ||
1823 | * @skb: the frame | ||
1824 | */ | ||
1825 | unsigned int ieee80211_get_hdrlen_from_skb(const struct sk_buff *skb); | ||
1826 | |||
1827 | /** | ||
1828 | * ieee80211_hdrlen - get header length in bytes from frame control | ||
1829 | * @fc: frame control field in little-endian format | ||
1830 | */ | ||
1831 | unsigned int ieee80211_hdrlen(__le16 fc); | ||
1832 | |||
1833 | /** | ||
1834 | * ieee80211_get_tkip_key - get a TKIP rc4 for skb | 1805 | * ieee80211_get_tkip_key - get a TKIP rc4 for skb |
1835 | * | 1806 | * |
1836 | * This function computes a TKIP rc4 key for an skb. It computes | 1807 | * This function computes a TKIP rc4 key for an skb. It computes |