Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp456207pxj; Thu, 20 May 2021 13:22:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzjCPjusy7RRUkIoS7hJvXaXgLUQOE4jibSOaaOpXPpQlFx6VSMasdpkO9PqCyhGA3D+6dQ X-Received: by 2002:a05:6602:21ca:: with SMTP id c10mr7675296ioc.10.1621542151439; Thu, 20 May 2021 13:22:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621542151; cv=none; d=google.com; s=arc-20160816; b=FR3ouFEUsVD9mUjPi5ti1wnnLSYmskMpMrhb2gAbGLw2dH8xtoLjQkkyO+t9oXZCCv o7LtC8DWD5WT+i2QG7+lyV4uTlhgaWCVZWbXGgBkHkuxaVVVPQv1GU/AwzOrGjlQMdIe RsyzHIjct0vgJILNpsOVExhMY3NmXg4PzqKiibp+HQqGzl20f5hOKoVAvz7ij2HxpANc TDJgz3tyjosZj7UU5iK1DYlVqXhrEaRZ8I10SlijdwB4JPA4ESmY705ehX2IEHwlbL+i vjw6Rm1oAqJoj2HLjwMaeAPEzp3ube+JQ2qsRRDUJUR4rV7EHS+W4hfxSPBxmZmOTMLl iJHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=s56DhvmsoEO4E0ncXUFJj4O0Y8uUZWVOy3WNWAB0kU8=; b=IyktZUrDtiOHVq/jkiZRwowcLasx1OB5f6PapqwjuWVvXioKtoH3qJSBQaBQFG3y0m fb1YaKIzF2jIt0vGlxaKmB29GKliAV05YNVl8hgzXIYanJxn3X6WtuRvPtx9KBpSq4gQ C5J4QIWuqDoDcapo8x6hM8eJ59mJnTHfqtGp34IA/GobML9nY3gOLZ0kOMakrBHE9ySE smdzas/WEE2nmogkhBgbWfcuQ5Q/4NKGV3g9UO1rfbO6WoCQ2HWIXWem8/8PDJvSvzVT hvJOSk3N+eKw3cFSbwMmmN6FeZP2fLpOJdzfsNpm1jhh32PKhS5A/gCOshh1Wk1Ygzm0 shGg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=M2TFrvfM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l21si3292999iol.42.2021.05.20.13.22.18; Thu, 20 May 2021 13:22:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=M2TFrvfM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239059AbhETKuv (ORCPT + 99 others); Thu, 20 May 2021 06:50:51 -0400 Received: from mail.kernel.org ([198.145.29.99]:39770 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237766AbhETKfb (ORCPT ); Thu, 20 May 2021 06:35:31 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id DE0F661C5D; Thu, 20 May 2021 09:53:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1621504420; bh=AMAJjQ9ujnVW2iJvR7jMrwqJOFWID0e5DYKKQR9xvCQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=M2TFrvfMhV6CIRKYygb4/M8rBY8yV5W1Ub5ZonicFKoosAoba6h2GPF1UPs3Yqw3W xQjbQTgOh4bejS4BNYqe0D2Yb4/DvhcI7G310bTn4ClVbgew7gcmGAzLkKBVfvtxuW 69xYzy96e6FRVDwDeEvOUe48T0mRE6LnG7549gOg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jonathan McDowell , "David S. Miller" , Sasha Levin Subject: [PATCH 4.14 236/323] net: stmmac: Set FIFO sizes for ipq806x Date: Thu, 20 May 2021 11:22:08 +0200 Message-Id: <20210520092128.250811725@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210520092120.115153432@linuxfoundation.org> References: <20210520092120.115153432@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 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 1924788d28da..f4ff43a1b5ba 100644 --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-ipq806x.c @@ -363,6 +363,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; err = stmmac_dvr_probe(&pdev->dev, plat_dat, &stmmac_res); if (err) -- 2.30.2