All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Pedersen <thomas@cozybit.com>
To: johannes@sipsolution.net
Cc: linux-wireless@vger.kernel.org, Thomas Pedersen <thomas@cozybit.com>
Subject: [PATCH v2 5/5] mac80211: disallow changing auto_open_plinks
Date: Mon,  4 Mar 2013 13:06:14 -0800	[thread overview]
Message-ID: <1362431174-4747-5-git-send-email-thomas@cozybit.com> (raw)
In-Reply-To: <1362431174-4747-1-git-send-email-thomas@cozybit.com>

while user MPM is running.

Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
---
 net/mac80211/cfg.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c
index 89c7b00..ebfb060 100644
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -1773,8 +1773,11 @@ static int ieee80211_update_mesh_config(struct wiphy *wiphy,
 		conf->dot11MeshTTL = nconf->dot11MeshTTL;
 	if (_chg_mesh_attr(NL80211_MESHCONF_ELEMENT_TTL, mask))
 		conf->element_ttl = nconf->element_ttl;
-	if (_chg_mesh_attr(NL80211_MESHCONF_AUTO_OPEN_PLINKS, mask))
+	if (_chg_mesh_attr(NL80211_MESHCONF_AUTO_OPEN_PLINKS, mask)) {
+		if (ifmsh->user_mpm)
+			return -EBUSY;
 		conf->auto_open_plinks = nconf->auto_open_plinks;
+	}
 	if (_chg_mesh_attr(NL80211_MESHCONF_SYNC_OFFSET_MAX_NEIGHBOR, mask))
 		conf->dot11MeshNbrOffsetMaxNeighbor =
 			nconf->dot11MeshNbrOffsetMaxNeighbor;
-- 
1.7.10.4


  parent reply	other threads:[~2013-03-04 21:08 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-04 21:06 [PATCH v2 1/5] nl80211: explicit userspace MPM Thomas Pedersen
2013-03-04 21:06 ` [PATCH v2 2/5] cfg80211: rename mesh station types Thomas Pedersen
2013-03-04 21:06 ` [PATCH v2 3/5] mac80211: support userspace MPM Thomas Pedersen
2013-03-04 21:06 ` [PATCH v2 4/5] nl80211: user_mpm overrides auto_open_plinks Thomas Pedersen
2013-03-04 21:06 ` Thomas Pedersen [this message]
2013-03-05 18:58 ` [PATCH v2 1/5] nl80211: explicit userspace MPM Johannes Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1362431174-4747-5-git-send-email-thomas@cozybit.com \
    --to=thomas@cozybit.com \
    --cc=johannes@sipsolution.net \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.