From patchwork Tue Jul 10 17:23:10 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Luis R. Rodriguez" X-Patchwork-Id: 1178611 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id B8A5F40B37 for ; Tue, 10 Jul 2012 17:24:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756538Ab2GJRYj (ORCPT ); Tue, 10 Jul 2012 13:24:39 -0400 Received: from wolverine02.qualcomm.com ([199.106.114.251]:26001 "EHLO wolverine02.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756509Ab2GJRYj (ORCPT ); Tue, 10 Jul 2012 13:24:39 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qca.qualcomm.com; i=@qca.qualcomm.com; q=dns/txt; s=qcdkim; t=1341941080; x=1373477080; h=cc:from:to:subject:date:message-id:in-reply-to: references:mime-version; bh=g9c9bPYSHypzUe8REzGo3T/OP6nGAO5PG3j/u38WHtk=; b=F21dflt3y3s8LFY0xOeKReTM5AEP1pgvzhEjC87Hd4ZQ2ZrbnDnquNxH Mlh1IIc0f81+cqa9yW8H09CLTaYmwUfr8ICOPFeyt32yWFfbymviQQ1Mj aPmXGuQMVvBFGXisLs+HdTfdrBjZMcdWGrhrD4HpvR22wBrtJmQ+Wel8N 0=; X-IronPort-AV: E=McAfee;i="5400,1158,6768"; a="206784957" Received: from ironmsg02-r.qualcomm.com ([172.30.46.16]) by wolverine02.qualcomm.com with ESMTP; 10 Jul 2012 10:24:39 -0700 Cc: , , , , , "Luis R. Rodriguez" X-IronPort-AV: E=Sophos;i="4.77,560,1336374000"; d="scan'208";a="159990227" Received: from nasanexhc08.na.qualcomm.com ([172.30.39.7]) by ironmsg02-R.qualcomm.com with ESMTP/TLS/RC4-SHA; 10 Jul 2012 10:24:39 -0700 Received: from tux (172.30.39.5) by qcmail1.qualcomm.com (172.30.39.7) with Microsoft SMTP Server (TLS) id 14.2.309.2; Tue, 10 Jul 2012 10:24:37 -0700 Received: by tux (sSMTP sendmail emulation); Tue, 10 Jul 2012 10:24:36 -0700 From: "Luis R. Rodriguez" To: , Subject: [PATCH v4 4/5] cfg80211: make regulatory_update() static Date: Tue, 10 Jul 2012 10:23:10 -0700 Message-ID: <1341940991-11234-5-git-send-email-rodrigue@qca.qualcomm.com> X-Mailer: git-send-email 1.7.10.rc1.22.gf5241 In-Reply-To: <1341940991-11234-1-git-send-email-rodrigue@qca.qualcomm.com> References: <1341940991-11234-1-git-send-email-rodrigue@qca.qualcomm.com> MIME-Version: 1.0 X-Originating-IP: [172.30.39.5] Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: "Luis R. Rodriguez" Now that we have wiphy_regulatory_register() we can tuck away the core's regulatory_update() call there and make it static. Signed-off-by: Luis R. Rodriguez --- net/wireless/core.c | 1 - net/wireless/reg.c | 6 ++++-- net/wireless/reg.h | 1 - 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/net/wireless/core.c b/net/wireless/core.c index 5b4463e..b7dc646 100644 --- a/net/wireless/core.c +++ b/net/wireless/core.c @@ -538,7 +538,6 @@ int wiphy_register(struct wiphy *wiphy) /* set up regulatory info */ wiphy_regulatory_register(wiphy); - regulatory_update(wiphy, NL80211_REGDOM_SET_BY_CORE); list_add_rcu(&rdev->list, &cfg80211_rdev_list); cfg80211_rdev_list_generation++; diff --git a/net/wireless/reg.c b/net/wireless/reg.c index 43b7750..b0a09b2 100644 --- a/net/wireless/reg.c +++ b/net/wireless/reg.c @@ -1232,8 +1232,8 @@ static void wiphy_update_regulatory(struct wiphy *wiphy, wiphy->reg_notifier(wiphy, last_request); } -void regulatory_update(struct wiphy *wiphy, - enum nl80211_reg_initiator setby) +static void regulatory_update(struct wiphy *wiphy, + enum nl80211_reg_initiator setby) { mutex_lock(®_mutex); wiphy_update_regulatory(wiphy, setby); @@ -2385,6 +2385,8 @@ void wiphy_regulatory_register(struct wiphy *wiphy) reg_num_devs_support_basehint++; mutex_unlock(®_mutex); + + regulatory_update(wiphy, NL80211_REGDOM_SET_BY_CORE); } /* Caller must hold cfg80211_mutex */ diff --git a/net/wireless/reg.h b/net/wireless/reg.h index f36b15f..f023c8a 100644 --- a/net/wireless/reg.h +++ b/net/wireless/reg.h @@ -34,7 +34,6 @@ void regulatory_exit(void); int set_regdom(const struct ieee80211_regdomain *rd); -void regulatory_update(struct wiphy *wiphy, enum nl80211_reg_initiator setby); bool reg_last_request_cell_base(void); /**