lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID:
 <SA3PR21MB3867A54AA709CEE59F610943CA8EA@SA3PR21MB3867.namprd21.prod.outlook.com>
Date: Tue, 13 Jan 2026 15:13:24 +0000
From: Haiyang Zhang <haiyangz@...rosoft.com>
To: Haiyang Zhang <haiyangz@...rosoft.com>, Jakub Kicinski <kuba@...nel.org>
CC: Haiyang Zhang <haiyangz@...ux.microsoft.com>,
	"linux-hyperv@...r.kernel.org" <linux-hyperv@...r.kernel.org>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>, KY Srinivasan
	<kys@...rosoft.com>, Wei Liu <wei.liu@...nel.org>, Dexuan Cui
	<DECUI@...rosoft.com>, Long Li <longli@...rosoft.com>, Andrew Lunn
	<andrew+netdev@...n.ch>, "David S. Miller" <davem@...emloft.net>, Eric
 Dumazet <edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>, Konstantin
 Taranov <kotaranov@...rosoft.com>, Simon Horman <horms@...nel.org>, Erni Sri
 Satya Vennela <ernis@...ux.microsoft.com>, Shradha Gupta
	<shradhagupta@...ux.microsoft.com>, Saurabh Sengar
	<ssengar@...ux.microsoft.com>, Aditya Garg <gargaditya@...ux.microsoft.com>,
	Dipayaan Roy <dipayanroy@...ux.microsoft.com>, Shiraz Saleem
	<shirazsaleem@...rosoft.com>, "linux-kernel@...r.kernel.org"
	<linux-kernel@...r.kernel.org>, "linux-rdma@...r.kernel.org"
	<linux-rdma@...r.kernel.org>, Paul Rosswurm <paulros@...rosoft.com>
Subject: RE: [EXTERNAL] Re: [PATCH V2,net-next, 1/2] net: mana: Add support
 for coalesced RX packets on CQE



> -----Original Message-----
> From: Haiyang Zhang <haiyangz@...rosoft.com>
> Sent: Tuesday, January 13, 2026 10:09 AM
> To: Jakub Kicinski <kuba@...nel.org>
> Cc: Haiyang Zhang <haiyangz@...ux.microsoft.com>; linux-
> hyperv@...r.kernel.org; netdev@...r.kernel.org; KY Srinivasan
> <kys@...rosoft.com>; Wei Liu <wei.liu@...nel.org>; Dexuan Cui
> <DECUI@...rosoft.com>; Long Li <longli@...rosoft.com>; Andrew Lunn
> <andrew+netdev@...n.ch>; David S. Miller <davem@...emloft.net>; Eric
> Dumazet <edumazet@...gle.com>; Paolo Abeni <pabeni@...hat.com>; Konstantin
> Taranov <kotaranov@...rosoft.com>; Simon Horman <horms@...nel.org>; Erni
> Sri Satya Vennela <ernis@...ux.microsoft.com>; Shradha Gupta
> <shradhagupta@...ux.microsoft.com>; Saurabh Sengar
> <ssengar@...ux.microsoft.com>; Aditya Garg
> <gargaditya@...ux.microsoft.com>; Dipayaan Roy
> <dipayanroy@...ux.microsoft.com>; Shiraz Saleem
> <shirazsaleem@...rosoft.com>; linux-kernel@...r.kernel.org; linux-
> rdma@...r.kernel.org; Paul Rosswurm <paulros@...rosoft.com>
> Subject: RE: [EXTERNAL] Re: [PATCH V2,net-next, 1/2] net: mana: Add
> support for coalesced RX packets on CQE
> 
> 
> 
> > -----Original Message-----
> > From: Jakub Kicinski <kuba@...nel.org>
> > Sent: Monday, January 12, 2026 8:22 PM
> > To: Haiyang Zhang <haiyangz@...rosoft.com>
> > Cc: Haiyang Zhang <haiyangz@...ux.microsoft.com>; linux-
> > hyperv@...r.kernel.org; netdev@...r.kernel.org; KY Srinivasan
> > <kys@...rosoft.com>; Wei Liu <wei.liu@...nel.org>; Dexuan Cui
> > <DECUI@...rosoft.com>; Long Li <longli@...rosoft.com>; Andrew Lunn
> > <andrew+netdev@...n.ch>; David S. Miller <davem@...emloft.net>; Eric
> > Dumazet <edumazet@...gle.com>; Paolo Abeni <pabeni@...hat.com>;
> Konstantin
> > Taranov <kotaranov@...rosoft.com>; Simon Horman <horms@...nel.org>; Erni
> > Sri Satya Vennela <ernis@...ux.microsoft.com>; Shradha Gupta
> > <shradhagupta@...ux.microsoft.com>; Saurabh Sengar
> > <ssengar@...ux.microsoft.com>; Aditya Garg
> > <gargaditya@...ux.microsoft.com>; Dipayaan Roy
> > <dipayanroy@...ux.microsoft.com>; Shiraz Saleem
> > <shirazsaleem@...rosoft.com>; linux-kernel@...r.kernel.org; linux-
> > rdma@...r.kernel.org; Paul Rosswurm <paulros@...rosoft.com>
> > Subject: Re: [EXTERNAL] Re: [PATCH V2,net-next, 1/2] net: mana: Add
> > support for coalesced RX packets on CQE
> >
> > On Mon, 12 Jan 2026 21:01:59 +0000 Haiyang Zhang wrote:
> > > > > Our NIC can have up to 4 RX packets on 1 CQE. To support this
> > feature,
> > > > > check and process the type CQE_RX_COALESCED_4. The default setting
> > is
> > > > > disabled, to avoid possible regression on latency.
> > > > >
> > > > > And add ethtool handler to switch this feature. To turn it on,
> run:
> > > > >   ethtool -C <nic> rx-frames 4
> > > > > To turn it off:
> > > > >   ethtool -C <nic> rx-frames 1
> > > >
> > > > Exposing just rx frame count, and only two values is quite unusual.
> > > > Please explain in more detail the coalescing logic of the device.
> > > Our NIC device only supports coalescing on RX. And when it's disabled
> > each
> > > RX CQE indicates 1 RX packet; when enabled each RX CQE indicates up to
> 4
> > packets.
> >
> > I get that. What is the logic for combining 4 packets into a single
> > completion? How does it work? Your commit message mentions "regression
> > on latency" - what is the bound on that regression?
> 
> When we received CQE type CQE_RX_COALESCED_4, it's a coalesced CQE. And in
> the CQE
> OOB, there is an array with 4 PPI elements, with each pkt's length:
> oob->ppi[i].pkt_len.
> 
> So we read the related WQE and the DMA buffers for the RX pkt payloads, up
> to 4.
> But, if the coalesced pkts <4, the pkt_len will be 0 after the last pkt,
> so we
> know when to stop reading the WQEs.

And, the coalescing can add up to 2 microseconds into one-way latency.

Thanks,
- Haiyang


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ