From patchwork Mon Nov 27 17:56:23 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthias Schiffer X-Patchwork-Id: 10077711 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 42E06602BD for ; Mon, 27 Nov 2017 17:57:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 370692853A for ; Mon, 27 Nov 2017 17:57:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2B65C28AC6; Mon, 27 Nov 2017 17:57:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 28BFD2853A for ; Mon, 27 Nov 2017 17:57:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=M8xN53KxwWxnVCSohn49ESCs7ZvbE1WxRORcrCPANPU=; b=ONcD6t5qTPb869y8QBvJcOSlH+ I0mBs5bb82stXYFDZzY8kf6VnSZ4+iAlmobYt531enJPhROBDdZUFymr5LC2/6QoJt4uzqmz/n7so nW1j17yIZyNm2Ng2+C2fGPIkspKu85FZQCDheBs6Cf4Z1f0d+LZOOQCZZoj/QQvJx7uov6PDkuHkK u88OfNyfPHsayYBw8wvOlLLxztcpGR6mPUsLxA8uGgZNiDSn/tNu8z/6H1XyX2faWsSw9jxHEuYRp i+uWx8kkr/OucP5Lvry/9hiHjiNwtokEr0drUC5hmj9hyJottaRslV5d97U8jALU5/DpuptgpEx/i svma+nUQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1eJNeS-0007Cn-SI; Mon, 27 Nov 2017 17:57:04 +0000 Received: from chaos.universe-factory.net ([2001:678:3b8:ff00::13]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eJNeN-0007AM-BX for ath10k@lists.infradead.org; Mon, 27 Nov 2017 17:57:01 +0000 Received: from localhost.localdomain (unknown [IPv6:2a00:c1a0:8084:2700:688b:f9c4:45d6:d265]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by chaos.universe-factory.net (Postfix) with ESMTPSA id B401B187FD8; Mon, 27 Nov 2017 18:56:31 +0100 (CET) From: Matthias Schiffer To: kvalo@qca.qualcomm.com Subject: [PATCH 3/3] ath10k: move spectral scan support under a separate config symbol Date: Mon, 27 Nov 2017 18:56:23 +0100 Message-Id: X-Mailer: git-send-email 2.15.0 In-Reply-To: References: In-Reply-To: References: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171127_095659_721811_BCBE5EE8 X-CRM114-Status: GOOD ( 12.38 ) X-BeenThere: ath10k@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: netdev@vger.kernel.org, linux-wireless@vger.kernel.org, ath9k-devel@qca.qualcomm.com, ath10k@lists.infradead.org, linux-kernel@vger.kernel.org, nbd@nbd.name MIME-Version: 1.0 Sender: "ath10k" Errors-To: ath10k-bounces+patchwork-ath10k=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP At the moment, spectral scan support, and with it RELAY, is always enabled with ATH10K_DEBUGFS. Spectral scan support is currently the only user of RELAY in ath10k, and it unconditionally reserves a relay channel. Having debugfs support in ath10k is often useful even on very small embedded routers, where we'd rather like to avoid the code size and RAM usage of the relay support. While ath10k-based devices usually have more resources than ath9k-based ones, it makes sense to keep the configuration symmetric to ath9k, so the same base kernel without RELAY can be used for both ath9k and ath10k hardware. Signed-off-by: Matthias Schiffer --- checkpatch.pl wants me to write a more meaningful description for ATH10K_SPECTRAL, but I don't actually know enough about the spectral scan feature to do so... drivers/net/wireless/ath/ath10k/Kconfig | 9 ++++++++- drivers/net/wireless/ath/ath10k/Makefile | 2 +- drivers/net/wireless/ath/ath10k/spectral.h | 4 ++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/Kconfig b/drivers/net/wireless/ath/ath10k/Kconfig index 87f56d0e17a6..deb5ae21a559 100644 --- a/drivers/net/wireless/ath/ath10k/Kconfig +++ b/drivers/net/wireless/ath/ath10k/Kconfig @@ -47,12 +47,19 @@ config ATH10K_DEBUG config ATH10K_DEBUGFS bool "Atheros ath10k debugfs support" depends on ATH10K && DEBUG_FS - select RELAY ---help--- Enabled debugfs support If unsure, say Y to make it easier to debug problems. +config ATH10K_SPECTRAL + bool "Atheros ath10k spectral scan support" + depends on ATH10K_DEBUGFS + select RELAY + default n + ---help--- + Say Y to enable access to the FFT/spectral data via debugfs. + config ATH10K_TRACING bool "Atheros ath10k tracing support" depends on ATH10K diff --git a/drivers/net/wireless/ath/ath10k/Makefile b/drivers/net/wireless/ath/ath10k/Makefile index 899b9b79f4ce..af8f11970a08 100644 --- a/drivers/net/wireless/ath/ath10k/Makefile +++ b/drivers/net/wireless/ath/ath10k/Makefile @@ -14,7 +14,7 @@ ath10k_core-y += mac.o \ p2p.o \ swap.o -ath10k_core-$(CONFIG_ATH10K_DEBUGFS) += spectral.o +ath10k_core-$(CONFIG_ATH10K_SPECTRAL) += spectral.o ath10k_core-$(CONFIG_NL80211_TESTMODE) += testmode.o ath10k_core-$(CONFIG_ATH10K_TRACING) += trace.o ath10k_core-$(CONFIG_THERMAL) += thermal.o diff --git a/drivers/net/wireless/ath/ath10k/spectral.h b/drivers/net/wireless/ath/ath10k/spectral.h index 89b0ad769d4f..b2a2e8ae04b8 100644 --- a/drivers/net/wireless/ath/ath10k/spectral.h +++ b/drivers/net/wireless/ath/ath10k/spectral.h @@ -44,7 +44,7 @@ enum ath10k_spectral_mode { SPECTRAL_MANUAL, }; -#ifdef CONFIG_ATH10K_DEBUGFS +#ifdef CONFIG_ATH10K_SPECTRAL int ath10k_spectral_process_fft(struct ath10k *ar, struct wmi_phyerr_ev_arg *phyerr, @@ -85,6 +85,6 @@ static inline void ath10k_spectral_destroy(struct ath10k *ar) { } -#endif /* CONFIG_ATH10K_DEBUGFS */ +#endif /* CONFIG_ATH10K_SPECTRAL */ #endif /* SPECTRAL_H */