From patchwork Sun Dec 21 13:25:28 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eliad Peller X-Patchwork-Id: 5524111 X-Patchwork-Delegate: johannes@sipsolutions.net 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 1CFA4BEEA8 for ; Sun, 21 Dec 2014 13:25:40 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 4E92120120 for ; Sun, 21 Dec 2014 13:25:39 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A37172011E for ; Sun, 21 Dec 2014 13:25:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752870AbaLUNZf (ORCPT ); Sun, 21 Dec 2014 08:25:35 -0500 Received: from mail-wi0-f174.google.com ([209.85.212.174]:44904 "EHLO mail-wi0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752675AbaLUNZe (ORCPT ); Sun, 21 Dec 2014 08:25:34 -0500 Received: by mail-wi0-f174.google.com with SMTP id h11so5885928wiw.7 for ; Sun, 21 Dec 2014 05:25:32 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=FxSXNEWYmrmMupoKe653xbZEcnAFyaVqVbuue2U4jP4=; b=jKFA0J9wUqTn78be/qklBI99QbKie4Qj9Iu8/VwWE/1oKwqUYhbeuXmajej9rmLiNu XePxPeomQ9GEM/xR4PSLmjoQ5LMlW4at+3fFGaAJT3LIaMLFNHR5ytUJH4KBaODAnaO5 4FAh4YQkCmakTTfGSZAJ08rdP98LkgJIr8OgbDgo/hQjnjl6vOH4lrbr4fLIljlGUYl0 ++xRSGPFE55VMQtG4oEaPysFI/NtI65466/akS+6eAu1me3rQ9kRJZ5q0D80XvWXe+1G ly/2Mk6rPwVVg+AHBu60pbDJkkWCpfkohIrdmU5L501b2kb42JmJUtTX8G8SM66EeQvJ w8/Q== X-Gm-Message-State: ALoCoQkQsQlvT2vHjvrzy4bVPm+DE7bu16ueQ+9XXJyLJUWSogOj/FTrbOiooiE4n4iR1i/BXF76 X-Received: by 10.180.8.70 with SMTP id p6mr23305914wia.72.1419168332862; Sun, 21 Dec 2014 05:25:32 -0800 (PST) Received: from localhost.localdomain (93-173-25-207.bb.netvision.net.il. [93.173.25.207]) by mx.google.com with ESMTPSA id be2sm18237882wjb.38.2014.12.21.05.25.31 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 21 Dec 2014 05:25:32 -0800 (PST) From: Eliad Peller To: Johannes Berg Cc: Subject: [PATCH] mac80211: fix dot11MulticastTransmittedFrameCount tested address Date: Sun, 21 Dec 2014 15:25:28 +0200 Message-Id: <1419168328-6114-1-git-send-email-eliad@wizery.com> X-Mailer: git-send-email 1.8.5.1.109.g3d252a9 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.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham 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 dot11MulticastTransmittedFrameCount should be updated according to the DA, which might be different from hdr1. (Checking hdr1 results in the counter being 0 in case of station, as TODS data frames use hdr1 for the bssid address) Signed-off-by: Eliad Peller --- net/mac80211/status.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/mac80211/status.c b/net/mac80211/status.c index d64037c..7d4e930 100644 --- a/net/mac80211/status.c +++ b/net/mac80211/status.c @@ -862,7 +862,7 @@ void ieee80211_tx_status(struct ieee80211_hw *hw, struct sk_buff *skb) (info->flags & IEEE80211_TX_STAT_NOACK_TRANSMITTED)) { if (ieee80211_is_first_frag(hdr->seq_ctrl)) { local->dot11TransmittedFrameCount++; - if (is_multicast_ether_addr(hdr->addr1)) + if (is_multicast_ether_addr(ieee80211_get_DA(hdr))) local->dot11MulticastTransmittedFrameCount++; if (retry_count > 0) local->dot11RetryCount++;