Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp4294105pxy; Tue, 27 Apr 2021 01:15:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJytr8ASw1SJ3Lt9fhVcNHVFNUhwxXhAGL4blCg/Tp7ZiQcBd7r73hIpaUviiSSpmDx9I3RU X-Received: by 2002:a17:906:c148:: with SMTP id dp8mr22322624ejc.193.1619511331451; Tue, 27 Apr 2021 01:15:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619511331; cv=none; d=google.com; s=arc-20160816; b=LDFHKrtyu9U29+QRAJGz9XawTEVPENFj1DBT2T9lyaZL0GlLkiWjJLj9rninjaOjO9 ZilVHE+uxF6F8ASCpJATEbK4mK10naanZWVtyMaTQfvuMbd4bjdxW0t8iNn3rXT/aAVA oOORPHjq3env1ChETzDSve5/SdkQH0gWYnQIA/AF3t9KxtyQQLSPlejqsTeAoJoyQiSI SW0hLwxRDsYdREcsmH7au972WyUWjZaXDPgThDFzratwkubbmWDRt2lnij6ECBHEP9aR 6kTB3j6T5ha1MrtqzaDsx4hhclyCmk5YQzyLgmlOoL8Pk1b0FQLRuSlv32pKlw9qxSff 4q1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=07RKmapJWTopIz2gVmzJzG36kGAwBXId0uiyJDLJlZA=; b=qKl4BrKEiLOv1+NVMF8NP5SCPDpAOmMZyZWenIIFbQD3VwAt5EbAbXDq/s8kivCVKR oFyjaH1LulQLYjgS55OjnJOw0EWKIy4RhoFajbDpM1GEc65CrgZJwH3QiIFOPt4fDYe5 hYtxyNfTauKzHizS8Xp8ANr3ovxOls6CvoUnP9OnFgxOQxHs1w0/Ri5RfAPrh62MKIKe fht4DGBEm5mPd0YMIeyJNoEvnXjEQ25W1ADGB2tfUCS3RsKLhb3aya8a6kCEmblGS8tR 9zNT51TVq+cAUfYPl1Vh9SvLqlZg+6bPiNq1RO+G8PZfnVvXrt7ILZdNJMFFkue9oR3W m89A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@nbd.name header.s=20160729 header.b=QKE+33mV; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o6si602715ejr.598.2021.04.27.01.15.07; Tue, 27 Apr 2021 01:15:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@nbd.name header.s=20160729 header.b=QKE+33mV; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234561AbhD0ILt (ORCPT + 99 others); Tue, 27 Apr 2021 04:11:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55560 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229629AbhD0ILr (ORCPT ); Tue, 27 Apr 2021 04:11:47 -0400 Received: from nbd.name (nbd.name [IPv6:2a01:4f8:221:3d45::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 46E92C061574 for ; Tue, 27 Apr 2021 01:11:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=nbd.name; s=20160729; h=Content-Transfer-Encoding:Content-Type:In-Reply-To: MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=07RKmapJWTopIz2gVmzJzG36kGAwBXId0uiyJDLJlZA=; b=QKE+33mVv6Ype/XoL1Jfx2uShW a9pMlZl9eLxgXzOwVuCNBwGkznYSA5xN7xmlMd5uS7w5qcUyFvPmbacYwWc5znKHp9DvduMz9qHUk a2KOwH+x39ms+yA9LMxPTiNoh8T4fqgYQe732OM/6R1cMYsXPRSQIawxsJi0fBRm5mSg=; Received: from p4ff13bc6.dip0.t-ipconnect.de ([79.241.59.198] helo=nf.local) by ds12 with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1lbIo7-00077p-VZ; Tue, 27 Apr 2021 10:11:00 +0200 Subject: Re: [PATCH] mac80211: minstrel_ht: fix minstrel_aggr_check for encap offload To: Ryder Lee Cc: Johannes Berg , Lorenzo Bianconi , Shayne Chen , linux-wireless@vger.kernel.org, linux-mediatek@lists.infradead.org References: From: Felix Fietkau Message-ID: <6d94a83a-c807-13a5-a2aa-d5adb780ba80@nbd.name> Date: Tue, 27 Apr 2021 10:10:58 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On 2021-04-27 04:20, Ryder Lee wrote: > Avoid checking ieee80211_hdr to support encap offload. > > Signed-off-by: Ryder Lee > --- > net/mac80211/rc80211_minstrel_ht.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/net/mac80211/rc80211_minstrel_ht.c b/net/mac80211/rc80211_minstrel_ht.c > index ecad9b10984f..02a6648aba54 100644 > --- a/net/mac80211/rc80211_minstrel_ht.c > +++ b/net/mac80211/rc80211_minstrel_ht.c > @@ -1180,20 +1180,19 @@ minstrel_downgrade_rate(struct minstrel_ht_sta *mi, u16 *idx, bool primary) > static void > minstrel_aggr_check(struct ieee80211_sta *pubsta, struct sk_buff *skb) > { > - struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; > struct sta_info *sta = container_of(pubsta, struct sta_info, sta); > u16 tid; > > if (skb_get_queue_mapping(skb) == IEEE80211_AC_VO) > return; > > - if (unlikely(!ieee80211_is_data_qos(hdr->frame_control))) > + if (unlikely(!pubsta->wme)) The ieee80211_is_data_qos check should still be performed for non-offloaded packets to avoid triggering on management frames. - Felix