From patchwork Mon Sep 20 22:22:26 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Lamparter X-Patchwork-Id: 195952 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o8KMMgNe013683 for ; Mon, 20 Sep 2010 22:22:42 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754495Ab0ITWWd (ORCPT ); Mon, 20 Sep 2010 18:22:33 -0400 Received: from mail-bw0-f46.google.com ([209.85.214.46]:33421 "EHLO mail-bw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753728Ab0ITWWc (ORCPT ); Mon, 20 Sep 2010 18:22:32 -0400 Received: by bwz11 with SMTP id 11so4662757bwz.19 for ; Mon, 20 Sep 2010 15:22:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:received:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:content-type :content-transfer-encoding:message-id; bh=3WtKSCMWHh/YrC/JCneXrEuE3IDPEvhRXpDwJ+O6pZ4=; b=HBPhao2d1SKIZCCnaVvzXOj2HzmvfmpAImH8KaigH5eQwT3XEdX4yDpVfvrx5tKt+P 9QUgmGaO6bAlef6w+xf+dpL3sWcurk1rMNaSh27tfoMsqpb3tPGFiGn4oXLVooGHk06n Dc+gTiwXI/XUSL1YETL5jaG8ToP2x5vei3O5s= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding:message-id; b=ONzP0fVrPMAPmQKB0HuPEn75xAmnwsNJEZJmooXK31f4z1uUwxPm6QKOqKL3LqPymw 9duh+tRGa9N9OU0+Wj54PDtSLnxRszBYRtAuJvwwNziGTjt0qfmhriGTst3djkOe0uQA Aeghk+3fs0U+sYjpk+5w0Jb/wMwGg4TDVI2Zo= Received: by 10.204.119.134 with SMTP id z6mr6996985bkq.193.1285021350509; Mon, 20 Sep 2010 15:22:30 -0700 (PDT) Received: from debian64.daheim (p549CCCB0.dip.t-dialin.net [84.156.204.176]) by mx.google.com with ESMTPS id x19sm6975153bkv.9.2010.09.20.15.22.29 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 20 Sep 2010 15:22:29 -0700 (PDT) Received: from debian64.daheim ([192.168.0.4] helo=debian64.localnet ident=chuck) by debian64.daheim with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.72) (envelope-from ) id 1Oxokl-0006DE-VD; Tue, 21 Sep 2010 00:22:27 +0200 From: Christian Lamparter To: Johannes Berg Subject: [PATCH] mac80211: clear txflags for ps-filtered frames Date: Tue, 21 Sep 2010 00:22:26 +0200 User-Agent: KMail/1.13.5 (Linux/2.6.36-rc4-wl+; KDE/4.4.5; x86_64; ; ) Cc: linux-wireless@vger.kernel.org, "John W. Linville" References: <201009182133.50104.chunkeey@googlemail.com> <1284978231.3688.2.camel@jlt3.sipsolutions.net> In-Reply-To: <1284978231.3688.2.camel@jlt3.sipsolutions.net> MIME-Version: 1.0 Message-Id: <201009210022.27383.chunkeey@googlemail.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Mon, 20 Sep 2010 22:22:42 +0000 (UTC) diff --git a/include/net/mac80211.h b/include/net/mac80211.h index 12a49f0..5d1187d 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h @@ -321,6 +321,9 @@ struct ieee80211_bss_conf { * @IEEE80211_TX_CTL_LDPC: tells the driver to use LDPC for this frame * @IEEE80211_TX_CTL_STBC: Enables Space-Time Block Coding (STBC) for this * frame and selects the maximum number of streams that it can use. + * + * Note: If you have to add new flags to the enumeration, then don't + * forget to update %IEEE80211_TX_TEMPORARY_FLAGS when necessary. */ enum mac80211_tx_control_flags { IEEE80211_TX_CTL_REQ_TX_STATUS = BIT(0), @@ -350,6 +353,19 @@ enum mac80211_tx_control_flags { #define IEEE80211_TX_CTL_STBC_SHIFT 23 +/* + * This definition is used as a mask to clear all temporary flags, which are + * set by the tx handlers for each transmission attempt by the mac80211 stack. + */ +#define IEEE80211_TX_TEMPORARY_FLAGS (IEEE80211_TX_CTL_NO_ACK | \ + IEEE80211_TX_CTL_CLEAR_PS_FILT | IEEE80211_TX_CTL_FIRST_FRAGMENT | \ + IEEE80211_TX_CTL_SEND_AFTER_DTIM | IEEE80211_TX_CTL_AMPDU | \ + IEEE80211_TX_STAT_TX_FILTERED | IEEE80211_TX_STAT_ACK | \ + IEEE80211_TX_STAT_AMPDU | IEEE80211_TX_STAT_AMPDU_NO_BACK | \ + IEEE80211_TX_CTL_RATE_CTRL_PROBE | IEEE80211_TX_CTL_PSPOLL_RESPONSE | \ + IEEE80211_TX_CTL_MORE_FRAMES | IEEE80211_TX_CTL_LDPC | \ + IEEE80211_TX_CTL_STBC) + /** * enum mac80211_rate_control_flags - per-rate flags set by the * Rate Control algorithm. diff --git a/net/mac80211/agg-rx.c b/net/mac80211/agg-rx.c index 58eab9e..309ed70 100644 --- a/net/mac80211/agg-rx.c +++ b/net/mac80211/agg-rx.c @@ -129,9 +129,7 @@ static void sta_rx_agg_reorder_timer_expired(unsigned long data) timer_to_tid[0]); rcu_read_lock(); - spin_lock(&sta->lock); ieee80211_release_reorder_timeout(sta, *ptid); - spin_unlock(&sta->lock); rcu_read_unlock(); } diff --git a/net/mac80211/status.c b/net/mac80211/status.c index 571b32b..dd85006 100644 --- a/net/mac80211/status.c +++ b/net/mac80211/status.c @@ -58,6 +58,7 @@ static void ieee80211_handle_filtered_frame(struct ieee80211_local *local, info->control.vif = &sta->sdata->vif; info->flags |= IEEE80211_TX_INTFL_NEED_TXPROCESSING | IEEE80211_TX_INTFL_RETRANSMISSION; + info->flags &= ~IEEE80211_TX_TEMPORARY_FLAGS; sta->tx_filtered_count++;