linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rafal Ozieblo <rafalo@cadence.com>
To: David Miller <davem@davemloft.net>
Cc: "nicolas.ferre@atmel.com" <nicolas.ferre@atmel.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH net-next v5] cadence: Add LSO support.
Date: Tue, 15 Nov 2016 07:07:14 +0000	[thread overview]
Message-ID: <BN3PR07MB251641C606D02892E2196960C9BF0@BN3PR07MB2516.namprd07.prod.outlook.com> (raw)
In-Reply-To: <20161114.123038.1075174354580074536.davem@davemloft.net>

> > > If UFO is in use it should not silently disable UDP checksums.
> > > 
> > > If you cannot support UFO with proper checksumming, then you cannot enable support for that feature.
> > 
> > According Cadence Gigabit Ethernet MAC documentation:
> > 
> > "Hardware will not calculate the UDP checksum or modify the UDP 
> > checksum field. Therefore software must set a value of zero in the 
> > checksum field in the UDP header (in the first payload buffer) to indicate to the receiver that the UDP datagram does not include a checksum."
> > 
> > It is hardware requirement.
>
> I do not doubt that it is a hardware restriction.
>
> But I am saying that you cannot enable this feature under Linux if this is how it operates on your hardware.

Would it be good to enable UFO conditionally with some internal define? Ex.:

+#ifdef MACB_ENABLE_UFO
+#define MACB_NETIF_LSO         (NETIF_F_TSO | NETIF_F_UFO)
+#else
+#define MACB_NETIF_LSO         (NETIF_F_TSO)
+#endif

I could add precise comment here that ufo is possible only without checksum.

Or maybe I could enable it from module_params or device-tree (like: drivers/net/ethernet/neterion/s2io.c).

  reply	other threads:[~2016-11-15  7:07 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-14  9:32 [PATCH net-next v5] cadence: Add LSO support Rafal Ozieblo
2016-11-14 14:35 ` Eric Dumazet
2016-11-14 17:30 ` David Miller
2016-11-15  7:07   ` Rafal Ozieblo [this message]
2016-11-15 13:11     ` Eric Dumazet
2016-11-15 14:20       ` Rafal Ozieblo
2016-11-15 15:15     ` David Miller
  -- strict thread matches above, loose matches on Subject: below --
2016-11-08 13:41 [PATCH net-next v4] " Rafal Ozieblo
2016-11-09 13:41 ` [PATCH net-next v5]] " Rafal Ozieblo
2016-11-10 17:01   ` David Miller

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=BN3PR07MB251641C606D02892E2196960C9BF0@BN3PR07MB2516.namprd07.prod.outlook.com \
    --to=rafalo@cadence.com \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=nicolas.ferre@atmel.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).