From patchwork Tue Nov 22 06:54:16 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Kirtika Ruchandani X-Patchwork-Id: 9440551 X-Patchwork-Delegate: johannes@sipsolutions.net 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 362A0600BA for ; Tue, 22 Nov 2016 06:54:31 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2CEBB2434C for ; Tue, 22 Nov 2016 06:54:31 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 207432843A; Tue, 22 Nov 2016 06:54:31 +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=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A9BD72434C for ; Tue, 22 Nov 2016 06:54:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754521AbcKVGyY (ORCPT ); Tue, 22 Nov 2016 01:54:24 -0500 Received: from mail-pf0-f196.google.com ([209.85.192.196]:34697 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752529AbcKVGyX (ORCPT ); Tue, 22 Nov 2016 01:54:23 -0500 Received: by mail-pf0-f196.google.com with SMTP id y68so786306pfb.1; Mon, 21 Nov 2016 22:54:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:date:to:cc:subject:message-id:mime-version:content-disposition :content-transfer-encoding:user-agent; bh=X/IWkYzdizzXx+Ota/G4iK9GzACV0vpqUZYI+62v1qM=; b=we3oMd9k2Gz9u/LLIVUNB9K9JLS0byvz3LS7PUum324/npRUWQ4rYH9QV+b4Nf2u9d BoUS/ZsvhcKuzro9jz43Vm0xLoJSh0M+7BSxH2bMVbY3kxJxlWzaMVtD8nhmXfLrusr7 70Y4RSvI1NGuWAzM/heeYbfrTEi2BHBCXCeWFAEnr2dLAnHJoFgxKMsaCG1PuKxw0qDZ 3J0nkV3K7BggO0ZcxccwXngC+zBZwT1cAF+VSIhJx7X5xJG9hzZbnD1yP8bBmEaqkYHp TSiikoK6tQ1OJvqr31tjW2JQTT/0bvzBItGsp2SKEAHfrm4e1KhowFanYnTWdBQvXC1T aq5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:date:to:cc:subject:message-id:mime-version :content-disposition:content-transfer-encoding:user-agent; bh=X/IWkYzdizzXx+Ota/G4iK9GzACV0vpqUZYI+62v1qM=; b=efs81Vp6Wrcm+nzZE/PCAEhmhBMWi7hCOdfUWt8h2NHLvckEDqFS7TiuYQjgatb6wL T7Av99K1gT1FekKZX0BrcxyjTdCbRfmEpsf5M5+ugEAPZeT3lPfomObUUUefLtM2PSi4 Akmg5xY5MvEo0zvJe7HXoi5BN22AuRQVXy2+mYxxLsArRR6kqpgUBp5Plmnks1Yqwift 5TvCuL5j72ZbwjrroJuoNwdAOX1XR4dDc20BGeih5DXNokqC63FtUESdE6oWOu/Vnq3F x3ok19unHEV3RBJzswHEnYifCgVZ9+DTm+lh/TYhbli5Qj/H6sEzls3fZ42eLPPkse2E 6t5w== X-Gm-Message-State: AKaTC02SmfMu7D3J1F2YNd5qwOcEGTMPadvzj32F49EVZyfbC7yL5DFI43lQuUo1n+mWWw== X-Received: by 10.98.89.129 with SMTP id k1mr23311127pfj.180.1479797662759; Mon, 21 Nov 2016 22:54:22 -0800 (PST) Received: from google.com ([2620:0:1000:1301:6c91:e255:ba2e:d0aa]) by smtp.gmail.com with ESMTPSA id j133sm24145658pgc.26.2016.11.21.22.54.20 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Mon, 21 Nov 2016 22:54:21 -0800 (PST) From: Kirtika Ruchandani X-Google-Original-From: Kirtika Ruchandani Date: Mon, 21 Nov 2016 22:54:16 -0800 To: Johannes Berg Cc: Arnd Bergmann , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, Maxim Altshul , Johannes Berg Subject: [PATCH] mac80211: Remove unused 'struct rate_control_ref' variable Message-ID: <20161122065416.GA3565@google.com> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Commit 3b17fbf87d5d introduced sta_get_expected_throughput() leaving variable 'struct rate_control_ref* ref' set but unused. Compiling with W=1 gives the following warning, fix it. net/mac80211/sta_info.c: In function ‘sta_set_sinfo’: net/mac80211/sta_info.c:2052:27: warning: variable ‘ref’ set but not used [-Wunused-but-set-variable] Fixes: 3b17fbf87d5d ("mac80211: mesh: Add support for HW RC implementation") Cc: Johannes Berg Cc: Maxim Altshul Signed-off-by: Kirtika Ruchandani --- net/mac80211/sta_info.c | 4 ---- 1 file changed, 4 deletions(-) -- 2.8.0.rc3.226.g39d4020 diff --git a/net/mac80211/sta_info.c b/net/mac80211/sta_info.c index 1711bae..4ab75a9 100644 --- a/net/mac80211/sta_info.c +++ b/net/mac80211/sta_info.c @@ -2049,16 +2049,12 @@ void sta_set_sinfo(struct sta_info *sta, struct station_info *sinfo) { struct ieee80211_sub_if_data *sdata = sta->sdata; struct ieee80211_local *local = sdata->local; - struct rate_control_ref *ref = NULL; u32 thr = 0; int i, ac, cpu; struct ieee80211_sta_rx_stats *last_rxstats; last_rxstats = sta_get_last_rx_stats(sta); - if (test_sta_flag(sta, WLAN_STA_RATE_CONTROL)) - ref = local->rate_ctrl; - sinfo->generation = sdata->local->sta_generation; /* do before driver, so beacon filtering drivers have a