From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2D8CDC4360C for ; Wed, 5 May 2021 17:21:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 066B6613F0 for ; Wed, 5 May 2021 17:21:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240054AbhEERUH (ORCPT ); Wed, 5 May 2021 13:20:07 -0400 Received: from mail.kernel.org ([198.145.29.99]:33118 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238049AbhEEREk (ORCPT ); Wed, 5 May 2021 13:04:40 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id ECA8461410; Wed, 5 May 2021 16:42:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1620232927; bh=UuI6kqth4+CJXrv9i+pQbcCa85wGcLTvm3qUCtZsltg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=q4K6rFB1iBsyGZIN+6t4MMP8XYx4cUr4as5hBreE526cNGEwcuV7wexaflILaJM53 z4qptW/qUaShaDfANj1pFWS27mt/NJ4WMpHOz0GXcoXXhOI3hrCQgduXTBcpP0kCA7 Zw8+9rHJG/cAcidp/obwWOgUSsQO5M1IDKm9wvTNxIrK1dMOfnuAkDyRPyZXtmbiRc QwynFqGBH12y7mAGoPcusowOJ+lozUs0PdYAPpC2qqr9vfOzn+zfKJcSrQMuaeozUt uCgQERfv7rdcLIScJKwQFfAO2fYVs+Da0pcNq12I5NwDbEYIiaazvLCaYeT2QqUrZ2 voNc8e5E9rqsw== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Jonathan McDowell , "David S . Miller" , Sasha Levin , netdev@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org Subject: [PATCH AUTOSEL 4.4 03/19] net: stmmac: Set FIFO sizes for ipq806x Date: Wed, 5 May 2021 12:41:46 -0400 Message-Id: <20210505164203.3464510-3-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210505164203.3464510-1-sashal@kernel.org> References: <20210505164203.3464510-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jonathan McDowell [ Upstream commit e127906b68b49ddb3ecba39ffa36a329c48197d3 ] Commit eaf4fac47807 ("net: stmmac: Do not accept invalid MTU values") started using the TX FIFO size to verify what counts as a valid MTU request for the stmmac driver. This is unset for the ipq806x variant. Looking at older patches for this it seems the RX + TXs buffers can be up to 8k, so set appropriately. (I sent this as an RFC patch in June last year, but received no replies. I've been running with this on my hardware (a MikroTik RB3011) since then with larger MTUs to support both the internal qca8k switch and VLANs with no problems. Without the patch it's impossible to set the larger MTU required to support this.) Signed-off-by: Jonathan McDowell Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c index ee5a7c05a0e6..f1eb9f99076a 100644 --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c @@ -361,6 +361,8 @@ static int ipq806x_gmac_probe(struct platform_device *pdev) plat_dat->bsp_priv = gmac; plat_dat->fix_mac_speed = ipq806x_gmac_fix_mac_speed; plat_dat->multicast_filter_bins = 0; + plat_dat->tx_fifo_size = 8192; + plat_dat->rx_fifo_size = 8192; return stmmac_dvr_probe(&pdev->dev, plat_dat, &stmmac_res); } -- 2.30.2