Merge branch 'for-2638/i2c/iop' into for-linus/i2c-2638
[firefly-linux-kernel-4.4.55.git] / include / linux / nl80211.h
index 1cee56b3a79abf50c02a50a13d982805c7e34ac3..2b89b712565b834ca3bb32a5bf5cdbe862b9326a 100644 (file)
  *     to the specified ISO/IEC 3166-1 alpha2 country code. The core will
  *     store this as a valid request and then query userspace for it.
  *
- * @NL80211_CMD_GET_MESH_PARAMS: Get mesh networking properties for the
+ * @NL80211_CMD_GET_MESH_CONFIG: Get mesh networking properties for the
  *     interface identified by %NL80211_ATTR_IFINDEX
  *
- * @NL80211_CMD_SET_MESH_PARAMS: Set mesh networking properties for the
+ * @NL80211_CMD_SET_MESH_CONFIG: Set mesh networking properties for the
  *      interface identified by %NL80211_ATTR_IFINDEX
  *
  * @NL80211_CMD_SET_MGMT_EXTRA_IE: Set extra IEs for management frames. The
  * @NL80211_CMD_LEAVE_MESH: Leave the mesh network -- no special arguments, the
  *     network is determined by the network interface.
  *
+ * @NL80211_CMD_UNPROT_DEAUTHENTICATE: Unprotected deauthentication frame
+ *     notification. This event is used to indicate that an unprotected
+ *     deauthentication frame was dropped when MFP is in use.
+ * @NL80211_CMD_UNPROT_DISASSOCIATE: Unprotected disassociation frame
+ *     notification. This event is used to indicate that an unprotected
+ *     disassociation frame was dropped when MFP is in use.
+ *
  * @NL80211_CMD_MAX: highest used command number
  * @__NL80211_CMD_AFTER_LAST: internal use
  */
@@ -441,8 +448,8 @@ enum nl80211_commands {
        NL80211_CMD_SET_REG,
        NL80211_CMD_REQ_SET_REG,
 
-       NL80211_CMD_GET_MESH_PARAMS,
-       NL80211_CMD_SET_MESH_PARAMS,
+       NL80211_CMD_GET_MESH_CONFIG,
+       NL80211_CMD_SET_MESH_CONFIG,
 
        NL80211_CMD_SET_MGMT_EXTRA_IE /* reserved; not used */,
 
@@ -508,6 +515,9 @@ enum nl80211_commands {
        NL80211_CMD_JOIN_MESH,
        NL80211_CMD_LEAVE_MESH,
 
+       NL80211_CMD_UNPROT_DEAUTHENTICATE,
+       NL80211_CMD_UNPROT_DISASSOCIATE,
+
        /* add new commands above here */
 
        /* used to define NL80211_CMD_MAX below */
@@ -528,6 +538,10 @@ enum nl80211_commands {
 #define NL80211_CMD_DISASSOCIATE NL80211_CMD_DISASSOCIATE
 #define NL80211_CMD_REG_BEACON_HINT NL80211_CMD_REG_BEACON_HINT
 
+/* source-level API compatibility */
+#define NL80211_CMD_GET_MESH_PARAMS NL80211_CMD_GET_MESH_CONFIG
+#define NL80211_CMD_SET_MESH_PARAMS NL80211_CMD_SET_MESH_CONFIG
+
 /**
  * enum nl80211_attrs - nl80211 netlink attributes
  *
@@ -844,6 +858,12 @@ enum nl80211_commands {
  *     the hardware should not be configured to receive on this antenna.
  *     For a more detailed descripton see @NL80211_ATTR_WIPHY_ANTENNA_TX.
  *
+ * @NL80211_ATTR_WIPHY_ANTENNA_AVAIL_TX: Bitmap of antennas which are available
+ *     for configuration as TX antennas via the above parameters.
+ *
+ * @NL80211_ATTR_WIPHY_ANTENNA_AVAIL_RX: Bitmap of antennas which are available
+ *     for configuration as RX antennas via the above parameters.
+ *
  * @NL80211_ATTR_MCAST_RATE: Multicast tx rate (in 100 kbps) for IBSS
  *
  * @NL80211_ATTR_OFFCHANNEL_TX_OK: For management frame TX, the frame may be
@@ -858,6 +878,9 @@ enum nl80211_commands {
  *     attributes, specifying what a key should be set as default as.
  *     See &enum nl80211_key_default_types.
  *
+ * @NL80211_ATTR_MESH_SETUP: Optional mesh setup parameters.  These cannot be
+ * changed once the mesh is active.
+ *
  * @NL80211_ATTR_MAX: highest attribute number currently defined
  * @__NL80211_ATTR_AFTER_LAST: internal use
  */
@@ -912,7 +935,7 @@ enum nl80211_attrs {
        NL80211_ATTR_REG_ALPHA2,
        NL80211_ATTR_REG_RULES,
 
-       NL80211_ATTR_MESH_PARAMS,
+       NL80211_ATTR_MESH_CONFIG,
 
        NL80211_ATTR_BSS_BASIC_RATES,
 
@@ -1040,6 +1063,11 @@ enum nl80211_attrs {
 
        NL80211_ATTR_MAX_REMAIN_ON_CHANNEL_DURATION,
 
+       NL80211_ATTR_MESH_SETUP,
+
+       NL80211_ATTR_WIPHY_ANTENNA_AVAIL_TX,
+       NL80211_ATTR_WIPHY_ANTENNA_AVAIL_RX,
+
        /* add attributes here, update the policy in nl80211.c */
 
        __NL80211_ATTR_AFTER_LAST,
@@ -1048,6 +1076,7 @@ enum nl80211_attrs {
 
 /* source-level API compatibility */
 #define NL80211_ATTR_SCAN_GENERATION NL80211_ATTR_GENERATION
+#define        NL80211_ATTR_MESH_PARAMS NL80211_ATTR_MESH_CONFIG
 
 /*
  * Allow user space programs to use #ifdef on new attributes by defining them
@@ -1549,7 +1578,8 @@ enum nl80211_mntr_flags {
 /**
  * enum nl80211_meshconf_params - mesh configuration parameters
  *
- * Mesh configuration parameters
+ * Mesh configuration parameters. These can be changed while the mesh is
+ * active.
  *
  * @__NL80211_MESHCONF_INVALID: internal use
  *
@@ -1572,9 +1602,6 @@ enum nl80211_mntr_flags {
  * @NL80211_MESHCONF_TTL: specifies the value of TTL field set at a source mesh
  * point.
  *
- * @NL80211_MESHCONF_ELEMENT_TTL: specifies the value of TTL field set at a
- * source mesh point for path selection elements.
- *
  * @NL80211_MESHCONF_AUTO_OPEN_PLINKS: whether we should automatically
  * open peer links when we detect compatible mesh peers.
  *
@@ -1601,6 +1628,9 @@ enum nl80211_mntr_flags {
  *
  * @NL80211_MESHCONF_ROOTMODE: whether root mode is enabled or not
  *
+ * @NL80211_MESHCONF_ELEMENT_TTL: specifies the value of TTL field set at a
+ * source mesh point for path selection elements.
+ *
  * @NL80211_MESHCONF_ATTR_MAX: highest possible mesh configuration attribute
  *
  * @__NL80211_MESHCONF_ATTR_AFTER_LAST: internal use
@@ -1628,6 +1658,39 @@ enum nl80211_meshconf_params {
        NL80211_MESHCONF_ATTR_MAX = __NL80211_MESHCONF_ATTR_AFTER_LAST - 1
 };
 
+/**
+ * enum nl80211_mesh_setup_params - mesh setup parameters
+ *
+ * Mesh setup parameters.  These are used to start/join a mesh and cannot be
+ * changed while the mesh is active.
+ *
+ * @__NL80211_MESH_SETUP_INVALID: Internal use
+ *
+ * @NL80211_MESH_SETUP_ENABLE_VENDOR_PATH_SEL: Enable this option to use a
+ * vendor specific path selection algorithm or disable it to use the default
+ * HWMP.
+ *
+ * @NL80211_MESH_SETUP_ENABLE_VENDOR_METRIC: Enable this option to use a
+ * vendor specific path metric or disable it to use the default Airtime
+ * metric.
+ *
+ * @NL80211_MESH_SETUP_VENDOR_PATH_SEL_IE: A vendor specific information
+ * element that vendors will use to identify the path selection methods and
+ * metrics in use.
+ *
+ * @__NL80211_MESH_SETUP_ATTR_AFTER_LAST: Internal use
+ */
+enum nl80211_mesh_setup_params {
+       __NL80211_MESH_SETUP_INVALID,
+       NL80211_MESH_SETUP_ENABLE_VENDOR_PATH_SEL,
+       NL80211_MESH_SETUP_ENABLE_VENDOR_METRIC,
+       NL80211_MESH_SETUP_VENDOR_PATH_SEL_IE,
+
+       /* keep last */
+       __NL80211_MESH_SETUP_ATTR_AFTER_LAST,
+       NL80211_MESH_SETUP_ATTR_MAX = __NL80211_MESH_SETUP_ATTR_AFTER_LAST - 1
+};
+
 /**
  * enum nl80211_txq_attr - TX queue parameter attributes
  * @__NL80211_TXQ_ATTR_INVALID: Attribute number 0 is reserved