Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp4098214ybf; Tue, 3 Mar 2020 20:06:19 -0800 (PST) X-Google-Smtp-Source: ADFU+vv7w3iexQyQRVWZFACPE/LEiMzG7Ga97fQZeAeS9A6G/nRwocSecxKo2n0SuRy6Ce+j5RsO X-Received: by 2002:a05:6808:a8e:: with SMTP id q14mr467986oij.173.1583294779744; Tue, 03 Mar 2020 20:06:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583294779; cv=none; d=google.com; s=arc-20160816; b=tTpW8nRCWy4WqzSEdPxpaopBJLmncl27pl8YzZb4ZU9L33+mqk/kdkrDZNqMt4EtQB PqoJp2Vau5hw2YS2QxY4yNRv9ZTclCQPr5SJ13gRC7Yi0YgFvm9GQmi9sBLUzdd+jYU4 WKdAEdcIwAcmeXagwQrlUBE+odGAVM3zUspzWCLFSuELHRI2hQbUS3FENItpWR5rHI0r JpnMG/F7YmOmuGb3HVC0QRZ382fU0pINomncUabO0/FJB0OQpTKU0XNH9+O2Nlz0+aLx 7KR4nlpMFnA2mGEm9xCK3digzmWMb0KZ2aINTDKb2R3GOLXDl0pw4FcmLUgV7dTnSNMd 07mg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:to:subject:dkim-signature; bh=N7489+DvZFXDsAxs/5zrBWYAyH6nC/7dSqSyIv694O4=; b=OmTIo7ypqNnxs88JeykWThoRPTu9atvBhtfcTjjv7sJvHxbG58qqtLvweOdF6DkazE wXrlII2M7Ux0p62jcgpUMfxEcCskB2Je2FVFgcxjvbwpqhXu6lsOKxtgMeCH3rOsyWqP ctgjbBpK3V+ywG4jR9aguy7NZ0SbOQDg+C7KmV45RZL2xjLscmLiem4qt276cFxrds/o lVLjab0KJmo1AUGvEwun+1fI9ZMIEuR0Wx0sJf/FzgJm92vlW0gP4+5fW/oHZX3OBkjn fZDSgyT3iU7KeLx1Nht4Q8NGzPaPambjab1EoBtcMqOQ6EQBTSfyE+OQ3rvaGH1o/g2q ywfw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=OEq2r8fA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p200si452635oic.213.2020.03.03.20.06.07; Tue, 03 Mar 2020 20:06:19 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=OEq2r8fA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726887AbgCDEF5 (ORCPT + 99 others); Tue, 3 Mar 2020 23:05:57 -0500 Received: from bombadil.infradead.org ([198.137.202.133]:48934 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725861AbgCDEF5 (ORCPT ); Tue, 3 Mar 2020 23:05:57 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:To: Subject:Sender:Reply-To:Cc:Content-ID:Content-Description; bh=N7489+DvZFXDsAxs/5zrBWYAyH6nC/7dSqSyIv694O4=; b=OEq2r8fAS6nfUOSCQYPvW8y4Iv SBZow0oDBWUVJemZMZ4g6N+8W5S1cMqrqOtxvAJddejKRbmMxGyO19K0B9J4f6sgUJTE0KzmPe28P j9c14DCsQGjj8gXbrBB+Khe9N+7mevFKSuh8M/Gd7VoFC0DFpGEYfHjtYpmHeXd2XtIuk3251TnhK fEM6ubKxb0t5ovqdjalLIR3f5C2yReGxa0+SUmONQc2bvxOe5qsIyoZ35W8zliEXnWOA867BBg7v5 s4oAd8TDOxbptiCGk2W59XdhbQH8eZKJJ/L1lOWaeOz1IuSek8Q4NQHZ//CJYmhBpdSMKa9sFSneR 3UQuTA2g==; Received: from [2601:1c0:6280:3f0::19c2] by bombadil.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1j9LIA-0006sA-RF; Wed, 04 Mar 2020 04:05:54 +0000 Subject: Re: v5.5-rc1 and beyond insta-kills some Comcast wifi routers To: "Mancini, Jason" , "linux-kernel@vger.kernel.org" , "netdev@vger.kernel.org" , Yan-Hsuan Chuang , Kalle Valo References: From: Randy Dunlap Message-ID: <4e2a1fc1-4c14-733d-74e2-750ef1f81bf6@infradead.org> Date: Tue, 3 Mar 2020 20:05:53 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [add netdev mailing list + 2 patch signers] On 3/3/20 7:34 PM, Mancini, Jason wrote: > [I can't seem to access the linux-net ml per kernel.org faq, apology > in advance.] > > This change, which I think first appeared for v5.5-rc1, basically > within seconds, knocks out our [apparently buggy] Comcast wifi for > about 2-3 minutes. Is there a boot option (or similar) where I can > achieve prior kernel behavior? Otherwise I am stuck on kernel 5.4 > (or Win10) it seems, or forever compiling custom kernels for my > choice of distribution [as I don't have physical access to the router > in question.] > Thanks! > Jason > > ================ > > 127eef1d46f80056fe9f18406c6eab38778d8a06 is the first bad commit > commit 127eef1d46f80056fe9f18406c6eab38778d8a06 > Author: Yan-Hsuan Chuang > Date: Wed Oct 2 14:35:23 2019 +0800 > > rtw88: add TX-AMSDU support > > Based on the mac80211's TXQ implementation, TX-AMSDU can > be used to get higher MAC efficiency. To make mac80211 > aggregate MSDUs, low level driver just need to leave skbs > in the TXQ, and mac80211 will try to aggregate them if > possible. As driver will schedule a tasklet when the TX > queue is woke, until the tasklet being served, there will > have some skbs in the queue if traffic is heavy. > > Driver can control the max AMSDU size depending on the > current bit rate used by hardware/firmware. The higher > rates are used, the larger AMSDU size can be. > > It is tested that can achieve higher T-Put at higher rates. > If the environment is relatively clean, and the bit_rate > is high enough, we can get about 80Mbps improvement. > > For lower bit rates, not much gain can we get, so leave > the max_amsdu length low to prevent aggregation. > > Signed-off-by: Yan-Hsuan Chuang > Signed-off-by: Kalle Valo > > drivers/net/wireless/realtek/rtw88/fw.c | 24 ++++++++++++++++++++++++ > drivers/net/wireless/realtek/rtw88/main.c | 1 + > 2 files changed, 25 insertions(+) > > ------------------- drivers/net/wireless/realtek/rtw88/fw.c ------------------- > index 4b41bf531998..51649df7cc98 100644 > @@ -29,6 +29,28 @@ static void rtw_fw_c2h_cmd_handle_ext(struct rtw_dev *rtwdev, > } > } > > +static u16 get_max_amsdu_len(u32 bit_rate) > +{ > + /* lower than ofdm, do not aggregate */ > + if (bit_rate < 550) > + return 1; > + > + /* lower than 20M 2ss mcs8, make it small */ > + if (bit_rate < 1800) > + return 1200; > + > + /* lower than 40M 2ss mcs9, make it medium */ > + if (bit_rate < 4000) > + return 2600; > + > + /* not yet 80M 2ss mcs8/9, make it twice regular packet size */ > + if (bit_rate < 7000) > + return 3500; > + > + /* unlimited */ > + return 0; > +} > + > struct rtw_fw_iter_ra_data { > struct rtw_dev *rtwdev; > u8 *payload; > @@ -83,6 +105,8 @@ static void rtw_fw_ra_report_iter(void *data, struct ieee80211_sta *sta) > > si->ra_report.desc_rate = rate; > si->ra_report.bit_rate = bit_rate; > + > + sta->max_rc_amsdu_len = get_max_amsdu_len(bit_rate); > } > > static void rtw_fw_ra_report_handle(struct rtw_dev *rtwdev, u8 *payload, > > ------------------ drivers/net/wireless/realtek/rtw88/main.c ------------------ > index 690a5c4d64e7..f7044e8bcb5b 100644 > @@ -1310,6 +1310,7 @@ int rtw_register_hw(struct rtw_dev *rtwdev, struct ieee80211_hw *hw) > ieee80211_hw_set(hw, SUPPORT_FAST_XMIT); > ieee80211_hw_set(hw, SUPPORTS_AMSDU_IN_AMPDU); > ieee80211_hw_set(hw, HAS_RATE_CONTROL); > + ieee80211_hw_set(hw, TX_AMSDU); > > hw->wiphy->interface_modes = BIT(NL80211_IFTYPE_STATION) | > BIT(NL80211_IFTYPE_AP) | > -- ~Randy Reported-by: Randy Dunlap