From patchwork Thu May 11 17:49:31 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Pundir X-Patchwork-Id: 99663 Delivered-To: patch@linaro.org Received: by 10.140.96.100 with SMTP id j91csp851439qge; Thu, 11 May 2017 10:49:45 -0700 (PDT) X-Received: by 10.99.39.194 with SMTP id n185mr313654pgn.15.1494524985612; Thu, 11 May 2017 10:49:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1494524985; cv=none; d=google.com; s=arc-20160816; b=CX0gQC6gEUoDxkuE9ShjqhsvhQ3P5qJhNHld5MNtdrdGW0ZA7wr6Z6A/YDOf9dQnlL inQ9mhveWt52PIR4DqKtIGcFsD93znAuqYPZ2zz2qfydYCxIulxYXvMHEQYWZY0dDTb2 oPJz1gtFd+arliylOd7kiDFfJHnDHTCesTspRQIqdOU95VE2L74ZlZ5+NnRsmQfcCWlo QrcInBvsq31UVOdKSdKfdbuGpnb0QLJ37ABkX5PCxApGFOJScBZkLD2iNx9BsSXJaCAa BggNDW28+qCFAX7PWVzqX9WR8LRUlsOciIoDdYoF07q1s1pTN0omrKaN7k/js80wh2+9 dMRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=/hi5Xuo4QhYDGjxOrWJaimbaHAc/c386eqyAndc1Bec=; b=qZTkrTehoTldFAjYDFF+Nntz3rrz8MWNQclVlbFI6Zsi0sW+8t4FKfawwsR+UNadwI zILY0Y+kJLD+opUGO49prNHA8sysDKfkCLfXNmpuFYeOZ9kQgi7puK0TaDOYKXBzCD+X eDYm7IxXPGddxzikY5sSicE7zuspYormBJ26XCXehsdLOYg5vQZabBoFeQnokVQTbPrA mDvn+1wgSCUnntloRZsGrSAnCvTNbMSL7Gt7tV9j/qAMOQTCjCPumn5FDC/EAGZWmXLQ Mr/U7TNNbWzYteR0Qu1Shkxaj8PRl37KhL+71l0JAJSLrRSCnesK7NwcL4FNx3wn7uM9 u9+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g1si712796pgc.15.2017.05.11.10.49.44; Thu, 11 May 2017 10:49:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755157AbdEKRtn (ORCPT + 6 others); Thu, 11 May 2017 13:49:43 -0400 Received: from mail-pf0-f169.google.com ([209.85.192.169]:35935 "EHLO mail-pf0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755121AbdEKRtm (ORCPT ); Thu, 11 May 2017 13:49:42 -0400 Received: by mail-pf0-f169.google.com with SMTP id m17so17309586pfg.3 for ; Thu, 11 May 2017 10:49:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=/hi5Xuo4QhYDGjxOrWJaimbaHAc/c386eqyAndc1Bec=; b=HyDxjHXVm3z+u0U3jEi9FxuW/Z0H2m6/BDj4GPBjQJt8KARyFYFRHQWNFA1/b00VIM HMJP+Kg4LTNEOIcTvaYEtpJwv7+MO0cVJk3UAtDtVUVqx0ZvG7/241zG7RVoDJB8+rZP kFbEKrTsIVf7I7sBjonz0TIZa/W+lDhtPChQI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=/hi5Xuo4QhYDGjxOrWJaimbaHAc/c386eqyAndc1Bec=; b=lV/4bPbpA7l85Rspc9P/ToIEbcsyJVJqWrZ7ZBrKpdi1huSHr/jf4VBCiyaqjyzfos zL+Gv6j/pAhIvY7L86nA30nB/o4TWsJ55PfezRdyzB68TAc+Zq8OClEdh416O1gGB+LO 69uochwha2bq5Sk7px9yPuXz5wEq8YmYOQ6MHIM9rWQ+nqUs9EoMmv8A6oOzRzizcNFb d2H81eJnA9UjtK+llFhkib2IzIXj1caBsOAFAzLbPn3p4kU43SBVz/lqbmXGXWeRdlq9 s+kf/fcvMXVqTibbYkhc/w9Y2pt5iGbz1lVpAULS/BLPa4BF4B9NMHEwo4eOnkk4IOUM EA/g== X-Gm-Message-State: AODbwcCUKZf48TwpstI2koO2a4/rR7PVKuN3AGB10cwkgbwpjg9UbORW peBEB0FLegHuCTOZ X-Received: by 10.99.98.65 with SMTP id w62mr206462pgb.207.1494524982059; Thu, 11 May 2017 10:49:42 -0700 (PDT) Received: from localhost.localdomain ([106.51.135.126]) by smtp.gmail.com with ESMTPSA id b72sm1200986pfd.118.2017.05.11.10.49.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 11 May 2017 10:49:41 -0700 (PDT) From: Amit Pundir To: Greg KH Cc: Stable , Maxim Altshul , Sara Sharon , Emmanuel Grumbach , Johannes Berg Subject: [PATCH for-4.4 1/5] mac80211: pass RX aggregation window size to driver Date: Thu, 11 May 2017 23:19:31 +0530 Message-Id: <1494524975-2352-2-git-send-email-amit.pundir@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1494524975-2352-1-git-send-email-amit.pundir@linaro.org> References: <1494524975-2352-1-git-send-email-amit.pundir@linaro.org> Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Sara Sharon commit fad471860c097844432c7cf5d3ae6a0a059c2bdc upstream. Currently mac80211 does not inform the driver of the window size when starting an RX aggregation session. To enable managing the reorder buffer in the driver or hardware the window size is needed. Signed-off-by: Sara Sharon Signed-off-by: Emmanuel Grumbach Signed-off-by: Johannes Berg Signed-off-by: Amit Pundir --- include/net/mac80211.h | 8 +++++--- net/mac80211/agg-rx.c | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) -- 2.7.4 diff --git a/include/net/mac80211.h b/include/net/mac80211.h index 760bc4d5a2cf..9867667243de 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h @@ -3020,9 +3020,11 @@ enum ieee80211_reconfig_type { * ieee80211_ampdu_mlme_action. Starting sequence number (@ssn) * is the first frame we expect to perform the action on. Notice * that TX/RX_STOP can pass NULL for this parameter. - * The @buf_size parameter is only valid when the action is set to - * %IEEE80211_AMPDU_TX_OPERATIONAL and indicates the peer's reorder - * buffer size (number of subframes) for this session -- the driver + * The @buf_size parameter is valid only when the action is set to + * %IEEE80211_AMPDU_RX_START or %IEEE80211_AMPDU_TX_OPERATIONAL and + * indicates the reorder buffer size (number of subframes) for this + * session. + * When the action is set to %IEEE80211_AMPDU_TX_OPERATIONAL the driver * may neither send aggregates containing more subframes than this * nor send aggregates in a way that lost frames would exceed the * buffer size. If just limiting the aggregate size, this would be diff --git a/net/mac80211/agg-rx.c b/net/mac80211/agg-rx.c index 367784be5df2..7def8b892d25 100644 --- a/net/mac80211/agg-rx.c +++ b/net/mac80211/agg-rx.c @@ -323,7 +323,7 @@ void __ieee80211_start_rx_ba_session(struct sta_info *sta, __skb_queue_head_init(&tid_agg_rx->reorder_buf[i]); ret = drv_ampdu_action(local, sta->sdata, IEEE80211_AMPDU_RX_START, - &sta->sta, tid, &start_seq_num, 0, false); + &sta->sta, tid, &start_seq_num, buf_size, false); ht_dbg(sta->sdata, "Rx A-MPDU request on %pM tid %d result %d\n", sta->sta.addr, tid, ret); if (ret) {