From patchwork Tue Jan 20 14:05:08 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mathy Vanhoef X-Patchwork-Id: 5669701 X-Patchwork-Delegate: johannes@sipsolutions.net Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id E913D9F357 for ; Tue, 20 Jan 2015 14:05:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2D1BB2037D for ; Tue, 20 Jan 2015 14:05:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4890120351 for ; Tue, 20 Jan 2015 14:05:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751465AbbATOFN (ORCPT ); Tue, 20 Jan 2015 09:05:13 -0500 Received: from mail-we0-f171.google.com ([74.125.82.171]:63706 "EHLO mail-we0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750777AbbATOFM (ORCPT ); Tue, 20 Jan 2015 09:05:12 -0500 Received: by mail-we0-f171.google.com with SMTP id u56so37553847wes.2 for ; Tue, 20 Jan 2015 06:05:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject :content-type:content-transfer-encoding; bh=+GwoCTa2iVYAI1lSl0mvophCbfukgHhn1dl1Db2/tAQ=; b=Z2+bRtIvlvOpoo8psBFiN/zppnD9UChPAToCi18ajjZqpkBoAK1zAZ8MaVwdWXBuFO GUx2DrFkLif2MKslE7G76KJL11k5h/1AB9dPK5acNZjntzmRNFN1A32W6uvh0PgMfQBS EikXg6YYqS4aNT2l11g3KfmDDCfPUREvh/gw/k0vimhQmsiKm6eB1VAExyTJzpwf2R3k jEOC0X1J3bDoY7f40G/Hv5aFe5zmrdLwnkEx6dna5WHD8gqe7yqSPuDM9D/u46KP1gLC 52lZPuLJcQzQl8vzzXZq2HrBtj/ciSFf+NtQhAoOSRbiOWiazh97NCphZfM9ziZ1jiG9 +KXw== X-Received: by 10.194.24.103 with SMTP id t7mr45731843wjf.15.1421762710898; Tue, 20 Jan 2015 06:05:10 -0800 (PST) Received: from ?IPv6:2a02:2c40:100:a000:d95f:5f52:3208:f8ce? ([2a02:2c40:100:a000:d95f:5f52:3208:f8ce]) by mx.google.com with ESMTPSA id d7sm9121987wjs.2.2015.01.20.06.05.09 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 20 Jan 2015 06:05:10 -0800 (PST) Message-ID: <54BE6094.6010001@gmail.com> Date: Tue, 20 Jan 2015 15:05:08 +0100 From: Mathy Vanhoef User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130801 Thunderbird/17.0.8 MIME-Version: 1.0 To: johannes@sipsolutions.net, linux-wireless@vger.kernel.org Subject: [PATCH] mac80211: properly set CCK flag in radiotap 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_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, 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 Fix a regression introduced by commit a5e70697d0c4 ("mac80211: add radiotap flag and handling for 5/10 MHz") where the IEEE80211_CHAN_CCK channel type flag was incorrectly replaced by the IEEE80211_CHAN_OFDM flag. This commit fixes that by using the CCK flag again. Signed-off-by: Mathy Vanhoef --- net/mac80211/rx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index a37f9af..2d23d33 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -235,7 +235,7 @@ ieee80211_add_rx_radiotap_header(struct ieee80211_local *local, else if (rate && rate->flags & IEEE80211_RATE_ERP_G) channel_flags |= IEEE80211_CHAN_OFDM | IEEE80211_CHAN_2GHZ; else if (rate) - channel_flags |= IEEE80211_CHAN_OFDM | IEEE80211_CHAN_2GHZ; + channel_flags |= IEEE80211_CHAN_CCK | IEEE80211_CHAN_2GHZ; else channel_flags |= IEEE80211_CHAN_2GHZ; put_unaligned_le16(channel_flags, pos);