From patchwork Mon Mar 4 21:06:14 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Pedersen X-Patchwork-Id: 2214551 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 26E2DDF2F2 for ; Mon, 4 Mar 2013 21:08:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932493Ab3CDVIE (ORCPT ); Mon, 4 Mar 2013 16:08:04 -0500 Received: from mail-pb0-f51.google.com ([209.85.160.51]:53437 "EHLO mail-pb0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932328Ab3CDVIC (ORCPT ); Mon, 4 Mar 2013 16:08:02 -0500 Received: by mail-pb0-f51.google.com with SMTP id un15so3423910pbc.10 for ; Mon, 04 Mar 2013 13:08:01 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=0GI39aP+bo+9qou+4jIIZ9ERm/Hv/WrryzTk4vyUOkQ=; b=GjEQIEsMm6H7vsRbws18R1kEcbXS+GIqO+WfQ4e/XpHegDnsLjdfK5DkDFoNw7y8iN hr1VQnHMJspOjFtAPpcY065XCmY1zmYrpX2N4Sfs54UCm+/bHrLpP8ez/QaCChTEe8nk Qn52Wa6REeSMHNtVLksBoJAQX2Z0syTFsTOoFdg+y6GdvBzd0TR4JLWT91YQ8lYiKPkz Dxg2295dD0Xm73rrM6LgQu7n0vOH7hhDY3y9t1lSo89fJlXsjSoguHFqik9GP6GaK/op 7fO+S/ezvARzz6pcELsFxvM2u7Rowy0MaUDAzQEsaH5sXazGYxqmLdk3ZKcjeW4CcNhk xzvg== X-Received: by 10.68.143.197 with SMTP id sg5mr31369212pbb.101.1362431281450; Mon, 04 Mar 2013 13:08:01 -0800 (PST) Received: from cable.lan (70-35-43-50.static.wiline.com. [70.35.43.50]) by mx.google.com with ESMTPS id tm1sm23643807pbc.11.2013.03.04.13.07.59 (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 04 Mar 2013 13:08:00 -0800 (PST) From: Thomas Pedersen To: johannes@sipsolution.net Cc: linux-wireless@vger.kernel.org, Thomas Pedersen Subject: [PATCH v2 5/5] mac80211: disallow changing auto_open_plinks Date: Mon, 4 Mar 2013 13:06:14 -0800 Message-Id: <1362431174-4747-5-git-send-email-thomas@cozybit.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1362431174-4747-1-git-send-email-thomas@cozybit.com> References: <1362431174-4747-1-git-send-email-thomas@cozybit.com> X-Gm-Message-State: ALoCoQkgt/5pU2h0pfOgldtoojNWlGwxAmyNfeiMA9/hG1MSCUnuWIgLJfqwP3NzBjxrxh3QoEip Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org while user MPM is running. Signed-off-by: Thomas Pedersen --- 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;