From patchwork Fri Aug 9 14:35:15 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Wunderlich X-Patchwork-Id: 2841967 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 43E0ABF547 for ; Fri, 9 Aug 2013 14:36:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 26037202B3 for ; Fri, 9 Aug 2013 14:36:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D76972027F for ; Fri, 9 Aug 2013 14:36:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030640Ab3HIOgI (ORCPT ); Fri, 9 Aug 2013 10:36:08 -0400 Received: from cora.hrz.tu-chemnitz.de ([134.109.228.40]:35725 "EHLO cora.hrz.tu-chemnitz.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030622Ab3HIOgE (ORCPT ); Fri, 9 Aug 2013 10:36:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tu-chemnitz.de; s=dkim2010; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From; bh=OMxCkgcdqjGZ55qWhihaExyceQFGgnV+gJ8ZmNP1F3M=; b=B7vB9/d73XwlWA0ACh5/1w8+2QGPmWsMY2SMvaqmNbiCKS6ZuPqpuQJ/1lMrYc2I6jWbLKjxHTJ7/9wlVA33rq4UCcyHu7MxN3DBLBKomuEhPAGpXUYIQBxSrYPlsB4DoLDx0fZ358jjuAG73BFmKn6TpFAhvJWyiRGuTKaykNQ=; Received: from p4ffe4ab9.dip0.t-ipconnect.de ([79.254.74.185] helo=pandem0nium) by cora.hrz.tu-chemnitz.de with esmtpsa (TLSv1:DHE-RSA-AES128-SHA:128) (Exim 4.80.1) (envelope-from ) id 1V7nnP-0000BG-KT; Fri, 09 Aug 2013 16:36:03 +0200 Received: from dotslash by pandem0nium with local (Exim 4.80) (envelope-from ) id 1V7nnM-0004eN-HJ; Fri, 09 Aug 2013 16:36:00 +0200 From: Simon Wunderlich To: linux-wireless@vger.kernel.org Cc: Johannes Berg , Mathias Kretschmer , Simon Wunderlich Subject: [PATCHv2 1/6] cfg80211: export cfg80211_chandef_dfs_required Date: Fri, 9 Aug 2013 16:35:15 +0200 Message-Id: <1376058920-17779-2-git-send-email-siwu@hrz.tu-chemnitz.de> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1376058920-17779-1-git-send-email-siwu@hrz.tu-chemnitz.de> References: <1376058920-17779-1-git-send-email-siwu@hrz.tu-chemnitz.de> X-purgate: clean X-purgate-type: clean X-purgate-ID: 154106::1376058963-0000051A-59D5B26A/0-0/0-0 X-Scan-AV: cora.hrz.tu-chemnitz.de; 2013-08-09 16:36:03; ce79e5ddafab2c6678b318573062706b X-Scan-SA: cora.hrz.tu-chemnitz.de; 2013-08-09 16:36:03; 2921f9422d42f680f9e4f039e0c1ba52 X-Spam-Score: -1.0 (-) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP It will be used later by the IBSS CSA implementation of mac80211. Signed-off-by: Simon Wunderlich Signed-off-by: Mathias Kretschmer --- Changes to PATCHv1: * remove one more newline in net/wireless/core.h --- include/net/cfg80211.h | 9 +++++++++ net/wireless/chan.c | 1 + net/wireless/core.h | 9 --------- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index b7495c7..3dd8fa3 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h @@ -437,6 +437,15 @@ bool cfg80211_chandef_usable(struct wiphy *wiphy, u32 prohibited_flags); /** + * cfg80211_chandef_dfs_required - checks if radar detection is required + * @wiphy: the wiphy to validate against + * @chandef: the channel definition to check + * Return: 1 if radar detection is required, 0 if it is not, < 0 on error + */ +int cfg80211_chandef_dfs_required(struct wiphy *wiphy, + const struct cfg80211_chan_def *c); + +/** * ieee80211_chandef_rate_flags - returns rate flags for a channel * * In some channel types, not all rates may be used - for example CCK diff --git a/net/wireless/chan.c b/net/wireless/chan.c index 50f6195..16f3c3a 100644 --- a/net/wireless/chan.c +++ b/net/wireless/chan.c @@ -328,6 +328,7 @@ int cfg80211_chandef_dfs_required(struct wiphy *wiphy, return cfg80211_get_chans_dfs_required(wiphy, chandef->center_freq2, width); } +EXPORT_SYMBOL(cfg80211_chandef_dfs_required); static bool cfg80211_secondary_chans_ok(struct wiphy *wiphy, u32 center_freq, u32 bandwidth, diff --git a/net/wireless/core.h b/net/wireless/core.h index 9ad43c6..b43efac 100644 --- a/net/wireless/core.h +++ b/net/wireless/core.h @@ -382,15 +382,6 @@ int cfg80211_can_use_iftype_chan(struct cfg80211_registered_device *rdev, enum cfg80211_chan_mode chanmode, u8 radar_detect); -/** - * cfg80211_chandef_dfs_required - checks if radar detection is required - * @wiphy: the wiphy to validate against - * @chandef: the channel definition to check - * Return: 1 if radar detection is required, 0 if it is not, < 0 on error - */ -int cfg80211_chandef_dfs_required(struct wiphy *wiphy, - const struct cfg80211_chan_def *c); - void cfg80211_set_dfs_state(struct wiphy *wiphy, const struct cfg80211_chan_def *chandef, enum nl80211_dfs_state dfs_state);