[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-04-08 Thread Michael S. Tsirkin
On Thu, Mar 30, 2023 at 08:37:21PM +0800, Heng Qi wrote: > > > 在 2023/3/21 上午3:48, Michael S. Tsirkin 写道: > > On Wed, Mar 15, 2023 at 08:55:45PM +0800, Heng Qi wrote: > > > We use the most basic GRE header fields (not NVGRE), not even optional > > > fields. > > I'd say yes, the most convincing

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-30 Thread Heng Qi
在 2023/3/21 上午3:48, Michael S. Tsirkin 写道: On Wed, Mar 15, 2023 at 08:55:45PM +0800, Heng Qi wrote: We use the most basic GRE header fields (not NVGRE), not even optional fields. I'd say yes, the most convincing usecase is with legacy GRE. Yes. But we still have a strong need for VXLAN

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-30 Thread Heng Qi
在 2023/3/21 上午3:45, Michael S. Tsirkin 写道: On Thu, Mar 16, 2023 at 09:17:26PM +0800, Heng Qi wrote: On Wed, Mar 15, 2023 at 10:57:40AM -0400, Michael S. Tsirkin wrote: On Wed, Mar 15, 2023 at 08:55:45PM +0800, Heng Qi wrote: 在 2023/3/15 下午7:58, Michael S. Tsirkin 写道: On Sat, Mar 11, 2023

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-20 Thread Michael S. Tsirkin
On Wed, Mar 15, 2023 at 08:55:45PM +0800, Heng Qi wrote: > We use the most basic GRE header fields (not NVGRE), not even optional > fields. I'd say yes, the most convincing usecase is with legacy GRE. Given that, do you need the rest of protocols there? We can start with just legacy GRE (think

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-20 Thread Michael S. Tsirkin
On Thu, Mar 16, 2023 at 09:17:26PM +0800, Heng Qi wrote: > On Wed, Mar 15, 2023 at 10:57:40AM -0400, Michael S. Tsirkin wrote: > > On Wed, Mar 15, 2023 at 08:55:45PM +0800, Heng Qi wrote: > > > > > > > > > 在 2023/3/15 下午7:58, Michael S. Tsirkin 写道: > > > > On Sat, Mar 11, 2023 at 11:23:08AM

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-16 Thread Heng Qi
On Wed, Mar 15, 2023 at 10:57:40AM -0400, Michael S. Tsirkin wrote: > On Wed, Mar 15, 2023 at 08:55:45PM +0800, Heng Qi wrote: > > > > > > 在 2023/3/15 下午7:58, Michael S. Tsirkin 写道: > > > On Sat, Mar 11, 2023 at 11:23:08AM +0800, Heng Qi wrote: > > > > > > > > > > > > 在 2023/3/10 上午3:36,

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-15 Thread Michael S. Tsirkin
On Wed, Mar 15, 2023 at 08:55:45PM +0800, Heng Qi wrote: > > > 在 2023/3/15 下午7:58, Michael S. Tsirkin 写道: > > On Sat, Mar 11, 2023 at 11:23:08AM +0800, Heng Qi wrote: > > > > > > > > > 在 2023/3/10 上午3:36, Michael S. Tsirkin 写道: > > > > On Thu, Mar 09, 2023 at 12:55:02PM +0800, Heng Qi wrote: >

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-15 Thread Heng Qi
在 2023/3/15 下午7:58, Michael S. Tsirkin 写道: On Sat, Mar 11, 2023 at 11:23:08AM +0800, Heng Qi wrote: 在 2023/3/10 上午3:36, Michael S. Tsirkin 写道: On Thu, Mar 09, 2023 at 12:55:02PM +0800, Heng Qi wrote: 在 2023/3/8 下午10:39, Michael S. Tsirkin 写道: On Wed, Mar 01, 2023 at 10:56:31AM +0800,

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-15 Thread Michael S. Tsirkin
On Sat, Mar 11, 2023 at 11:23:08AM +0800, Heng Qi wrote: > > > > 在 2023/3/10 上午3:36, Michael S. Tsirkin 写道: > > On Thu, Mar 09, 2023 at 12:55:02PM +0800, Heng Qi wrote: > > > > > > 在 2023/3/8 下午10:39, Michael S. Tsirkin 写道: > > > > On Wed, Mar 01, 2023 at 10:56:31AM +0800, Heng Qi wrote: > > >

Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-10 Thread Heng Qi
在 2023/3/10 上午3:36, Michael S. Tsirkin 写道: On Thu, Mar 09, 2023 at 12:55:02PM +0800, Heng Qi wrote: 在 2023/3/8 下午10:39, Michael S. Tsirkin 写道: On Wed, Mar 01, 2023 at 10:56:31AM +0800, Heng Qi wrote: 在 2023/2/28 下午7:16, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800,

Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-09 Thread Michael S. Tsirkin
On Thu, Mar 09, 2023 at 12:55:02PM +0800, Heng Qi wrote: > > > 在 2023/3/8 下午10:39, Michael S. Tsirkin 写道: > > On Wed, Mar 01, 2023 at 10:56:31AM +0800, Heng Qi wrote: > > > > > > 在 2023/2/28 下午7:16, Michael S. Tsirkin 写道: > > > > On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > > > >

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-09 Thread Heng Qi
在 2023/2/28 下午7:16, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: If the tunnel is used to encapsulate the packets, the hash calculated using the outer header of the receive packets is always fixed for the same flow packets, i.e. they will be steered to the

Re: [virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-08 Thread Heng Qi
在 2023/3/8 下午10:39, Michael S. Tsirkin 写道: On Wed, Mar 01, 2023 at 10:56:31AM +0800, Heng Qi wrote: 在 2023/2/28 下午7:16, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: If the tunnel is used to encapsulate the packets, the hash calculated using the outer

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-08 Thread Michael S. Tsirkin
On Wed, Mar 01, 2023 at 10:56:31AM +0800, Heng Qi wrote: > > > 在 2023/2/28 下午7:16, Michael S. Tsirkin 写道: > > On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > > > If the tunnel is used to encapsulate the packets, the hash calculated > > > using the outer header of the receive packets

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-02 Thread Michael S. Tsirkin
On Thu, Mar 02, 2023 at 04:59:46PM +0800, Jason Wang wrote: > On Thu, Mar 2, 2023 at 4:41 PM Michael S. Tsirkin wrote: > > > > On Thu, Mar 02, 2023 at 04:15:39PM +0800, Jason Wang wrote: > > > On Thu, Mar 2, 2023 at 4:10 PM Michael S. Tsirkin wrote: > > > > > > > > On Thu, Mar 02, 2023 at

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-02 Thread Jason Wang
On Thu, Mar 2, 2023 at 4:41 PM Michael S. Tsirkin wrote: > > On Thu, Mar 02, 2023 at 04:15:39PM +0800, Jason Wang wrote: > > On Thu, Mar 2, 2023 at 4:10 PM Michael S. Tsirkin wrote: > > > > > > On Thu, Mar 02, 2023 at 03:57:10PM +0800, Jason Wang wrote: > > > > Kernel had already used the eBPF

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-02 Thread Michael S. Tsirkin
On Thu, Mar 02, 2023 at 04:15:39PM +0800, Jason Wang wrote: > On Thu, Mar 2, 2023 at 4:10 PM Michael S. Tsirkin wrote: > > > > On Thu, Mar 02, 2023 at 03:57:10PM +0800, Jason Wang wrote: > > > Kernel had already used the eBPF program for hashing, classifying > > > various types of eBPF program

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-02 Thread Jason Wang
On Thu, Mar 2, 2023 at 4:10 PM Michael S. Tsirkin wrote: > > On Thu, Mar 02, 2023 at 03:57:10PM +0800, Jason Wang wrote: > > Kernel had already used the eBPF program for hashing, classifying > > various types of eBPF program other than XDP/socket filter > > (pass/drop). > > > > Thanks > > where

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-02 Thread Michael S. Tsirkin
On Thu, Mar 02, 2023 at 03:57:10PM +0800, Jason Wang wrote: > Kernel had already used the eBPF program for hashing, classifying > various types of eBPF program other than XDP/socket filter > (pass/drop). > > Thanks where is it used for hashing? -- MST

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-01 Thread Jason Wang
On Thu, Mar 2, 2023 at 3:42 PM Michael S. Tsirkin wrote: > > On Thu, Mar 02, 2023 at 10:57:12AM +0800, Jason Wang wrote: > > On Wed, Mar 1, 2023 at 6:36 PM Michael S. Tsirkin wrote: > > > > > > On Wed, Mar 01, 2023 at 10:36:41AM +0800, Jason Wang wrote: > > > > On Tue, Feb 28, 2023 at 7:05 PM

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-01 Thread Michael S. Tsirkin
On Thu, Mar 02, 2023 at 10:57:12AM +0800, Jason Wang wrote: > On Wed, Mar 1, 2023 at 6:36 PM Michael S. Tsirkin wrote: > > > > On Wed, Mar 01, 2023 at 10:36:41AM +0800, Jason Wang wrote: > > > On Tue, Feb 28, 2023 at 7:05 PM Michael S. Tsirkin > > > wrote: > > > > > > > > On Tue, Feb 28, 2023

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-01 Thread Jason Wang
On Wed, Mar 1, 2023 at 6:36 PM Michael S. Tsirkin wrote: > > On Wed, Mar 01, 2023 at 10:36:41AM +0800, Jason Wang wrote: > > On Tue, Feb 28, 2023 at 7:05 PM Michael S. Tsirkin wrote: > > > > > > On Tue, Feb 28, 2023 at 11:04:26AM +0800, Jason Wang wrote: > > > > On Tue, Feb 28, 2023 at 1:49 AM

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-03-01 Thread Michael S. Tsirkin
On Wed, Mar 01, 2023 at 10:36:41AM +0800, Jason Wang wrote: > On Tue, Feb 28, 2023 at 7:05 PM Michael S. Tsirkin wrote: > > > > On Tue, Feb 28, 2023 at 11:04:26AM +0800, Jason Wang wrote: > > > On Tue, Feb 28, 2023 at 1:49 AM Michael S. Tsirkin > > > wrote: > > > > > > > > On Mon, Feb 27, 2023

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-28 Thread Heng Qi
在 2023/2/28 下午7:16, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: If the tunnel is used to encapsulate the packets, the hash calculated using the outer header of the receive packets is always fixed for the same flow packets, i.e. they will be steered to the

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-28 Thread Jason Wang
On Tue, Feb 28, 2023 at 7:05 PM Michael S. Tsirkin wrote: > > On Tue, Feb 28, 2023 at 11:04:26AM +0800, Jason Wang wrote: > > On Tue, Feb 28, 2023 at 1:49 AM Michael S. Tsirkin wrote: > > > > > > On Mon, Feb 27, 2023 at 04:35:09PM +0800, Jason Wang wrote: > > > > On Mon, Feb 27, 2023 at 3:39 PM

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-28 Thread Michael S. Tsirkin
On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > If the tunnel is used to encapsulate the packets, the hash calculated > using the outer header of the receive packets is always fixed for the > same flow packets, i.e. they will be steered to the same receive queue. Wait a second. How is

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-28 Thread Michael S. Tsirkin
On Tue, Feb 28, 2023 at 11:04:26AM +0800, Jason Wang wrote: > On Tue, Feb 28, 2023 at 1:49 AM Michael S. Tsirkin wrote: > > > > On Mon, Feb 27, 2023 at 04:35:09PM +0800, Jason Wang wrote: > > > On Mon, Feb 27, 2023 at 3:39 PM Michael S. Tsirkin > > > wrote: > > > > > > > > On Mon, Feb 27, 2023

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-28 Thread Heng Qi
在 2023/2/28 下午4:52, Michael S. Tsirkin 写道: On Tue, Feb 28, 2023 at 11:04:26AM +0800, Jason Wang wrote: On Tue, Feb 28, 2023 at 1:49 AM Michael S. Tsirkin wrote: On Mon, Feb 27, 2023 at 04:35:09PM +0800, Jason Wang wrote: On Mon, Feb 27, 2023 at 3:39 PM Michael S. Tsirkin wrote: On Mon,

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-28 Thread Michael S. Tsirkin
On Tue, Feb 28, 2023 at 11:04:26AM +0800, Jason Wang wrote: > On Tue, Feb 28, 2023 at 1:49 AM Michael S. Tsirkin wrote: > > > > On Mon, Feb 27, 2023 at 04:35:09PM +0800, Jason Wang wrote: > > > On Mon, Feb 27, 2023 at 3:39 PM Michael S. Tsirkin > > > wrote: > > > > > > > > On Mon, Feb 27, 2023

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-27 Thread Jason Wang
On Tue, Feb 28, 2023 at 1:49 AM Michael S. Tsirkin wrote: > > On Mon, Feb 27, 2023 at 04:35:09PM +0800, Jason Wang wrote: > > On Mon, Feb 27, 2023 at 3:39 PM Michael S. Tsirkin wrote: > > > > > > On Mon, Feb 27, 2023 at 12:07:17PM +0800, Jason Wang wrote: > > > > Btw, this kind of 1:1 hash

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-27 Thread Michael S. Tsirkin
On Mon, Feb 27, 2023 at 04:35:09PM +0800, Jason Wang wrote: > On Mon, Feb 27, 2023 at 3:39 PM Michael S. Tsirkin wrote: > > > > On Mon, Feb 27, 2023 at 12:07:17PM +0800, Jason Wang wrote: > > > Btw, this kind of 1:1 hash features seems not scalable and flexible. > > > It requires an endless

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-27 Thread Heng Qi
在 2023/2/27 下午4:35, Jason Wang 写道: On Mon, Feb 27, 2023 at 3:39 PM Michael S. Tsirkin wrote: On Mon, Feb 27, 2023 at 12:07:17PM +0800, Jason Wang wrote: Btw, this kind of 1:1 hash features seems not scalable and flexible. It requires an endless extension on bits/fields. Modern NICs allow

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-27 Thread Jason Wang
On Mon, Feb 27, 2023 at 3:39 PM Michael S. Tsirkin wrote: > > On Mon, Feb 27, 2023 at 12:07:17PM +0800, Jason Wang wrote: > > Btw, this kind of 1:1 hash features seems not scalable and flexible. > > It requires an endless extension on bits/fields. Modern NICs allow the > > user to customize the

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-26 Thread Michael S. Tsirkin
On Mon, Feb 27, 2023 at 12:07:17PM +0800, Jason Wang wrote: > Btw, this kind of 1:1 hash features seems not scalable and flexible. > It requires an endless extension on bits/fields. Modern NICs allow the > user to customize the hash calculation, for virtio-net we can allow to > use eBPF program to

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-26 Thread Jason Wang
On Fri, Feb 24, 2023 at 4:06 PM Michael S. Tsirkin wrote: > > On Fri, Feb 24, 2023 at 10:26:30AM +0800, Jason Wang wrote: > > On Thu, Feb 23, 2023 at 9:03 PM Michael S. Tsirkin wrote: > > > > > > On Thu, Feb 23, 2023 at 10:50:48AM +0800, Jason Wang wrote: > > > > Hi: > > > > > > > > 在 2023/2/22

[virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-26 Thread Parav Pandit
> From: Michael S. Tsirkin > Sent: Friday, February 24, 2023 3:13 AM [..] > > The inner hash is only needed for GRE, IPIP etc. > > For VXLAN and NVGRE Linux kernel transmit side uses the entropy of the > source port of the outer header. > > It does that based on the inner header. > > Refer to

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-24 Thread Michael S. Tsirkin
On Fri, Feb 24, 2023 at 10:38:37PM +0800, Heng Qi wrote: > > > 在 2023/2/24 下午4:13, Michael S. Tsirkin 写道: > > On Thu, Feb 23, 2023 at 02:40:46PM +, Parav Pandit wrote: > > > > > > > From: Michael S. Tsirkin > > > > Sent: Thursday, February 23, 2023 8:14 AM > > > > > > > > On Sat, Feb 18,

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-24 Thread Heng Qi
在 2023/2/24 下午4:13, Michael S. Tsirkin 写道: On Thu, Feb 23, 2023 at 02:40:46PM +, Parav Pandit wrote: From: Michael S. Tsirkin Sent: Thursday, February 23, 2023 8:14 AM On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: So for RSS specifically, we brain-stormed with Amnon

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-24 Thread Michael S. Tsirkin
On Thu, Feb 23, 2023 at 02:40:46PM +, Parav Pandit wrote: > > > > From: Michael S. Tsirkin > > Sent: Thursday, February 23, 2023 8:14 AM > > > > On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > > > > So for RSS specifically, we brain-stormed with Amnon (Cc'd) and came up with >

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-24 Thread Michael S. Tsirkin
On Fri, Feb 24, 2023 at 10:45:13AM +0800, Jason Wang wrote: > > 在 2023/2/23 12:41, Heng Qi 写道: > > > > > > 在 2023/2/23 上午10:50, Jason Wang 写道: > > > Hi: > > > > > > 在 2023/2/22 14:46, Heng Qi 写道: > > > > Hi, Jason. Long time no see. :) > > > > > > > > 在 2023/2/22 上午11:22, Jason Wang 写道: > > >

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-24 Thread Michael S. Tsirkin
On Fri, Feb 24, 2023 at 10:26:30AM +0800, Jason Wang wrote: > On Thu, Feb 23, 2023 at 9:03 PM Michael S. Tsirkin wrote: > > > > On Thu, Feb 23, 2023 at 10:50:48AM +0800, Jason Wang wrote: > > > Hi: > > > > > > 在 2023/2/22 14:46, Heng Qi 写道: > > > > Hi, Jason. Long time no see. :) > > > > > > > >

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-24 Thread Michael S. Tsirkin
On Fri, Feb 24, 2023 at 12:42:40PM +0800, Heng Qi wrote: > > > 在 2023/2/23 下午9:13, Michael S. Tsirkin 写道: > > On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > > > +\subparagraph{Security risks between encapsulated packets and RSS} > > > +There may be potential security risks when

[virtio-dev] Re: [virtio-comment] Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-23 Thread Heng Qi
在 2023/2/24 上午10:45, Jason Wang 写道: 在 2023/2/23 12:41, Heng Qi 写道: 在 2023/2/23 上午10:50, Jason Wang 写道: Hi: 在 2023/2/22 14:46, Heng Qi 写道: Hi, Jason. Long time no see. :) 在 2023/2/22 上午11:22, Jason Wang 写道: 在 2023/2/22 01:50, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-23 Thread Heng Qi
在 2023/2/23 下午9:13, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: +\subparagraph{Security risks between encapsulated packets and RSS} +There may be potential security risks when encapsulated packets using RSS to +select queues for placement. Is this just

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-23 Thread Jason Wang
在 2023/2/23 12:41, Heng Qi 写道: 在 2023/2/23 上午10:50, Jason Wang 写道: Hi: 在 2023/2/22 14:46, Heng Qi 写道: Hi, Jason. Long time no see. :) 在 2023/2/22 上午11:22, Jason Wang 写道: 在 2023/2/22 01:50, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote:

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-23 Thread Jason Wang
On Thu, Feb 23, 2023 at 9:03 PM Michael S. Tsirkin wrote: > > On Thu, Feb 23, 2023 at 10:50:48AM +0800, Jason Wang wrote: > > Hi: > > > > 在 2023/2/22 14:46, Heng Qi 写道: > > > Hi, Jason. Long time no see. :) > > > > > > 在 2023/2/22 上午11:22, Jason Wang 写道: > > > > > > > > 在 2023/2/22 01:50, Michael

[virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-23 Thread Parav Pandit
> From: Michael S. Tsirkin > Sent: Thursday, February 23, 2023 8:14 AM > > On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > So for RSS specifically, we brain-stormed with Amnon (Cc'd) and came up with > an idea: RSS indirection table entries are 16 bit but onlu 15 bits are used to

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-23 Thread Michael S. Tsirkin
On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > +\subparagraph{Security risks between encapsulated packets and RSS} > +There may be potential security risks when encapsulated packets using RSS to > +select queues for placement. Is this just with RSS? I assume hash calculation is also

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-23 Thread Michael S. Tsirkin
On Thu, Feb 23, 2023 at 10:50:48AM +0800, Jason Wang wrote: > Hi: > > 在 2023/2/22 14:46, Heng Qi 写道: > > Hi, Jason. Long time no see. :) > > > > 在 2023/2/22 上午11:22, Jason Wang 写道: > > > > > > 在 2023/2/22 01:50, Michael S. Tsirkin 写道: > > > > On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-22 Thread Heng Qi
在 2023/2/23 上午10:50, Jason Wang 写道: Hi: 在 2023/2/22 14:46, Heng Qi 写道: Hi, Jason. Long time no see. :) 在 2023/2/22 上午11:22, Jason Wang 写道: 在 2023/2/22 01:50, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: +\subparagraph{Security risks between

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-22 Thread Jason Wang
Hi: 在 2023/2/22 14:46, Heng Qi 写道: Hi, Jason. Long time no see. :) 在 2023/2/22 上午11:22, Jason Wang 写道: 在 2023/2/22 01:50, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: +\subparagraph{Security risks between encapsulated packets and RSS} +There may be

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-22 Thread Michael S. Tsirkin
On Wed, Feb 22, 2023 at 02:46:51PM +0800, Heng Qi wrote: > Hi, Jason. Long time no see. :) > > 在 2023/2/22 上午11:22, Jason Wang 写道: > > > > 在 2023/2/22 01:50, Michael S. Tsirkin 写道: > > > On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > > > > +\subparagraph{Security risks between

Re: [virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-22 Thread Michael S. Tsirkin
On Wed, Feb 22, 2023 at 03:03:32PM +0800, Heng Qi wrote: > > > 在 2023/2/22 下午2:21, Michael S. Tsirkin 写道: > > On Wed, Feb 22, 2023 at 10:34:39AM +0800, Heng Qi wrote: > > > > The user will figure out how to mitigate when such QoS is not > > > > available. Either to run in best-effort mode or

Re: [virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Heng Qi
在 2023/2/22 下午2:21, Michael S. Tsirkin 写道: On Wed, Feb 22, 2023 at 10:34:39AM +0800, Heng Qi wrote: The user will figure out how to mitigate when such QoS is not available. Either to run in best-effort mode or mitigate differently. Yes, our cloud security and cloud network team will

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Heng Qi
Hi, Jason. Long time no see. :) 在 2023/2/22 上午11:22, Jason Wang 写道: 在 2023/2/22 01:50, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: +\subparagraph{Security risks between encapsulated packets and RSS} +There may be potential security risks when encapsulated

Re: [virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Michael S. Tsirkin
On Wed, Feb 22, 2023 at 10:34:39AM +0800, Heng Qi wrote: > > The user will figure out how to mitigate when such QoS is not available. > > Either to run in best-effort mode or mitigate differently. > > Yes, our cloud security and cloud network team will configure and use inner > hash on dpdk.

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Jason Wang
在 2023/2/22 01:50, Michael S. Tsirkin 写道: On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: +\subparagraph{Security risks between encapsulated packets and RSS} +There may be potential security risks when encapsulated packets using RSS to +select queues for placement. When a user inside

Re: [virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Heng Qi
在 2023/2/22 上午7:18, Michael S. Tsirkin 写道: On Tue, Feb 21, 2023 at 10:32:11PM +, Parav Pandit wrote: From: Michael S. Tsirkin Sent: Tuesday, February 21, 2023 4:46 PM What is this information driver can't observe? It sees all the packets after all, we are not stripping tunneling

[virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Parav Pandit
> From: Michael S. Tsirkin > Sent: Tuesday, February 21, 2023 6:18 PM > > The question of discussion was, > > Scenario: > > 1. device advertises the ability to hash on the inner packet header. > > 2. device prefers that driver enable it only when it needs to use this extra > packet parser in

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Michael S. Tsirkin
On Tue, Feb 21, 2023 at 10:32:11PM +, Parav Pandit wrote: > > > From: Michael S. Tsirkin > > Sent: Tuesday, February 21, 2023 4:46 PM > > > > What is this information driver can't observe? It sees all the packets > > after all, > > we are not stripping tunneling headers. > Just the tunnel

[virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Parav Pandit
> From: Michael S. Tsirkin > Sent: Tuesday, February 21, 2023 4:46 PM > > What is this information driver can't observe? It sees all the packets after > all, > we are not stripping tunneling headers. Just the tunnel type. If/when that tunnel header is stripped, it gets complicated where

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Michael S. Tsirkin
On Tue, Feb 21, 2023 at 09:36:06PM +, Parav Pandit wrote: > > So you are saying either live with the problem (this is best effort yes?) > Yes to best effort usage. For sure something can be done to mitigate? How about randomizing the key for example? That's in just like 1 minute of thinking.

[virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Parav Pandit
> From: Michael S. Tsirkin > Sent: Tuesday, February 21, 2023 4:24 PM > > On Tue, Feb 21, 2023 at 07:29:20PM +, Parav Pandit wrote: > > > > When a specific receive queue is shared to receive packets of > > > > multiple > > > tunnels, there is no quality of service for packets of multiple

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Michael S. Tsirkin
On Tue, Feb 21, 2023 at 07:29:20PM +, Parav Pandit wrote: > > > When a specific receive queue is shared to receive packets of multiple > > tunnels, there is no quality of service for packets of multiple tunnels. > > > > "shared to receive" is not grammatical either :) > > > "Shared by

[virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Parav Pandit
> From: Michael S. Tsirkin > Sent: Tuesday, February 21, 2023 12:06 PM > > On Tue, Feb 21, 2023 at 04:20:59AM +, Parav Pandit wrote: > > > > > From: Heng Qi > > > Sent: Saturday, February 18, 2023 9:37 AM > > > > > If the tunnel is used to encapsulate the packets, the hash > > >

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Michael S. Tsirkin
On Sat, Feb 18, 2023 at 10:37:15PM +0800, Heng Qi wrote: > +\subparagraph{Security risks between encapsulated packets and RSS} > +There may be potential security risks when encapsulated packets using RSS to > +select queues for placement. When a user inside a tunnel tries to control the >

[virtio-dev] Re: [PATCH v9] virtio-net: support inner header hash

2023-02-21 Thread Michael S. Tsirkin
On Tue, Feb 21, 2023 at 04:20:59AM +, Parav Pandit wrote: > > > From: Heng Qi > > Sent: Saturday, February 18, 2023 9:37 AM > > > If the tunnel is used to encapsulate the packets, the hash calculated using > > the > s/hash calculated/hash is calculated > > > outer header of the receive

[virtio-dev] RE: [PATCH v9] virtio-net: support inner header hash

2023-02-20 Thread Parav Pandit
> From: Heng Qi > Sent: Saturday, February 18, 2023 9:37 AM > If the tunnel is used to encapsulate the packets, the hash calculated using > the s/hash calculated/hash is calculated > outer header of the receive packets is always fixed for the same flow packets, > i.e. they will be steered to