1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>struct wiphy</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="The 802.11 subsystems – for kernel developers"><link rel="up" href="bk01ch01.html" title="Chapter 1. Device registration"><link rel="prev" href="API-enum-wiphy-flags.html" title="enum wiphy_flags"><link rel="next" href="API-struct-wireless-dev.html" title="struct wireless_dev"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center"><span class="phrase">struct wiphy</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-enum-wiphy-flags.html">Prev</a> </td><th width="60%" align="center">Chapter 1. Device registration</th><td width="20%" align="right"> <a accesskey="n" href="API-struct-wireless-dev.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-struct-wiphy"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>struct wiphy — 2 wireless hardware description 3 </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><pre class="programlisting"> 4struct wiphy { 5 u8 perm_addr[ETH_ALEN]; 6 u8 addr_mask[ETH_ALEN]; 7 struct mac_address * addresses; 8 const struct ieee80211_txrx_stypes * mgmt_stypes; 9 const struct ieee80211_iface_combination * iface_combinations; 10 int n_iface_combinations; 11 u16 software_iftypes; 12 u16 n_addresses; 13 u16 interface_modes; 14 u16 max_acl_mac_addrs; 15 u32 flags; 16 u32 regulatory_flags; 17 u32 features; 18 u8 ext_features[DIV_ROUND_UP(NUM_NL80211_EXT_FEATURES# 8)]; 19 u32 ap_sme_capa; 20 enum cfg80211_signal_type signal_type; 21 int bss_priv_size; 22 u8 max_scan_ssids; 23 u8 max_sched_scan_ssids; 24 u8 max_match_sets; 25 u16 max_scan_ie_len; 26 u16 max_sched_scan_ie_len; 27 int n_cipher_suites; 28 const u32 * cipher_suites; 29 u8 retry_short; 30 u8 retry_long; 31 u32 frag_threshold; 32 u32 rts_threshold; 33 u8 coverage_class; 34 char fw_version[ETHTOOL_FWVERS_LEN]; 35 u32 hw_version; 36#ifdef CONFIG_PM 37 const struct wiphy_wowlan_support * wowlan; 38 struct cfg80211_wowlan * wowlan_config; 39#endif 40 u16 max_remain_on_channel_duration; 41 u8 max_num_pmkids; 42 u32 available_antennas_tx; 43 u32 available_antennas_rx; 44 u32 probe_resp_offload; 45 const u8 * extended_capabilities; 46 const u8 * extended_capabilities_mask; 47 u8 extended_capabilities_len; 48 const void * privid; 49 struct ieee80211_supported_band * bands[IEEE80211_NUM_BANDS]; 50 void (* reg_notifier) (struct wiphy *wiphy,struct regulatory_request *request); 51 const struct ieee80211_regdomain __rcu * regd; 52 struct device dev; 53 bool registered; 54 struct dentry * debugfsdir; 55 const struct ieee80211_ht_cap * ht_capa_mod_mask; 56 const struct ieee80211_vht_cap * vht_capa_mod_mask; 57 possible_net_t _net; 58#ifdef CONFIG_CFG80211_WEXT 59 const struct iw_handler_def * wext; 60#endif 61 const struct wiphy_coalesce_support * coalesce; 62 const struct wiphy_vendor_command * vendor_commands; 63 const struct nl80211_vendor_cmd_info * vendor_events; 64 int n_vendor_commands; 65 int n_vendor_events; 66 u16 max_ap_assoc_sta; 67 u8 max_num_csa_counters; 68 u8 max_adj_channel_rssi_comp; 69 char priv[0]; 70}; </pre></div><div class="refsect1"><a name="idp1112172108"></a><h2>Members</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term">perm_addr[ETH_ALEN]</span></dt><dd><p> 71permanent MAC address of this device 72 </p></dd><dt><span class="term">addr_mask[ETH_ALEN]</span></dt><dd><p> 73If the device supports multiple MAC addresses by masking, 74set this to a mask with variable bits set to 1, e.g. if the last 75four bits are variable then set it to 00-00-00-00-00-0f. The actual 76variable bits shall be determined by the interfaces added, with 77interfaces not matching the mask being rejected to be brought up. 78 </p></dd><dt><span class="term">addresses</span></dt><dd><p> 79If the device has more than one address, set this pointer 80to a list of addresses (6 bytes each). The first one will be used 81by default for perm_addr. In this case, the mask should be set to 82all-zeroes. In this case it is assumed that the device can handle 83the same number of arbitrary MAC addresses. 84 </p></dd><dt><span class="term">mgmt_stypes</span></dt><dd><p> 85bitmasks of frame subtypes that can be subscribed to or 86transmitted through nl80211, points to an array indexed by interface 87type 88 </p></dd><dt><span class="term">iface_combinations</span></dt><dd><p> 89Valid interface combinations array, should not 90list single interface types. 91 </p></dd><dt><span class="term">n_iface_combinations</span></dt><dd><p> 92number of entries in <em class="parameter"><code>iface_combinations</code></em> array. 93 </p></dd><dt><span class="term">software_iftypes</span></dt><dd><p> 94bitmask of software interface types, these are not 95subject to any restrictions since they are purely managed in SW. 96 </p></dd><dt><span class="term">n_addresses</span></dt><dd><p> 97number of addresses in <em class="parameter"><code>addresses</code></em>. 98 </p></dd><dt><span class="term">interface_modes</span></dt><dd><p> 99bitmask of interfaces types valid for this wiphy, 100must be set by driver 101 </p></dd><dt><span class="term">max_acl_mac_addrs</span></dt><dd><p> 102Maximum number of MAC addresses that the device 103supports for ACL. 104 </p></dd><dt><span class="term">flags</span></dt><dd><p> 105wiphy flags, see <span class="structname">enum</span> wiphy_flags 106 </p></dd><dt><span class="term">regulatory_flags</span></dt><dd><p> 107wiphy regulatory flags, see 108<span class="structname">enum</span> ieee80211_regulatory_flags 109 </p></dd><dt><span class="term">features</span></dt><dd><p> 110features advertised to nl80211, see <span class="structname">enum</span> nl80211_feature_flags. 111 </p></dd><dt><span class="term">ext_features[DIV_ROUND_UP(NUM_NL80211_EXT_FEATURES# 8)]</span></dt><dd><p> 112extended features advertised to nl80211, see 113<span class="structname">enum</span> nl80211_ext_feature_index. 114 </p></dd><dt><span class="term">ap_sme_capa</span></dt><dd><p> 115AP SME capabilities, flags from <span class="structname">enum</span> nl80211_ap_sme_features. 116 </p></dd><dt><span class="term">signal_type</span></dt><dd><p> 117signal type reported in <span class="structname">struct cfg80211_bss</span>. 118 </p></dd><dt><span class="term">bss_priv_size</span></dt><dd><p> 119each BSS struct has private data allocated with it, 120this variable determines its size 121 </p></dd><dt><span class="term">max_scan_ssids</span></dt><dd><p> 122maximum number of SSIDs the device can scan for in 123any given scan 124 </p></dd><dt><span class="term">max_sched_scan_ssids</span></dt><dd><p> 125maximum number of SSIDs the device can scan 126for in any given scheduled scan 127 </p></dd><dt><span class="term">max_match_sets</span></dt><dd><p> 128maximum number of match sets the device can handle 129when performing a scheduled scan, 0 if filtering is not 130supported. 131 </p></dd><dt><span class="term">max_scan_ie_len</span></dt><dd><p> 132maximum length of user-controlled IEs device can 133add to probe request frames transmitted during a scan, must not 134include fixed IEs like supported rates 135 </p></dd><dt><span class="term">max_sched_scan_ie_len</span></dt><dd><p> 136same as max_scan_ie_len, but for scheduled 137scans 138 </p></dd><dt><span class="term">n_cipher_suites</span></dt><dd><p> 139number of supported cipher suites 140 </p></dd><dt><span class="term">cipher_suites</span></dt><dd><p> 141supported cipher suites 142 </p></dd><dt><span class="term">retry_short</span></dt><dd><p> 143Retry limit for short frames (dot11ShortRetryLimit) 144 </p></dd><dt><span class="term">retry_long</span></dt><dd><p> 145Retry limit for long frames (dot11LongRetryLimit) 146 </p></dd><dt><span class="term">frag_threshold</span></dt><dd><p> 147Fragmentation threshold (dot11FragmentationThreshold); 148-1 = fragmentation disabled, only odd values >= 256 used 149 </p></dd><dt><span class="term">rts_threshold</span></dt><dd><p> 150RTS threshold (dot11RTSThreshold); -1 = RTS/CTS disabled 151 </p></dd><dt><span class="term">coverage_class</span></dt><dd><p> 152current coverage class 153 </p></dd><dt><span class="term">fw_version[ETHTOOL_FWVERS_LEN]</span></dt><dd><p> 154firmware version for ethtool reporting 155 </p></dd><dt><span class="term">hw_version</span></dt><dd><p> 156hardware version for ethtool reporting 157 </p></dd><dt><span class="term">wowlan</span></dt><dd><p> 158WoWLAN support information 159 </p></dd><dt><span class="term">wowlan_config</span></dt><dd><p> 160current WoWLAN configuration; this should usually not be 161used since access to it is necessarily racy, use the parameter passed 162to the <code class="function">suspend</code> operation instead. 163 </p></dd><dt><span class="term">max_remain_on_channel_duration</span></dt><dd><p> 164Maximum time a remain-on-channel operation 165may request, if implemented. 166 </p></dd><dt><span class="term">max_num_pmkids</span></dt><dd><p> 167maximum number of PMKIDs supported by device 168 </p></dd><dt><span class="term">available_antennas_tx</span></dt><dd><p> 169bitmap of antennas which are available to be 170configured as TX antennas. Antenna configuration commands will be 171rejected unless this or <em class="parameter"><code>available_antennas_rx</code></em> is set. 172 </p></dd><dt><span class="term">available_antennas_rx</span></dt><dd><p> 173bitmap of antennas which are available to be 174configured as RX antennas. Antenna configuration commands will be 175rejected unless this or <em class="parameter"><code>available_antennas_tx</code></em> is set. 176 </p></dd><dt><span class="term">probe_resp_offload</span></dt><dd><p> 177Bitmap of supported protocols for probe response offloading. 178See <span class="structname">enum</span> nl80211_probe_resp_offload_support_attr. Only valid 179when the wiphy flag <em class="parameter"><code>WIPHY_FLAG_AP_PROBE_RESP_OFFLOAD</code></em> is set. 180 </p></dd><dt><span class="term">extended_capabilities</span></dt><dd><p> 181extended capabilities supported by the driver, 182additional capabilities might be supported by userspace; these are 183the 802.11 extended capabilities (<span class="quote">“<span class="quote">Extended Capabilities element</span>”</span>) 184and are in the same format as in the information element. See 185802.11-2012 8.4.2.29 for the defined fields. 186 </p></dd><dt><span class="term">extended_capabilities_mask</span></dt><dd><p> 187mask of the valid values 188 </p></dd><dt><span class="term">extended_capabilities_len</span></dt><dd><p> 189length of the extended capabilities 190 </p></dd><dt><span class="term">privid</span></dt><dd><p> 191a pointer that drivers can use to identify if an arbitrary 192wiphy is theirs, e.g. in global notifiers 193 </p></dd><dt><span class="term">bands[IEEE80211_NUM_BANDS]</span></dt><dd><p> 194information about bands/channels supported by this device 195 </p></dd><dt><span class="term">reg_notifier</span></dt><dd><p> 196the driver's regulatory notification callback, 197note that if your driver uses <code class="function">wiphy_apply_custom_regulatory</code> 198the reg_notifier's request can be passed as NULL 199 </p></dd><dt><span class="term">regd</span></dt><dd><p> 200the driver's regulatory domain, if one was requested via 201the <code class="function">regulatory_hint</code> API. This can be used by the driver 202on the <code class="function">reg_notifier</code> if it chooses to ignore future 203regulatory domain changes caused by other drivers. 204 </p></dd><dt><span class="term">dev</span></dt><dd><p> 205(virtual) struct device for this wiphy 206 </p></dd><dt><span class="term">registered</span></dt><dd><p> 207helps synchronize suspend/resume with wiphy unregister 208 </p></dd><dt><span class="term">debugfsdir</span></dt><dd><p> 209debugfs directory used for this wiphy, will be renamed 210automatically on wiphy renames 211 </p></dd><dt><span class="term">ht_capa_mod_mask</span></dt><dd><p> 212Specify what ht_cap values can be over-ridden. 213If null, then none can be over-ridden. 214 </p></dd><dt><span class="term">vht_capa_mod_mask</span></dt><dd><p> 215Specify what VHT capabilities can be over-ridden. 216If null, then none can be over-ridden. 217 </p></dd><dt><span class="term">_net</span></dt><dd><p> 218the network namespace this wiphy currently lives in 219 </p></dd><dt><span class="term">wext</span></dt><dd><p> 220wireless extension handlers 221 </p></dd><dt><span class="term">coalesce</span></dt><dd><p> 222packet coalescing support information 223 </p></dd><dt><span class="term">vendor_commands</span></dt><dd><p> 224array of vendor commands supported by the hardware 225 </p></dd><dt><span class="term">vendor_events</span></dt><dd><p> 226array of vendor events supported by the hardware 227 </p></dd><dt><span class="term">n_vendor_commands</span></dt><dd><p> 228number of vendor commands 229 </p></dd><dt><span class="term">n_vendor_events</span></dt><dd><p> 230number of vendor events 231 </p></dd><dt><span class="term">max_ap_assoc_sta</span></dt><dd><p> 232maximum number of associated stations supported in AP mode 233(including P2P GO) or 0 to indicate no such limit is advertised. The 234driver is allowed to advertise a theoretical limit that it can reach in 235some cases, but may not always reach. 236 </p></dd><dt><span class="term">max_num_csa_counters</span></dt><dd><p> 237Number of supported csa_counters in beacons 238and probe responses. This value should be set if the driver 239wishes to limit the number of csa counters. Default (0) means 240infinite. 241 </p></dd><dt><span class="term">max_adj_channel_rssi_comp</span></dt><dd><p> 242max offset of between the channel on which the 243frame was sent and the channel on which the frame was heard for which 244the reported rssi is still valid. If a driver is able to compensate the 245low rssi when a frame is heard on different channel, then it should set 246this variable to the maximal offset for which it can compensate. 247This value should be set in MHz. 248 </p></dd><dt><span class="term">priv[0]</span></dt><dd><p> 249driver private data (sized according to <code class="function">wiphy_new</code> parameter) 250 </p></dd></dl></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-enum-wiphy-flags.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="bk01ch01.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="API-struct-wireless-dev.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">enum wiphy_flags</span> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> <span class="phrase">struct wireless_dev</span></td></tr></table></div></body></html> 251