Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-17 Thread David Ahern
On 12/17/20 12:06 PM, Boris Pismenny wrote: > > > On 15/12/2020 7:19, David Ahern wrote: >> On 12/13/20 11:21 AM, Boris Pismenny wrote: > as zerocopy for the following reasons: > (1) The former places buffers *exactly* where the user requests > regardless of the order of response arri

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-17 Thread Boris Pismenny
On 15/12/2020 7:19, David Ahern wrote: > On 12/13/20 11:21 AM, Boris Pismenny wrote: as zerocopy for the following reasons: (1) The former places buffers *exactly* where the user requests regardless of the order of response arrivals, while the latter places packets in a

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-14 Thread David Ahern
On 12/13/20 11:21 AM, Boris Pismenny wrote: >>> as zerocopy for the following reasons: >>> (1) The former places buffers *exactly* where the user requests >>> regardless of the order of response arrivals, while the latter places >>> packets >>> in anonymous buffers according to packet arrival orde

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-13 Thread Boris Pismenny
On 11/12/2020 20:45, Jakub Kicinski wrote: > On Thu, 10 Dec 2020 19:43:57 -0700 David Ahern wrote: >> On 12/10/20 7:01 PM, Jakub Kicinski wrote: >>> On Wed, 9 Dec 2020 21:26:05 -0700 David Ahern wrote: Yes, TCP is a byte stream, so the packets could very well show up like this:

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-13 Thread Boris Pismenny
On 10/12/2020 6:26, David Ahern wrote: > On 12/9/20 1:15 AM, Boris Pismenny wrote: >> On 09/12/2020 2:38, David Ahern wrote: [...] >> >> There is more to this than TCP zerocopy that exists in userspace or >> inside the kernel. First, please note that the patches include support for >> CRC offload a

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-11 Thread Jonathan Lemon
On Fri, Dec 11, 2020 at 12:59:52PM -0700, David Ahern wrote: > On 12/11/20 11:45 AM, Jakub Kicinski wrote: > > Ack, these patches are not exciting (to me), so I'm wondering if there > > is a better way. The only reason NIC would have to understand a ULP for > > ZC is to parse out header/message len

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-11 Thread David Ahern
On 12/11/20 11:45 AM, Jakub Kicinski wrote: > Ack, these patches are not exciting (to me), so I'm wondering if there > is a better way. The only reason NIC would have to understand a ULP for > ZC is to parse out header/message lengths. There's gotta be a way to > pass those in header options or suc

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-11 Thread Jakub Kicinski
On Thu, 10 Dec 2020 19:43:57 -0700 David Ahern wrote: > On 12/10/20 7:01 PM, Jakub Kicinski wrote: > > On Wed, 9 Dec 2020 21:26:05 -0700 David Ahern wrote: > >> Yes, TCP is a byte stream, so the packets could very well show up like > >> this: > >> > >> +--+-+---+

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-10 Thread David Ahern
On 12/10/20 7:01 PM, Jakub Kicinski wrote: > On Wed, 9 Dec 2020 21:26:05 -0700 David Ahern wrote: >> Yes, TCP is a byte stream, so the packets could very well show up like this: >> >> +--+-+---+-++-+ >> | data - seg 1 | PDU hdr | prev data | TCP hdr

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-10 Thread Jakub Kicinski
On Wed, 9 Dec 2020 21:26:05 -0700 David Ahern wrote: > Yes, TCP is a byte stream, so the packets could very well show up like this: > > +--+-+---+-++-+ > | data - seg 1 | PDU hdr | prev data | TCP hdr | IP hdr | eth | > +--+-+-

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-09 Thread David Ahern
On 12/9/20 1:15 AM, Boris Pismenny wrote: > On 09/12/2020 2:38, David Ahern wrote: >> >> The AF_XDP reference was to differentiate one zerocopy use case (all >> packets go to userspace) from another (kernel managed TCP socket with >> zerocopy payload). You are focusing on a very narrow use case - k

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-09 Thread Boris Pismenny
On 09/12/2020 3:11, David Ahern wrote: > On 12/8/20 5:57 PM, David Ahern wrote: >>> diff --git a/include/net/inet_connection_sock.h >>> b/include/net/inet_connection_sock.h >>> index 7338b3865a2a..a08b85b53aa8 100644 >>> --- a/include/net/inet_connection_sock.h >>> +++ b/include/net/inet_conne

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-09 Thread Boris Pismenny
On 09/12/2020 2:57, David Ahern wrote: > On 12/7/20 2:06 PM, Boris Pismenny wrote: >> diff --git a/include/linux/netdev_features.h >> b/include/linux/netdev_features.h >> index 934de56644e7..fb35dcac03d2 100644 >> --- a/include/linux/netdev_features.h >> +++ b/include/linux/netdev_features.h >>

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-09 Thread Boris Pismenny
On 09/12/2020 2:38, David Ahern wrote: > > The AF_XDP reference was to differentiate one zerocopy use case (all > packets go to userspace) from another (kernel managed TCP socket with > zerocopy payload). You are focusing on a very narrow use case - kernel > based NVMe over TCP - of a more general

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-08 Thread David Ahern
On 12/8/20 5:57 PM, David Ahern wrote: >> diff --git a/include/net/inet_connection_sock.h >> b/include/net/inet_connection_sock.h >> index 7338b3865a2a..a08b85b53aa8 100644 >> --- a/include/net/inet_connection_sock.h >> +++ b/include/net/inet_connection_sock.h >> @@ -66,6 +66,8 @@ struct inet_conn

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-08 Thread David Ahern
On 12/7/20 2:06 PM, Boris Pismenny wrote: > diff --git a/include/linux/netdev_features.h b/include/linux/netdev_features.h > index 934de56644e7..fb35dcac03d2 100644 > --- a/include/linux/netdev_features.h > +++ b/include/linux/netdev_features.h > @@ -84,6 +84,7 @@ enum { > NETIF_F_GRO_FRAGLIS

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-08 Thread David Ahern
On 12/8/20 7:36 AM, Boris Pismenny wrote: > On 08/12/2020 2:42, David Ahern wrote: >> On 12/7/20 2:06 PM, Boris Pismenny wrote: >>> This commit introduces direct data placement offload for TCP. >>> This capability is accompanied by new net_device operations that >>> configure >>> hardware contexts.

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-08 Thread Boris Pismenny
On 08/12/2020 2:42, David Ahern wrote: > On 12/7/20 2:06 PM, Boris Pismenny wrote: >> This commit introduces direct data placement offload for TCP. >> This capability is accompanied by new net_device operations that >> configure >> hardware contexts. There is a context per socket, and a context per

Re: [PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-07 Thread David Ahern
On 12/7/20 2:06 PM, Boris Pismenny wrote: > This commit introduces direct data placement offload for TCP. > This capability is accompanied by new net_device operations that > configure > hardware contexts. There is a context per socket, and a context per DDP > opreation. Additionally, a resynchroni

[PATCH v1 net-next 02/15] net: Introduce direct data placement tcp offload

2020-12-07 Thread Boris Pismenny
This commit introduces direct data placement offload for TCP. This capability is accompanied by new net_device operations that configure hardware contexts. There is a context per socket, and a context per DDP opreation. Additionally, a resynchronization routine is used to assist hardware handle TCP