Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp567183ybz; Wed, 22 Apr 2020 03:53:21 -0700 (PDT) X-Google-Smtp-Source: APiQypI0PIDbTiSRfDo/aIKU+nwFLK/hkSXJfs3cGtR3rVtJyFFIIG7sLRmbSMHFqVsc2K0ijVJQ X-Received: by 2002:a17:906:5051:: with SMTP id e17mr24570509ejk.142.1587552801134; Wed, 22 Apr 2020 03:53:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587552801; cv=none; d=google.com; s=arc-20160816; b=TXFilMwF5D2LbY9FfchbHgHUVIMBEBCUlmFcFif4/yaglNM5Wy2ErYinFVOrbw7jHF wauTywVtPSRoG14CLidNbE57iE4XABeqScB70ktd/tAGJfSdj3PcAaAzX/3RCSrM5dcj vS7Sb+Qi6rDMYUUVPWYdXrIqbYBpRO4qBvhlhlOqh9L/nk4Blrip4+sd5VfPQvbRmMJP J9LhV4ubwm/w2OdjFgYVeOB4vS2+w4p14r14FM5/1QPO+dN1o/M7EUTMaKHl+WVfOV/F 7yKPzCofWTTqFVG+hNrXUCKi/BYx4bKV4ZFSFt9QRdzmOv75CcJpDqSyf30HNe+2Jull MUuQ== 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:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=OKJM29mkt0xMJd+lW1nB+BmT4ylfJcUcGh+d74pOqeg=; b=lTJup8R/OamDDEA1Cjpmci37ewcDSGfxaRxbH2D/QXYS/RTxI+igobe05MgrvgwWxB 7AG2+FrEy4RkuBsYMhe84Pe3BE2wd6InorkWfr/j63b9fEIHlNixNpm0zOnOCvoRzpeo DJyXnvNqBXH8gqgOPHuWWXqpFEhSiqAVEssYMx0VEPnhrcwvrkocUzHjhAk1TJihw9Yd hbsquVZpa3Hby2jr0Grg+KPwDeCh7fWcRC8GxWval2D1bj/W07Nc6cYTbOJAzv92TIBH cQe8nnUPWZrmWc/HwXb6902LCRc3lt7C0mkcLMeJzlZjY3C9ONQ4GvM7r9aRPgZjSbcu E8Pw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=aeJ42B0R; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f17si3253052ejx.11.2020.04.22.03.52.58; Wed, 22 Apr 2020 03:53:21 -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=@kernel.org header.s=default header.b=aeJ42B0R; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730168AbgDVKuS (ORCPT + 99 others); Wed, 22 Apr 2020 06:50:18 -0400 Received: from mail.kernel.org ([198.145.29.99]:45638 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728754AbgDVKMc (ORCPT ); Wed, 22 Apr 2020 06:12:32 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 3374C2070B; Wed, 22 Apr 2020 10:12:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1587550351; bh=zqEIafLdABW1ykFZi1ROD4+wSZHXs3eWhQzSHPhb3iE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=aeJ42B0RbxEvxe+QFVAYfr9FY5o9cCVBoHoM9NmtR43IQEpasULG4L1cH/4oHHIJJ aEwkxECqiYrf55qczvbx8aiPeni83PqwmMMfGJoQVxes6Rf/9YeSjsGoVHFGXxBtn2 VlQpZ35tfkKsyNtVdBdowa5K5cY79lw7fis4wn1g= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Chen-Yu Tsai , Florian Fainelli , "David S. Miller" Subject: [PATCH 4.14 112/199] net: stmmac: dwmac-sunxi: Provide TX and RX fifo sizes Date: Wed, 22 Apr 2020 11:57:18 +0200 Message-Id: <20200422095108.876080084@linuxfoundation.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200422095057.806111593@linuxfoundation.org> References: <20200422095057.806111593@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Florian Fainelli [ Upstream commit 806fd188ce2a4f8b587e83e73c478e6484fbfa55 ] After commit bfcb813203e619a8960a819bf533ad2a108d8105 ("net: dsa: configure the MTU for switch ports") my Lamobo R1 platform which uses an allwinner,sun7i-a20-gmac compatible Ethernet MAC started to fail by rejecting a MTU of 1536. The reason for that is that the DMA capabilities are not readable on this version of the IP, and there is also no 'tx-fifo-depth' property being provided in Device Tree. The property is documented as optional, and is not provided. Chen-Yu indicated that the FIFO sizes are 4KB for TX and 16KB for RX, so provide these values through platform data as an immediate fix until various Device Tree sources get updated accordingly. Fixes: eaf4fac47807 ("net: stmmac: Do not accept invalid MTU values") Suggested-by: Chen-Yu Tsai Signed-off-by: Florian Fainelli Acked-by: Chen-Yu Tsai Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c | 2 ++ 1 file changed, 2 insertions(+) --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-sunxi.c @@ -155,6 +155,8 @@ static int sun7i_gmac_probe(struct platf plat_dat->init = sun7i_gmac_init; plat_dat->exit = sun7i_gmac_exit; plat_dat->fix_mac_speed = sun7i_fix_speed; + plat_dat->tx_fifo_size = 4096; + plat_dat->rx_fifo_size = 16384; ret = sun7i_gmac_init(pdev, plat_dat->bsp_priv); if (ret)