netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Przemek Kitszel <przemyslaw.kitszel@intel.com>
To: Tom Herbert <tom@herbertland.com>, <anthony.l.nguyen@intel.com>
Cc: <davem@davemloft.net>, <kuba@kernel.org>,
	<jesse.brandeburg@intel.com>, <cai.huoqing@linux.dev>,
	<netdev@vger.kernel.org>, <felipe@sipanda.io>,
	<justin.iurman@uliege.be>,
	Paul Greenwalt <paul.greenwalt@intel.com>,
	Alexander Lobakin <aleksander.lobakin@intel.com>
Subject: Re: [PATCH net-next v2 0/7] drivers: Fix drivers doing TX csum offload with EH
Date: Tue, 2 Jul 2024 12:31:01 +0200	[thread overview]
Message-ID: <ab3e6312-cf67-47bb-b30f-d425f7914053@intel.com> (raw)
In-Reply-To: <20240701195507.256374-1-tom@herbertland.com>

On 7/1/24 21:55, Tom Herbert wrote:
> Several NICs would seem to support protocol specific TX checksum offload
> and allow for cases where an IPv6 packet contains extension headers.
> When deciding whether to offload a packet, ipv6_skip_exthdr is called
> to skip extension headers. The problem is that if a packet contains an
> IPv6 Routing Header then protocol specific checksum offload can't work,
> the destination IP address in the IPv6 header is not the same one that
> is used in the pseudo header for TCP or UDP. The correct address is
> derived from the last segment in the routing list (which itself might
> be obfuscated so that a device could even read it).

feels like there is a missing "not" after "could" - with it added, reads
fine (not a request to change, just being verbose about assumptions)

> 
> This patch set adds a new function ipv6_skip_exthdr_no_rthdr to be
> called in lieu of ipv6_skip_exthdr. If a routing header is present in
> a packet then ipv6_skip_exthdr_no_rthdr returns a value less than
> zero, this is an indication to the driver that TX checksum offload
> is not viable and it should call skb_checksum_help instead of
> offloading the checksum.
> 
> The i40e, iavf, ice, idpf, hinic, and fm10k are updated accordingly
> to call ipv6_skip_exthdr_no_rthdr.
> 
> Testing: The code compiles, but is otherwise untested due to lack of
> NIC hardware. It would be appreciated if someone with access to the
> hardware could test.

we could test intel ones (except fm10k) via @Tony's tree

> 
> v2: Fixed uninitialized variable in exthdrs_core.c
> 
> Tom Herbert (7):
>    ipv6: Add ipv6_skip_exthdr_no_rthdr
>    i40e: Don't do TX csum offload with routing header present
>    iavf: Don't do TX csum offload with routing header present
>    ice: Don't do TX csum offload with routing header present

sidenote:
our HW is supporting (among others) a GCO check-summing mode described
as: "Checksum 16bit (TCP/UDP) with no pseudo Header", but we have not
yet provided patches for that, and I don't even know if this mode
will be used (CC @Paul)

>    idpf: Don't do TX csum offload with routing header present
>    hinic: Don't do TX csum offload with routing header present
>    fm10k: Don't do TX csum offload with routing header present
> 
>   drivers/net/ethernet/huawei/hinic/hinic_tx.c  | 23 +++++++++++----
>   drivers/net/ethernet/intel/fm10k/fm10k_main.c |  9 ++++--
>   drivers/net/ethernet/intel/i40e/i40e_txrx.c   | 22 ++++++---------
>   drivers/net/ethernet/intel/iavf/iavf_txrx.c   | 20 ++++++-------
>   drivers/net/ethernet/intel/ice/ice_txrx.c     | 22 ++++++---------
>   .../ethernet/intel/idpf/idpf_singleq_txrx.c   | 28 +++++++++----------
>   include/net/ipv6.h                            | 17 +++++++++--
>   net/ipv6/exthdrs_core.c                       | 25 ++++++++++++-----
>   8 files changed, 98 insertions(+), 68 deletions(-)
> 

I have reviewed the patches and they conform to commit message/intent,
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
(for the series)

  parent reply	other threads:[~2024-07-02 10:31 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-01 19:55 [PATCH net-next v2 0/7] drivers: Fix drivers doing TX csum offload with EH Tom Herbert
2024-07-01 19:55 ` [PATCH net-next v2 1/7] ipv6: Add ipv6_skip_exthdr_no_rthdr Tom Herbert
2024-07-01 19:55 ` [PATCH net-next v2 2/7] i40e: Don't do TX csum offload with routing header present Tom Herbert
2024-07-01 19:55 ` [PATCH net-next v2 3/7] iavf: " Tom Herbert
2024-07-01 19:55 ` [PATCH net-next v2 4/7] ice: " Tom Herbert
2024-07-01 19:55 ` [PATCH net-next v2 5/7] idpf: " Tom Herbert
2024-07-01 19:55 ` [PATCH net-next v2 6/7] hinic: " Tom Herbert
2024-07-01 19:55 ` [PATCH net-next v2 7/7] fm10k: " Tom Herbert
2024-07-02 10:31 ` Przemek Kitszel [this message]
2024-07-03 14:20   ` [PATCH net-next v2 0/7] drivers: Fix drivers doing TX csum offload with EH Greenwalt, Paul
     [not found]     ` <CALx6S35zhg8HAUj9_1=Zm=nV0mzSe-Batdo5qpjz6Zd4G8T17g@mail.gmail.com>
2024-07-03 15:02       ` Przemek Kitszel
2024-07-03 15:56         ` Tom Herbert
2024-07-03  1:46 ` Jakub Kicinski
2024-07-03 14:39   ` Tom Herbert

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=ab3e6312-cf67-47bb-b30f-d425f7914053@intel.com \
    --to=przemyslaw.kitszel@intel.com \
    --cc=aleksander.lobakin@intel.com \
    --cc=anthony.l.nguyen@intel.com \
    --cc=cai.huoqing@linux.dev \
    --cc=davem@davemloft.net \
    --cc=felipe@sipanda.io \
    --cc=jesse.brandeburg@intel.com \
    --cc=justin.iurman@uliege.be \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=paul.greenwalt@intel.com \
    --cc=tom@herbertland.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).