]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commitdiff
nl80211: user_mpm overrides auto_open_plinks
authorThomas Pedersen <thomas@cozybit.com>
Mon, 4 Mar 2013 21:06:13 +0000 (13:06 -0800)
committerJohannes Berg <johannes.berg@intel.com>
Wed, 6 Mar 2013 15:36:13 +0000 (16:36 +0100)
If the user requested a userspace MPM, automatically
disable auto_open_plinks to fully disable the kernel MPM.

Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
include/uapi/linux/nl80211.h
net/wireless/nl80211.c

index 8134c6a96f573019114d449659e2b50ddae36efc..79da8710448e9ec9359bcbe031377a2208e97f5b 100644 (file)
@@ -2467,8 +2467,10 @@ enum nl80211_mesh_power_mode {
  * @NL80211_MESHCONF_TTL: specifies the value of TTL field set at a source mesh
  *     point.
  *
- * @NL80211_MESHCONF_AUTO_OPEN_PLINKS: whether we should automatically
- *     open peer links when we detect compatible mesh peers.
+ * @NL80211_MESHCONF_AUTO_OPEN_PLINKS: whether we should automatically open
+ *     peer links when we detect compatible mesh peers. Disabled if
+ *     @NL80211_MESH_SETUP_USERSPACE_MPM or @NL80211_MESH_SETUP_USERSPACE_AMPE are
+ *     set.
  *
  * @NL80211_MESHCONF_HWMP_MAX_PREQ_RETRIES: the number of action frames
  *     containing a PREQ that an MP can send to a particular destination (path
index 946b2e7acdf291c28acfafac51b0aa354998ae7c..f924d45af1b80e4d19d6e72c7b490551af4a5f83 100644 (file)
@@ -7449,6 +7449,9 @@ static int nl80211_join_mesh(struct sk_buff *skb, struct genl_info *info)
                        return err;
        }
 
+       if (setup.user_mpm)
+               cfg.auto_open_plinks = false;
+
        if (info->attrs[NL80211_ATTR_WIPHY_FREQ]) {
                err = nl80211_parse_chandef(rdev, info, &setup.chandef);
                if (err)