Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp1598099ybp; Wed, 9 Oct 2019 17:11:09 -0700 (PDT) X-Google-Smtp-Source: APXvYqwrkc0JyeBKxcAYc78sdjXxo+iPnKwlv/BhqRa04Af1JbW6082gnPRfmwK2bAdLRuy8yIop X-Received: by 2002:a05:6402:68b:: with SMTP id f11mr5318235edy.173.1570666269179; Wed, 09 Oct 2019 17:11:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570666269; cv=none; d=google.com; s=arc-20160816; b=Q/i92biSmwpe5kIs7/BuLEnHHrfdhgBwhH2gqSSCs9JfaS0gcprftdd3Egggmmug2Y DJ3ioOrOewKmST2JqKg2AaYK8pHf+7dkHd2SgTICweHr22FDyH87TaRXGiwRnO6nEtf5 a9JHGArMjFSyP3lUA13Cx/xYcF3SJzci2JzDfJ48GLzeh5Y5BSQTNumIDNJ4SQxeJWkG IuapcLWdHQQfLnPGA4JRa9FHY01xYaeokNPZDaXgdk3LIF1FomO8tcD6P8mrQJaoz6ky G5v2pp2Q94rvz6E9aPqMuMZupD3ijN75Kh/oNRH1wgGVrBsGoOg4j/Pz0Xgo6ib96P3i cCCg== 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 :references:in-reply-to:date:cc:to:from:subject:message-id; bh=+XV6O9My7M30Osqe7kVLS/19svTEmQZ/+ToJI/jIiQU=; b=Jc+uma+JnTBnrGO3s9cNR2riZHYyup6KgbrKz5GyfpM1wdICIP1ku2e13P7XWsb878 j41UmBxCtnxv+8s6jOKvdOGHaJf7v1aO9qv2cq4Dh3+gx8M/xLlyfefpaKTDjbo2Zplx iukabaFygh4rSYc7AZaG/fL5sfj33ltTol6b13K8OUWvnXcmrmOoUIUxOvjGgxPWLg2s RlEdbpoH47UO2xamOb60LYISqJl7XLtyQfCEvPGl1Omkkv5e6sv/XLOu7QI9lydfK6DF UwZidFmOzlYTevnNLsvA8be2Cu/3t4OYJW17H1Bbo5DwfYx16Om1JTC1zoCPxce2j5kb 5+8w== ARC-Authentication-Results: i=1; mx.google.com; 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 me23si2047688ejb.344.2019.10.09.17.10.45; Wed, 09 Oct 2019 17:11:09 -0700 (PDT) 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; 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 S1732252AbfJJAJ5 (ORCPT + 99 others); Wed, 9 Oct 2019 20:09:57 -0400 Received: from gate.crashing.org ([63.228.1.57]:56011 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730815AbfJJAJ5 (ORCPT ); Wed, 9 Oct 2019 20:09:57 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id x9A09Bj1023417; Wed, 9 Oct 2019 19:09:12 -0500 Message-ID: Subject: Re: [PATCH] ftgmac100: Disable HW checksum generation on AST2500 From: Benjamin Herrenschmidt To: Oskar Senft , Florian Fainelli Cc: Joel Stanley , Kate Stewart , Andrew Lunn , linux-aspeed , netdev@vger.kernel.org, "openbmc @ lists . ozlabs . org" , YueHaibing , Linux Kernel Mailing List , "David S. Miller" , Luis Chamberlain , Mauro Carvalho Chehab , Thomas Gleixner , Vijay Khemka Date: Thu, 10 Oct 2019 11:09:11 +1100 In-Reply-To: References: <20190910213734.3112330-1-vijaykhemka@fb.com> <95e215664612c0487808c02232852ef2188c95a5.camel@kernel.crashing.org> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2019-10-09 at 14:18 -0400, Oskar Senft wrote: > Does HW in the AST2500 actually perform the HW checksum calculation, > or would that be the responsibility of the NIC that it's talking to > via NC-SI? I wouldn't rely on the NC-SI NIC for UDP/TCP checksums. We should be providing it with well formed traffic. Cheers, Ben. > Oskar. > > On Wed, Oct 9, 2019 at 12:38 AM Benjamin Herrenschmidt < > benh@kernel.crashing.org> wrote: > > On Wed, 2019-09-11 at 14:48 +0000, Joel Stanley wrote: > > > Hi Ben, > > > > > > On Tue, 10 Sep 2019 at 22:05, Florian Fainelli < > > f.fainelli@gmail.com> > > > wrote: > > > > > > > > On 9/10/19 2:37 PM, Vijay Khemka wrote: > > > > > HW checksum generation is not working for AST2500, specially > > with > > > > > IPV6 > > > > > over NCSI. All TCP packets with IPv6 get dropped. By > > disabling > > > > > this > > > > > it works perfectly fine with IPV6. > > > > > > > > > > Verified with IPV6 enabled and can do ssh. > > > > > > > > How about IPv4, do these packets have problem? If not, can you > > > > continue > > > > advertising NETIF_F_IP_CSUM but take out NETIF_F_IPV6_CSUM? > > > > > > > > > > > > > > Signed-off-by: Vijay Khemka > > > > > --- > > > > > drivers/net/ethernet/faraday/ftgmac100.c | 5 +++-- > > > > > 1 file changed, 3 insertions(+), 2 deletions(-) > > > > > > > > > > diff --git a/drivers/net/ethernet/faraday/ftgmac100.c > > > > > b/drivers/net/ethernet/faraday/ftgmac100.c > > > > > index 030fed65393e..591c9725002b 100644 > > > > > --- a/drivers/net/ethernet/faraday/ftgmac100.c > > > > > +++ b/drivers/net/ethernet/faraday/ftgmac100.c > > > > > @@ -1839,8 +1839,9 @@ static int ftgmac100_probe(struct > > > > > platform_device *pdev) > > > > > if (priv->use_ncsi) > > > > > netdev->hw_features |= > > NETIF_F_HW_VLAN_CTAG_FILTER; > > > > > > > > > > - /* AST2400 doesn't have working HW checksum generation > > */ > > > > > - if (np && (of_device_is_compatible(np, "aspeed,ast2400- > > > > > mac"))) > > > > > + /* AST2400 and AST2500 doesn't have working HW > > checksum > > > > > generation */ > > > > > + if (np && (of_device_is_compatible(np, "aspeed,ast2400- > > > > > mac") || > > > > > + of_device_is_compatible(np, "aspeed,ast2500- > > > > > mac"))) > > > > > > Do you recall under what circumstances we need to disable > > hardware > > > checksumming? > > > > Any news on this ? AST2400 has no HW checksum logic in HW, AST2500 > > should work for IPV4 fine, we should only selectively disable it > > for > > IPV6. > > > > Can you do an updated patch ? > > > > Cheers, > > Ben. > >