linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Oskar Senft <osk@google.com>, Florian Fainelli <f.fainelli@gmail.com>
Cc: Joel Stanley <joel@jms.id.au>,
	Kate Stewart <kstewart@linuxfoundation.org>,
	Andrew Lunn <andrew@lunn.ch>,
	linux-aspeed <linux-aspeed@lists.ozlabs.org>,
	netdev@vger.kernel.org,
	"openbmc @ lists . ozlabs . org" <openbmc@lists.ozlabs.org>,
	YueHaibing <yuehaibing@huawei.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Luis Chamberlain <mcgrof@kernel.org>,
	Mauro Carvalho Chehab <mchehab+samsung@kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Vijay Khemka <vijaykhemka@fb.com>
Subject: Re: [PATCH] ftgmac100: Disable HW checksum generation on AST2500
Date: Thu, 10 Oct 2019 11:09:11 +1100	[thread overview]
Message-ID: <b749ebb3c85007b7a49f12a4c80613a7a3dbbe61.camel@kernel.crashing.org> (raw)
In-Reply-To: <CABoTLcTNwNTua9Neuw5cuFn0Nuz1E6UAakqfkLp1rirbwoQo=w@mail.gmail.com>

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 <vijaykhemka@fb.com>
> > > > > ---
> > > > >  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.
> > 


  parent reply	other threads:[~2019-10-10  0:09 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20190910213734.3112330-1-vijaykhemka@fb.com>
2019-09-10 22:05 ` [PATCH] ftgmac100: Disable HW checksum generation on AST2500 Florian Fainelli
2019-09-10 22:13   ` Vijay Khemka
2019-09-10 22:48   ` Vijay Khemka
2019-09-10 23:07     ` Vijay Khemka
2019-09-11 18:30       ` Vijay Khemka
2019-09-11 18:34         ` Florian Fainelli
2019-09-11 18:50           ` Vijay Khemka
2019-09-11 14:48   ` Joel Stanley
2019-09-11 17:44     ` Vijay Khemka
2019-10-09  4:37     ` Benjamin Herrenschmidt
2019-10-09 18:20       ` Oskar Senft
     [not found]       ` <CABoTLcTNwNTua9Neuw5cuFn0Nuz1E6UAakqfkLp1rirbwoQo=w@mail.gmail.com>
2019-10-10  0:09         ` Benjamin Herrenschmidt [this message]
2019-10-10 19:15       ` Vijay Khemka
2019-10-11  3:10         ` Benjamin Herrenschmidt
2019-10-11 21:28           ` Vijay Khemka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b749ebb3c85007b7a49f12a4c80613a7a3dbbe61.camel@kernel.crashing.org \
    --to=benh@kernel.crashing.org \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=joel@jms.id.au \
    --cc=kstewart@linuxfoundation.org \
    --cc=linux-aspeed@lists.ozlabs.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mcgrof@kernel.org \
    --cc=mchehab+samsung@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=openbmc@lists.ozlabs.org \
    --cc=osk@google.com \
    --cc=tglx@linutronix.de \
    --cc=vijaykhemka@fb.com \
    --cc=yuehaibing@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).